Screenshots don't get automatically copied. Ubuntu 20.04.1 LTS

in terminal run
gnome-screenshot -c

and add -d   for a delay to test anything else which you can switch to after running it
and then if that works better, make a custom ubuntu keyboard shortcut for it


Why User Accounts doesn't open? How can I open it?

You should reinstall the desktop package, it seems something went wrong with your installation as you say "I'm facing this problem from the start of using Ubuntu 14.04 LTS".

Open a terminal and run

sudo apt-get install --reinstall ubuntu-desktop
sudo reboot

This will reinstall the settings application.


Your disk is set up with the Windows Logical Disk Manager (LDM) system (aka "dynamic disks"), which is a proprietary Microsoft layer atop regular partitions. LDM is conceptually similar to the Linux Logical Volume Manager (LVM), but the two are incompatible formats. In any event, you cannot install Ubuntu on the disk in its current state -- at least, not easily. (It might be possible to cobble something together, but even for a Linux guru, that would be a bit of a challenge.)

The easiest solution is to convert from LDM to a more conventional partitioning setup. Some commercial Windows tools, such as EaseUS Partition Master and Partition Wizard, are supposed to be able to do this losslessly. The tools that come with Windows can do the conversion, too, but only by starting with a clean set of partitions (thus effectively wiping your data). Of course, if you're willing to back up your data and know how to restore your system to bootability upon restoring it, this may be an acceptable solution. (For that matter, I strongly recommend backing up all your data before attempting to convert the disk in any way; although the conversion is likely to be simple, the consequences of a bug, power failure at an inopportune moment, or other problem could be catastrophic.) Some people have reported success with wiping the partition table and then using TestDisk to create a new set of partitions, but I recommend against this because there's no guarantee that the filesystems in an LDM setup will be contiguous, which is an assumption of TestDisk. Thus, TestDisk will work if that assumption is met, but if it's not, you could end up with corrupted filesystems and at least some lost data.

Another option is to buy another disk and install Linux on it. That way, you can leave the Windows LDM configuration alone and let Linux control the new disk.

FWIW, Windows has a habit of converting from a conventional configuration to LDM whenever you create a setup with more than four partitions on a disk. AFAIK, Windows doesn't warn you about what it's doing -- or if it does, the message seems to leave little impression, because I have yet to see anybody ever mention it. Thus, you should never use the standard Windows partitioning tools to add partitions, particularly if you know you'll be exceeding four partitions, unless you're willing to use an LDM setup. (A common newbie mistake is to use Windows to create a partition for Linux prior to running the Linux installer. This often pushes the partition count over four and creates more work to undo this problem.)


Can my local host get attacked if I don't port forward?

If you have zero ports forwarded through your firewall you should be safe from an internet based attack. If you forward ANY port you have a greater vulnerability.
Having a default password is another vulnerability. What if someone gets on your wifi?

Ultimately, I'd REALLY recommended against it.


I would like to make my new HP Envy 700-230qe Desktop a dual boot platform

Ubuntu doesn't need much disk space. You can partition your hard drive 50-50 but you don't have to. This guide recommends 5 GB free disk space. I am not sure if it is still up to date, but 10 GB should be enough for a minimal installation.

How much disk space you really need, depends on the programs you are installing.

But, you have to consider where you want to store your private files (Music, Photos, Documents, etc.). Ubuntu is able to access your windows partion, so you can store this things primiliy there, but if you want to store them on the Ubuntu partion you need some more space for that.

Most of your peripherals should run out of the box, but that depends on your hardware. I suggest installing Ubuntu first. If something is not working, come back and ask again ;-)


Ubuntu desktop issues/overall systematic issues

This is a generic but very rough way to get a working user session when something unknown in the $HOME folder has been corrupted. Consider this as a last resort if nothing else helps.

Execute this series of commands:

cd /home
sudo mv "$USER" "$USER".bak
sudo mkdir "$USER"
cd
sudo chown "$USER": .
cp -rT /etc/skel/ .

Log out and log in again

Copy documents and other stuff of your choice from the old $HOME folder (with the .bak extension) to the new one.

Edit:

To fix insufficient permissions in the old $HOME, do this:

cd /home
sudo chown -R "$USER": "$USER".bak


Run df -h in terminal and make sure there is nothing mounted that looks like /dev/sdb*.
I had /dev/sdb11/ and /dev/sdb8 mounted so I had to run umount /dev/sdb11 and umount /dev/sdb8.


Network manager icon suddenly disappeared along with internet connection

in the terminal run nm-applet. Network manager icon should come back again.

If did not work, try:
dbus-launch nm-applet


How should one tell if it's kubuntu or ubuntu installed?

echo $DESKTOP_SESSION should tell you what Desktop Environment is in use.  ubuntu == some gtk based DE, unity by default. The others I don't know off-hand, but that environment variable is there for exactly this purpose.


i had the same problem the fix was simple just upgrade the kernel
you need the latest kernel version i suggest 3.12

Go here: http://kernel.ubuntu.com/~kernel-ppa/mainline/
Download 3 (maybe 4) debs to a folder somewhere:

linux-headers-VERSION-NUMBER_all.deb

linux-headers-VERSION-NUMBER_amd64.deb

linux-image-VERSION-NUMBER_amd64.deb

linux-image-extra-VERSION-NUMBER_amd64.deb   # if available

3.Install the debs with whatever package manager front-end you use (is gdebi still around?), or use these commands:

cd /path/to/folder/where/you/put/the/debs

sudo dpkg -i *.deb


Are you using Flash or HTML5?

Flash - there may not be a solution. Flash for Windows is much more optimized than Flash for Linux.
HTML5 - do you have graphics acceleration enabled for your graphics card? If you can play 1080p in MPlayer or VLC, then it should work with HTML5 on YouTube.


Is it possible to get a HP printer to work with or without hplip in Ubuntu 14.04?

I don't have the same exact model as you, but I do have an HP printer which works just fine without the HPLIP.  I can print and scan everything just fine.  The only thing I cannot do is check my ink levels and do other HP specific stuff, but for other everyday stuff I have zero problems.


As far as I know the process to replace a damaged drive are:

zpool offline pool_name device_name
Shutdown and replace drive
zpool replace pool_name device_name

The first one takes a device_name drive offline from a pool_name pool, you then replace the drive with a new one and tell Zfs to replace the drive device_name in in the pool pool_name.

device_name and pool_name are the names of your drive and pool shown in zpool status.


Why does dragging and dropping on the Unity launcher sometimes moves the icon and sometimes slides all icons?

If you click and move quickly you drag all the icons.

If you click, wait and move you move a single icon.


In order to install phpmyadmin on Ubuntu, you need to have Apache2 , MySQL and PHP  installed and configured properly.

After installing apache2, MySQL and PHP, you can install and configure phpmyadmin.  Just press Ctrl+Alt+T on your keyboard to open Terminal. When it opens, run the command(s) below:

sudo apt-get update
sudo apt-get install phpmyadmin


How to update linux kernel automatically?

You need to unhold these packages with this apt-mark command:

sudo apt-mark unhold linux-generic linux-headers-generic linux-image-generic

Then You can run sudo apt-get upgrade again.


for Kubuntu:

sudo apt-get install kubuntu-desktop

EDIT: for gnome3

sudo add-apt-repository ppa:gnome3-team/gnome3-staging
sudo apt-get update
sudo apt-get dist-upgrade
sudo apt-get install gnome-shell ubuntu-gnome-desktop


dpkg error when trying to install ssh server

sudo apt-get install openssh-client

sudo apt-get install openssh-server

As far as I know the client allows you to access other machines, while the server allows other machines to access yours.


How should I go about debugging a PHP Fatal Error?

Check the PHP version on the server, we had the same issue today due to this:
https://www.reddit.com/r/PHP/comments/j98i7s/ubuntu_ppa_installs_php_80rc1_automatically/


Will ticking the "Install third-party software" box install non open-source software?

If you would like to stick to running only open source software, then you will likely want to stay away from ticking the box. Not all third-party software is closed source, but not checking the box will give you the opportunity to first research the packages you need/want, then install them manually later.


How to upgrade nautilus to 3.4 on 11.04?

Upgrading to 12.04 is by far the easiest way to get a new version of Nautilus.

Nautilus is an integral part of Gnome, which is an integral part of the whole distro, depending on a particular version of libc and other stuff. Trying to update only some of the packages will lead you straight into dependency hell, as you're already discovering, especially when migrating from Gnome2 to Gnome3.

Another option is compiling new version of Gnome from source with a separate prefix, but that's also probably more work that you'll be willing to invest.


How can I capture shell variable output to use in my capistrano task

Use printenv instead, which does not require a shell:

capture('printenv ENV_VAR')

Replace ENV_VAR with the name of the environment variable you want. Do not prepend $.

Although printenv is not POSIX, GNU/Linux systems like Debian, Ubuntu, Fedora, and CentOS support it because GNU Coreutils provides it, and it works on many other *nix systems, like FreeBSD. The reason you need to use printenv instead of env is that printenv ENV_VAR outputs the value of ENV_VAR, while env ENV_VAR tries to run a command called ENV_VAR, which is not what you want.

The rest of this post covers other methods, their limitations, and how they can be improved. This is optional reading, since printenv is simple and solves the problem fully.

Your original method, capture("env | grep ENV_VAR").split("=").last, should not be used even on a system where it does appear to work, because it is unreliable. It greps for the variable name everywhere in the VAR=val line, and thus will return results for variables whose names--or even values--contain the name of the desired variable. Using ^ENV_VAR= instead of ENV_VAR fixes this problem by matching the name only when it appears at the beginning of the line (^) and requiring a = character to appear right after it. However, it is possible for the value of an environment variable to contain an = character, and since you call split and last, you are actually getting the longest trailing substring of the value that contains no =. Even if you fixed that, the method is still needlessly complex when all you need is printenv.

The solution you found, capture("/bin/sh -c 'echo $ENV_VAR'"), will work most of the time, but will return an incorrect value when the variable (a) contains whitespace other than single space characters surrounded by non-whitespace, or (b) contains globbing characters like *, ?, and [ if they happen to match any filenames. The problem is that, in the shell command echo $ENV_VAR, the parameter expansion $ENV_VAR is not quoted, so word splitting and globbing are performed. echo reinserts whitespace but not always in the same way: echo foo bar prints foo bar, but so does echo foo   bar. This problem can be solved by placing " " quotes around the expansion, though you will have to either escape them so the Ruby interpreter doesn't take them as ending the "-quoted string and starting a new one, or you can '-quote the Ruby string and escape any internal ' characters.

You also get a wrong result in the less common situation that the value of ENV_VAR begins with an option that echo supports. Different echo implementations support different options; -n and -e are common. Most shells have echo as a builtin and may support different options from other shells and from /bin/echo. This is to say that echo is not very portable. It's reasonable for inspecting environment variables interactively, when you'll probably realize if something odd is happening, but less so for scripting. echo's portability woes are exacerbated by how /bin/sh is not always bash. In Ubuntu it is dash. This can be avoided by using printf '%s\n' or printf "%s\n" instead of echo (or, in your case, printf %s might suffice).

Thus your solution can be improved to capture('/bin/sh -c \'printf "%s\n" "$ENV_VAR"\''). This may look wrong to experienced shell scripters who do not know Ruby; note that Ruby, unlike Bash and other Bourne-style shells, treats \' as a literal ' inside a ' '-quoted string. Even though it's correct, your colleagues will have to look at it twice to satisfy themselves of that, even if they are proficient in both Ruby and shell scripting. capture('printenv ENV_VAR') is simpler.


My active window is "underneath" the XFCE panel (eg. toolbar). How to fix this?

From the panel preferences (accessible by right click on the panel) make shure that "Don't reserve space on borders" is unticked as shown below:


Why does Ubuntu really slow down the rest of my home network?

My guess is that there is a specific program that could be eating up your bandwidth and without actual data it is harder to debug.

There are a lot of different ways you can see what applications and services are eating bandwidth.

nethogs is a per application based solution
ntop is an overall statistics solution
netstat is also a good way to see which services are connected
bmon is a nice real time monitor

I would also check your router logs and see if Ubuntu is trying to use some services from your router, but being denied or generating errors.

Once you post more information I can try and debug further.


Deleting files from external NTFS drive in Nautilus

I found an answer but i'm not sure if it's safe to try it since my partition is mounted as NTFS in /mnt/DATA and i have important data inside. So basically, the answer sais i have to edit the /etc/fstab file (sudo gedit /etc/fstab). There, on the line for the required partition i should put uid=1000 and restart the OS. Sincer my partition is called 'DATA', this is the one that should be modified
(/dev/disk/by-label/DATA /mnt/DATA auto nosuid,nodev,nofail,x-gvfs-show 0 0).

EDIT: This method works! The answer was found here (Can't move files to the trash [duplicate]) on dr mat's post, at Mukesh Sai Kumar's suggestion. Since i am the owner for Trash, i didn't have to apply the steps regarding deleting and recreating it. Thanks!


Make my external camera (webcam) as default for Telegram Desktop

I have found the video call settings. It was a matter of selecting the default input video there. However, I think video call setting is a little hide in the settings menu.
Settings → Advanced → Call settings (in system integration section)


Getting 2 monitors to work off a Lenovo Docking station Ubuntu 17.10

Seems likely your video hardware can drive only 1 monitor at a time.  You plug in 2, but it only uses the more preferred type. Usually, unless you have special video hardware (Nvidia quadro, for example), your system supports one external monitor.  We have lots of Dell laptops with VGA, HDMI, and mini Display ports, but only one works at a given time.

If you think that's wrong, write back to tell us what kind of graphics devices you have and what models. Can you show us output from

lspci

For comparison, here are my video lines

00:02.0 VGA compatible controller: Intel Corporation HD Graphics 530 (rev 06)
01:00.0 3D controller: NVIDIA Corporation GM107GLM [Quadro M1000M] (rev a2)

The Nvidia quadro does allow me to use both devices at onces for 2 monitors, but most of the laptops around here do not allow it.


Ubuntu 18.04 Login Shows Dialog Box vs. Greeter

I figured out what was causing this problem. I was testing the new communitheme and it was loading a CSS that had issues.

Option 1 - Remove the theme

sudo apt-get remove ubuntu-communitheme-session

Option 2 - Change the CSS you are using with the following command

sudo update-alternatives --config gdm3.css

You will be prompted to select an alternative select the path "/usr/share/gnome-shell/theme/ubuntu.css"

Reboot and it will be back to normal.


How to wake from suspend with USB keyboard (16.04 LTS)

Below is a pure udev way of doing what is suggested https://askubuntu.com/a/848699/1048516.

Become root
Get a rough idea of where mice and keyboards are connected:

# udevadm info  /dev/input/by-path/*-kbd
P: /devices/pci0000:00/0000:00:14.0/usb2/2-3/2-3.1/2-3.1:1.0/0003:045E:001D.0002/input/inp
ut4/event4
[...]
# udevadm info  /dev/input/by-path/*-mouse | grep P:
P: /devices/pci0000:00/0000:00:14.0/usb2/2-4/2-4:1.0/0003:046D:C03D.0001/input/input3/event3
P: /devices/pci0000:00/0000:00:14.0/usb2/2-4/2-4:1.0/0003:046D:C03D.0001/input/input3/mouse0

from the path, keyboard is at usb2/2-3/2-3.1 and mouse is at usb2/2-4
Check current state of wakeup:

# grep . /sys/bus/usb/devices/*/power/wakeup
/sys/bus/usb/devices/1-1/power/wakeup:disabled
/sys/bus/usb/devices/2-10/power/wakeup:disabled
/sys/bus/usb/devices/2-3.1/power/wakeup:disabled
/sys/bus/usb/devices/2-3/power/wakeup:disabled
/sys/bus/usb/devices/2-4/power/wakeup:disabled
/sys/bus/usb/devices/2-8/power/wakeup:disabled
/sys/bus/usb/devices/4-1/power/wakeup:disabled
/sys/bus/usb/devices/usb1/power/wakeup:disabled
/sys/bus/usb/devices/usb2/power/wakeup:disabled
/sys/bus/usb/devices/usb3/power/wakeup:disabled
/sys/bus/usb/devices/usb4/power/wakeup:disabled

Add the below to the file /etc/udev/rules.d/10-wake-computer-with-keyboard-or-mouse.rules

# /etc/udev/rules.d/10-wake-computer-with-keyboard-or-mouse.rules

# - enable wakeup on ALL USB hubs (0-99)
# e.g. ls /sys/bus/usb/devices/usb*
# - rumor is that this step may not be necessary
# on all computers
# (I couldn't figure out how to enable wake on
# only parent hub of the keyboard and mouse.)
KERNEL=="usb[0-9]|usb[0-9][0-9]", SUBSYSTEM=="usb", DRIVER=="usb", ATTR{power/wakeup}="enabled"

# enable wakeup for all keyboards
# Keyboards are HID class 3 protocol 1 devices.
SUBSYSTEM=="usb", ATTRS{bInterfaceClass}=="03", ATTRS{bInterfaceProtocol}=="01", ATTR{../power/wakeup}="enabled"

# enable wakeup for all mice (button click, not movement)
# Mice are HID class 3 protocol 2 devices.
SUBSYSTEM=="usb", ATTRS{bInterfaceClass}=="03", ATTRS{bInterfaceProtocol}=="02", ATTR{../power/wakeup}="enabled"

reload and trigger udev:

# systemctl restart udev.service
# udevadm trigger

check allowed wakeup status again:

# grep . /sys/bus/usb/devices/*/power/wakeup
/sys/bus/usb/devices/1-1/power/wakeup:disabled
/sys/bus/usb/devices/2-10/power/wakeup:disabled
/sys/bus/usb/devices/2-3.1/power/wakeup:enabled
/sys/bus/usb/devices/2-3/power/wakeup:disabled
/sys/bus/usb/devices/2-4/power/wakeup:enabled
/sys/bus/usb/devices/2-8/power/wakeup:disabled
/sys/bus/usb/devices/4-1/power/wakeup:disabled
/sys/bus/usb/devices/usb1/power/wakeup:enabled
/sys/bus/usb/devices/usb2/power/wakeup:enabled
/sys/bus/usb/devices/usb3/power/wakeup:enabled
/sys/bus/usb/devices/usb4/power/wakeup:enabled

test (one of various methods)

# systemctl unmask suspend.target
# systemctl suspend


Getting touchpad to work in desktop ubuntu

Try touchpad indicator. That may solve your problem.

http://www.webupd8.org/2010/11/touchpad-indicator-lets-you-quickly.html


How do I install Ubuntu 12.10 if GParted detects no drive, Western Digital SATA hdd?

How should I proceed with installing Ubuntu 12.10 in this case?

You are using a SATA disc with a controller that Gparted does not seem to recognize. For such cases you need to use the alternate installer.

The alternate installer has some extra checks and will show you a list of drivers to select for your controller. So (obviously) to get the correct one you need to find out what type of controller you have. You might be able to find this information in your manuals, maybe in your BIOS or maybe from the live CD (lspci and/or dmesg | grep SATA). It might be useful to include hardware specs in your question (and someone might be able to tell from that what the controller might be).

The iSCSI part is probably shown due to selecting the wrong controller. It is a setup where you provide IP and port to get to the controller. The IP I am unsure of but al lot of examples I see state 192.168.1.10 with port 3260 (is the default).

I found the following, that looks like your issue, on launchpad: https://answers.launchpad.net/ubuntu/+source/linux/+question/122781

There is a command there

dmesg > ~/out123.txt; gedit ~/out123.txt; rm ~/out123.txt

Search for lines that state ata and look like errors. From the topic it shows [ 8.188025] ata3.00: failed to IDENTIFY (I/O error, err_mask=0x4) where the last reply is not very reassuring.

Also found a note about checking BIOS and set data mode not to RAID.

I shall try to expand this answer; comments are getting out of hand


How to identify Ubuntu's Release version via the GUI?

Gui : Go to system settings --> about system.

With commandline : lsb_release -d


Right click on the panel (Not running application) -> Task Manager Settings -> General -> uncheck "Show Tooltips"


You most likely introduced some error in the passwd's syntax. You need to fix it.
Might be through editing from Windows you have introduced Windows line endings, try:
sudo apt install dos2unix
sudo dos2unix /etc/passwd


Can't import installed packages in python

The issue is that when you install things with sudo apt-get install (or sudo pip install), they install to places in /usr, but the python you compiled from source got installed in /usr/local. The python you actually end up running when you type python at the prompt is the one you compiled (based on the output of the python -c 'import sys; print(sys.path)' command), and it can't find the python packages installed in the /usr directory. However, Ubuntu comes with python (both python 2 and python 3) already installed in the correct location, where it will find the installed packages. So a general recommendation is to try not to mix installation methods like this. Ubuntu has many software packages available through the official repositories which obviates the need to do much compiling yourself, and it's generally recommended to install software via apt when possible.

That said, for python packages (like Pygame and Beautiful Soup), things can get a bit more complicated. Mixing pip and apt-get can cause troubles down the road, so one approach to keep things simple is to stick with just the system package manager. If you end up needing to use pip because the package manager doesn't have things you need (or up to date versions), it's better to work within virtual environments and use pip for all the python packages you need within that virtual environment.

To tell your system to find the default system python correctly (python 2, which is the default when you just call python), try rewriting the symlink that routes the python command at a prompt to the original destination:

sudo ln -s /usr/bin/python2.7 /usr/bin/python

Hopefully that should allow it to find the python packages you installed.


Here is a command line to stream webcam:

vlc v4l2:// :v4l2-dev=/dev/video0 :v4l2-width=640 :v4l2-height=480 --sout="#transcode{vcodec=h264,vb=800,scale=1,acodec=mp4a,ab=128,channels=2,samplerate=44100}:rtp{sdp=rtsp://:8554/live.ts}" -I dummy


Why did my middle mouse button stop working in firefox exclusively?

Purging Firefox removes global settings only, not the Firefox profile itself. To check whether it's an issue related to your Firefox profile settings, try creating a new, clean one:

mkdir /tmp/firefox-test
firefox -profile /tmp/firefox-test -no-remote &

/tmp/firefox-test can be removed afterwards. If the problem is persistent, you might want to take a look at your settings in the about:config URL, search for keywords like "mouse", "click" and "tab". Otherwise, you could check the prefs.js file in your Firefox profile folder which is located at ~/.mozilla/firefox/XXXXXXX.PROFILENAME/prefs.js. If you can't get any out of it, quit the Firefox instance using this profile folder and rename / remove this prefs.js file to reset your settings. If this still does not help, export data like your bookmarks and create a new profile using the Profile Manager which can be started with firefox -p.


EGalax touchscreen no input on Ubuntu 18.04

This is working on 5 of my machines and has the advantage that you can stop and start the touchscreen with systemD (systemctl status eGTouch.service)

Download the latest touchscreen driver from eGalax
Untar the files

tar xvzf eGTouch_v2.5.5814.L-x

Run setup

sudo ./setup.sh

Create the SystemD .service file.

sudo systemctl edit --force --full eGTouch.service

Paste the following unit file modification

#######################################################
#### eGalax Touch Unit File for auto start on boot ####
#######################################################
[Unit]
Documentation=man:systemd-sysv-generator(8)
SourcePath=/usr/bin/eGTouchD
DefaultDependencies=no
Before=sysinit.target
After=apparmor.service

[Service]
Type=forking
Restart=always
RestartSec=5
StartLimitInterval=60s
StartLimitBurst=3
TimeoutSec=0
IgnoreSIGPIPE=no
KillMode=process
GuessMainPID=no
RemainAfterExit=no
User=root
Group=root
ExecStart=/usr/bin/eGTouchD start
ExecReload=/usr/bin/eGTouchD restart
ExecStop=/usr/bin/eGTouchD stop

[Install]
WantedBy=multi-user.target
################################################

Then enable it

sudo systemctl enable eGTouch.service

Then restart it

sudo systemctl restart eGTouch.service

Then reboot

sudo reboot


Can I access my Ubuntu One account via FTP?

Yes you can. See James Henstridge's u1ftp, at https://launchpad.net/u1ftp, and some description of it and videos at http://www.kryogenix.org/days/2012/09/11/accessing-ubuntu-one-file-storage-via-ftp-from-any-os.


Allow programs to access /etc/alternatives, i.e. use --private-etc=alternatives

Long answer (maybe helpful for other "command not found" errors): Find out, which binary is actually executed

$ whereis javac
javac: /usr/bin/javac /usr/share/man/man1/javac.1.gz
$ ls -l /usr/bin/javac
lrwxrwxrwx 1 root root 23 /usr/bin/javac -> /etc/alternatives/javac

And here we have the culprit: /etc/alternatives


I looked forward to your problem and found two solutions.

Try reinstalling Spotify and Barckets.

2.Reinstall your Ubuntu system with the command:
sudo dpkg-reconfigure -phigh -a

*Note that step 2 erases your data so back all your data before reinstalling.

Hope this works for you as this worked for my friend :D !!!


Left CTRL key is not working after updating to 18.04

Try Resetting keyboard shortcuts in Settings > Devices > Keyboard.


Ubuntu 20 application menu scrolling issue

I was also facing same issue.
Did you change shell theme in "Gnome Tweaks"?
Try changing theme of shell.
Go to Tweaks > Appearance > Shell and select Yaru-dark.
This worked for me.


VirtualBox boots only in UEFI Interactive shell

I encountered the same problem and found that if I issue following command in the interactive shell, the virtual machine would boot into Ubuntu:

fs0:\efi\ubuntu\grubx64.efi

(Use backslash, forward slash does not work. Commands in UEFI interactive shell are case insensitive.)

My VirtualBox version is 4.3.20 r96997, Ubuntu version is 14.10 AMD64. I do not know why this happens and how to solve it. Just found this not elegant and still a little bit troublesome workaround.

Update 1:

I read this, tracked down to a bug report and found a better workaround.

Update 2:

Workaround in Update 1 failed. I turned off the virtual machine, launched it. And it booted into UEFI Interactive shell again. According to this, the problem was probably cause by a VirtualBox bug. I am still looking for further solution to this.

Update 3:

Finally found an solution. According to this, you need to create a startup.nsh script manually. Except for the method in mentioned post, you can also do this:

$ sudo mount /dev/sda1 /mnt
$ cd /mnt
$ sudo sh -c "echo '\EFI\ubuntu\grubx64.efi' > startup.nsh"


This bug is confirmed. As packages require vivid tools, upgadring to 15.04 may be a workaround.


I think you need to check your video cables to be sure they are connected firmly. After that, I'd boot into single user mode and run the uninstall procedure that's provided by the NVIDIA install binary. How to uninstall manually installed Nvidia drivers? -- shows you how to do this. Then see if your pc boots fine, if it does, reinstall the nvidia driver.


How to create an empty file from command line

Use the touch command:

The touch utility sets the modification and access times of files to the
current time of day. If the file doesn't exist, it is created with
default permissions.

Example:

touch newfile


How do I always run in low graphics mode?

Just do the following. Go to System-administration-login screen and change to the safemode


UbuntuStudio 12.04 does not boot after install - no "intrd" image

Boot LiveCD
Mount installed system
Copy  cdrom/casper/initrd.lz  to /boot directory of the installed system
Delete broken initrd.img link and create new link at boot/inird.lz
the command is:

sudo ln -s /boot/initrd.lz initrd.img
Reboot
Edit grub line to boot system by changing root to sdd2 instead of hdd2

The System will boot now, but drop you into initramfs prompts

Create directory /mnt  by command mkdir mnt
Mount installed system, mount /dev/sdd2 -t  ext4  /mnt
Change root to the installed system by this command chroot /mnt
Now run this commands to go to /boot directory cd boot.
Create new initrd by this command update-initramfs -c -k all
Relink to new initrd by running this commands,

cd ..
mv initrd.img initrd.old and
ln -s boot/initrd... initrd.img , replace ... with your initrd version number

Exit chroot by command exit

Reboot now.


When you remove an interface completely from your netplan config, netplan (or specifically, networkd) can no longer distinguish between a removed config and an interface that you have manually configured outside of netplan.  You can remove the no-longer-used vlans manually at runtime from the command line after applying the netplan config, or you can reboot the system to get a clean network state.


Master Boot Record(MBR) of Windows is corrupted. Try to repair start-up of Windows using Automatic Start-up Repair. You need a Windows DVD to do so. But be careful you may not be able to boot into Ubuntu afterwords.


While removing mysql completely mysql-config-apt files are left and gives error

If apt is unable to do this for you, it may be necessary to use dpkg instead:
sudo dpkg --remove --force-all mysql-apt-config

From here, be sure to update apt:
$ sudo apt autoremove
$ sudo apt autoclean

Hope this helps


With 2 drives it is important to partition second drive as gpt partitioned not the usual default MBR(msdos). I might also make an efi partition on that drive even though system will only boot thru one efi partition. Then you could boot Ubuntu SSD without Windows drive, if you also install grub2's boot loader to both efi partitions.

Then you should be able to install in UEFI mode following the UEFI type installs.

I have only BIOS but use gpt and use gparted to partition drives.
I used gparted and selected gpt under device, advanced & select gpt over msdos(MBR) default partitioning....


Here you can find detailed info How to install and setup SmokePing on Ubuntu 10.10, 10.04, and for older versions as well. Hope it should cover your needs.


How to include all monitors in Gnome 3 workspace thumbnails

I think you want the "Multi Monitors Add-On" Gnome Shell Extension by spin83:
Multi Monitors Add-On by spin83
This duplicates the desktop thumbnails that are on the primary monitor on a second (and presumably third) display.
This allows you to see thumbnails on additional monitors but also drag thumbnails from desktop to desktop to re-arrange things on that additional monitor.  It's a wonderful extension.
IF you are reading this around December 2020, do get version 22.1 or later via github which fixes a bug that may cause recent versions of Gnome (like 3.38) to crash.
The author hasn't made a release of this version or posted it to extensions.gnome.org yet, but in time I expect they'll do so.


Open-source Blu-ray playback is a cat and mouse game, which involves constantly waiting for hackers to discover up-to-date keys to play more recent titles. But there is another option, involving partially proprietary closed-source software, which is (for the moment) free to use on Linux.

MakeMKV is an application that decodes Blu-ray disks and saves them to DRM-free files – they either have their own official decryption key or they have found one by hacking some OEM device and are keeping it unpublished to avoid it being revoked, and hence it can always decode the latest titles. It will eventually become a paid app, but is free to use whilst in beta (requires entering a new temporary activation code every 30 days, found here: http://www.makemkv.com/forum2/viewtopic.php?f=5&t=1053). It's been in beta for several years already, so here's hoping they do a GMail.

The marvellous thing about MakeMKV however is that it can "emulate" libaacs and libdplus – meaning any calls from apps that link to those libraries expecting the default open source decoder will instead get passed through MakeMKV's closed-source decoder – hence any video playback software which uses those libraries will automatically use MakeMKV's decoder and be able to play the latest titles.

To install and set up MakeMKV:

Step 1: Install it
(I built from source so haven't actually tried these packages myself)

sudo add-apt-repository ppa:heyarje/makemkv-beta
sudo apt-get update
sudo apt-get install makemkv-bin makemkv-oss

Step 2: Uninstall the open-source libaacs

sudo apt-get remove libaacs0

Step 3: Symlink MakeMKV's libmmbd to emulate libaacs and libdplus
(/usr/lib might not be the correct directory for you – do a search for "libmmbd.so")

cd /usr/lib
sudo ln -s libmmbd.so.0 libaacs.so.0
sudo ln -s libmmbd.so.0 libbdplus.so.0

And just like that, VLC (You may have to mount it before reading from device - /dev/sr0 for example) and other players configured to use libbluray will be able to play any blu-ray disk, without any "no valid AACS key found" errors.

Note: it might require a reboot (sudo shutdown -r now) to get VLC to work with libmmbd.so.0.


I think this might be because of UEFI. I did a quick search and found this, try it.

http://scienceblogs.com/aardvarchaeology/2013/12/16/tech-note-how-to-install-linux-on-a-laptop-with-uefi/


dpkg-buildpackage: dpkg-source: no upstream tarball found

I referred this blog and did the trick.

solution found from this forum

This command got fix my issue.

dpkg-buildpackage -b -rfakeroot -us -uc


Speakers make noise while headphones are plugged in Ubuntu 13.04

I found the solution. While playing with the alsamixer I scroll to the right and Disabled the option < Auto- Mut >. I don't know what's that for but know it's working fine.


I think I found the answer, but not sure how to make it permanent(I think it resets on reboot?)

First, do the above xinput list and get the id of your device. Not sure why, but there are 2 mice coming up with id=8 and id=10. I picked 8, and it worked.

I ran the following line xinput --set-prop "8" "Device Accel Constant Deceleration" 1.5, with the value of 1.5 being just tested and I found it pretty nice. Depends on mouse, so test different values etc.

However I guess you should create a bash script for this for it to work on startup. Not sure how to do so, but will figure it out I guess.


Which Linux distribution to choose for creating a USB boot-repair-disk?

Boot-Repair-Disk is based on Lubuntu, so select Ubuntu.


how to stop a script to start xampp by default in a startup

You can remove it with the following command:

sudo update-rc.d -f lampp remove


Changed settings, now slow startups and USB not working

Ok well I fixed one problem and found a work around for another. To fix the USBs I used the clear CMOS button on my motherboard. That was literally the only thing that would work. As for the slow startup, unplugging the power cable for 5 minutes, plugging it back in and booting up fixed it. It now passes the motherboard splash screen in under 2 seconds. Only problem is the slow boot problem congress back every so often and I have to drain the power again.


Latest update to 16.04 breaks wifi, sound

There arem many reports about the latest kernel not working for users.
the easiest solution for now would be to boot to a older kernel wich does not contain the bug or issues mentioned

See this article on how to boot older kernels trough grub

How can I boot with an older kernel version?


You may add your very own User with sudo rights.
You can create a User and add this User to the sudo Group.

sudo adduser youruser sudo

Or if you already have a user, you can add this to the sudo Group.

sudo usermod -a -G sudo youruser

After this log in to this user with su youruser and try to run the installation again with sudo yourinstallcommand.

You should never run any Installations with the root User. User always your very own User with sudo due to security reasons.


"More Apps" icon disappered on launcher. How can it be restored?

Make sure you have the package unity-place-applications installed and that the file /usr/share/unity/places/applications.place exists.


Ubuntu 16.04 32-bit - How to upgrade netbeans-8.0.2 to netbeans-8.2?

The recommended way to upgrade to NetBeans 8.2 is with the following commands:

sudo apt update
sudo apt upgrade
sudo apt install ubuntu-make # it's compatible with 16.04 32-bit
umake ide netbeans

These commands will install NetBeans 8.2 which is compatible with openjdk-8-jdk.
To start the NetBeans IDE Plugin Installer open NetBeans and from the menu bar select Help -> Check for Updates. This will offer updates to multiple NetBeans plugins including plugins for JavaScript, HTML5 Kit and Node.js Project Support.

The version of NetBeans from the default Ubuntu repositories is 10.0 in Ubuntu 18.04 and later.


Great amount of diskspace is used and I hardly have any files

Not clear myself why this happened but i can help you locate them

Open you Home Folder and do [ctrl - h] to reveal hidden folders

Navigate to /.local/share/Trash/expunged to remove the files permanently

Do not remove these folder however


login ubuntu program center,
search b43 find

firmware-b43-installer
and instal.

Or Look :http://forum.ubuntu-tr.net/index.php?topic=765.0


If you enable (this link tells you how) the partner repository within your software sources (and reload the list).

Now you should be able to install Skype in 11.04 from the Software Centre.

Screenshot, it happened.


Grub Boot Loader Error Occured when Ubuntu and SlackWare is Installed

Grub2 is the default bootloader in Ubuntu. Grub2 has the advantage that it brings up a menu on booting and it is possible to use the menu to dual boot with Ubuntu and other operating systems. Replace Slackware's default LILO bootloader with grub2. There are a few tutorials describing various ways of installing grub2 in the Slackware documentation, depending on what hardware you are using.

Boot-Repair can solve the majority of bootsector/GRUB/MBR problems.

Download boot-repair-disk.
Write it on a live USB stick using UNetbootin USB creator application.
Insert the Boot Repair disk and reboot the computer.
Choose your language.
Connect to the internet if possible.
Click the Recommended repair (repairs most frequent problems) button.

Reboot the computer.


USB AOC monitor displaying, but cannot move/see mouse pointer on 2nd monitor

Probably there is a gap between your monitors. Go to System Settings > Displays and check your monitor scheme. You must touch each other to ensure the mouse can move between them.


MSI Bigfoot gaming LAN Killer e2200 not working

This hardware is not yet supported by default.
Look at http://ubuntuforums.org/showthread.php?t=2008332
there is a patched version of the alx driver working with this ethernet


Transferring terabytes of data between two machines efficiently (samba and NFS mounts)

First of all, the error in rsync you quote seems to be that you pasted stuff into a terminal. It's not the original error message.

The original message, that you pasted into the terminal indicates that the connection was closed for some reason, like reboot, network problem or similar. But rsync should be able to resume.

Simply run

rsync -rvz --stats --progress /mnt/samba/my_15TB_data user@second_machine:/mnt/NFS/backup

once more, and it will check up on the status of the files, comparing time stamp and size, and ignores any file that have identical size and time stamp on source and destination side. This process will take some time, but unless it's a lot of very small files it will be quicker than re-transferring the files.

You can in general resume as many times as you want with rsync; it is a fairly robust file transfer mechanism.


Why do I get "Items Cannot be installed or removed until package catalog is repaired"?

Try this.

Open terminal with Ctrl+Alt+t

Type the following:
clear package database (just in case some of them were corrupted)

sudo apt-get clean

sudo apt-get autoclean

sudo apt-get -f install

then run

sudo dpkg --configure -a

and run this again

sudo apt-get -f install

if you get something like

0 upgraded, 0 newly installed, 0 to remove and 1 not upgraded.

then it failed. Else, you can try downloading the packages from Ubuntu Software Center

Btw, did you tick all options in Software Sources Options?:


HTTPS really shouldn't be blocked - it may be another network issue (with DNS or certificates etc). Anyway, you could try different commands:

Use HTTP instead:

curl -L http://deb.nodesource.com/setup_0.12 | sudo bash -

Use wget (or another downloader) instead, and execute it:

wget https://deb.nodesource.com/setup_0.12
sudo bash ./setup_0.12

All curl -L https://deb.nodesource.com/setup_0.12 | sudo bash - should do is download the script and run it as root, so it can be done in other ways. However it may be a good idea to talk to the people who run the setup if HTTPS is blocked/scanned  - as generally doing that makes things insecure.

You can install nodejs from the Ubuntu repos (with apt-get etc), but it may be a older version (see here)


How to play music on multiple Ubuntu machines simultaneously?

I'd recommend Icecast. You'll be able to install the Icecast streaming server on one of the laptops, which should be able to broadcast on your local network to an open port. You'll need to configure a streaming server (icecast) and a source client (IceS), but then you'll be able to broadcast from that server and tune into the stream from each other device you want to play the same track.

It's been quite some time since I've used Icecast, so I unfortunately don't know if I can give you a great step-by-step configuration, but hopefully you'll might be able to get started with their Basic Setup guide. It's not really a GUI process; it'll require manually creating and/or editing configuration files.


Easiest way, IMO, is to compile from source.

Just specify a location with 'prefix'

./configure --prefix=/home/your_user/
make
make install

Often the hardest part of compiling is installing the dependencies.


Write incrementing value to all files matching a filename in subdirectories

This should work for you:

/bin/bash
x=1
find . -name 'randomseed.txt' | \
while IFS= read file ; do
  echo $x > "$file"
  x=$(($x+1))
done

IFS= is to prevent breaking on spaces in file path if they exist, probably will not happen in your case.

Piping results of find into the while loop read which assigns the value to file then runs loop body. x=$(($x+1)) is your gross x+=1


It seems like your cerberus.crt is corrupted. How did you transfer the files to your client machine? Are you sure your keys are correct?
Have you used some other operative system for the transfer or have you edited the file, something that could have changed the way it was originally generated?
Did you use:

./pkitool cerberus

to generate the keys?
I have connected succesfully these configurations:
Client 11.10 (keys generated from a 10.04 server) -> server 12.04 (upgraded from 10.04, same key set as of 10.04 era).
Client 12.04 -> server 12.04 (both, client and server keys generated on a 10.04 server)
The only thing different between your conf files and mine, is that I don't have this line

tls-auth /home/fpayer/keys/ta.key 1

neither on server nor client


How can I minimize windows, only on a specific monitor?

Only minimize windows on one screen

The script below can be used to (only) minimize windows on the left screen or only on the right screen.

The script is run with either 1 or 2 as argument, depending on which screen you'd like to minimize the windows.

The script

#!/usr/bin/env python3
import subprocess
import sys

scr = sys.argv[1]

def get(cmd):
    return subprocess.check_output(cmd).decode("utf-8")

# find the right side of the left screen
edge = [int(s.split("x")[0]) for s in get("xrandr").split() if "+0+" in s][0]
# read the window list
wlist = [w.split() for w in get(["wmctrl", "-lG"]).splitlines()]
for w in wlist:
    # retrieve the window id and -position
    w_id = w[0]; xpos = int(w[2])
    # check the position of the window, decide action depending on arg.
    test = xpos < edge if scr == "1" else xpos >= edge
    if test:
        # check if the window is "normal" and / or minimized
        w_data = get(["xprop", "-id", w_id])
        if all([not "_NET_WM_STATE_HIDDEN" in w_data,
                    "_NET_WM_WINDOW_TYPE_NORMAL" in w_data]):
            subprocess.Popen(["xdotool", "windowminimize", w_id])

How to use

The script needs both wmctrl and xdotool

sudo apt-get install xdotool wmctrl

Copy the script into an empty file, save it as min_screen.py
To run it:

python3 /path/to/min_screen.py 1

to minimize windows on the left screen, and

python3 /path/to/min_screen.py 2

to minimize windows only on the right screen
If all works fine, add it to a shortcut key

Notes

The script assumes python3 is installed, but the code is not python3 specific I believe.
The script was written on Unity, but unlike workspaces (viewports), handling the screens should not make a difference.
The script will not minimize windows with pid 0 (Idle or other tkinterwindows for example). If that is an issue, please mention. Can be solved.

Explanation

The script first looks up the right edge of the left screen, by looking up the string with +0+ in the output of xrandr, looking like:

1680x1050+0+0

The first section, 1680, is the widht of the left screen. Subsequently, all we have to do is look into the window list (wmctrl -lG) and see which of the windows is "below" or "above" 1680, and act accordingly, minimizing with the command xdotool windowminimize <window_id> (or not).

Th "test" finally (mmiz): xprop -id <window_id> is to check if we are dealing with a "normal" window (instead of e.g. your desktop, which is also listed as a window), and if the window is already minimized.

See also the comment in the script.

Binding the script to a keyboard shortcut

1. On Lubuntu

To edit global keyboard shortcuts in Lubuntu see Lubuntu minimize all show desktop keyboard shortcut?

In this case: save script from this answer into a file on the computer, make this file executable, open /.config/openbox/lubuntu-rc.xml and replace

  <keybind key="W-d">
    <action name="ToggleShowDesktop"/>
  </keybind>

by

  <action name="Execute">
   <command>/path/to/show_desktop.py 1</command>
  </action>

where /path/to/show_desktop.pyis (of course) the path to the script, and either 1 or 2 the targeted screen. Make the script executable.

Restart computer to reload config.

2. Unity/Gnome

Make the script executable and choose: System Settings > "Keyboard" > "Shortcuts" > "Custom Shortcuts". Click the "+" and add the command:

/path/to/show_desktop.py 1

...to a shortcut of your choice


The dashes are the normal indicator that you have sound muted. The red is an extra reminder that happens when you try to play sound while it's still muted.


I'm confident you can just tell Grub about the Windows installation and use it to select the OS to load on startup. I haven't mucked about with this in a while, but this page should get you on the right track: https://help.ubuntu.com/community/Grub2


How can I include the mouse pointer using a command-line screenshot utility?

Well, was just looking for the same, and I stumbled upon this man page: https://manpages.debian.org/testing/scrot/scrot.1.en.html where I could see:
...
-p, --pointer
    Capture the mouse pointer.
...
18 July 2020    scrot-1.4

... and it links to a Github:
https://github.com/resurrecting-open-source-projects/scrot
Obviously, no apt for this on Raspbian Stretch, so I had to build it from source - but the --pointer option seems to work fine.


According to the developers there is no support for Last.fm/Libre.fm scrobbling implemented at the moment, but they seem to be positive for the future: https://answers.launchpad.net/music-app/+question/269528


How can I check which filesystems have greater than 85% usage?

I assume you want to list all file systems that are more than 85% full.

For this, we need to inspect and filter the output of df:

virtual file systems like tmpfs are not interesting, as they are located in memory and not on any disk, and also barely contain anything
we must filter the output by comparing the numerical value of the output's 5th (Use%) column to our threshold of 85%

df -h -x tmpfs -x devtmpfs | awk '$5+0 > 85'

If you want to include the column titles int he output as well, try

df -h -x tmpfs -x devtmpfs | awk '$5+0 > 85 || NR == 1'


Chrome/Chromium: 20-30 seconds delay before a download will start

I found a solution which is working for me. In Chrome or Chromium open extended settings and scroll down to the bottom and reset Chrome/Chromium completely. Your website-history, favs and your password-settings will not be touched.

But reactivate extensions like add-blocker and so on carefully, because in Chromium i had one of them in my list, which ist starting the above problem again.


How to know how much data is consumed in ubuntu

BitMeter OS is an open source bandwidth monitor with features similar to Networx. It has a Web interface and a command line interface as well. It also has an experimental desktop client. ".deb" packages can be downloaded from http://codebox.org.uk/pages/bitmeteros/downloads and installed with gdebi package installer or from the command line using (64-bit version)

$ sudo dpkg -i bitmeteros_0.7.6-amd64.deb

See http://codebox.org.uk/pages/bitmeteros for more information on the application.


Ubuntu 14.04 running slow on Compaq gq60 615dx 2009model

If you did what I did and installed it side by side, then yes your computer still can suffer from the malware from windows


Cannot remove website from the address bar suggestions

Strg is not same as the Shift key, Strg is equivalent to the Ctrl (control) key in a standard English keyboard.

Shift is the key above Strg (marked with an upwards arrow) in your screenshot.


You should not use desktopcouch for your application. If you want structured data storage in your application, you should start looking at using u1db instead.


I just down loaded Opera browser why is it no longer pinned to my menu the next day?

Open Dash (windows key) and search for Opera. Start it.

When started it will show an icon in the launcher. Now rightclick on the Opera launcher and choose "lock to laucher".

There are 2 possible launcher options:

lock to launcher
unlock from launcher

In case "lock to launcher" is shown the launcher will close when you close the application. When "Unlock from launcher" the icon will stick to the launcher when you close the application.

(this is valid for all launcher incons; not just Opera).


Add a kernel parameter ? `mmcblk.perdev_minors`

You can add kernel parameters in the Grub boot menu (which I assume is provided when you boot from CD). The following is from the top of my head and may not be totally accurate, so read the hints on the screen, too:

When the Grub boot menu appears press the letter e to change the selected boot option.
Select the long line with the kernel parameters (the second IIRC) and press e to edit.
Press End to set the cursor to the end of the line.
Enter the additional option(s).
Press 'Enter' to finish editing, b to boot with the current options.


How do I synchronize files or directories on an Android device with Ubuntu One?

The android app can be found here.

The way this works is that everything in the Ubuntu One folder (located in your home folder) is automatically synchronized to the cloud. You can add more folders to be synchronized by right clicking on them in the file manager and navigating to the Ubuntu One sub menu and finally clicking Synchronize This Folder.

On Android your photos are uploaded to a folder named after the model of your phone (mine is Pictures - HTC Ruby), and you can select files to be downloaded from Ubuntu One to your phone. These are not synchronized with their versions in the cloud after download, however. You can upload files within the android app by navigating into a folder and hitting the + icon in the right. You will need an app like File Manager installed to be able to just select any file from the SD card, however. To do this, select Add file after tapping the + icon and select File Manager (or your preferred app) from the list.

To get your pictures or other files in Ubuntu One on your PC you need to use the Ubuntu One app for Ubuntu (Open the dash and type Ubuntu One). Select the folders here that you want to sync to your computer:

The folders in the cloud that you select will be placed in your home folder and synchronized with other computers. For example I sync my scripts so I always have my most current work no matter which machine I turn on.

There is also a music app for Ubuntu One that requires a subscription to work. It can stream your whole music collection to you, which is great if you have an unlimited data plan. It can be found here, if you are interested.


Having trouble upgrading Linux kernel in Xenial

Okay as mentioned in my post the final answer was to reinstall Grub:

# purge old and reinstall new to sda
sudo apt-get purge grub grub-pc grub-common
sudo mv /boot/grub /boot/grub_backup
sudo mkdir /boot/grub
sudo apt-get install grub-pc grub-common
sudo grub-install --recheck /dev/sda
sudo update-grub


aplay -l says no soundcards found; alsaconf says no supported cords; yet /proc/asound contains cards

1.0.24 is quite old; you should at least use the 1.0.25 driver package.

Your aplay/amixer problems sound as if you have permission problems. Check that your user is in a group that has access to the device nodes in /dev/snd/.


Booting from cd, how update grub2 to reflect changed uuid?

Couple of steps to fix this:

Use sudo fdisk -l to get a list of the current partitions. Output will be of the form:

Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *        2048      391167      194560   83  Linux
/dev/sda2          391168    40429567    20019200   83  Linux
/dev/sda3        40431614    41940991      754689    5  Extended
/dev/sda5        40431616    41940991      754688   82  Linux swap / Solaris

Use sudo blkid device to get the UUID for your boot partition. Suppose it's sda1, then sudo blkid /dev/sda1 would give something like:

/dev/sda1: UUID="b3855dc7-ab6e-4167-92a8-7679477e17c2" TYPE="ext3"

Edit your /etc/fstab to reflect the new UUID:


Black screen when trying to install ubuntu

Try using the options acpi=off and noapic.
If it does not work you should try the text-based installation of the Alternate-CD.
http://releases.ubuntu.com/precise/


Launch two processes and return first process to the foreground so it can be killed with ctrl-c

&(Ampersand) sends the process to the background. It means if you run "run_webserver &" then this process will run in the backgrond.

You can bring this process to foreground by looking at the job id for the process in the terminal.

Steps to bring the process to foreground and kill

jobs :--> this command will list all the process running on the terminal.
fg  :--> this command will bring the process to the foreground.

Then you can use your ctrl-c to kill the process, or any other sequence which kills the process.

Please find the attached screen shots:-


Black screen when upgrading to 16.04 from 14.04

So I was able to fix it myself in the end. Update manager popped up asking to do a partial upgrade and I went through with it and everything seems to work now.


5Gb would be the unformatted capacity.  By the time it is formatted things like inode tables and other necessary things use roughly 3-5% of the unformatted capacity on that size drive.

The other part of the puzzle is the usual one when people ask "where has my disk space gone?"  Usually, disk drive size is given with the assumed value of 1Mb - 1000000 bytes.  Most operating systems however actually give real byte lengths for files, so the maths means that a 1Mb file is really 1048576 bytes effectively eating another 4%

The wubi installer will let you set much more than 11Gb for the virtual disk size but it seems likely that it was limited to this by the free space on your Windows partition.

A normal default install will be almost 4Gb, so it sounds like you may have a cut down version installed due to the small partition size.


I had a similar issue. For me it was due to an outdated kernel. Specifically, it was with a haswell cpu and ubuntu 14.04. The laptop idled at 60 degrees Celsius.

What is your kernel version and what os are you running?

Use the command uname -a in the terminal to determine the kernel version.

Edit: This could also be a graphics card issue, check your graphics card drivers if you have one to see if they are up to date. Search for additional drivers in the search box and verify that you are using modern drivers.

Edit: I haven't tried any of these methods but they might be worth a look.

http://itsfoss.com/reduce-overheating-laptops-linux/


Answer:
    mknod -m 666 /dev/fuse c 10 229

666 = perms
c = character device
10 = minor num for /dev/fuse in the host
229 = major num for /dev/fuse in the host

Thanks to
https://forum.proxmox.com/threads/kernel-module-fuse-for-lxc.24855/


Unable to install software with armv7l architecture (Xubuntu 13.10)

If you install either of the 32-bit or 64-bit packages, you will get the error as stated above, because neither of those two architectures exist on an ARMv7l device. Suggest you try downloading the "open source package" from the drop down (your choice which) and see if it can be installed on the ARMv7l architecture.

Usually such packages contain a README file for compilation steps and IF (and yest, that is a big if), it installs at all, then your device was open enough to allow you to compile the software or run the binary (if that is all that is available) on that 'odroid' device.

Can not provide the 'odroid' device support, but certainly the manufacturer could tell you if they have enough space or hardware to support the Splashtop Streamer you seek to use.

Do hope that help (HTH). Have a nice day.


How can I cut videos with otrverwaltung when avidemux crashes?

LiVES

For the more technically minded, the application is frame and sample
accurate, and it can be controlled remotely or scripted for use as a
video server. And it supports all of the latest free standards.

Available at the Software Centre.
OpenShot

OpenShot Video Editor is a free, open-source video editor for Linux
licensed under the GPL version 3.0.
OpenShot can take your videos, photos, and music files and help you
create the film you have always dreamed of. Easily add sub-titles,
transitions, and effects, and then export your film to DVD, YouTube,
Vimeo, Xbox 360, and many other common formats.

Also available from the Software Centre.
Pitivi

PiTiVi allows users to easily edit audio/video projects based on the
GStreamer framework.  PiTIVi provides several ways of creating and
modifying a timeline.  Ranging from a simple synopsis view (a-la
iMovie) to the full-blown editing view (aka Complex View) which puts
you in complete control of your editing.

Also available from the Software Centre.


I used the command xrandr to give me a list of my monitor names (DVI-D-0, DisplayPort-0, HDMI-A-0) and I used the following command to achieve what I wanted (which was to have my primary as a main) and monitor 2 and the TV mirrored.  since there are several types of linux versions available, you may have to use a different command.

xrandr --output DVI-D-0 --output DisplayPort-0 --output HDMI-A-0 --same-as DisplayPort-0


Temporary Failure in Name Resolution - NGINX

You've made a critical error.  You're trying to resolve DNS directly from your server without a DNS server to do recursive lookups on the server (resolved is just a 'forwarder' / stub - you still need to point it at an active DNS server, and you don't have one it seems on your system)
In your resolved.conf change your DNS= line to Google DNS (8.8.8.8) and then try again.  This will let you resolve things again.  DO NOT point your DNS at itself unless you install bind9 or some other type of DNS resolver that can recurse - you don't have that set up so you've fubar'd your ability to resolve any websites or domains.


Boot error: wpa_supplicant dbus_property=? on Ubuntu 18.04 LTS

The package wpa_supplicant provides client support for WPA and WPA2 encryption. If you expect that your wireless will successfully authenticate with a wireless access point, usually a router, that uses WPA and/or WPA2, then it is required to be installed and running.

  My system boots fine and Network Manager kicks in

I assume that your wireless then connects perfectly well.

wpa_supplicant[6756]: dbus: fill_dict_with_properties dbus_interface=fi.w1.wpa_supplicant1.Interface dbus_property=
wpa_supplicant[6756]: dbus: wpa_dbus_get_object_properties: failed to get object properties: (none) none
wpa_supplicant[6756]: dbus: Failed to construct signal
wpa_supplicant[6756]: dbus: fill_dict_with_properties dbus_interface=fi.w1.wpa_supplicant1.Interface dbus_property=

We see no error there, nor even any warnings. I suspect that these are informational messages only.

In any event, if your system boots normally and the wireless connects normally, as it apparently does, there is nothing to fix.


I'm no IBM bladecenter speciallist, but look:
try, if you have gnome network connection manager, ticking the "require ipv4 addressing for this connection to complete"
Or try setting up your DHCP to issue both ipv4 and ipv6 adresses (if this have changed in anyway)


ubuntu dist update python package failed

Fix packages on currently installed system
sudo apt --fix-broken install

sudo apt-get update
sudo apt-get install aptitude

sudo aptitude safe-upgrade
sudo aptitude upgrade
sudo aptitude dist-upgrade

sudo apt-get upgrade
sudo apt-get dist-upgrade

sudo apt --fix-broken install
sudo dpkg --configure -a

If you really want to upgrade to non-LTS 9-months supported-version (say to have many unnecessary upgrades to next LTS like: 20.04 LTS → 20.10 → 21.04 → 21.10 → 22.04 LTS), then allow such upgrade process and run it with supported correct method
sudo rm /etc/apt/preferences.d/pin-focal

sudo sed -i "s/^Prompt=lts/Prompt=normal/" /etc/update-manager/release-upgrades
sudo sed -i "s/^Prompt=never/Prompt=normal/" /etc/update-manager/release-upgrades

update-manager -c # in GUI or
# sudo do-release-upgrade # in terminal

Note: the last command should be run twice - first for 20.04 LTS → 20.10 and second for 20.10 → 21.04 . For the latter you may need to provide extra -d option.


Why does `svn` hang in `ssh` terminal but work from desktop `lxterminal` using `http` protocol?

I did some further experiments with my laptop sitting next to the Ubuntu machine that was causing me problems.  With them next to each other, I noticed that after I entered my svn password in the ssh session started from the laptop, I was getting a keyring dialog box in the desktop session. That's terrible behavior since I'm generally using ssh because I don't have access to the machine, but it was entirely the culprit.  If I clicked "Cancel" in that dialog box in the desktop session, the svn transaction in the ssh terminal would complete.

Armed with that information, I was able to track an apparently permanent fix.  In the file ~/.subversion/servers toward the bottom, there is an option commented out for store-passwords = no.  I uncommented that, and now it seems to work. It doesn't store the password, but that's what I wanted anyway.


After trying several things, I solved it by reseting the BIOS (Lenovo B570).

When you turn on the computer, press F2 to enter the BIOS, then reset it F9 .


Need help with a full install of Ubuntu 15.10 on flash drive?

From my understanding you want to a fully functional system installed onto the USB that runs on any computer. I haven't heard of anyone doing this outside of the after mentioned Live Boot. The installer is doing its job in creating the system partition on the USB as requested, but the boot loader is installed on the hard system. In other words it is on the computer.

I do not believe its possible to do want you want. As the primary disc (where your windows is installed) has the boot loader partition, and thus automatically installs grub there. I don't think its possible for a working computer to refer to its normal boot partition, AND a partition created on an external USB. Unless it was setup with the boot partition on the USB in the first place. Which can be done on a system without a pre loaded boot partition.
Your best bet is to stick with the live boot feature on the USB.
Goodluck hope this helps, and isn't totally wrong!


Partitions are usually the drive path followed by a number.
With this information, we can establish that /dev/sdb is the drive, and not the partition.

The partitions available on your /dev/sdb drive are:

   Device Boot      Start         End      Blocks   Id  System
/dev/sdb1   ?  1869771365  2038460886    84344761   69  Unknown
/dev/sdb2   ?  1701519481  3571400945   934940732+  73  Unknown
/dev/sdb3   ?        2573        2573           0   74  Unknown
/dev/sdb4      2885681152  2885733566       26207+   0  Empty

The partitions which are marked as Unknown are formatted in a partition table unknown to Ubuntu, you can solve this by formatting the partition table into a known filesystem type.


Can I make my QT GUI programs run after completely removing unity desktop?

Unity isn't a dependency of QT apps in any way that I know of. If your question is "How can I launch a program without Unity?" The answer is this: I wouldn't uninstall Unity at all because you don't need to. First press CTL-ALT-F1. Log in, and type xinit -- :1. Now, with the X Terminal, you can start you window manager (for example metacity) and anything else you want. To make sure you always have a working XTerm, remember to use & after commands.

Basically, this just creates a new X screen, and you can switch back to your main screen with CTL-ALT-F7. To go back to your new X screen, press CTL-ALT-F8. You can create up to 6 X screens at a time, each one corresponding to F7-F12. I hope this answers your question!


Why am I getting a mkdir error with this sudo mkdir /var/www/magento-dev.local/public command?

mkdir will fail if any directory in the given path (except the last) doesn't exist. Use the -p option to tell it to make such directories automatically:

sudo mkdir -p /var/www/magento-dev.local/public

Be warned that this can create problems if you made a typo:

sudo mkdir -p /var/www/magento-deva.local/public

This will create a magento-deva.local directory and a public directory in it.
Always double check your paths if you use -p.

From man mkdir:

-p, --parents
      no error if existing, make parent directories as needed


TFTP Server Install and Setup

Install following packages.

sudo apt-get install xinetd tftpd tftp

Create /etc/xinetd.d/tftp and put this entry

service tftp
{
protocol        = udp
port            = 69
socket_type     = dgram
wait            = yes
user            = nobody
server          = /usr/sbin/in.tftpd
server_args     = /tftpboot
disable         = no
}

Create a folder /tftpboot  this should match whatever you gave in server_args. mostly it will be tftpboot

sudo mkdir /tftpboot
sudo chmod -R 777 /tftpboot
sudo chown -R nobody /tftpboot

Restart the xinetd service.

newer systems:

sudo service xinetd restart

older systems:

sudo /etc/init.d/xinetd restart

Now our tftp server is up and running.

Testing our tftp server

Create a file named test with some content in /tftpboot path of the tftp server

Obtain the ip address of the tftp server using ifconfig command
Now in some other system follow the following steps.

tftp 192.168.1.2
tftp> get test
Sent 159 bytes in 0.0 seconds

tftp> quit

cat test

Source:
http://mohammadthalif.wordpress.com/2010/03/05/installing-and-testing-tftpd-in-ubuntudebian/


Firefox Developer Edition fails to update itself automatically although the settings show I allowed it to automatically install updates

I chose the chown fix, and it worked well for me.
Here is what you need to do:

Add Firefox Developer Edition PPA by following this tutorial.

Quit all Firefox instances. Also, make sure there is no more firefox processes running in the background.

Give the ownership of Firefox Developer Edition directory to your user by running the following command:

your_user_group_name = $(id --group --name)
sudo chown $USER:$your_user_group_name /path/to/firefox_dev -R

-R stands for 'recursively'

Your user group name may be the same as your user name. To check what groups your user belongs to, run groups $USER.

Finally run
 $ sudo apt update
 $ sudo apt install firefox

[2021 02 UPD]
I've been currently using Ubuntu 20.10 (groovy) and everything is fine.
Here's also the meta details and content of my desktop launcher icon:
$ ll ~/.local/share/applications/firefox-developer.desktop
-rw-r--r-- 1 MYUSERNAME MYUSERNAME 384 avril 20  2019 /home/MYUSERNAME/.local/share/applications/firefox-developer.desktop

$ cat ~/.local/share/applications/firefox-developer.desktop
[Desktop Entry]
Version=1.0
Type=Application
Name=Firefox Developer Edition
Icon=/home/MYUSERNAME/.local/share/umake/web/firefox-dev/browser/chrome/icons/default/default128.png
TryExec=/home/MYUSERNAME/.local/share/umake/web/firefox-dev/firefox
Exec=firefox-developer
Comment=Firefox Aurora with Developer tools
Categories=Development;IDE;
Terminal=false
StartupWMClass=Firefox Developer Edition


This page is outdated but it says, you can use a Live CD for disk partitioning

https://help.ubuntu.com/community/LiveCD#Reasons_for_Using_a_LiveCD_Session


Make sure that .htaccess file with the following content is created in the document root directory of your website:

# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>
# END WordPress

Also, check if using of .htaccess files is allowed in the Apache configuration.


I changed my user password, but now i can't login. What can i do?

You can do it from recovery mode.

Reboot from lock screen.
Press esc while rebooting.
Go to Advanced Options for Ubuntu.
Go to Ubuntu, with Linux 4.##-generic (recovery mode).
Got to root.
Press ctrl+d.
Now execute the following commands...

Remount root with write access.
mount -rw -o remount /

It should not output anything.

List users.
ls /home

Remember your username from the list.

Change your password.
passwd your_username

Type your new password and Press Enter.

Exit the terminal.
exit

Press Enter.


Ubuntu 18.04.2 (LTS) gets stuck in a login loop

Switch the login display manager from gdm3 to lightdm. LightDM is a more lightweight login display manager than gdm3. Download lightdm, change directories using cd to the directory containing lightdm_1.26.0-0ubuntu1_amd64.deb file that you downloaded, and run the following commands:

sudo apt install ./lightdm_1.26.0-0ubuntu1_amd64.deb
sudo dpkg-reconfigure lightdm
sudo reboot

sudo dpkg-reconfigure lightdm will open up a new window allowing you to select lightdm as the default login display manager. Use the arrow keys to select lightdm, press the Tab key to put the focus on <OK> and press Enter. Then reboot by running sudo reboot

If that doesn't work, try booting from Xorg instead of Wayland. Edit /etc/gdm3/custom.conf with sudo nano /etc/gdm3/custom.conf, uncomment #WaylandEnable=false so it is WaylandEnable=falseand runsudo dpkg-reconfigure gdm3 # select lightdm

You might need to delete .Xauthority (which is located in /home/your-username/.Xauthority) if the login loop persists after trying these suggestions. It will be created automatically the next time you reboot.


How to install another Ubuntu alongside different version of Ubuntu?

You should get the option to install alongside, it will not try to use a second drive if one is not available, it will attempt to create a logical partition within the existing setup.

You back up your existing install and the either shrink existing partitions and use the Something Else option to manually set partitions or let the installer do so.

If you do that the NEW install will install grub and the OLD system will be available as boot entry.


Determine which kernel ships with which Ubuntu version

14.04 and 14.04.1 had kernel 3.13

14.04.2 - 3.16

14.04.3 - 3.19

14.04.4 - 4.2

See LTS HWE Stack

The idea is that new installs on new hardware may need a new major kernels. Older kernels also get security and some hardware enablement updates.

But if you initially installed e.g. 14.04.2, and did updates, the Ubuntu version number will change to 14.04.3, then 14.04.4, but you will still have kernel 3.16.

If you want to install kernel 4.2 to the system that was not initially installed from an Ubuntu 14.04.4 image, you can run

sudo apt-get install linux-generic-lts-wily


If you only need the other Ubuntu for testing, then creating a virtual machine in VirtualBox is the easiest option.

Alternatively, if you only need a one-off Ubuntu instance then just booting from an Ubuntu LiveUSB may be enough.

I wouldn't resize partitions and install another Ubuntu just for testing, although you can do that too - you can have as many instances of Ubuntu (or different Linux distros) installed each in its own partition as you like.


How to move a part of my files to another ubuntu one account?

I think that the easiest way is to copy the files from the share on your computer to some other folder and offer that folder as a share to the other Ubuntu One user.


Vmware server vmnet module compilation problem

A similar question was posted on UbuntuForums for your version of Ubuntu.

The recommendation was to follow the link post - I've reproduced this below:

Download VMware-server-2.0.2-203138.x86_64.tar.gz from the vmware website and place it in /usr/src (you need to register on the VMware website before you can download)

Download my install file below and unpack it to /usr/src:

cd /usr/src
wget http://www.troublenow.org/files/vmware/vmware2.0.2-on-debian6.0.1.tar.gz
tar xvzf vmware2.0.2-on-debian6.0.1.tar.gz
cd /usr/src/vmware2
sh install-vmware-2.0.2.sh

This will unpack the files, patch them and start the vmware installation.
Answer all the questions during the vmware install and the installation should complete.

Now reboot the server and you should be ready to go.

The above vmware2.0.2-on-debian6.0.1.tar.gz file has the following content:

00-vmware-2.6.32_functional.diff
01-vmware-2.6.32_cosmetic.diff
02-vmnet-include.diff
install-vmware-2.0.2.sh
patch-vmware_2.6.3x.sh
vmware-config.pl.diff


A Music Player with CD ripping and CDDB lookup

There are players that can rip audio CDs, but one should consider the fact that this procedure may be tricky, not all are equally good, and specialized tools would fit the purpose better: Sound Juicer and Asunder in Gnome and related desktops, Audex, SoundKonverter and Asunder in KDE.

One of the most striking difference between all these (whether players or separate ripping tools) comes with CDs for which the metadata is not easy to find. You may need to try different tools to get the proper track names, so it's better to have 2 or 3  different such tools installed. (From my experience, Deadbeef, Qmmp, Amarok and Asunder rarely miss.)

That said, the already mentioned Rhythmbox is fine, except in KDE. For KDE, see below. It can even read the CD-Text data (track info present on the CD itself that can be accessed offline but not all players can read)

Deadbeef can work very well on all desktops and it is very light.

To get the CDDB info, version 6.2 needs you to un-check the option "Prefer CD-Text over CDDB" (under Preferences-Plugins-Audio CD player-Configure) - because of a bug.

Deadbeef can also read CD-Text.

In the past some codecs needed to be installed - like so - possibly this is not needed, but you can test

sudo apt-get install faac flac lame musepack-tools vorbis-tools wavpack

To start an Audio CD directly in Deadbeef the command to use is deadbeef all.cda. (That can be used in a launcher/icon etc.)

Wait for the CDDB metadata or CD-Text to be read. Before converting, you may select files and reload CDDB

To adjust converting settings, one cannot edit or remove the default configurations, but new ones can be created based on the default ones. Just select one of those as if to edit,

then select copy:

that will open the  'add new encoder' window. Make changes there (for example, for FLAC, level 8 is maximum compression), press ok and a new configuration is added.

More details in a special answer on this topic,here.

Banshee is still a good solution (but avoid it in KDE).

Once inserted, the Audio CD is displayed in the left pane. Select it, it will fetch the online track info. Press Import CD in the top right corner to rip. To set the ripping options right click Audio CD in the left pane, Audio CD Preferences (OR - Edit - Preferences in main menus), then: Source specific - Source - Audio CDs

You can chose between Wav, mp3, flac and ogg with various settings. It has a somewhat limited capacity of finding cd info online. Tracks go to ~./Music folder.

Qmmp - present in repos, but it's better to install the latest version

sudo add-apt-repository ppa:forkotov02/ppa
sudo apt-get update
sudo apt-get install qmmp qmmp-plugin-pack

It seems to lack an internal menu option to open audio CDs, but that can be easily fixed following this answer.

Enable converter and decoders plugins.

(At the plugins settings you can change also the interface: replacing the "skinned" Winamp-like user interface with the "simpler" one, which in fact is more fully-featured to easily access tabs, files and folders, etc. But the following does not depend on that.)

After opening the audio CD, Qmmp looks for proper names etc. Select them all, and go to 'Actions' -'Convert'.

Exaile version 3.4 and above can see the cd easily

The 14.04 version is 3.3 and lacks that. To install latest in 14.04:

sudo add-apt-repository -y ppa:nilarimogard/webupd8

sudo apt-get update

sudo apt-get install exaile exaile-plugin-contextinfo exaile-plugin-ipod exaile-plugin-moodbar

Click Import CD button above the list and it will convert the cd to flac in ~./

It works fine in both KDE and Gnome&co.

In KDE.

Amarok.

Just inserting a cd and starting the player you get the Audio CD entry inside Media sources - Local Music pane.

Right-click cd title: 'Copy to collection' > 'Local collection'

There you can select formats and advanced options

Then you can set tags, location (default ./Music), etc

Proceed, and you'll see the progress in the lower part of the player window.

Amarok can also read CD-Text. Ripping seems to take longer with this tool than with others.

Deadbeef is my favourite.


How can I run a at command with existing environmental variables and libs?

One of the reasons is because the at command scheduler is not set to run on a GUI display by default. It should work if you add export DISPLAY=:0 to myscrpit.sh above the line pycharm.py. You can check the DISPLAY variable by typing echo $DISPLAY in a terminal window.
The other reason is the environment variables. The $PATH variable in cron jobs may not contain all the paths where the executables are. There may also be library files.
You can check the path for the executables by typing which <excutable> (e.g. which gjs). For the library directory the varible is $LD_LIBRARY_PATH and to see where the libraries it uses, it's ldd $(which gjs).
Then add export PATH=$PATH:<exepath> and export LD_LIBRARY_PATH=<libpath> to your at scripts.


Can't play midi file, Gstreamer keeps asking for i386 plugin that can't be installed (64bit)

The issue still exists in Ubuntu 13.04 (64 bits). I can play midi with vlc (fluid-synth) and timidity but cannot with Totem/audacitous which keeps telling me to look for audio/midi decoder and cannot find them. I tried all kinds of wildmidi/fluidsynth/gstream-bad/timidity solution I could think about.

My ultimate goal would be to play midi files in chrome/firefox but it does not work. Too bad to see midi more and more unsupported while WebMIDI is starting to point out in HTML5


Increase ext4 partition size by decreasing Swap memory size in linux

It's pretty easy. Install GParted (available under your Software Center). Run, in a terminal, 'sudo gparted'. Type your password and press ENTER. GParted will open up. Right-click your swap partition and decrease its size to your needs. Be sure that the unallocated space generated by the size decreasing is "before" the swap partition, and not "after".

Now right-click your ext4 partition and select to increase/decrease size. You will be able to increase its size with the unallocated size now.


I found the problem. I had to run

systemctl enable test2d

else it wouldn't work.


Need the standard "gtk-color-scheme" for ambiance

Another way to set things back the way they were, at least for Ambiance and Radiance, is to run:

sudo apt-get install --reinstall light-themes

This will simply restore the Ambiance and Radiance themes to the version that is in the repos.

Also, for the future, it may be better to copy over whichever theme you plan to modify to the ~/.themes hidden subfolder in your home folder. Then, do whatever you want there. (If ~/.themes doesn't exist, just create it.) The advantage is that you have the original as a backup and don't need sudo to edit any files in ~/.themes.


From How does Ubuntu keep track of the “System restart required” flag in motd? You can see which packages requested the reboot:

$ cat /var/run/reboot-required.pkgs
linux-image-2.6.32-28-generic
dbus
network-manager

I try to remove old kernels before I do the reboot.  The removal of a kernel re-runs grub and triggers the reboot.


How to be warned when downgrading a package will break a depender

Let's take evince and gedit as examples. Open a terminal and run:

apt-cache show evince | grep Conflicts
apt-cache show evince | grep Breaks

This pair of commands will tell you if evince breaks or conflicts with something else. In my case I get

$ apt-cache show evince | grep Conflicts
Conflicts: evince-gtk

$ apt-cache show evince | grep Breaks
<blank>

so evince conflicts with evince-gtk that means they shouldn't be installed at the same time (APT will complain if this ever happens).

In my case evince doesn't declare to break any package so let's skip to gedit. Now, run

$ apt-cache show gedit | grep Conflicts
<blank>

$ apt-cache show gedit | grep Breaks
Breaks: gedit-plugins (<< 2.91)

As you can see gedit does not conflict with anyone. Nonetheless, it does break the package called gedit-plugins for versions strictly less than 2.91. That means gedit-plugins most be more recent than this version to work correctly with gedit and in particular APT will refuse to install gedit unless you remove gedit-plugins (<< 2.91) first.

Notice that even though the gedit-plugins in the official repositories are recent enough, you might want to download (from github maybe) a particular GEdit plugin that is older, this line serves you as a remainder that this older version should not work with the current GEdit version.

For more details about package relationships (and the official definitions of Breaks and Conflicts) refer to Debian Policy Manual - Chapter 7.


nginx-rtmp module can be installed directly from the Ubuntu 18.04 repository

  sudo apt install libnginx-mod-rtmp

The latest version of nginx supports dynamic modules, make sure the statement to load the module is added in the nginx.conf:

  load_module "modules/ngx_rtmp_module.so";

reference: https://stackoverflow.com/questions/36554405/how-to-enable-dynamic-module-with-an-existing-nginx-installation


If you use bash or bash.exe as mentioned by Terrance, you'll be invoking the default WSL distribution in your system which may or may not be Ubuntu or desired version of Ubuntu in case you have multiple distributions or multiple versions of Ubuntu. In those scenarios you can specify the distribution instead of bash or bash.exe, i.e.
ubuntu -c "whoami"

This would execute the command in default shell in non-interactive mode, i.e., environment variables won't be available at this stage (for example, SHELL and PATH). You'll get no result if you run
ubuntu -c "echo $SHELL"

As an alternative of c option, you can use run as well. From the help page of ubuntu (which can be obtained using ubuntu help):
run <command line>
    Run the provided command line in the current working directory. If no command line is provided, the default shell is launched.

The resultant command would be:
ubuntu run "whoami"

Footnotes:

Enclosing command in quotes is optional. Anyway you should escape the special characters (if used anywhere).
.exe is part is also optional after bash, ubuntu and even wsl.
ubuntu command can vary according to the version. For example, if you have installed Ubuntu, command would be ubuntu but for Ubuntu 18.04 and 20.04, it would be ubuntu1804 and ubuntu2004 respectively.


How to get an email notification when a USB storage device is inserted?

The way to do this is to use a udev rule which will apply to all USB storage devices from any manufacturer. For the email part, note that Ubuntu Desktop does NOT include any command-line email client, so unless you wish to install one, the notification script should communicate directly via raw SMTP commands to your local mail server.


After system reboot I got Exception handling console input error

Looks like the cause of this problem is broken kernel. I tried a workaround (adding --nojline to my arguments in start.sh) and it worked.
https://www.spigotmc.org/threads/ubuntu-18-04-bad-kernel-update.357871/


Failed to get properties: Launch helper exited with unknown return code 1

In my case the following command worked:

sudo service docker status


fail2ban is not sending mail when it bans an ip!

In the jail.conf file Look for the line:

action = %(action_)s

and change it to

action = %(action_mwl)s

or

action = %(action_mw)s


What Ubuntu 11.10 version, 32-bit or 64-bit, for laptop with Core i5 processor 8Gb Ram?

You should install 64-bit. You have a modern 64-bit processor and plenty of RAM. It's no longer the case that the 64-bit version is less stable, and virtually all software is available for both platforms.

I would say the only reason you should consider installing the 32-bit version is if there's some key piece of software that you need which is only available as a 32-bit version.


Working out what went wrong

Looking through the APT history log /var/log/apt/history.log I was able to determine that unattended upgrades had updated the Linux kernel from 4.4.0-104 to 4.4.0-112.

Start-Date: 2018-01-24  06:36:09
Commandline: /usr/bin/unattended-upgrade
Install: linux-image-extra-4.4.0-112-generic:amd64 (4.4.0-112.135, automatic)

The system hadn't been rebooted until immediately before the tuner stopped working, and so I assume that this was the first time the newer kernel was used.

Booting from the previous kernel at the Grub menu confirmed this was the cause, and I was able to re-build the driver for the kernel I'd used initially.

Getting it working again

Kernel version 4.4.0-110 included a host of changes to (I assume) address the Meltdown/Spectre vulnerabilities, so it makes sense to use the latest version for the added security and peace of mind it should provide.

The solution was to rebuild the driver as before, but using a fresh media_build directory. This ensured the modules were compiled and installed for the current kernel.


14.04: When changing the default desktop environment to to Gnome Flashback Compiz, and reboot I get a 'The system is running in low-graphics mode"

Try with this Gnome3 shell, remove the gnome-fallback-compiz
Remove this in terminal, DON'T purge anything and install:
sudo apt-get install gnome-shell ubuntu-gnome-desktop


Update Manager shows '2 updates have been selected' when there are no updates

I did some searching in Synaptic for packages that I had locked, and I found that two packages I had locked and forced the version of, so I unlocked those packages and now it doesn't show that '2 packages have been selected' anymore.
Still, I think this is a bug.


How do you use Q_INVOKABLE to access c++ functions in QML?

To make the KTerminalDisplay instance accessible from QML, you must register it in your main.cpp. Since you're expecting parent to be a QQuickItem, your question is not so simple. After looking at the terminal app, I can propose the following trick:

QQuickItem *item = view.rootObject();
KTerminalDisplay * display = (KTerminalDisplay *) item;
view.engine()->rootContext()->setContextProperty("kdisplay", display);

Once registered, you can call setFontStyle from QML:

kdisplay.setFontStyle("foo")

Note: See Embedding C++ Objects into QML with Context Properties as you can mark your method as a slot.

Source: http://developer.nokia.com/community/wiki/Calling_Qt_class_methods_from_QML


Although I am not yet running Ubuntu, I just had a similar problem with HDMI audio (analog audio worked fine) on my system (F17/KDE, Asus P8Z77-V, i5 CPU with HD4000 graphics, Panasonic TV), so I wish to share my findings:

Googling the problem bought me here, prompting to install mythtv (0.25.2). There at the advanced audio settings forcing the audio device (set to ALSA:hdmi...) to output 48 kHz made the buzzing go away as regards mythtv - probably similar to what you experienced.

As I have pulseaudio installed, the solution - at least for mplayer, vlc and mythtv -  was to set the default sampling rate to 48 kHz in /etc/pulse/daemon.conf (I do not have a PA config file in my home directory).

Before that I did some experimenting with ALSA and mplayer addressing the HDMI device without PA (suspending PA with the command pacmd and entering suspend 1): the problem persisted until I used the option -srate 48000 in mplayer (with PA active -srate did not help as the default sampling rate for PA is 44100 Hz).

In my case I did not need to set the (re-)sampling rate for ALSA, but if you still want to experiment with it, please bear in mind that an active PA can have an influence on the final sampling rate at your sound device. This rate you can see by checking out /proc/asound/cardX/pcmXp/subX/hw_params while playing audio (for me cat /proc/asound/card0/pcm7p/sub0/hw_params worked).


I could find two alternatives to keymon:

screenkey is packaged, maintained, but is not really useful for most screencast tasks.

kmcaster is not packaged, but the .jar file provided by the project should run on Ubuntu. A video compares it to key-mon:


How do I make vim the default graphical text editor?

OP fixed the problem here:

  Ok, I have created vim.desktop in ~/.local/share/applications and
  modified defaults.list (in the same dir) to include

text/plain=vim.desktop

  After that, sudo update-mime and its working! (I am not sure
  whether this step is require)

  Clicking on a text file opens vim, not gvim, in terminal and :q
  closes the terminal too.


It uses a number of anti-patterns, but it does the trick on my server:

ls -U | shuf -n 100 | xargs rm -rf

where you can replace 100 by the number of files you want to delete.

Caution, though, because the deletion is random, you have no control over which files you are deleting. This situation is not ideal and a better backup strategy which is easier to maintain is preferred.


How to enable laptop lid suspend using alternative window manager in ubuntu 20.04?

Check if pm-utils is installed, else install it with sudo apt install pm-utils
Create a backup of your login configuration file sudo cp /etc/systemd/logind.conf  /etc/systemd/logind.conf.back
Open /etc/systemd/logind.conf with root privilege with your favourite editor
Un-comment the following lines HandleSuspendKey=suspend, HandleLidSwitch=suspend and HandleLidSwitchDocked=suspend and save the file
Reboot the system

Hope it helps


How can I use gnome-terminal in qt creator?

This issue is reported as a bug in Qt Creator.
https://bugreports.qt.io/browse/QTCREATORBUG-1633

Update: Seems to be fixed on 31 Aug 2012.


Ubuntu 16.04 using a serial terminal with a FTDI chip usb virtual comport

The FTDI chip should be supported out-of-the box. Just connect the device and it will be available. The commands lsusb and dmesg | tail (directly after plugging in the device) are your friends here.

Serial COM Ports are addressed as /dev/tty* (hardware serial COM ports) while USB serials (like the FTDI chip) appear as /dev/ttyUSB* when they are connected.

Personally I like moserial which is available in the repository. Install it like so:

sudo apt install moserial

There you can configure your connection and read/write to the device.


ordering of executing preinst and config scripts

I've found a way to do it.

So, in order for single apt-get install my-mysql to work as described in question, I had to do several things:

make my-mysql package so it pre-depends on my-mysql-config and depends on mysql-server
create additional package my-mysql-config, which pre-depends on debconf and contains my-mysql-config.templates and my-mysql-config.config script (which among other things sets password so mysql-server-5.5 won't ask for it) containing code like:

. /usr/share/debconf/confmodule
db_set  mysql-server/root_password "$PW"
db_fset mysql-server/root_password seen true

db_set  mysql-server/root_password_again "$PW"
db_fset mysql-server/root_password_again seen true

also my-mysql-config.preinst contains code that does db_get and creates config files before mysql-server gets started
you can use my-mysql package .postinst script to run stuff you want after mysql-server is installed and running.

The Debconf Programmer's Tutorial was great help there, as was using export DEBCONF_DEBUG=developer and set -x in scripts for debugging.

Another two time-consuming issues for debug was making sure that config/preinst/postinst scripts do not output ANYTHING to STDOUT (as it breaks debconf in strange and interesting ways) and that you need db_stop if you do stuff like invoke-rc.d mysql restart or similar (or your apt-get will hang hard, without even responding to Ctrl + C)


Bionic: apt-get install docker-ce always hangs

In my case, the problem was I had to change docker daemon to dockerd in /etc/systemd/system/docker.service.d/service-overrides.conf.

After changing this, I got docker installed as usual with sudo apt-get install docker-ce docker-ce-cli.


Integrated Graphics not recognized on Ubuntu 15.04

You need to install Nvidia proprietary drivers to use nvidia-prime.
Run in terminal

sudo apt-get install nvidia-346 nvidia-prime

and reboot.

You will be able no switch adapters in Nvidia X Server Settings and by prime-select command.

If the 346 driver does not work well, you can install 352 by

sudo apt-get purge nvidia*
sudo killall nvidia-persistenced
sudo add-apt-repository ppa:xorg-edgers/ppa
sudo apt-get update
sudo apt-get install nvidia-352 nvidia-prime
sudo add-apt-repository -r ppa:xorg-edgers/ppa


Find all files with specific extensions that contains a string

You can do it with grep only (without using find):

grep --include=\*.{xml,py} -Rl ./ -e "Jason"

And to exclude .po:

grep --exclude=*.po --include=\*.{xml,py} -Rl ./ -e "Jason"


bash - merging 2 files using 2 common columns and add up the values of the 3rd column

The "classic" solution for this kind of thing uses an associative array in awk:

$ awk 'BEGIN{FS="\t"; OFS=FS} {a[$1 FS $2] += $3;} END {for (i in a) print i, a[i]}' file1 file2
nice:::Adj      a:::DT  2
house:::NN      nice:::Adj      1
apple:::NN      garden:::NN     20
garden:::NN     great:::Adj     6

(note that the output order is not guaranteed). A similar algorithm can be implemented in perl using a hash.

A newer tool that you may wish to try out is GNU datamash which allows grouping by fields and various mathematical operations on the results e.g.

$ cat file1 file2 | datamash -s groupby 1,2 sum 3
apple:::NN      garden:::NN     20
garden:::NN     great:::Adj     6
house:::NN      nice:::Adj      1
nice:::Adj      a:::DT  2


Ubuntu, messed up default group ownership

Barring anything else unforeseen at this time, I believe I solved my issue. I installed gnome-system-tools and found out that I accidentally changed my user's default group to :btsync. By using gnome-system-tools I was able to revert my mistake and change my default group back to :paul.

See this thread for more usage