Can't boot: "mdadm: CREATE group disk not found"

This error is generated by the initramfs script that finds and mounts the root fs.

I've experienced this message before and it turned out to be caused by updating the initramfs from a live cd.

The thing was that I had an encrypted root, and when opening the luks volume from the live cd I didn't use the same name that was in my crypttab.

So, I booted the live cd and did:

cryptsetup luksOpen /dev/md1 md1
vgchange -ay
mount /dev/vgmain/lvroot /mnt/custom
<... mount dev et. al ...>
chroot /mnt/custom
<... fix something ...>
update-initramfs -u
exit
umount /mnt/custom && vgchange -an && cryptsetup luksClose md1

The update-initramfs -u did warn about cryptsetup: WARNING: invalid line in /etc/crypttab - but at first I didn't deem it important.

After some failed attempts to boot it hit me: my crypttab had md1_crypt for the luks volume, but when I updated the initramfs it saw md1 so it went with that. From within the boot scripts md1 was not available as a luks volume.

So I booted my livecd again and corrected it:

cryptsetup luksOpen /dev/md1 md1_crypt
vgchange -ay
mount /dev/vgmain/lvroot /mnt/custom
<... mount dev et. al ...>
chroot /mnt/custom
update-initramfs -u
exit
umount /mnt/custom
vgchange -an
cryptsetup luksClose md1_crypt

I've looked through the initramfs-tools scripts, but I couldn't find the exact spot where this went wrong, so I assume it was just some weird interaction between cryptsetup, mdadm and lvm.

On another debian host I had a similar issue*, except this time without crypttools or lvm involved, and I was able to work around it by changing my mdadm.conf from /dev/md/n device paths to /dev/mdn. On this ocassion, the issue only presented itself while the array was rebuilding and not when everything was normal.

Perhaps someone more familiar with the inner workings of initramfs-tools can figure this out.

* the debian host also showed a message like incrementally starting raid arrays after a few CREATE group disk not found.


Try swapping the order of the export and source statements, so that source comes later.

According to @muru's suggestion, try using . instead of source, which is more bulletproof when encountered by various interpreters.

It seems in some cases using the tilde ~ as home alias does not work in ~/.profile. (Even though your use case might work, as suggested by @muru, again.) Anyways, it's worth remembering that the $HOME env var tends to be more bulletproof.

Your last lines then could look like this:
# "I wanted to use my GTK theme on a QT program [...]"
export QT_QPA_PLATFORMTHEME=gtk2

# include Mycroft commands
. "$HOME/.profile_mycroft"


Application launcher that lets me define shortcuts (like DragThing on OS X)

There's something like this built into Compiz (the desktop effects engine in Ubuntu). You need compizconfig-settings-manager (sudo apt-get install compizconfig-settings-manager)to edit the bindings in a nice way though.

Once installed, load it up. It's sitting in System -> Preferences. When it loads up. Click the Commands item.

In there you can specify 12 commands each with their own key, mouse-button and mouse-movement bindings.

There may well be other ways of doing this.. But if you're already running Compiz, this is fairly fast, fairly effective and fairly easy to understand when you know where to find it.


Accessing the grub2? Common methods already tried

Make sure you set both GRUB_TIMEOUT_STYLE and GRUB_TIMEOUT.

Finally, make sure you run sudo update-grub after editing Grub.

If the GRUB_TIMEOUT_STYLE option is set to menu, then GRUB will display the menu and then wait for the timeout set by GRUB_TIMEOUT.

Make a backup...

cp /etc/default/grub ~/grub.original

Edit Grub with a text editor.

gksudo gedit /etc/default/grub

Change (or add) the following option, as shown...

GRUB_TIMEOUT=10

Change (or add) the following option, as shown...

GRUB_TIMEOUT_STYLE=menu

If they are present, comment out the following (because they are deprecated)...

# GRUB_HIDDEN_TIMEOUT=<???>
# GRUB_HIDDEN_TIMEOUT_QUIET=<???>

Save the file and exit the text editor.
Update Grub...

sudo update-grub

Reboot.

Here is an example grub file, that I have tested, with these settings...

# /boot/grub/grub.cfg.
# For full documentation of the options in this file, see:
#   info -f grub -n 'Simple configuration'

# Execute 'sudo update-grub' after making changes.

GRUB_DEFAULT=0
#GRUB_HIDDEN_TIMEOUT=0
#GRUB_HIDDEN_TIMEOUT_QUIET=true
GRUB_TIMEOUT=10
GRUB_TIMEOUT_STYLE=menu
GRUB_DISTRIBUTOR=`lsb_release -i -s 2> /dev/null || echo Debian`
GRUB_CMDLINE_LINUX_DEFAULT="quiet splash"
GRUB_CMDLINE_LINUX=""

# Uncomment to enable BadRAM filtering, modify to suit your needs
# This works with Linux (no patch required) and with any kernel that obtains
# the memory map information from GRUB (GNU Mach, kernel of FreeBSD ...)
#GRUB_BADRAM="0x01234567,0xfefefefe,0x89abcdef,0xefefefef"

# Uncomment to disable graphical terminal (grub-pc only)
#GRUB_TERMINAL=console

# The resolution used on graphical terminal
# note that you can use only modes which your graphic card supports via VBE
# you can see them in real GRUB with the command `vbeinfo'
#GRUB_GFXMODE=640x480

# Uncomment if you don't want GRUB to pass "root=UUID=xxx" parameter to Linux
#GRUB_DISABLE_LINUX_UUID=true

# Uncomment to disable generation of recovery mode menu entries
#GRUB_DISABLE_RECOVERY="true"

# Uncomment to get a beep at grub start
#GRUB_INIT_TUNE="480 440 1"


Trouble Installing Ubuntu on an old PC with USB stick

go into the bios and set the boot order to allow the usb before the hard drive. also im not familiar with your choice of iso burner, i recomend blackbox iso, its free... shouldn't have to convert to .img, just burn the image straight to the flash.  another option might be to use booti on a cd, then select the usb, or cd of your choice.


Possibly the only use that I personally have for Chrome is to make a 'Netflix App' out of it.

google-chrome-stable --app=http://netflix.com

Running that, or editing the launcher for Chrome to run this command will open Google Chrome and launch the netflix website without any pesky window dressing like a location bar, buttons, tabs.....just Netflix.

Of course going full screen works too, if you aren't multitasking while watching a show or movie.


Same problem here. I thought this problem was due to the changes that I made in the secure boot settings (UEFI) in the upgrade process of my dual boot laptop (ubuntu and windows).
After browsing some forums and comments section, I finally found the solution (for my laptop at least, I dont know if this works for everybody)

Open terminal at log-in screen (ctrl+alt+F2)
after logging-in, run
sudo apt-get purge nvidia*


How to add new private key (OpenSSH) with multiple identities?

Easy as pie.

Simply go to the .ssh folder in your home and add the file config

nano /home/${USER}/.ssh/config

and add the following lines e.g.

Host duck-a-rub
HostName mail.man.com OR <IP-Address>
User rubberduck
Port 223
IdentityFile /full/path/to/keys/rubberduck_id_dsa

save the file and give it a try.

ssh duck-a-rub

HTH,
s1mmel


iptables, order of rules - do I understand it right?

You are correct.

The rules will be processed in line order of the file.
If there is a match for a rule no other rules will be processed for that IP packet in your case.

http://en.wikipedia.org/wiki/Iptables

  Each rule in a chain contains the specification of which packets it
  matches. It may also contain a target (used for extensions) or verdict
  (one of the built-in decisions). As a packet traverses a chain, each
  rule in turn is examined. If a rule does not match the packet, the
  packet is passed to the next rule. If a rule does match the packet,
  the rule takes the action indicated by the target/verdict, which may
  result in the packet being allowed to continue along the chain or it
  may not


I have this polaroid.sh-Skript:

#!/bin/bash
#
# jpg-Dateien in Vorschau umwandeln.
#
montage -size 256x256 './*jpg' \
    -thumbnail 128x128 \
    -set caption '%t' \
    -bordercolor AliceBlue \
    -background grey20 \
    -polaroid 0 \
    -set label '' \
    -background white \
    -geometry +1+1 \
    -tile 4x  $1.html && firefox ./$1.html

Maybe you can adopt some ideas. The basic command montage is in the ImageMagick package, which is easily installed:

 apt-get install ImageMagick


Best way to set up a company shared drive using Ubuntu Server?

Don't use FTP: not only is it insecure ( passwords are sent in plain text ), but it is also a pain for users to use.  Install samba and use regular windows file sharing.  To give users permission to /home/company-docs, use chmod to allow world read and optionally write access:

sudo chmod a+rw /home/company-docs


Why delete it with the Windows disk manager? You can make all your alterations with the live usb-stick's volume manager, after booting with the live usb-drive. You can even leave Windows in place then, if you like.

Just boot with the live usb-stick. See if it works, replace Ubuntu with the old one, see if it boots.

If GRUB for some reason doesn't work then, you can use the live usb-stick to boot from either the stick, the Ubuntu partition or the Windows partition.


Problems with authentification on proxy cntlm Ubuntu 18.4 server

If you are behind a proxy with CNTLM authentication, you need to properly configure CNTLM daemon.

First set the proper domain and username in the /etc/cntlm.conffile:

#
# Cntlm Authentication Proxy Configuration
#
# NOTE: all values are parsed literally, do NOT escape spaces,
# do not quote. Use 0600 perms if you use plaintext password.
#

Username      domainusername
Domain          domainname

# List of parent proxies to use. More proxies can be defined
# one per line in format <proxy_ip>:<proxy_port>
Proxy           123.123.123.123:1234

Then run cntlm -H and enter your domain password:

$ cntlm -H
Password:
PassLM          XXXXXXXXXXXXXXXXXXXXXXXXXXXXX
PassNT          XXXXXXXXXXXXXXXXXXXXXXXXXXXXX
PassNTLMv2      XXXXXXXXXXXXXXXXXXXXXXXXXXXXX    # Only for user ' domainusername ', domain ' domainname '

Add the output (from PassLM to PassNTLMv2) to the /etc/cntlm.conf file and restart the CNTLM daemon.

Then you can add export http_proxy=http://localhost:3128 to your bash configuration.


Permissions issue with sudo chown -R www-data:www-data

In order to run a script it has to be executable.

Check if it has the executable flag set by running

ls -la /var/www/owncloud/

If not then set the flag running

sudo chmod +x /var/www/owncloud/fail2ban

Also if another user than www-data shall be able to run it you could instead run

sudo chown www-data:<otherUser> /var/www/owncloud/fail2ban


Skype-bin not installable -- 'held broken packages'

After 8 hours, I finally figured this out. I'm using a Lenovo Ideapad u400.

dpkg --print-foreign-architectures
dpkg --print-architecture

If the first command does not show any output, and the second one gives "amd64" you should try the following commands

sudo dpkg --add-architecture i386
sudo apt-get update
sudo apt-get install skype


And if you want to get really hairy and avoid applications that aren't installed by default:

xkill -id `xprop -root _NET_ACTIVE_WINDOW | cut -d\# -f2`

Again, this seems to work fairly well.

NOTE: In the case of some applications (see comments) this may mean that all windows for an application are closed. gnome-terminal is one such application but terminator and xterm are not affected. I would suggest this is more a bug (maybe by design) with those applications rather than one with my command.


How to create a VPN only accessible website?

I would use something called xampp it is a full fledged web server and it has something in its httpd.conf file that you can set to only allow users connected to your network to access the server so setup VPN and use xampp and it will work out great


Moving applications from unity launcher to docky

You don't drag it.

Open the program, with the launcher.
Then the icon should appear in docky?
Right click on the icon in the dock, and chose pin to dock. Even when you close it, it will still be there.

For other things, you could create a custom .desktop file with the command xdotool key Super+S.

Then you can drag that from where you saved it to docky.


How to add files to /var/www/html/ without using the terminal?

You have to run nautilus as root.

  gksu is now depreciated so

  I believe the proper way to open nautilus as root would be to use sudo
  -i instead.

  Here's an example:

  sudo -i nautilus &

  Can not install nautilus-gksu in Ubuntu 14.04 LTS


You have to add --force-overwrite suffix on dpkg command, this will overwrite file that causing the error.

sudo dpkg -r --force-overwrite (file)

In your case, it would be

sudo dpkg -r --force-overwrite /var/cache/apt/archives/jenkins_2.19.1_all.deb

Make sure everything is fixed by running:

sudo apt-get -f install


There are various dynamic dns services, of which dyndns is probably the most well known. The repos have a few packages to automatically update your dyndns for you if your IP changes: try the `dyndns' package.


Multipass, virt-manager and bridged network

Thanks for giving Multipass a try.  In Multipass, we use Ubuntu cloud images by default, so there are a few things to be aware of.  By default, cloud images do not have a user that has an enabled password.  However, since they are cloud images, you can use cloud-init to provision your Multipass instance in many different ways.  cloud-init documentation can be found at https://cloudinit.readthedocs.io/en/latest/.  There are many examples in there for many different configurations.  Also, there is a short blog post at https://ubuntu.com/blog/using-cloud-init-with-multipass about using cloud-init with Multipass.

Regarding the networking and multipass connections to the instance, yes, we require an ssh connection and as such, we need to be able to easily discover the IP address of the instance.  The best way to use bridged networking would be to add a second interface via cloud-init and then point libvirt to this second interface for bridged networking and leave the NAT'd network intact so as multipass can connect to it.

I hope this helps and good luck!


There is a few things you can try. The error message you get is itself helpful: the directory is not mounted.

If you get this type of files CRYPTFS_FNEK_ENCRYPTED.[some code here] in fact the decryption was not succesful. That means something went wrong in the decryption process (usually the problem is related to the settings you provide in the prompt). Make sure to type the full passphrase in gedit and copy it from there. I once already spend two days figuring out what went wrong decrypting and for some reason I had a tiny mistake (O as 0) in the passphrase.

You can also give this command a try:

mount -t ecryptfs [SRC DIR] [DST DIR] -o [OPTIONS]

This will do the mounting and decrypting for you. Read more here and don't stick too close to that tutorial you mention.

BTW: Is your username the same as on the old system?


Default file hierarchy for juju created instances

This is not specified by juju; it's up to the charm authors to put things in sensible places.

In the case of wordpress, in particular, /var/www will eventually be populated... but the authors chose to delay doing so until the service has joined a relation with a database (such as mysql), because that's the first point at which they can actually serve anything useful.


You have to copy the /etc/xdg/autostart/org.gnome.Evolution-alarm-notify.desktop file to your home folder by
mkdir -p ~/.config/autostart/
cp /etc/xdg/autostart/org.gnome.Evolution-alarm-notify.desktop ~/.config/autostart/
sed -i "s/NoDisplay=true/NoDisplay=false/" ~/.config/autostart/org.gnome.Evolution-alarm-notify.desktop

and then disable its launch from gnome-session-properties (Startup Applications).
Also disable its systemd user services:
systemctl --user mask evolution-addressbook-factory.service
systemctl --user mask evolution-calendar-factory.service
systemctl --user mask evolution-source-registry.service
systemctl --user mask evolution-user-prompter.service

and then reboot.


Trouble getting logs to autorotate with logrotate

This solution here took care of everything.


CMUS Error: opening audio device: No such device

If you are using alsa as output, you need to set these:
set output_plugin=alsa
set dsp.alsa.device=default
set mixer.alsa.device=default
set mixer.alsa.channel=Master

Source: Arch Wiki


Citrix receiver client: Web interface - "You do not have the proper encryption level to access this session"

After a long break I tried it with Chrome and latest citrix receiver. To my surprise, it worked!!

I downloaded the latest Citrix receiver (version 13.6) for Linux (Released on 11th July 2017) from https://www.citrix.co.in/downloads/citrix-receiver/linux/receiver-for-linux-latest.html
and I am able to open the virtual desktop using Citrix receiver with Chrome Version 60.0.3112.78.

Note: The issue mentioned as point#2 in my question still persists with Firefox.


ALFA AWUS036NH and ALFA AWUS036ACH adapters showing weird interface name and unable to use any commands with them

Your interface name is "weird" because of the introduction of predictable interface naming. Please see: https://www.freedesktop.org/wiki/Software/systemd/PredictableNetworkInterfaceNames/ The name of your wireless interface, wlx00c0ca5a4f9d, suggests that it is a WireLess interface, that it is eXternal and the unique identifier is its MAC address. In future Ubuntu versions, your internal device will be renamed to something like wlp3s0, suggesting a WireLess PCI interface at PCI bus 03:00.0.

Taking an interface up or down is not permitted by ordinary users. If you are a privileged user, that is, if you have the sudo password, then you may do:

sudo ifconfig wlx00c0ca5a4f9d down


should I move /bin and /lib folders that's inside a program to /usr/local/?

Don't fix what ain't broken. There's no real need to move those files anywhere. (Or is there?) So, leave as it is.

If you want to do something fancy, create a deb package from it so you can easily install and uninstall.


Lm-sensors can't find fans on a Acer Laptop

Your CPU only has 4 cores, but 8 hardware threads (2 per core).

Fan control under Linux is painful. You might like to watch a video of Matthew Garrett from the last LinuxConf AU to understand more of the problems faced by developers. He's the main guy for Linux laptop support from what I understand.

Linky: http://blip.tv/linuxconfau/making-laptops-work-with-linux-4738042


This is a known bug in compiz see https://bugs.launchpad.net/ubuntu/+source/compiz/+bug/141500.

I found a workaround that works great for me on the bug page.

Create a file
Mark it as executable (Right Click > Properties > Permissions > Allow executing file as program)
Open in gedit and paste the following

#!/bin/bash

mkdir -p $HOME/.icons/default
CURSOR_THEME=$(gconftool -g /desktop/gnome/peripherals/mouse/cursor_theme)
echo "[Icon Theme]
Inherits = $CURSOR_THEME" > $HOME/.icons/default/index.theme
echo "Compiz will be restarted to enable this. Please stand by."
compiz --replace &

Then Just run that file every time you change your mouse theme.


Apt "could not find a distribution template" error

Easy to fix
Just do this

gksudo gedit /etc/lsb-release

Then edit the file that opens so that it looks like this

DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=10.04
DISTRIB_CODENAME=karmic
DISTRIB_DESCRIPTION="Ubuntu Karmic Koala"

Remember to enter which version of ubuntu you are using.
I am using karmic koala so I put that in.

You can get a list here towards the bottom
http://en.wikipedia.org/wiki/Ubuntu_%28operating_system%29

Then go back to the terminal after you have saved the lsb-release file and you should be able to add-apt-repository


Msdos file system should be fine. Black screen suggests the USB is not bootable, although on many computers the BIOS would at least tell you that it can't find an OS, rather than just show you a flashing cursor. How did you make the USB?
If you need a software to make the bootable USB, you have several choices. All of the below will let you create an Ubuntu Live USB, or a wide variety of other distros or rescue disks.
Cross-platform
UNetbootin is very easy to use. Let's you install a single OS.
Linux Only
I really like LiveUSB MultiBoot. It's a little more complex, but it lets you install several OSes on one USB key. The GUI is not great, and the download site is in French, but if you know what you're doing, it's very powerful.
Windows Only
I haven't used this before, but LinuxLive USB Creator doesn't look too bad (judging from screenshots and information on the website).


Ubuntu install on nexus 7 hangs on Noting disapperance of ubiquity

I had exactly the same issue. I got round it by installing the image from this link:

last-good-image

I had to use an OTG cable and USB keyboard to do the installation (if I tried to configure the wifi then the keyboard stopped functioning - so I installed without specifying the wifi).

Once booted I found I could not apt-get update, the work around was to type:

cd /var/lib/apt
sudo rm -fr lists
sudo mkdir lists
sudo mkdir lists/partial

Then I could apt-get update and upgrade.

I hope this helps!

/Simon


Lubuntu 17.04 - Multiple displays not recognized [HDMI]

I resolved this.

I plugged the HDMI into my TV and it worked automatically.  Then I unplugged it and plugged it back to the original monitor that it was not recognizing and now it works.


Missing icons from system settings KDE 15.04

I have the same problem, I not use ppa from kubuntu but I use UbuntuStudio 15.04 and have the same problem, I only can make appear one icon, installing this package(the package systemsettings must be installed):

kde-config-gtk-style

see this picture (the other icons are missing):

Note: You can open from terminal with:

systemsettings5

I do not find the way to make appear the other icons, I need to configure the search option in dolphin file manager that not working because I use dolphin under UbuntuStudio 15.04, and I use kdenlive that have fonts very small, see:

At the momento I found a solution for the fonts on dolphin that is install this package:

qt4-qtconf

see this picture:

This run from terminal with:

qtconfig-qt4

or from system config UbuntuStudio

Only I don't understant why not working on kdenlive, there must be some missing package to install that I don't know what is (on UbntuStudio 14.04 this problem there is no)


Dual boot windows 8 and Ubuntu with Windows 8 Boot manager

I just did it in VMPlayer using EasyBCD 2.2. What I did

I installed windows 8 normally using a 20GB parition. Windows also created a system reserved partition.

Boot with ubuntu, created two partition. One for SWAP and one for /.
Most important, choose the GRUB location same as the / partition. See pic below (I think I took wrong screenshot, bootloader location should be sda6 in picture),

Now after installation, open up EasyBCD. Goto Add new menu entry, select Linux tab, choose GRUB2 from dropdown and the disk name where we put the GRUb in step 2. Click on Add Entry

Goto BCD deployment, and write MBR

Now boot and you should get the screen. I restarted several times, every time I got the GUI boot screen. And ubuntu works also.(I forget to change the name step3)


Sudo: sessions still open not unmounting

Adapting one of my previous answers, get the file from the sudo package:

apt-get download sudo
dpkg-deb --fsys-tarfile sudo_*.deb | pkexec tar -xC / ./etc/ssh/ssh_config

Use pkexec instead of sudo when you need root permissions and sudo doesn't work.


Why are Abiword documents flickering since the upgrade to Lubuntu 16?

My workaround is:

Menu > Preferences > Customize Look and Feel

Change the Widget theme to anything BUT Lubuntu


11.10 and previous versions
Lubuntu uses the same base as Ubuntu, so once you install the Ubuntu One client, everything should be fine. Note though that you will not get the same level of integration with PCManFM that you do with Nautilus.
The best UbuntuOne client package to install is ubuntuone-client-gtk. You can install this in the Synaptic Package Manager (present by default on Lubuntu systems), in the Software Center (if you have that installed), or in the LXTerminal by running sudo apt-get update followed by sudo apt-get install ubuntuone-client-gtk.


I'm having the same problem with minicom. AFAICT there is no way to tell minicom that you don't want to connect to a modem. It just sends a bunch of modem commands to your linux box serial console and sometime locks it up.


How can I get multi-threaded sound back again?

This sounds* like you've removed or have otherwise broken or hobbled PulseAudio and things are connecting directly to ALSA. To work out what's going on, I would:

Stop X via sudo stop lightdm.
Check htop to make sure any graphical applications aren't lurking.
Attempt to run killall pulseaudio && pulseaudio This should run PA in the foreground so you can see any debugging output. If you see any errors at this point, that's where you go from... Be that reinstalling pulseaudio (if it's missing) or spotting the configuration errors.
If the above works without error, run sudo start lightdm in another TTY and play some audio from multiple places. This should all work. Assuming it all does, there's a problem in the way that PulseAudio is being loaded on normal boot. I'm ashamed to admit I don't know where PA is loaded from. Anwsers on a post card.

Past that it's anybody's guess but I'm fairly sure PulseAudio is crashing on boot or isn't being loaded.

* The pun wasn't originally intended but what the heck.


There is a, still running, 2012 PulseAudio bug:
"bluetooth audio out of sync when connection temporarily drops"

In a nutshell anytime there is a drop in the connection quality, audio packets accumulate in the buffer, causing a delay.
Connection quality drop can happen very easily, passing your hand in front of the receiver might cause it.
In my case this problem also cause a computer crash after a few repetitions.

However if, instead of using high quality audio A2DP sink, I use "HSP/HFP", when connection quality drop I get a very bad, speaking in a tin box-like sound, but no delay is building. Like audio packets are dropped instead of being hogged.

However the audio quality of "HSP/HFS" is very poor and is only suitable for "one speaker at a time"-like audio.

It seems to me some, at least, of the similar questions you gathered, are related to this PulseAudio Buffering Issue (buffering is legitimate, but what is to be done when connection quality drop; and is it actually legitimate in a real time setting?).

Anyway, IMO the only solution is to wait for a proper solution to this issue. Even though it's opened since 2012.


Method 1: Change your GTK+ theme

Follow the steps below.

Install (GNOME) Tweak Tool and Ambience theme (if not installed already) by running

sudo apt install gnome-tweak-tool light-themes

Open Tweak Tool and go to  Appearance. Select "Ambiance" for application theme (or GTK+ theme).

Launch Terminal and go to Edit > Profile Preferences > Colours (tab) (or something similar) and check the "Use colours from system theme" option.

Note: Ambiance is a global GTK+ theme, so it would make (almost) all the applications look "Unity-like", not just the Terminal.

Method 2: Change Terminal's colour profile

If you just want to change the colour of Terminal's background and font without changing your GTK+ theme, you may tweak Terminal's colour profile manually.

First load Terminal with Ambiance theme as suggested above and get hex codes of all the colours using some colour-picker application like gpick. You may install gpick by

sudo apt install gpick

Then switch to your preferred GTK+ theme (application theme), in Terminal's Profile Preferences uncheck the "Use colours from system theme" option and manually create a colour profile using the collected hex codes.

  Hex codes for Unity Terminal

  #300A24 - Background (Purple)
  #FEF8D9 - Text Colour (White)

  (courtesy of Rahul)

  With the Hex codes provided above terminal looks something like this:

  (screenshot courtesy of Rahul)


Trying to get a Third Monitor to work on Kubuntu 16.10

Is KDE and X the same? If they are different which starts first?

They are not the same, X starts first.

This Thursday a new Kubuntu version will be released, with improvements in multi-monitor management.

If I were you, I would try your setup with the new version.


In your browser open 'Gnome Shell Extensions'.
Select 'Installed extensions' and open 'Night Light Slider' configuration.
Turn off 'Enable always'.


Ubuntu can't mount / format formerly TrueCrypt encrypted SD card which works on Windows 8

You can try zeroing the card out. This can easily be done with dd command.

sudo dd if=/dev/zero of=/dev/mmcblk0 bs=1M

This will write zeros to all memory cells inside the card making it completely blank.


libqt4-dbus 4:4.8.1-0ubuntu4.4 installation complaining about wrong version it relies on

solved the problem today. I had to install the libqt4-dbus:amd64 package to get the normal libqt4-dbus package to update. Found it out when i tried to force install the libqt4-dbus:i386 package.

emarnau@eld1256hzj-l7:~/Downloads$ sudo dpkg -i libqt4-dbus_4.8.1-0ubuntu4.4_i386.deb
(Reading database ... 219816 files and directories currently installed.)
Preparing to replace libqt4-dbus:i386 4:4.8.1-0ubuntu4.4 (using libqt4-dbus_4.8.1-0ubuntu4.4_i386.deb) ...
Unpacking replacement libqt4-dbus:i386 ...
dpkg: error processing libqt4-dbus:i386 (--install):
 libqt4-dbus:i386 4:4.8.1-0ubuntu4.4 cannot be configured because libqt4-dbus:amd64 is in a different version (4:4.8.1-0ubuntu4.3)

emarnau@eld1256hzj-l7:~/Downloads$ sudo dpkg -i libqt4-dbus_4.8.1-0ubuntu4.4_amd64.deb
(Reading database ... 219816 files and directories currently installed.)
Preparing to replace libqt4-dbus 4:4.8.1-0ubuntu4.3 (using libqt4-dbus_4.8.1-0ubuntu4.4_amd64.deb) ...
Unpacking replacement libqt4-dbus ...
Setting up libqt4-dbus (4:4.8.1-0ubuntu4.4) ...
Processing triggers for libc-bin ...
ldconfig deferred processing now taking place

ii  libqt4-dbus                             4:4.8.1-0ubuntu4.4                       Qt 4 D-Bus module
ii  libqt4-dbus:i386                        4:4.8.1-0ubuntu4.4                       Qt 4 D-Bus module

Odd that the apt could not figure this out. Maybe because i386 package is always installed before the amd 64 package. if it was the other way around it would of fixed it.


I had the same problem, and after a lot of googling around in vain I finally managed to discover a solution.
The following solution works both when the English keyboard is selected, and when the Greek keyboard is selected. (Or any other keyboard for that matter, I suppose.)
Open "Tweaks" (aka "Gnome Tweaks") go to Keyboard & Mouse > Additional Layout Options > Key to choose the 3rd level and put a check mark on Right Alt never chooses 3rd level.

If you want to be able to achieve the same thing via the command line:
The corresponding dconf setting is /org/gnome/desktop/input-sources/xkb-options, the value 'lv3:ralt_alt' must be included in the array of values for that key.
After setting the value of this key, the tweak tool then causes the setxkbmap command to be invoked, with some parameters that actually do the trick on the fly, but I have not been able to figure out what those parameters are, so my guess is that if you only do dconf then you will need to restart your login session for the changes to take effect.
<rant-mode>
I suppose the problem here is that Ubuntu is a) trying to offer an impossibly oversimplified interface which yields an unusable computer out of the box, so you absolutely have to resort to things like the "Gnome Tweaks" tool, and b) this tool is offering so many incredibly arcane and entirely useless options, that the one little option that actually matters is hidden in the noise.
</rant-mode>


What should I do after a ClamAV Scan found 2 virus-infected files on my computer?

Stay calm
Delete the files if you can
Put the files in quarantine if you cannot delete them

Once they are in quarantine, they cannot "break out" especially if they're Windows executables that cannot infect your Ubuntu installation (provided you don't have wine installed)

That's it!  Well done! :-)


Why is Mysql Workbench refusing to accept the original root in Ubuntu 20.04?

By default root is configured with unix_socket authentication. Basically speaking if a database user (in this case root) is configured this way it does NOT use a password. The only way to logon is if you are that same unix/linux user.
So your mysql workbench is not running as root so therefore it's not possible for it to login as the root database user. By changing the authentication method to password authentication you solved your problem but possibly made the database more insecure.
Often the root database user would remain as unix_socket authentication for security reasons and you would just create whatever other database users with whatever permissions are required.
Here is a good article on the subject:
https://mariadb.com/kb/en/authentication-plugin-unix-socket/


How to know what is the model of my wireless card?

To find the model of your wireless card:

lspci -nn | grep 0280

The pipe symbol | is on the right side of my keyboard on the same key with backslash. We added -nn because we want numerical details, particularly the pci.id, that may help diagnose a problem. 0280 is the class used by lspci for wireless devices: for example:

03:00.0 Network controller [0280]: Intel Corporation PRO/Wireless 3945ABG [Golan] Network Connection [8086:4227] (rev 02)

Are you looking for just Atheros with all other details removed?


How to change the screen resolution for the GDM login screen?

On newer systems, you will want to place your monitors.xml file into the gdm configuration directory, the resolution will be picked up there:

This, of course, assumes that you have gon into Settings > Displays, and have selected the resolution you want, click 'Apply', this will create a monitors.xml in .config of your home dir.

sudo cp ~/.config/monitors.xml /var/lib/gdm3/.config/monitors.xml

More details available at
https://wiki.archlinux.org/index.php/GDM#Setup_default_monitor_settings


By changing the settings in gedit solved the problem.

    Edit menu --> Preferences --> Editor --> Tab Stops

and uncheck

    insert spaces instead of tab


Yes it can be reinstalled, however, you were originally trying to get rid of that software so lets not fix this problem by settling for a problem that's not as bad. Here's how to fix the problem by installing the desktop of your choice so you can enjoy your operating system once again.

First, power up your computer and when everything seems to be booted up, press CTRL + ALT + F2 . Doing this will take you to a login screen in a text only session with no desktop. Enter your username and then your password to sign in.

After you sign in, type the following command to update your package list before installing any packages.

sudo apt-get update

Now, If you want the standard Ubuntu desktop with the Standard Unity interface, type the following command:

sudo apt-get install ubuntu-desktop

To install Gnome-Shell instead of Unity, type:

sudo apt-get install gnome gnome-shell

To install the Xubuntu desktop type:

sudo apt-get install xubuntu-desktop

To install Ubuntustudio, type:

sudo apt-get install ubuntustudio-desktop

For the Lubuntu desktop, type:

sudo apt-get install lubuntu-desktop

& for Kubuntu, type:

sudo apt-get install kubuntu-desktop

when your desired desktop is installed type this command to reboot

sudo reboot


gpg: keyblock resource ‘/etc/apt/trusted.gpg.d//webupd8team-sublime-text-3.gpg’: resource limit

If you pre-install the webupd8 team's y-ppa-manager your life is going to be easier

sudo add-apt-repository ppa:webupd8team/y-ppa-manager
sudo update && sudo apt-get install y-ppa-manager

You can then remove or backup the existing gpg's by executing:

sudo rm /etc/apt/trusted.gpg.d/*
sudo apt-get update

Now you will see something like this :

W: GPG error: http://ppa.launchpad.net wily InRelease: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY C2518248EEA14886
W: GPG error: http://ppa.launchpad.net wily InRelease: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY C2518248EEA14886
W: GPG error: http://ppa.launchpad.net wily InRelease: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY C2518248EEA14886
W: GPG error: http://ppa.launchpad.net vivid InRelease: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY C2518248EEA14886

This means that you will have to re-import all keys ...

Now launch the y-ppa-manager application

Click on Advanced
Select Try to import all missing GPG keys

BAM! You should be back in business with all your repos working correctly!


Brightness fn keys not working new HP gaming laptop

I own the same model laptop and also experience this issue. Nothing seemed to work ..

Today I installed Ubuntu 19.04 to a USB stick and the function keys for the brightness worked out of the box! However, when I upgraded my Ubuntu 18.04 to 19.04 it did not work, neither did installing a 'clean' 19.04 over my upgraded version.

Since my clean USB installation of 19.04 did work you might want to give that a shot.

Edit: Seems to be working on my upgraded version as well now.


I may have found the answer after some lurking in IRC for a while.

SUBSYSTEM:block
DEVTYPE:disk

Here's how I found it. it was suggested this command:

sudo udevadm info --root  --name=/dev/sdX

Here 'X' in sdX must be replaced by the device that represents your USB mass storage device. If you need  to find that out, go to /dev and enter ls, once with the device connected to your machine and once without. Find the missing sdX and voila!

This also shows properties such as ID_FS_TYPE, ID_BUS ,etc...
However I'm not too sure about the DEVTYPE of USB mass storage devices. There's a chance it could be partition. If anyone knows, please comment or add an answer!


Is there a way to run Azure Storage Emulator on Ubuntu?

There is no Azure Storage emulator for Linux and there will be none according to Microsoft response on this customer feedback.

They advise, however, using open-source alternative like Azurite.


You have to edit the firefox.desktop file, that you can find in /usr/share/applications/. Run this command:

sudo nano /usr/share/applications/firefox.desktop

and edit the entry Icon like this:

Icon=/path/to/your/icon/your-icon.png

To search in nano use this shortcut Ctrl+W and type the string "Icon".


network-manager-sstp plugin not working on Ubuntu 17.10

I think you're missing the package network-manager-sstp-gnome.
Here's what I did to make it work:
There's a PPA that provides precompiled packages for the necessary software. I added that with:

$ sudo add-apt-repository ppa:eivnaes/network-manager-sstp
...
$ sudo apt-get update

Then I installed the 3 packages like so:

$ sudo apt-get install sstp-client network-manager-sstp network-manager-sstp-gnome

I then rebooted but it should do to restart the network-manager service:

$ sudo service network-manager restart

After that you should be able to choose the SSTP option in the dialog where you can add a new connection. You can open that dialog with the command

$ nm-connection-editor

And then click the button that reads "Add".


According to already answered question :

How to force Wine into acting like 32-bit Windows on 64-bit Ubuntu?

you can  switch between  32 and 64-bit windows by changing  WINEARCH environment variable.


Take a look at this thread WiFi randomly disconnected on Ubuntu 18.04 LTS you may help you. If it doesn’t try using an Ethernet cable and seeing if it works. If your wifi is 5ghz and going through walls or other insulators it will be weaker than 2.4ghz would because it has larger wave lengths. But this may not help you so if these fail wait for someone else to reply.


For Gtk.Grid, you should be calling it's attach method, not add.  Also you need to call show() on your button before it will be visible.


Yes and no.

There is no official support in dpkg's libraries at this point. There is however a patch you can try to use.

Replacing the libraries is not an option because they are not binary compatible. A wrapper library would be needed.


Error :: You must put some 'source' URIs in your sources.list

software-properties-gtk option "Source code"
I recommend this for the desktop:
software-properties-gtk

then under the "Ubuntu Software" tab click "Source code":

This has added some deb-src lines under /etc/apt/sources.list, and now I can do sudo apt-get build-dep <package>.
I've couldn't find a clean CLI method so I create this bug report for it: https://bugs.launchpad.net/ubuntu/+source/apt/+bug/1802718
Tested on Ubuntu 16.04 to 18.04.
CLI method
I recommend this for Docker images:
sudo cp /etc/apt/sources.list /etc/apt/sources.list~
sudo sed -Ei 's/^# deb-src /deb-src /' /etc/apt/sources.list
sudo apt-get update

Tested on the Ubuntu 18.04 Docker image. After this change, I can successfully do for example:
sudo apt-get build-dep hello

and before the change it failed with the error:
E: You must put some 'source' URIs in your sources.list

Previously mentioned at: https://askubuntu.com/a/1011675/52975 go and upvote that answer.
Note however that the /etc/apt/sources.list file contains lines such as:
# deb http://archive.canonical.com/ubuntu bionic partner
# deb-src http://archive.canonical.com/ubuntu bionic partner

which means that the above sed would enable sources but not non-sources for some types of repos. I don't think that it  matters much though.


installing Ubuntu on an older laptop gives me an error message

First

At boot time, try to press F6 and add one, two or these 3 commands: acpi=off noapic noalpic

That is:
acpi=off noapic noalpic, or
acpi=off noalpic, or
acpi=off noapic, or
noapic noalpic, or
acpi=off, or
noapic, or
noalpic

Second

After the installation has completed, you will have to edit grub to add the command needed.

As pointed by fossfreedom:

"
To edit Grub2 during the boot process try the following:

Immediately after the BIOS splash screen during boot, press and hold the SHIFT button.  This will display you grub containing a list of kernels and recovery options

Press e to edit the first kernel displayed

Find the line ending with "quiet splash".  Add your boot option before these key words - i.e. so the line looks like ..."acpi=off noapic noalpic quiet splash"
Press CTRL + X to boot

"

Third

After successfully booting in your system, you can edit grub to turn the options permanent.

Paste on a terminal gksudo leafpad /etc/default/grub

Look for GRUB_CMDLINE_LINUX_DEFAULT="quiet splash" and change it for something like GRUB_CMDLINE_LINUX_DEFAULT="acpi=off noapic noalpic quiet splash".  Save and close.

Finally run sudo update-grub.

Enjoy ;-)


How can I access Ubuntu Server using MySQL Workbench and FileZilla?

For filezilla, you need to setup an FTP server. https://help.ubuntu.com/12.04/serverguide/ftp-server.html It will allow you to connect to your instance by using port 21. IP:21. But warning, FTP alone can be a security issue, especially if this server is accessible by external IP.

As for MySQL Workbench http://dev.mysql.com/doc/workbench/en/wb-new-server-instance-wizard.html It looks like it relies on ssh connection. So you'll need to setup an ssh server on that machine as well. https://help.ubuntu.com/11.04/serverguide/openssh-server.html I think you might need to run " /etc/init.d/mysql status" like the first contributor mentioned. SSH might not be enough.

I don't know if mysql is already setup on that server but take a look at this as well
https://help.ubuntu.com/11.04/serverguide/mysql.html


Try:

steam 2>&1 > /dev/null &

2>&1 redirects stderr to stdin, and > /dev/null redirects stdin to /dev/null.

The & to background the process was misplaced. It must go at the end of the line. If placed after steam but before >, nothing from steam will be redirected, though the process will properly background.


How can I disable the SPAM notification from a known contact in Thunderbird?

If you are talking about the classification that Thunderbird itself does, there's a way. Go to your account settings, there go to "Junk-Filter" (I'm retranslating from German here, so I'm not 100% sure about the wording). There you should find something like "Don't mark messages as junk automatically, if the sender is in one of the following address books". There you can choose one or more address books. If somebody from those address books sends you an e-mail, Thunderbird automatically categorizes it as ham (no spam).

If, on the other hand, you are talking about the markings in the mail subject that some server-side tools like SpamAssassin set ("**SPAM** the original subject of the mail"), it's a different case. In that case you'd have to talk to your mail provider, if and how you can whitelist sender addresses.


List of addons/extensions for gnome-shell

alternative-status-menu

For those who want a power off item visible at all the time.


How would I create startup and logoff music for Ubuntu 13.04?

If You just want to have Your .mp3 played after logging in the easiest way is probably to put line like this to You 'Startup Applications' (you can find it in Bash).

mplayer <exact address to Your file - for example: /home/tom/Music/Good.mp3>

But before that You will need to have mplayer installed. To do so type this in the terminal:

sudo apt-get install mplayer

. If You would like to have few .mp3 files played one after another You will probably need to create .sh file with lines similar to this presented before, make it executable and put exact path to this .sh file to 'Sturtup Applications'.

More info about mplayer here: http://docs.slackware.com/howtos:software:mplayer .

I've noticed that with MPlayer You can easily use playlists. To do that just create text file and in every new line paste a path to Your .mp3 file. Example below - let's say it's /home/tom/Music/StartupPlaylist.txt.

/home/tom/Music/Good.mp3
/home/tom/Music/EpicMusic/Just Another Epic Track.mp3
/home/tom/Desktop/Sounds of Desktop.mp3

After doing that Your one-line-script should look similar to this below.

mplayer -playlist <exact path to Your playlist file - for example: /home/tom/Music/StartupPlaylist.txt>


Problem with libgstreamer0.10 when trying to install some software

There's no libgstapp.0.10.so.0 in Ubuntu but there's libgstapp-0.10.so.0 (note the dash instead of the dot) in the package libgstreamer-plugins-base0.10-0.

If this is no typo (like your other typos in the package names in your question) and your application really needs libgstapp.0.10.so.0 that's a hint that it's not meant to work with Ubuntu or other Debian-based Linux distributions. You can try to work around that with a symbolic link and additional library search path:

cd /path/to/your/application
ln -s "/usr/lib/$(uname -m)-linux-gnu/libgstapp-0.10.so.0" libgstapp.0.10.so.0
LD_LIBRARY_PATH="$PWD" ./application-executable


How to edit the core dump pattern without disabling apport?

You can edit the apport python file to do this.
Changing the location of the core is straight forward:
instead of

core_path = os.path.join(cwd, 'core')

you can put

core_path = os.path.join('my_custom_path, 'core)

the name can also be changed in a similar manner i.e.
from:

core_path += '.' + str(pid)

to

core_path += '.' + str(my_custom_name) + '.' + str(pid)

note that if you want to add the binary name to the core file, you will have to pass it to apport using the core_pattern
i.e something like

|/usr/share/apport/apport %p %s %c %d %P %e

Notice the %e above which passes the executable name to the apport script

Remember to restart the apport service after making a change in the script


In your control panel, under network options you can connect and disconnect from networks. Just reconnect using that, you are essentially doing the same thing with your reboots.

Step #1:
http://mytestingsite.djun.net/storage/askubuntu_com_windows_xp_enable_disable_network_connection_1.PNG

Step #2:
http://mytestingsite.djun.net/storage/askubuntu_com_windows_xp_enable_disable_network_connection_2.PNG

Step #3:
http://mytestingsite.djun.net/storage/askubuntu_com_windows_xp_enable_disable_network_connection_3.PNG

Step #4:
http://mytestingsite.djun.net/storage/askubuntu_com_windows_xp_enable_disable_network_connection_4.PNG

The repair feature is also an invaluable feature. :)


Does ubuntu ever clear ~/.cache automatically?

Short answer: no.
It is your cache, so no specific global system process will interfere with it. File manager thumbnails, alt least in the default Ubuntu desktop, will be automatically deleted if they are more than 180 days around (as set by org.gnome.desktop.thumbnail-cache maximum-age) or when the cache exceeds 512 megabytes (as set by org.gnome.desktop.thumbnail-cache maximum-size). How other items in the cache are maintained or handled depends on the application maintaining the cache.


High cpu load in Chrome with Moonlight plugin on Ubuntu

Try to use Mozilla Firefox instead of Google Chrome or Chromium, for some reason Google Chrome and Chromium use 100% of my CPU too, so I switched to Mozilla Firefox and now every find is going great. And Google Chrome and Chromium also "eat" a big part of my RAM memory to run.


Try projectM which works for any PulseAudio app.

If it helps, Amarok has a plugin for it, as does Quod Libet now (which I wrote).


How do you rename files ignoring file extension in terminal?

Quick answer:

You can't do that since extensions are part of filename.

Long answer:

You can use a graphical interface to do advanced renames as purrr or gprename

BUT!

In your batch renaming script you can use the following techniques of filename splitting:

FULLFILENAME="/home/user/video/myvideo-release.xvid.128kbps.avi"
DIRNAME=$(dirname ${FULLFILENAME})   #-- /home/user/video
BASENAME=$(basename ${FULLFILENAME}) #-- myvideo-release.xvid.128kbps.avi
FILENAME=${BASENAME%.*}              #-- myvideo-release.xvid.128kbps
EXTENSION=${BASENAME##*.}            #-- avi


Can I install Ubuntu on a separate SSD, AFTER having encrypted my Windows 8 drive using Truecrypt, without messing up the bootloader?

This is relatively simple. Following @hmayag advice will insure you don't accidentally overwrite the MBR on your Windows 8 drive. Install Ubuntu to your SSD and install grub to the MBR of the SSD. You will end up with 2 bootable systems after reinstalling your Windows 8 drive. (Both drives will have an active MBR) You can choose which to boot from through the BIOS, but I would set the boot order to the SSD as the first drive and reinstall grub2 as outlined here so that you can choose either system at boot time without adjusting boot order in the BIOS.

You can do this by making the right choices during installation as well and skip removing the Windows 8 drive but be absolutely certain that you install grub to the other drive (the "fresh SSD")


Windows jutter from place to place in classic desktop with ATI driver

Most likely it's related to the "Sync to VBlank"
First - make sure you have CCSM installed. If not, then from a terminal type
 sudo apt-get install compizconfig-settings-manager

Second - After it's done installing, click on the Unity launcher button in the top left and type ccsm and then hit enter

Third - With CCSM open, in the General area, click on OpenGL and UNCHECK the "Sync to VBlank"

Fourth - Click on Back at the bottom to go back to the main ccsm menu, then click on Composite and UNCHECK Detect Refresh Rate and drag the Refresh Rate slider all the way to 200


I'm not 100% certain I understand what happened, but it sounds like your bootloader is messed up.  The partition you chose to use as swap would have had its data erased and been reformatted as a Linux swap partition.  Since you haven't managed to boot the system since it's probably recoverable if it was important.

The simple way to fix it is probably to reinstall Ubuntu.  That should also reinstall GRUB.  You'll want to choose for your swap partition one that is not in use for anything else.  Depending on your machine you may be able to get away without one, or to use swapfiles, but that's a different discussion.

If that fails, http://www.supergrubdisk.org/ has a neat utility disk which should let you restore the Windows bootloader without having to reinstall Windows.


I can't get my AMD APU to use the propriety drivers, is there anyway to fix this?

Press Alt+F2
run gksu jockey-gtk. This will search for the drivers required for your AMD APU.

If the above doesn't work, open a terminal. Issue following,

sudo apt-get update
sudo apt-get install fglrx


There is a program that was developed that does just this, titled GOPreload, but it is not available in the official repos or any Ubuntu PPA. If you are interested, you can find the source code for it here.


Windows USB drive from ubuntu failing repeteadly

You got a /bin/mount: Permission denied mount_source_filesystem: Error: Unable to mount source media Error: Unable to mount source filesystem error. Connect the woe-usb:removable-media plug to the woe-usb:removable-media slot in order to enable USB devices to be mounted automatically by WoeUSB.

Search for woeusb in Ubuntu Software and click it to go to the woe-usb screen.
Click the Permissions button.
Toggle the Read/Write files on removeable storage devices slider from OFF to ON as shown in the below screenshot.
Authenticate with your user password when the Authentication Required window pops up.


Stop microsoft teams from automaticaly booting up

Find the Startup Applications control with the Dashboard.

Click on the button to the right labeled Remove.
See if that works for you.


import mini DV films from Samsung digital cam VP-D353 [USB]

With great exception of some Panasonic miniDV camcorders most miniDV cameras support download of the still images via usb and video via firewire. However even in those cameras where the support of video download and its quality is similar using both protocols the usb2 mode can be used with a special driver mostly available for Windows XP. This implies big problems in Windows Vista, Windows 7, MacOSX, and obviously, and especially in Linux to use this capability. Even finding so-called updated drivers for Windows Vista does not help much since those drivers still work with old video editing software which is only working unfortunately in Windows XP 32 bit and is mostly incompatible with newer Windows versions.


Installing Windows using mkusb 12.5.7

Install mkusb: Can I install mkusb in Ubuntu live USB?

Click mkusb-plug icon to start and then proceed as follows:

Step 1

Step 2

Step 3
[]4]
Step 4

Step 5

Step 6

Step 7

Step 8
You should now have a USB installer ready to infect your computer with Windows


Super key combinations for media keys don't work

This is a known bug https://bugs.launchpad.net/ubuntu/+source/gnome-control-center/+bug/951805


How to copy files containing a specific phrase to another directory?

find and grep:

find /dir/ -type f -name 'log*.csv' -exec grep -q 'xyz' {} \; -exec mv -t /target/ {} \;

find /dir/ -type f -name 'log*.csv' finds all log<anything>.csv files inside directory /dir
-exec grep -q 'xyz' {} \; runs grep on each found file to match for Regex pattern xyz
-exec mv -t /target/ {} \; moves the matched files (based on exit status of grep; success (0) means matched) from previous step into target directory /target


no desktop: signon-ui segfault in libqxcb.so

Well, I took the sledgehammer approach and upgraded to 16.04 LTS.
Everything runs as expected.
Bummer I couldn't find out what the cause was.


sounds play through both speakers of the laptop and headphone

Open a terminal (by Ctrl+Alt+T).
Execute alsamixer.
Find the Auto-Mute option and make sure it's enabled.


I was experiencing the same problem and TLP kind of helped reducing its amplitude (but my laptop still overheats from time to time... Guess things aren't that stable on 13.04 yet).

Here's how to install tlp:

sudo add-apt-repository ppa:linrunner/tlp
sudo apt-get update
sudo apt-get install tlp tlp-rdw

And then just launch it (once, it's supposed to launch at startup after that):

sudo tlp start

More information about tlp on webupd8.

EDIT:

More info on how to configure tlp on this answer from this AskUbuntu answer.


The option to select the type of OS is just so that VirtualBox can determine the default settings necessary for the guest OS, and hence selecting Ubuntu on the menu will suffice.

Open VirtualBox and click on New.
Choose your guest OS and architecture (32bit and Ubuntu in your case)
Set your Base Memory (RAM)
Click next to get to the VM Storage Size. Input the size you require and click on "Create"
On the VirtualBox main window, select "start" and pick your install media. In this case, select the ISO of Lubuntu 18.04 that you've downloaded
Finish the installation as usual
Unmount the ISO after you're done

You can additionally install Guest Additions as mentioned here.


default location of postgresql when installing through apt-get

In the Filesystem Hierarchy Standard, `/var/lib/ is stated as (in italic the most important part):

  5.8.1 Purpose

  This hierarchy holds state information pertaining to an application or
  the system. State information is data that programs modify while they
  run, and that pertains to one specific host. Users must never need to
  modify files in /var/lib to configure a package's operation.

  State information is generally used to preserve the condition of an
  application (or a group of inter-related applications) between
  invocations and between different instances of the same application.
  State information should generally remain valid after a reboot, should
  not be logging output, and should not be spooled data.

  An application (or a group of inter-related applications) must use a
  subdirectory of /var/lib for its data. There is one
  required subdirectory, /var/lib/misc, which is intended for state
  files that don't need a subdirectory; the other subdirectories should
  only be present if the application in question is included in the
  distribution.

  /var/lib/ is the location that must be used for all distribution
  packaging support. Different distributions may use different names, of
  course.

In short: /var/lib/ is for data that is used locally.

So it makes perfect sense to put a database's data into /var/lib/{mysql|postgress}/ directory but... the FHS is a standard created mostly for use by distributions. As a user you are free to put your data wherever you want and it is mostly a matter of opinion.

You are misunderstanding the word "local". /usr/local/bin/ is not for system software but for your own software (basically anything with "local" in must never be touched by the system. As explained by FHS:

/usr/local/

  4.9.1 Purpose

  The /usr/local hierarchy is for use by the system administrator when
  installing software locally. It needs to be safe from being
  overwritten when the system software is updated. It may be used for
  programs and data that are shareable amongst a group of hosts, but not
  found in /usr. Locally installed software must be placed within
  /usr/local rather than /usr unless it is being installed to replace or
  upgrade software in /usr.

An executable installed from system software should never go to anything local.

Now for /usr/lib/.

  4.7.1 Purpose

  /usr/lib includes object files, libraries, and internal binaries that
  are not intended to be executed directly by users or shell
  scripts. Applications may use a single subdirectory under
  /usr/lib. If an application uses a subdirectory, all
  architecture-dependent data exclusively used by the application must
  be placed within that subdirectory.

postgressql is probably a daemon started at boot? If so it makes sense to put it here. You are not suppose to use the command yourself but start a service. The files in /usr/lib/ tend to have their own user and group and/or a daemon that restricts access to /var/lib (only mysqld can access /var/lib/mysql/ for instance; this will be the same for postgressql)


Ubuntu, its 'flavour' variations, and other Linux distros, will use as much RAM as available. It will also release that memory for other higher priority use as needed. This is normal.


The pkg.tox.chat repository was removed, as can be learned from https://pkg.tox.chat/README.txt:

The Debian and Ubuntu package repository was removed per the announcement [1].
[1] https://blog.tox.chat/2018/02/shutdown-of-the-debian-and-ubuntu-package-repository/
-- nurupo (2018-03-16 02:00 UTC)

Remove the repository from your list of software sources. You can do that either through the Software & Updates system settings GUI, or by removing its respective line from the file /etc/apt/sources.list or any of the /etc/apt/sources.list.d/*.list files, depending on how you added it.


I have made an entry for the server alias in my .conf file in '/etc/apache2/example.com.conf' but still it doesn't work with www in the browser

you must add the www prefix in /etc/hosts file:

127.0.0.1   www.example.com


Cannot connect to X Server when running app with sudo

You need to allow the root user access to the X server:

xhost local:root

And point the command to the right DISPLAY:

sudo DISPLAY=$DISPLAY gedit /etc/profile


Deleted read messages in Sylpheed are not shown in Trash view

On top of the message field in Trash view, there is a select button right next to the 'Search' field, with the options All, Unread, Have color label etc

These are filters for Trash view and need to be set to All to be able to see all deleted folder. Somehow, I had Unread set. Changed it to All solved it.


Do I need to check my intel graphics driver version and update it regularly?

You linked to a PPA.
This is not software that is officially in Ubuntu's repositories.  It hasn't undergone the same standards of testing and process review as packages that are officially supported by Ubuntu.
This could mean that the software might not work with your system and could break things.  It's also possible that the software has an unknown vulnerability which makes it unsafe or dangerous to install or use.
From the package description, it's not even immediately apparent which devices this package is supposed to support.
Updates for your currently installed software, including the graphics driver you are currently using, will be updated when you update your system normally through the software center or apt / apt-get.
See Also: Are PPAs safe to add to my system and what are some "red flags" to watch out for?

From the comment you made on the original question:

yes i probably dont need to update it, I was just curious.I face lag while scrolling on chrome and firefox , tried smooth scrolling nothing changed.

It seems by asking this question that you might be caught in the trap of the XY Problem: The actual issue you seem to be trying to solve has to do with scrolling in your web browser.  But it's hard to guess the reason for this or to suggest a solution because you didn't ask or tell about the actual issue you're facing (hence the XY problem).  Perhaps there is an about:config entry in Firefox that can be adjusted?  Depending on which DE you use, in system settings, there may or may not be additional configuration settings for mouse/scrolling.


On Trusty: there are 19 packages shown as 'not to upgrade'

If a package is marked "not to upgrade" it means that there is a more recent version of the package available, but apt-get upgrade will not upgrade to it because it would involve removing currently installed packages, or installing new packages.

From man apt-get:

    apt-get upgrade: Packages currently installed with new versions available are retrieved and upgraded; under no circumstances are
    currently installed packages removed, or packages not already
    installed retrieved and installed. New versions of currently installed
    packages that cannot be upgraded without changing the install status
    of another package will be left at their current version. An update
    must be performed first so that apt-get knows that new versions of
    packages are available.

You can force an upgrade by running apt-get dist-upgrade, which will satisfy dependencies by removing packages and installing new packages.

For more information see What is "dist-upgrade" and why does it upgrade more than "upgrade"?


To check the file system on your Ubuntu partition...

boot to the GRUB menu
choose Advanced Options
choose Recovery mode
choose Root access
at the # prompt, type sudo fsck -f /
repeat the fsck command if there were errors
type `reboot

If for some reason you can't do the above...

boot to a Ubuntu Live DVD/USB
start gparted and determine which /dev/sdaX is your Ubuntu partition
quit gparted
open a terminal window
type sudo fsck -f /dev/sdaX # replacing X with the number you found earlier
repeat the fsck command if there were errors
type reboot


How do I extract the package version from debian/changelog?

If you have version 1.17.0 or later, you can use

dpkg-parsechangelog --show-field Version

No need to process the output further then. This version is currently (February 2014) available in Debian Testing.


An easy way to delete a file in Rhythmbox play queue

You can not. From the play queue you can only remove the file from the queue since it is a temporary list of the songs you have chosen to listen. The real list of songs is in the Music Option

in this picture you see the Music section to the left. In the list below is where you can delete files. Right click on them and Move to trash for example. That will remove it. But to not have from the queue and remove you need to remove it from Queue and the delete like i said from the Music section.


Is there a central configuration tool for ubuntu such as yast on opensuse?

Ubuntu Tweak does much of that - you can install it with:

sudo apt-get install ubuntu-tweak

It looks like this:

As for Service Administration, this may work:

sudo apt-get install jobs-admin

For more, see the question here.


How to make show desktop work only on the current workspace?

There is a bug report about this for 12.04. The bug's status is Fix Committed, meaning the fix will only be available in the next release.

In the meantime I can only recommend gnome3. There ControlSuperd works as expected.
In case you want to give it a try:

sudo apt-get install gnome-shell

Restart, and at the login, choose GNOME (first in the list):

Where to find the show desktop keybinding:
open dconf-editor and navigate to schema org.gnome.desktop.wm.keybindings.
You should find a key named show-desktop with its current value.


Thinkpad Edge E330 refuses to boot from USB after installing Ubuntu

This is clearly a firmware (what manufacturers and most people call a "BIOS," although it's not) bug. I recommend you go to your manufacturer's site and look for an update.

If that fails, my only suggestion is to use a third-party boot manager that will provide its own way to boot an external medium. My own rEFInd should do this, although in some cases you'll need to hit the Esc key to re-scan for bootable devices after it's booted.

Edit: It occurred to me after making the original post that disabling any "fast startup" type options in the firmware might also resolve the problem. Sometimes these options prevent the firmware from detecting a removable USB flash drive, so if such an option was accidentally enabled, it could cause the symptoms you're seeing.


How can I create a bootable USB disk from a CD image?

You can use UNetbootin
sudo apt-get install unetbootin

Select Diskimage and browse to the ISO files location.

Make sure that the right USB drive is selected and then hit OK.

This will create a bootable USB drive off the provided image.


My shell script won't work on Lubuntu but work on Ubuntu. (Only one command don't work)

The issue is that when you spawn a Firefox instance for the first time, it will block the execution of the script until you manually close all the instances or kill the process. This behavior is keeping your script from going past the line which runs firefox.

The odd part of the problem is (probably) that on Ubuntu you were running the script after manually opening Firefox from the GUI, but on Lubuntu you didn't have any running Firefox instance.

To solve this issue, you may run the firefox process in the background, letting the script continue even if the proccess won't exit inmediately. To do this, you only need to append an ampersand to your command like so:

/home/lubi/Desktop/firefox/firefox &


Where can I get a better understanding of Repositories?

You can read about repositories here.

ppa:otto-kesselgulasch/gimp is a PPA (personal package archive) - kind of a personal repository.

Its description says:

CAUTION!

This PPA could break your installed OS. There are dependency issues
especially for Oneiric (11.10). Only use it if you know what you do! I'm
working with others on a stable and reliable solution.

Gimp is currently at version 2.8, but older Ubuntu releases have older versions, which are maintained either by Ubuntu developers or the community.


What uses and fills up ~/.cache/kioexec/krun/?

It could be any KDE based app that need file access, either local or remote.

KIO
Network transparent access to files and data
Introduction
This framework implements almost all the file management functions you
will ever need. In fact, the KDE file manager (Dolphin) and the KDE
file dialog also uses this to provide its network-enabled file
management.
It supports accessing files locally as well as via HTTP and FTP out of
the box and can be extended by plugins to support other protocols as
well. There is a variety of plugins available, e.g. to support access
via SSH.
The framework can also be used to bridge a native protocol to a
file-based interface. This makes the data accessible in all
applications using the KDE file dialog or any other KIO enabled
infrastructure.

Source: Kio git - README
Check this function here: src/kioexec/main.cpp


rails --v works for root user but not for other users

You can install for the specific user either or try the below.

You might need to change your /etc/gemrc or /root/.gemrc. The default is set to:

gem: --user-install

Or you can use

gem install --no-user-install rails

Via: https://superuser.com/questions/475977/how-install-gem-rails-for-all-users-in-arch-linux


How to change the permission on a single file?

as owner or user with write permissions on the file:

chmod o+r filename


Changing permissions in fstab in order to allow writing for this partition, or just change permissions for backup folder


You must install nomarch

sudo apt-get install nomarch

after installation

nomarch -p arhive.arc

Also you have man pages for additional options

man nomarch


Find out what file is running:

pgrep nginx | xargs -I{} readlink -f /proc/{}/exe

Then you can expand on that to find out which package that file (or those files) belong to:

dpkg -S $(pgrep nginx | xargs -I{} readlink -f /proc/{}/exe | uniq)

In my case that highlights the nginx-full package but it might be you find a version of Nginx you manually installed (not from packages) that you now need to manually remove.


How to use the "About Me" without evolution

Unfortunately in order to use About Me (part of the gnome-control-center) the application needs to take advantage of evolution-data-server, which is the service that let's the rest of the desktop connect to mail/contacts/task, etc.

Ideally someone would write a program that would sync e-d-s to your Google App account (or whatever) in order to take advantage of this feature -- unfortunately nothing like this exists as far as I know.

References:

Bug report for support in Mozilla Thunderbird
Bug report for support in OpenOffice.org
e-d-s Documentation


Update 20210115: the newest kazam 1.5.4-0ubuntu6 from this PPA works normally.
Thanks to the PPA owner!

Notes:

some systems need manual installation of gir1.2-gudev-1.0 package.
possible alternative is OBS Studio snap.


How to change the name of Ubuntu installer

Make changes in Cubic
This is very easy, and you do not need to do anything in Cubic's Terminal environment.
(However, there may be a small issue with the exclamation mark ("!") in your custom OS name, which I will explain below).
On the "Project" page in Cubic, in the "Custom Disk" section, rename the first part of the "Volume ID" to your custom OS name.
For example, rename...
Ubuntu 20.04.0 2021.04.14 LTS

...to...
zink! 20.04.0 2021.04.14 LTS

You will notice that the "Disk Name" automatically changes to...
zink! 20.04.0 2021.04.14 LTS "Custom Focal Fossa"

Then generate the customized ISO, as you normally would.
Test your changes
Boot into your new Live ISO. (You can use VirtualBox for testing).
The Ubuntu Live environment will use everything before the first space character of the "Disk Name" value to display these two new buttons:

Try zink!
Install zink!

Furthermore, once you have booted into the Live environment, you will see an app launcher on your Desktop for the Ubiquity installer. This app launcher will now be named "zink! 20.04.0". (This corresponds to everything before the second space character of the "Disk Name" value on Cubic's Project page).
Potential issue
Regarding, the small issue I mentioned before, when you include the exclamation mark ("!") in your OS name, the behavior of the Live Environment changes: After you click the Try zink! button, you will be prompted to select a locale, user name, password, and other information for the Live Environment.
As you know, the typical behavior of the Live ISO is to immediately boot you into the Live Environment as user ubuntu, and if you do not include an exclamation mark ("!") in your OS name, this is what the behavior will be.
Otherwise, with the exclamation mark ("!") in your OS name, you will need to supply this preliminary information before you can enter the Live Environment. (I think this may be a "feature" of how the Live ISO works, and you may not consider this to be a issue for you).


Figured it out for myself. As I thought, nvidia drivers were the issue. I looked through a few directories and still had the .run file for the nvidia 367.27 graphics drivers. I removed the current drivers with:

    sudo apt-get purge nvidia*

Stopped the current Xsession with:

    sudo service lightdm stop

and finally just installed the drivers from my downloads folder:

    sudo sh ~/Downloads/NVIDIA-Linux-*-367.27.run

Ran a sudo reboot and everything is back to normal.


Network drive data security - how to restrict access

You can restrict access by IP by editing your /etc/samba/smb.conf like this:

[global]
...
# Override the default network interface list that Samba will use for browsing.
interfaces = eth0, 127.0.0.1

# Limit what interfaces on a machine will serve SMB requests.
bind interfaces only = yes

# List, IP range etc. of hosts that are not allowed to access Samba services.
# In case of conflict between 'hosts allow' and 'hosts deny', the 'allow' list will take precedence.
hosts deny = ALL

# List, IP range etc. of hosts that are allowed to access Samba services
hosts allow = 192.168.0.127.
...

Remember to edit the above with your own network information.

Change eth0 to be your network interface.  For example, mine is enp3s0
Change the hosts allow = line to match the IP addresses of the machines you want to have access to the shares


Installing NVIDIA driver causes black screen (750M)

Quick googling gave me this 319.17 Certified

Added support for the following GPUs:

GeForce GTX 650 Ti BOOST
GeForce GT 720M
GeForce GT 735M
GeForce GT 740M
GeForce GT 745M
GeForce GT 750M

So you'll probably need 319.17

It's from 2013.05.02 and not yet in any official Ubuntu repository.

To install it, first remove the ones you installed from the repo's sudo apt-get purge nvidia* (or  --purge remove) should do that. If you installed one manually, please look up how to remove them.

Then follow: Install New Nvidia Drivers, Nvidia 319.17, on Ubuntu 13.04 Raring Ringtail


Disable CPU frequency scaling on Lenovo Laptop

Just to make sure it's not going to interfere, remove the powernowd package from your system. From a terminal, run:

sudo apt-get remove powernowd

After that, or if you don't have that package installed, install rcconf by running:

sudo apt-get install rcconf

Then run sudo rcconf and press space with the ondemand service highlighted to disable it. This service controls CPU frequency scaling. Press enter to save and quit. To manually stop it once, you can run sudo /etc/init.d/ondemand stop.


Can't apt-get install ot remove any package. initramfs-tool failed

The error message that is reported in the question only occurs in 20.04. Here is a workaround.

Boot into Recovery mode and wait until the loading of the cryptswapfile times out.

Go to a root shell (the second entry from the bottom in the Recovery Menu) and comment out the following lines in /etc/fstab and /etc/crypttab by preceding each line with a # character.
/etc/fstab :
 /dev/mapper/cryptswap none swap defaults 0 0

/etc/crypttab :
cryptswap /cryptswapfile /dev/urandom swap,cipher=aes-xts-plain64,size=256

Run  swapoff -a && update-initramfs -u.

Uncomment the lines in fstab and crypttab that you commented out, and reboot with sudo reboot.


I would definitely recommend "Empathy" - it's the default Chat program and already installed. You might have to install an additional package for video though. See the wiki page

I think video chat works via Jabber/XMPP, which is a free protocol and there are different servers, for example jabber.org but also Google/Gmail has it's own version of XMPP. Here is also a list of servers

If you don't want your students to create their own accounts, you can just create pc1-4 accounts and create the friend lists yourself.


Dynamic editing and running quickly apps


Could you install Ubuntu on an external hdd and run it on a Samsung smart TV?

No, but you could use the Ubuntu-Powered Intel Compute Stick. It's processor, memory, SD slot and USB port that plugs into the HDMI input of anything that has an HDMI input.

If it proves to be useful, I'm sure it will only be the first available.


Unity equivalent to the Gnome 2 system monitor

The best alternative I know is Indicator Multiload.
The review and installation instructions can be found here.


X11/extensions/Xcomposite.h: No such file or directory

Whenever a compile fails with a missing file simply leverage the infrastructure to search for the missing ubuntu package

apt-file search   some_missing_file_goes_here   #  cmd 1
apt-file search   X11/extensions/Xcomposite.h   #  cmd 1

which returns with

libxcomposite-dev: /usr/include/X11/extensions/Xcomposite.h

so solution is to install that missing package

sudo apt-get install libxcomposite-dev              #  cmd 2

this technique works across any missing file

On a fresh OS if you issue

apt-file search   X11/extensions/Xcomposite.h

it will fail with error

The program 'apt-file' is currently not installed. To run 'apt-file' please ask your administrator to install the package 'apt-file'

which just means you need to do a one time setup of the local search cache so just run

sudo apt-get install apt-file -y
sudo apt-file update

now re-issue the search shown above (cmd 1) then install package (cmd 2)


How do I set a wine program (ex. Foxit Reader for Windows) as the default program?

I solved the problem myself. Here's how:

Step 1: Create script

I followed the procedure in the https://help.ubuntu.com/community/Wine page:

gedit ~/.wine/Foxit5

Now paste the following script in it, save and close gedit. If you changed the installation path, modify the 2nd line accordingly.

#!/bin/sh

QUICKPARLOCATION="c:\\Program Files\\Foxit Software\\Foxit Reader\\Foxit Reader.exe"
PARAM=`winepath -w "$*"`
wine "$QUICKPARLOCATION" "$PARAM"
exit 0

Make sure the file is executable with this command.

chmod +x ~/.wine/Foxit5

Step 2: Create .desktop file

Info from this site: http://ubuntuforums.org/showthread.php?t=1863021

cd to the directory /usr/share/applications
use 'grep -i foxit *' this will search for the name foxit ignoring case.
if it's not there make one from one of the smaller ones.
I used sol.destop and copied it to my own fake app.
Don't forget the %f, this shows that the application can be passed a file name, it has to be there to show up in the list.

sudo cp sol.desktop foxit.destop

gksudo gedit foxit.desktop

foxit.desktop Code: (I created an icon and saved it in the .icons folder)

[Desktop Entry]
Name=Foxit Reader 5
Comment=Read and annotate pdf files
Exec=~/.wine/Foxit5 %f
Icon=~/.icons/Foxit.png
Terminal=false
Type=Application
Categories=Office;
X-GNOME-Bugzilla-Bugzilla=Foxit
X-GNOME-Bugzilla-Product=foxit reader
X-GNOME-Bugzilla-Component=Zwischenlager
X-GNOME-Bugzilla-Version=3.2.1
StartupNotify=true
X-HildonDesk-ShowInToolbar=true
X-Osso-Service=org.gnome.Games.AisleRiot
X-Osso-Type=application/x-executable
X-Ubuntu-Gettext-Domain=aisleriot

Step 3: Set as default

Open file manager and find any pdf file.
Click properties.
Open with.
Show all.
Choose Foxit Reader

That's it! Well sort of… This method works only if Foxit reader 4 is not running. If it is a "file not found" error pops up.

EDIT: This methods works fully with Foxit Reader 5 but you would need to install wine 1.5 for this version to work. Visit http://www.winehq.org/download/ubuntu to do so.


You didn't specify an initrd. The bootloader loads the kernel and the initrd. The initrd contains the files that the kernel uses for booting up, including init, since you're not booting to a real installation. Without it, the kernel probably panicked quickly enough.


Quick way to temporarily disable compiz and gnome shortcuts

To disable compiz temporarily, replace it with metacity, that's the other window manager/decorator.

Alt+F2, and run metacity --replace

To restore compiz, run compiz --replace

Of course, after logging off and in, or rebooting your computer, compiz will be used as the window manager (since this command disables it temporarily).

I use it quite often, so I've even bound it to a launcher in the gnome panel.


Unwanted output audio looping through input

Pulse Audio GUI is not able to manage physical inputs and outputs. So you should try with  alsamixer and one of its GUI (ex: gnome-alsamixer). This way, you can manage the physical i/o of your sound card.

sudo apt-get install alsamixer gnome-alsamixer

Using alsamixer (in terminal) go to input (F4) and turn down the PCM volume level to 0

Note: To stop hearing your own microphone in your headset/speakers turn down the microphone level to 0 on Output (F3)


How to remove directory from terminal title and only keep running command?

According to this answer in this similar question in Stack Overflow Bash - Update terminal title by running a second command, you can add the following at the end of your .bashrc:
trap 'echo -ne "\033]2;$(history 1 | sed "s/^[ ]*[0-9]*[ ]*//g")\007"' DEBUG

Then run:
source ~/.bashrc

for the change to take effect.
The above command changes your terminal's title to your currently running command. If a command is not currently running, your terminal's title is the default one.
You may also be interested in having the last run command inside brackets as your title. According to this answer How to set the terminal title to show the current running command while it's running and to show it in brackets once it's finished?, you have to also add this in your .bashrc:
export PS1="\033]2;[\$(history 1 | sed 's/^[ ]*[0-9]*[ ]*//g')]\007$PS1"


How can I publish my project code online so someone can help me with it?

Use Launchpad's +junk branch feature to publish your code to a temporary location. In fact, it is not temporary, as it will remain there until you explicitly delete it, but it is a nice place to put unfinished code you're experimenting with on a public location.

This way it will stay out of the way from your regular branches, but you'll still be able to access it and show it to everyone online.

The only requirement is that you've got a Launchpad account and have uploaded SSH keys and finished the procedure to use Launchpad for code hosting.

After that, you simply need to run this command on your terminal, from the location where your code lives:

bzr push lp:~<your-launchpad-id>/+junk/<name-of-your-temp-branch>

That's it! You'll then be able to point other people to https://code.launchpad.net/~<your-launchpad-id>/+junk/<name-of-your-temp-branch>


/dev/mapper indicates that you're using LVM; so resizing the physical volume is not enough to resize the logical volume contained within, let alone the filesystem.
To increase the filesystem size, I followed these instructions from ServerFault with success:

First, I increased the physical partition using gparted. This was straightforward, and I assume you've already done that. If you don't have access to a LiveCD, you can increase the size of the physical disk while online, via pvresize, as shown in the linked instructions.

Then I used lvresize to grow the logical volume to fill the physical volume. I used pvdisplay to verify the size of the physical volume, and tried using that size.
 sudo lvresize -L 28.82G /dev/ubuntu-tt-vg/root

However, it was too large, so I started with 27G, and kept resizing my partition bigger until I hit the max.

Then, I used resize2fs to grow the filesystem inside the logical volume.
 sudo resize2fs /dev/ubuntu-tt-vg/root 7290881

Finding the max here was much easier. If you try a number bigger than the max, it will tell you exactly what the max is.

At this point, df -h should show that your filesystem has grown to the new size.


The "Date" in Ubuntu 18.04 Lock Screen is not always center aligned. How to fix?

There may be a bug in the Ubuntu gdm3 3.28.3-0ubuntu18.04.4 package. I have reported it.

I discovered the trigger for this issue. It occurs when Tweaks-->Top Bar-->Seconds is toggled on. For now, the solution to this issue is not to show the "Seconds" in the timing. Tweaks-->Top Bar-->Seconds must be toggled off.


Upstart, one job definition to start and one to stop

It should be as simple as creating a file /etc/init/myjob.conf:

description    "My Job"

# start conditions for automatic start
# stop conditions for automatic stop

pre-start exec /path/to/program start
post-stop exec /path/to/program stop

You should then be able to do sudo start myjob to start and sudo stop myjob to stop.

See http://upstart.ubuntu.com for some more info.


If you have nothing to update you are already using 12.04.3.

Point releases incluide secutiry and software updates after a certain period of time so you don't need to install gazillion of updates since the first time if was released.

https://wiki.ubuntu.com/PrecisePangolin/ReleaseSchedule


Ubuntu not displaying full 4GB memory on 64bit installation!

If you are booting using standard BIOS, maybe the BIOS e820 memory map is lying to the kernel.  The kernel has to trust what the firmware tells it when it comes to memory layout. To see what you have use:

dmesg | grep e820

alternatively, one can look at the entries in /sys/firmware/memmap, but these are a little tricky to read, so one could use:

sudo apt-get install fwts
sudo fwts memmapdump -


How to execute a file based on the mime type in Nautlius?

You can add mime type associations in $/.local/share/application/mimeapps.list for current user. Sample snippet is here,

    [Added Associations]
    application/excel=planmaker-free18.desktop;
    application/mspowerpoint=presentations-free18.desktop;
    application/msword=textmaker-free18.desktop;
    application/ppt=presentations-free18.desktop;

   [Default Applications]
   text/html=google-chrome.desktop
   text/x-arduino=arduino-arduinoide.desktop

You have to first add new association it to [Added Associations] section and then add to [Default Applications] section to make default. For your type in question add application/x-sharedlib=some-application.desktop in both sections. Then save the file and try to open. May be you want to restart the nautilus.

If you want to make edits globally edit file in /usr/share/application/default.list


I was able to find beets, which is pretty much exactly what I could have hoped for. It's a command line tool , written in Python, that will tag, sort, and clean up music libraries for you. the plugin possibilities are also pretty good.


Check if bash is at the newest available version with:

[romano:~/etc] % apt-cache policy bash
bash:
  Installed: 4.3-7ubuntu1.4
  Candidate: 4.3-7ubuntu1.4
  Version table:
 *** 4.3-7ubuntu1.4 0
        500 http://archive.ubuntu.com/ubuntu/ trusty-updates/main amd64 Packages
        500 http://archive.ubuntu.com/ubuntu/ trusty-security/main amd64 Packages
        100 /var/lib/dpkg/status
     4.3-6ubuntu1 0
        500 http://archive.ubuntu.com/ubuntu/ trusty/main amd64 Packages

If not, you probably held(1) it; to unhold:

[romano:~/etc] % sudo apt-mark unhold bash

and then the normal apt-get update; apt-get dist-upgrade should give you a completely up-to-date system.

BTW, to see a list of held packages, the incantation is:

dpkg --get-selections | grep hold

Footnotes:

(1) "Holding" a package means asking the package system to refuse to upgrade it to newer versions.


I had a similar issue after upgrading. I found the removing flashplugin-installer first then re-installing it (as suggested by chronitis) worked:

sudo apt-get remove flashplugin-installer
sudo apt-get install flashplugin-installer


Installation 16.04 question related to lvmetad

I am guessing that GRUB did not install correctly. To fix that please follow these steps carefully:

Insert Ubuntu installation disk (USB or DVD).
Boot and select "Try without installing" option
Open a terminal when the desktop has loaded
Run the following commands:

sudo -s
add-apt-repository ppa:yannubuntu/boot-repair
apt update
apt install boot-repair
boot-repair
Chose recommended option.
After a while it will ask you to copy and paste commands into the terminal. Copy and paste all commands given, open a new terminal window, and paste them. You will need to do this at least twice.
Once finished, shut down, remove installation medium, and reboot your computer.

This procedure will install GRUB on your computer, the utility that loads the Ubuntu operating system.


Unusuable windows pops up using Shift + 2 in Ubuntu 18

You should check the keyboard shortcuts in GNOME Control Center (Keyboard tab):

Open it from dash (or with gnome-control-center keyboard)
Compare your settings with default settings below:

and locate or change the problematic items.


Following worked for me. Very simple but effective till now:

Open terminal with Ctrl+Alt+T
Type sudo gedit /etc/gdm3/custom.conf
Type the password when prompted. (It will not be visible while typing.) edit the file and remove '#' located at the beginning of the following line (its 7th line)

#Wayland = false

So now the line will look like this - Wayland = false
Save and close the window
Exit and restart


Install the x-swat repository to install the current nvidia driver 304.43 and that will solve the problem.

sudo apt-add-repository ppa:ubuntu-x-swat/x-updates
sudo apt-get update
sudo apt-get install nvidia-current

I found these instructions somewhere in this forum but I can't find it. I'm very happy with the person that posted them.


There is no /dev/ support in Windows Subsystem for Linux (WSL). There is a Microsoft User Voice Page where you can comment your needs for such support. Currently 779 people have voted for this feature. You can post a comment linking back to this question and pointing out how the feature is needed to install your software.

For myself it would be great to have /sys/class/backlight support. It seems every WSL user has something they'd like supported in future versions.


I'm thinking he doesn't have any samba users.

sudo smbpasswd -a <username>
gksu gedit /etc/samba/smbusers


Want to share folders with another user in Ubuntu 14.04

You can do this by adding the secondary user to a specific group, and then modifying the permissions of the shared folder. Here is how I would do it:

Add new group sharedfolders to your Group list:

    sudo addgroup sharedfolders

Then, add the secondary user to this group

   sudo usermod -a -G sharedfolders secondusername

Just replace "secondusername" with, well, your second username.

Lastly, on your main user that owns the folder you want to share. Right click the folder in your file browser, go to the permissions tab and under "group" select the correct permissions for the "sharedfolders" group. When on your secondary user account, you can browse to that folder and make a bookmark or link to it however you prefer to do that for easier access.


What command is executed when shutdown from the graphical menu in 14.04?

systemd-logind manages user sessions in 14.04 (replacing consolekit and upower with login1), the commands to use are now:

PowerOff:

dbus-send --system --print-reply --dest=org.freedesktop.login1 /org/freedesktop/login1 "org.freedesktop.login1.Manager.PowerOff" boolean:true

Reboot:

dbus-send --system --print-reply --dest=org.freedesktop.login1 /org/freedesktop/login1 "org.freedesktop.login1.Manager.Reboot" boolean:true

Suspend:

dbus-send --system --print-reply --dest=org.freedesktop.login1 /org/freedesktop/login1 "org.freedesktop.login1.Manager.Suspend" boolean:true

Hibernate:

dbus-send --system --print-reply --dest=org.freedesktop.login1 /org/freedesktop/login1 "org.freedesktop.login1.Manager.Hibernate" boolean:true

Source: forum.ubuntu-fr.org


Ubuntu 18.10 crashes system when trying to play a game

I replaced the PSU to rule out the possibility of a broken PSU just in case, hence the delay. While it was a risk, I needed an excuse you buy a quieter one anyway. And guess what @heynnema? No more crash. While I find it difficult to believe that a software update uncovers an issue with the PSU, I suppose I just have to accept that it was slowly dying. Thank you for your effort anyway.


high frequency app for the Ubuntu smartphone

2 & 3 would be trivial as Qt has very good APIs for dealing with this kind of thing.

1 & 4 would require extra A/D and D/A hardware interfaced to the phone somehow. This presents a problem as there are multiple ways of interfacing and every phone supports a different subset of these standards. Assuming your phone supports USB-OTG then this would be quite easy. You would simply communicate with the hardware using libusb, much as you would on a normal PC.


How can I permanently delete tun interfaces

If your want to permanently delete any interface so that it does not appear after a reboot, then it depends on which service they are under the control of. If your used nm, then in essence it automatically creates tun/tap interfaces when your install openvpn and they cannot be removed using networkctl, but only by force with nmcli tool. There is one subtlety between nm and sn, when your activate sn, it is important for your to uninstall nm BEFORE installing for example 'openvpn', since nm automatically creates an interface for traffic tunneling and it remains in the list networkctl and it CANNOT remove it. But if your uninstall and deactivate nm before installing openvpn, then the created interfaces can be not created from and disappear from the networkctl list.  So that your do not stumble over the created
by nm interfaces, ... there is no beach in the list of networkctl and if your want to revolutionize then i advise your to use systemd-networkd, your can gradually get used to its syntax.

Nmcli is a command-line tool for controlling network-manager and reporting network status.
Networkctl may be used to introspect the state of the network links as seen by systemd-networkd.

Nmcli from network-manager.
shut down all interfaces after reboot managed by nm:
nmcli networking off

show interfaces/connection:
nmcli
nmcli general status
nmcli device show tun0
nmcli connection

temporarily disable/remove interface from nm until reboot:
nmcli device set autoconnect no tun0
nmcli device set managed no tun0
nmcli device delete tun0
uuidgen tun0

84a068f7-efe5-40c5-a813-3fc85fabdcc3 # replace it with yours uuid

nmcli connection delete 84a068f7-efe5-40c5-a813-3fc85fabdcc3

Networkctl from systemd-networkd.
In order to have a possibility to think about an adequate solution to the setting and not in a hurry to reinstall the system, then the only way to bypass unnecessary interfaces from nm is to create a config that uses sn of all the interfaces your need in /etc/default/grub, thereby adding their in autoload.
to see the interfaces in networkctl, only which ones your are interested in, create a config 01-netcfg.yaml:
https://netplan.io/
sudo apt install bridge-utils net-tools ; reboot # use net-tools to display ifconfig list
sudo nano /etc/netplan/01-netcfg.yaml
netplan --debug generate

add the config you created to autoload:
sudo nano /etc/default/grub

replace the line:
GRUB_CMDLINE_LINUX=""

on:
GRUB_CMDLINE_LINUX="netcfg/do_not_use_netplan=true"

update-grub ; reboot
ifconfig

see all the interfaces you have:
networkctl status all

WARNING: systemd-networkd is not running, output will be incomplete.
Failed to request link: No such device

accordingly, your can see here that networkctl does not display until sn is running.
to shut down the interface before rebooting in networkctl:
sudo ifconfig tun0 down
sudo ip link set tun0 down
sudo ip link delete tun0
sudo systemctl restart systemd-networkd ; sudo systemctl status systemd-networkd


VeraCrypt volumes get unmounted after sleep

Finally found a solution myself.

To prevent VeraCrypt from unmounting volumes on sleep\suspend edit the file

/etc/default/veracrypt

And change line

VERACRYPT_SUSPEND_UNMOUNT="yes"

To

VERACRYPT_SUSPEND_UNMOUNT="no"

Changes take effect immediately after saving the file. No need to reboot nor restart any services.


How can I connect to a Windows 10 remote desktop over openfortivpn from behind a router?

It's more of a workaround, but based on this page I found that if I issue the command:

sudo route add 192.168.1.xxx dev ppp0

I could connect to the remote desktop just fine. "192.168.1.xxx" being the (slightly redacted) IP address of my work PC, and "ppp0" being what I surmise to be my VPN gateway. I obtained it by installing net-tools and issuing the command:

ifconfig

As I understand it, the setting is lost upon disconnecting from the VPN.


@PerlDuck resolved my issue for me. This is simply a case of unwanted blank space. This extra whitespace after the final EOF prevents the heredoc from terminating. Thus producing the error

./vhost.sh: line 22: warning: here-document at line 6 delimited by end-of-file (wanted `EOF')
./vhost.sh: line 23: syntax error: unexpected end of file

Remember kids! Blankspace, blankspace, blankspace !