How to run a program using the Nvidia card with bbswitch?

I found out by trial that the bbswitch daemon alone can only turn the power on for the card. The driver is not loaded and card is not functional. Installing bumblebee is the solution. If uninstalling bbswitch manually doesn't work (using purge bbswitch-dkms) bumblebee will uninstall it automatically.

Other things I found out by experience: sometimes bumblebee may not install itself properly or fails to automatically keep the dedicated card switched off, in which case purge bumblebee and reinstall.

Running bumblebee with primus is supposed to give better performance than the default virtualgl. Primus is included with bumblebee 3.1 onwards at the time of writing so there's no need to install primus manually.

If the command

primusrun <<APPLICATION NAME>>

doesn't work, use

optirun -b primus <<APPLICATION NAME>>

Useful links:

http://www.webupd8.org/2013/02/bumblebee-31-released-with-primus.html

http://techies.ncsu.edu/wiki/bumblebee

Do your research before installing and using if you are a newbie :)


Total CPU load won't exceed 90% - is this by design?

To test CPU capability outside of handbrake, you can force CPUs to 100%. Below are the steps from this answer: How do I stress test CPU and RAM (at the same time)?.

You can install stress with:

sudo apt install stress

Then call it with:

stress --cpu 8 --io 4 --vm 4 --vm-bytes 1024M --timeout 10s

On my conky display notice how:

In the top section CPU utilization spikes from 3% to 100%
In the middle the temperature spikes from 60C to 80C
At the bottom memory spikes from normal 2.75 GiB to 6.25 GiB

Type stress --help for a full list of options.


Fan sporadically maxed on wake-up due to unavailable sensor temperature

For now, as a workaround, I have moved to using thinkfan (http://manpages.ubuntu.com/manpages/bionic/man1/thinkfan.1.html) which can be configured not to use the disappearing temp value.


I'm guessing that you have been running Ubuntu from a USB stick?
When you do that, I think you have the option to save on that USB drive, or don't save anything. You may have done the latter, or if you run it again, you will find what you did.

There are a few options if you want to keep MacOS:

start the installer, choose install and see if you can choose : resize existing partition or anything like that : this will shrink the MacOS partition for you and install it next to it on the external hard disk
start the installer and install on the external drive (assuming you boot from 1 usb stick and you have another for storage, or an external SATA drive enclosure for example)

In the first way, you can install GRUB on the main hard drive, in the second you could install it on the external one.

I hope this gives you some pointers on where to go, in any way, make a backup of important data before you start and lookup how to boot macOS from the recovery partition if you may need to restore. Good luck!


How to loop over folders in a directory and take input into a list then print

With grep and sed:

grep -oP 'Elapsed time \(sec\):\K.*' {3..8}/OUTCAR | sed 's_/OUTCAR:__'

This uses the brace expansion {3..8}/OUTCAR to construct this list of arguments to the grep process:

3/OUTCAR 4/OUTCAR 5/OUTCAR …

grep searches these files for matching lines and outputs only the part after the colon with the relative file path and name. sed removes the unwanted file name part from every line, leaving just the directory name and the match (which already contains a space).


what you have to do it the following :

open up a terminal (Ctrl+Alt+T), (or preferably move to the folder with all the files you shared (install.sh, ect...) and right click on empty space and select the menu option "open in terminal"), if you simply opened up a terminal and are in the wrong folder you can put yourself in that directory in the terminal by typing cd Downloads/RTL8188C_8192C_USB_linux_v3.4.4_4749.20121105 (or whatever the real path to the folder is, cd means "Change directory"), then in the opened termianl window, type :

chmod +x install.sh

(if you wish to copy paste these commands in there are several methods, you can Ctrl+C them here then in the terminal Ctrl+Shift+V, or you can simply highlight them here, then in the terminal press down the scroll wheel)

then once you've done that we are certain your install script is executable (it very likely already was).

then you may execute it with :

./install.sh

it might prompt you for details as to your prefered instalations settings or it may be able to sort everything out on it's own.

.sh is a file extention for shell scripts a universal (universal as in, it .sh is runnable on every operating system) executable file type that cannot contain much beyond scripting. Scripts however are very usefull for both installing things and automating repeatable tasks.

this isn't the last time you'll use .sh files. Many linux programs use them as launchers or installers.

hope this helped! :)


What interface mockup programs are available?

As has  been suggested in many other similar threads, Pencil offers you a nice framework for prototyping and wireframing (even web stuff). And it's free.

I realise you've already said this isn't the answer you're looking for (having been linked to my question on the topic) but my scope is web development... Which is what you say you want to do. It's perfect for fleshing out page-level objects in a quick grid layout. Much more simple than a full graphics package, with various UI hints available as drag-on objects.

There's a deb package available for installation.


to me it sounds like your cd has a error that makes it unbootable.

Have you checked the cd or the download to see if it is corrupted? sometimes a the download can be corrupted check this website how to check for that:

Ubuntu MD5 sum help

If the iso is correct you could try to burn it to a new cd. I always use a USB for my installations since it is re-usable see:

Ubuntu usb installation


Why can't I delete or move these files without sudo?

Removing a file requires write permission in its parent directory - so may fail if either

~/Desktop/ has has incorrect permission bits
~/Desktop/ has correct permissions but has become owned by someone else such as root

Check and adjust as necessary.


I am running Kubuntu 20.04 LTS and this is in my fonts folder:
abyssinica
dejavu
droid
fonts-beng-extra
fonts-deva-extra
fonts-gujr-extra
fonts-guru-extra
fonts-kalapi
fonts-orya-extra
fonts-telu-extra
fonts-yrsa-rasa
freefont
Gargi
Gubbi
hack
kacst
kacst-one
lao
liberation
liberation2
lohit-assamese
lohit-bengali
lohit-devanagari
lohit-gujarati
lohit-kannada
lohit-malayalam
lohit-oriya
lohit-punjabi
lohit-tamil
lohit-tamil-classical
lohit-telugu
malayalam
Nakula
Navilu
noto
openoffice
padauk
pagul
Sahadeva
samyak
samyak-fonts
Sarai
sinhala
tibetan-machine
tlwg
ttf-khmeros-core
ubuntu

I can't tell you for other distros but I hope it helps anyway.


no 12.04 login after locking user account setting on autologin

You can log in on a virtual console (you must be doing that after pressing Ctrl+Alt+F1 but before running startx). So if the problem really is that you set a blank password for yourself (as MeM suggested), you can fix that easily by running:

passwd

Then change it to something that's not blank. You'll know it was changed successfully because the new password will work to log on at a virtual console. (You can type exit or logout to log off, then try logging back on.)

If that doesn't fix the problem, try disabling automatic login by editing /etc/lightdm/lightdm.conf with:

sudo nano -w /etc/lightdm/lightdm.conf

Remove the text that makes automatic login happen. That text looks like:

[SeatDefaults]
autologin-user=<YOUR USER>
autologin-user-timeout=0
user-session=ubuntu
greeter-session=unity-greeter

Source: htorque's answer to How do I enable auto-login in LightDM?


Desktop doesn't load after install/restart (dual boot)

Have a look at this post. If you installed ubuntu using a USB, then grub may have been installed to the usb, try booting with the usb connected. If you then see grub and can boot ubuntu, follow our solution in the above link or look at this page on my website for more details.

If not you could try booting the live ubuntu disc and using boot repair.


Thanks to this false bug report, which helped A LOT, the key is not to append

session-cleanup-script=/etc/lightdm/lightdm.conf.d/cleanup.sh

at the end of /etc/lightdm/lightdm.conf but to uncomment the #session-cleanup-script= line and add a value there, as position matters.

Good luck!


tmux start-server

should start it again.


Try switching to another tty (Ctrl-Alt-F1), login, then at the prompt type:

gnome-shell --display :0 --replace

Then switch back to the GUI (Ctrl-Alt-F7).

Also, are you sure its actually frozen? I have a problem where the password dialog isn't visible after the screen locks. Its actually there though and if you blind type your password and hit enter the screen unlocks. You might want to try that first.


How do I get the Wubi installer to use a pre-downloaded ISO?

Note: wubi.exe will say "downloading files" for a short time even if it is using the pre-downloaded ISO. Please follow the steps below and try again.

  Quick links to wubi.exe and appropriate ISOs:

  10.04.4 Lucid LTS: wubi.exe, 32-bit ISO, 64-bit ISO
  11.10 Oneiric: wubi.exe, 32-bit ISO, 64-bit ISO
  12.04 Precise LTS: wubi.exe, 32-bit ISO, 64-bit ISO

Requirements to use an existing ISO:

In general, here are the requirements to use a pre-downloaded ISO with Wubi along with my recommendations for a successful install:

You must download the desktop CD version of the ISO and place it in the same directory/folder as wubi.exe before running wubi.exe

Get both wubi.exe and the ISO from the same server folder, e.g. http://releases.ubuntu.com/lucid/
I highly recommend creating a new folder with but two files in it: wubi.exe and the ISO
The ISO can be 32-bit (i386) or 64-bit (amd64); Wubi will happily install whichever it finds in its folder.

Alternate/server ISOs are not supported
DVD ISOs are not supported except for Edubuntu

Illustration of the misleading "downloading/retrieving" issue:


This is a workaround. Not the actual solution for your problem:

Execute this command in Terminal:

  sudo chmod 777 /usr/share/applications/*

We permitted the entire world to change  your menu settings.
 So alacarte can save settings as well.

To revert this execute command:

  sudo chmod 755 /usr/share/applications/*


pkgProblemResolver error when running Package Manager and updating 12.04

I solved a problem involving a subset of the packages mentioned by the OP as follows:

sudo apt-get -f install
sudo apt-get remove evolution-plugins
sudo apt-get upgrade
sudo apt-get dist-upgrade

Note sure if all of these steps were essential...

Source: https://bugs.launchpad.net/ubuntu/+source/nspr/+bug/1036794


pulseaudio, replaced by jackd on demand only

Found the following solution:

only do install these sudo apt install jackd qjackctl
using pasuspender -- alsamixer as pulsaudio stopper, AND quick volume changer via up down arrows
then starting qjackctl, and the bitwig, or whatever other software needed
no magic :-)

would probably work without qjackctl, as jackd is communicating via dbus, so bitwig could start it on demand. I prefer to know what's happening exactly - dbus support can be disabled in qjackctl > setup > misc - more on this here
ocenaudio works with jack, whereas I didnt get VLC to connect/use it (for now, on it's wiki it says it's capable!). Firefox and Chrome dont work either... not a real issue for me.


Try using the key combination Mod4+r it will display the word Run: on the top (besides the tags, assuming you're using a barebones configuration) then you can type the program you want to run, if it's installed you can use Tab key for auto-completion.

E.g.:

Press Mod4+r
Note the Run: dialog at the top
Type thun then press Tab key if installed you will see that it completes to thunderbird and cycle with other similar commands/applications after pressing several times the Tab key
Press Return/Enter key to execute the program

Another options are:

Install dmenu found on package suckless-tools (something similar in Ubuntu?)
Load a menu (if not loaded!) for instance in Debian is done like this on the rc.lua file under ~/config/awesome/:

-- Load Debian menu entries
require("debian.menu")

-- {{{ Menu
-- Create a laucher widget and a main menu
myawesomemenu = {
    { "manual", terminal .. " -e man awesome" },
    { "edit config", editor_cmd .. " " .. awesome.conffile },
    { "restart", awesome.restart },
    { "quit", awesome.quit }
}

mymainmenu = awful.menu({ items = { { "awesome", myawesomemenu, beautiful.awesome_icon },
                                    { "Debian", debian.menu.Debian_menu.Debian },
                                    { "open terminal", terminal }
                                  }
                       })

mylauncher = awful.widget.launcher({ image = image(beautiful.awesome_icon),
                                     menu = mymainmenu })

Of course the file /etc/xdg/awesome/debian/menu.lua must exist or something similar, you can create your own.


Go in you menus to Tools > Preferences > Video > Output and select from the drop-down X11 video output (XCB).  Close down vlc and restart it.


Only close button shows up in Google Chrome in GNOME Shell

Okay, I've found a workaround involving the use of Ubuntu-Tweak. Using Window Manager Settings, check Custom under Window Titlebar Button Layout. Then simply moving one of the elements to a different location and then moving it back again will cause all the buttons to appear correctly.


If the LTS expires for Ubuntu 18.04 in april 2021, will the devs of third party apps immediately stop with releasing updates for Ubuntu 18.04?

From the fridge notice of Ubuntu 18.04.4's release

  Maintenance updates will be provided for 5 years for Ubuntu Desktop,
  Ubuntu Server, Ubuntu Cloud, and Ubuntu Base. All the remaining
  flavours will be supported for 3 years.

http://fridge.ubuntu.com/2020/02/12/ubuntu-18-04-4-lts-released/

Flavors only provide 3 years of support so their support only ends in April 2021 for 18.04 LTS (Ubuntu Studio excepted as it was not a LTS release).  The main Ubuntu has 5 years of support which can be extended through ESM if you need longer life (https://ubuntu.com/esm)

For Ubuntu Studio 18.04 (https://ubuntustudio.org/2018/04/ubuntu-studio-18-04-released/) it was a standard release (not a LTS or long-term-support release), however it's support can be extended to 3 years matching other flavors via the use of PPA (https://ubuntustudio.org/2019/04/ubuntu-studio-18-04-extended-support/)

The best place to check is always release notes for the flavor & release you're interested in.

For repositories best to look up https://help.ubuntu.com/community/Repositories/Ubuntu (noting the 5 years applies to 'main' software, and community based has the same support as the flavors do)


How do I set up network boot in Mythbuntu?

Install the necessary prerequisites.

You have the following 2 options:

If you already have a DHCP server on your network do the following:

sudo apt-get install mythbuntu-diskless-server tftpd-hpa
If you do not have a DHCP server on your network do the following

sudo apt-get install mythbuntu-diskless-server-standalone tftpd-hpa

Edit the tftp configuration

sudo vi /etc/default/tftpd-hpa
Edit the TFTP_DIRECTORY= to

TFTP_DIRECTORY="/var/lib/tftpboot/ltsp/i386"
Restart tftp

sudo service tftpd-hpa restart

Configure the overlay NFS export

sudo dpkg-reconfigure mythbuntu-diskless-server
Answer yes to both questions

Create the boot image

Check the following first

ltsp-build-client --extra-help
Start the image making

sudo ltsp-build-client --mythbuntu --mythbuntu-user-credentials="your-user-id-here:your-password-here"
For the credentials do not use "mythtv" it will already be created.
Later we will setup mythtv ID to auto-login.
This will install the image to /opt/ltsp/i386
This will take awhile!

Configure the DHCP server

For Untangle do the following
Go to the Web UI for Untange, Config, Networking, Advanced, DHCP &
DNS (from the dropdown). In the custom field box put

dhcp-boot=pxelinux.0,,X.X.X.X
Put the IP where you installed the diskless and tftpd packages
For DD-WRT you should be able to do the following --- Untested
Navigate to Admin>Services\
Add the following for Additional DNS options:

dhcp-boot=/pxelinux.0,,X.X.X.X
Put the IP where you installed the diskless and tftpd packages
For the mythbuntu-diskless-server-standalone package do the following
--- Untested

sudo vi /etc/dhcp3.conf
Add the following lines:

allow booting;
allow bootp;
class "pxeclients" {
   match if substring(option vendor-class-identifier, 0, 9) = "PXEClient";
   next-server 192.168.1.100;
   filename "linux-install/pxelinux.0";
}
The next-server directive indicates the TFTP server that the
system will contact. The filename is the init file that will be
loaded to provide the bootloader. This example is specific to the
Redhat and Fedora Core implementation and may vary depending on your
distribution. //Alternative dhcp.conf, assume your PXE root is
/mnt/pxe, and you assign your box a static IP of 192.168.1.60:

#option domain-name "domain";
default-lease-time 600;
max-lease-time 7200;
ddns-update-style ad-hoc;
subnet 192.168.1.0 netmask 255.255.255.0 {
   range 192.168.1.60 192.168.1.60;
   }
  option option-150 code 150 = text ;
   host mythtoo {
       hardware ethernet 00:14:2A:B3:E4:1C;
       option option-150 "/mnt/pxe/boot/grub.lst";
       option routers 192.168.1.1;
       next-server 192.168.1.90;
       filename "/mnt/pxe/boot/pxegrub";
       filename "/mnt/pxe/pxelinux.0";
   }

You can now boot your client

Any changes you make while your frontend is booted will be saved for
only that fronend on the server under
/var/cache/mythbuntu-diskless/overlay
Updating Configs/Adding Packages To the boot image
First mount /proc to the image

sudo mount -o bind /proc /opt/ltsp/i386/proc/
Switch to the image environment

sudo chroot /opt/ltsp/i386
Now do whatever you want as if you were on a frontend. Anything you
do here will be done for all frontends that boot via the network

Somethings you can do

Enable Mythbuntu repos

wget http://www.mythbuntu.org/files/mythbuntu-repos.deb
dpkg -i mythbuntu-repos.deb
dpkg-reconfigure mythbuntu-repos
apt-get update
apt-get upgrade
Configure Auto-Login

cd /etc/gdm
vi custom.conf
Paste the following

[daemon]
DefaultSession=mythbuntu
TimedLoginEnable=false
AutomaticLoginEnable=true
TimedLogin=mythtv
AutomaticLogin=mythtv
TimedLoginDelay=0

Configure frontend to connect to the backend for all frontends.

cd /etc/mythtv
Edit config.xml and mysql.txt

NVIDA-Drivers

Blacklist nouveau

vi /etc/modprobe.d/blacklist.conf
Add the following to the end of the file

blacklist nouveau
Install Nvidia Drivers

apt-get install nvidia-common
apt-get install nvidia-current
Go to Nvidia's website get the link for the current nvidia drivers.
Use wget to save it somewhere (I used /home/mythtv)
Continued after booting frontend
When done making changes do

exit
sudo umount /opt/ltsp/i386/proc
sudo ltsp-update-image
Remove Overlays for frontends already booted -IF NEEDED or WHEN YOU
WANT TO
Note this will remove all settings you made to your frontend when it
was booted

cd /var/cache/mythbuntu-diskless/overlay
sudo rm -fr *

NVIDIA-Drivers Final

Boot frontend

CTRL-ALT-F1
Login

sudo service gdm stop
sudo sh ./PATH_TO_DOWNLOADED_NVIDIA_DRIVERS
sudo service gdm start
To enable sound via HDMI
Open Terminal

alsamixer
Unmute the SPIF outputs to enable sound via HDMI


Problems with disappearing authentication window

This fix the problem.

sudo chmod +s /usr/lib/policykit-1/polkit-agent-helper-1

as simple as this...


How do you select multiple files in Ubuntu Touch file manager?

There is currently no way to select multiple files.  There are bug reports about it. This one is a current wishlist item.

https://bugs.launchpad.net/canonical-devices-system-image/+bug/1587499

Add yourself to it.


External Monitor not working. Ubuntu, nvidia

I recently installed the nvidia-418 driver on my laptop which uses Ubuntu 18.04. At first the external monitor worked perfectly, but after I switched from power saving mode (sudo prime-select intel) back to performance mode (sudo prime-select nvidia), the second monitor was not detected anymore.

I discovered that prime-select writes a configuration file which causes the problem. It enables the nvidia-drm modeset option. You can simply undo the change made by prime-select by commenting out this option. It will not be reset, because prime-select only writes this file when it does not yet exists.

Open the file in your favorite editor (vim, nano, gedit, etc.).

sudo nano /lib/modprobe.d/nvidia-kms.conf

And comment out the the nvidia-drm modeset option.

# This file was generated by nvidia-prime
# Set value to 0 to disable modesetting
# options nvidia-drm modeset=1

Hope this also helps you and many others!

ps: It is completely normal that the second monitor is not detected in power saving mode when the connection is part of the nvidia graphics card.


Are old WiFi AP settings stored in Ubuntu Server?

Your /etc/network/interfaces file uses the method 'manual' (I think you mean static) but declares no static address and other details. It also implies that your network is encrypted with WEP. WEP is extremely insecure and can usually be cracked in minutes. I strongly recommend you change the encryption in the router to WPA2-AES and then set up /etc/network/interfaces like this:

auto lo
iface lo inet loopback

auto wlan0
iface wlan0 inet static
address 192.168.1.150
netmask 255.255.255.0
gateway 192.168.1.1
dns-nameservers 192.168.1.1 8.8.8.8
wpa-essid ASUS-2.4
wpa-psk 222222222222

Of course, substitute your details here. Restart the interface:

sudo ifdown wlan0 && sudo ifup -v wlan0

Now is it stable?


In the dash type.

Displays

and then hit enter.

In this window you should see scale for menu and title bars.  This might have an effect on the program.

If this doesn't work you can also adjust the text size of Sublime Text it self.  You can find it outlined here - http://www.sublimetext.com/docs/3/font.html

which says

  Changing the font can be done via adding these lines to
  Preferences/Settings - User:

  "font_face": "Courier New",     "font_size": 10

  and then change as desired. The font will change when you save.

  You can see other settings to change by browsing through
  Preferences/Settings - Default. There are many things that can be
  customized in Sublime Text.

Finally if none of this works you could always use a lower resolution.  I personally find I run into problems with a lot of programs that where designed with 1080p in mind.  Obviously not something some one wants to hear when they purchase a nice 2k, 4k+ monitor.  On the plus side if you are on a laptop lowering the resolution to 1080p gives you better battery life and still looks good at least for me on my 2015 Razer Blade.


How to pass strings stored in variables to find command

If your variable might not contain what you think it does, use

set -x

to see the result of each expansion.

The shell processes the backslashes and double quotes in find commands, but it's not processing them the same way when it expands your variable...

On the command line, we write:

find "/path/to/Recycle Bin" -type d \( ! -path "/path/to/1/Recycle Bin" \) -or \( ! -path "/path/to/2/Recycle Bin" \)

If you've run set -x, you can see what Bash makes of that and what's actually passed to find:

+ find '/path/to/Recycle Bin' -type d '(' '!' -path '/path/to/1/Recycle Bin' ')' -or '(' '!' -path '/path/to/2/Recycle Bin' ')'

Quote removal on your variable doesn't happen (you put the \ and " characters in there, so you want them kept, right? These character have "resulted from the expansion" so they are not removed) (\" became " when you assigned it as you presumably intended because in double quotes backslash quotes the chars \$`"), but wordsplitting does:

$ find "/path/to/Recycle Bin" -type d $s
+ find '/path/to/Recycle Bin' -type d '\(' '!' -path '"/path/to/1/Recycle' 'Bin"' '\)' -or '\(' '!' -path '"/path/to/2/Recycle' 'Bin"' '\)'
find: paths must precede expression: \(

Quoting the variable fixes the bad word splitting but also prevents tokenisation:

$ find "/path/to/Recycle Bin" -type d "$s"
+ find '/path/to/Recycle Bin' -type d '\( ! -path "/path/to/1/Recycle Bin" \) -or \( ! -path "/path/to/2/Recycle Bin" \)'
find: paths must precede expression: \( ! -path "/path/to/1/Recycle Bin" \) -or \( ! -path "/path/to/2/Recycle Bin" \)

Pretty much anything you do with these two strings is going to result in find seeing the wrong thing. Getting your variable to contain only and exactly a string that expands to '(' '!' -path '/path/to/1/Recycle Bin' ')' -or '(' '!' -path '/path/to/2/Recycle Bin' ')' is a quote war I personally couldn't win.

Something like this will work fine

s="/path/to/1/Recycle Bin"
t="/path/to/2/Recycle Bin"
find "/path/to/Recycle Bin" -type d \( ! -path "$s" \) -or \( ! -path "$t" \)

You can also get away with it if you remove the need for quoting by not using paths with spaces - if you take out the backslashes and double quotes:

s="( ! -path /path/to/1/Trash ) -or"
s="${s} ( ! -path /path/to/2/Trash )"
find /path/to/Trash -type d $s

Maybe if you explain why you want to do it this way someone can suggest a better workaround.


You have two easy options:

You install the one in the official repositories. Open Ubuntu software Center and search for wine and install it. Alternatively in a terminal type sudo apt-get install wine.
If you wish to have the latest version you're better off adding the official wine ppa.
In a terminal type: sudo add-apt-repository ppa:ubuntu-wine/ppa
Followed by sudo apt-get update and finally sudo apt-get install wine1.7 winetricks


Mount partitions before apache starts (ubuntu 20.04)

Run
systemctl status apache(or apache2)
sudo vi /the/file/from/Loaded:/line/apache.service
add media-user-WWW.mount to the "After=" line.
save and exit


Xubuntu 12.10 won't boot into desktop on XPS L502x

Sounds like a driver problem for sure - if you can go back to the drivers you were using before installing bumblebee, might help?


Is it possible to automount local SMB/CIFS share from /etc/fstab?

Problem may be solved with one of the following solutions:

Quick dirty hack with /etc/network/if-up.d:

cat <<EOF | sudo tee /etc/network/if-up.d/zz-mount-all
#!/bin/sh
mount -a

EOF

sudo chmod a+x /etc/network/if-up.d/zz-mount-all

With this change it mounts normally:

$ systemctl status media-public_share.mount
● media-public_share.mount - /media/public_share
   Loaded: loaded (/etc/fstab; bad; vendor preset: enabled)
   Active: active (mounted) (Result: exit-code) since Вт 2017-12-19 23:17:34 MSK; 7s ago
    Where: /media/public_share
     What: //127.0.0.1/public_share
     Docs: man:fstab(5)
           man:systemd-fstab-generator(8)
  Process: 1481 ExecMount=/bin/mount //127.0.0.1/public_share /media/public_share -t cifs -o guest,noperm (code=exited, status=32)

It works even with localhost address.

It works as expected without hacks if I add x-systemd.automount,noauto to /etc/fstab as

 //localhost/public_share /media/public_share/ cifs guest,noperm,x-systemd.automount,noauto 0 255

and it creates two systemd units:

$ systemctl status media-public_share.*
● media-public_share.mount - /media/public_share
   Loaded: loaded (/etc/fstab; bad; vendor preset: enabled)
   Active: active (mounted) since Ср 2017-12-20 20:33:10 MSK; 3min 4s ago
    Where: /media/public_share
     What: //localhost/public_share
     Docs: man:fstab(5)
           man:systemd-fstab-generator(8)
  Process: 2461 ExecMount=/bin/mount //localhost/public_share /media/public_share -t cifs -o guest,noperm,x-systemd.automount (code=exited, status=0/SUCCESS)

дек 20 20:33:10 hostname systemd[1]: Mounting /media/public_share...
дек 20 20:33:10 hostname systemd[1]: Mounted /media/public_share.

● media-public_share.automount
   Loaded: loaded (/etc/fstab; bad; vendor preset: enabled)
   Active: active (running) since Ср 2017-12-20 20:33:02 MSK; 3min 12s ago
    Where: /media/public_share
     Docs: man:fstab(5)
           man:systemd-fstab-generator(8)

дек 20 20:33:09 hostname systemd[1]: media-public_share.automount: Got automount request for /media/public_share, triggered by 2456 (pool)
Warning: Journal has been rotated since unit was started. Log output is incomplete or unavail

But this solution adds two share icons to my Caja file-manager window.

So I'll use if-up.d hack.


GRUB menu gets skipped when using HDMI cable

Since it will not show you your grub screen at startup, there is something you can do to select what OS you want to boot to, but it will require booting to your Ubuntu first.

You can use grub-reboot to select the next one time boot.

First, make sure the default is selected for grub:

:~$ grep "GRUB_DEFAULT" /etc/default/grub
GRUB_DEFAULT=0

Here you can see that GRUB_DEFAULT is set for the first entry since it starts counting at 0.

Next, view all your entries that you have in your grub menu by using grep -i "menuentry '" /boot/grub/grub.cfg:

:~$ grep -i "menuentry '" /boot/grub/grub.cfg
menuentry 'Ubuntu' --class ubuntu --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-simple-9e4539a5-7229-424e-aa91-60ab1417e6f1' {
    menuentry 'Ubuntu, with Linux 4.4.0-53-generic' --class ubuntu --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-4.4.0-53-generic-advanced-9e4539a5-7229-424e-aa91-60ab1417e6f1' {
    menuentry 'Ubuntu, with Linux 4.4.0-53-generic (upstart)' --class ubuntu --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-4.4.0-53-generic-init-upstart-9e4539a5-7229-424e-aa91-60ab1417e6f1' {
    menuentry 'Ubuntu, with Linux 4.4.0-53-generic (recovery mode)' --class ubuntu --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-4.4.0-53-generic-recovery-9e4539a5-7229-424e-aa91-60ab1417e6f1' {
    menuentry 'Ubuntu, with Linux 4.4.0-52-generic' --class ubuntu --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-4.4.0-52-generic-advanced-9e4539a5-7229-424e-aa91-60ab1417e6f1' {
    menuentry 'Ubuntu, with Linux 4.4.0-52-generic (upstart)' --class ubuntu --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-4.4.0-52-generic-init-upstart-9e4539a5-7229-424e-aa91-60ab1417e6f1' {
    menuentry 'Ubuntu, with Linux 4.4.0-52-generic (recovery mode)' --class ubuntu --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-4.4.0-52-generic-recovery-9e4539a5-7229-424e-aa91-60ab1417e6f1' {
menuentry 'Memory test (memtest86+)' {
menuentry 'Memory test (memtest86+, serial console 115200)' {
menuentry 'Windows 10 (loader) (on /dev/sdh1)' --class windows --class os $menuentry_id_option 'osprober-chain-E2CAE74ACAE71A15' {

See the entry you want to have your system boot to by default for the next boot only.  Here we are going to use my Windows 10 entry.  We will set it up using grub-reboot command:

:~$ sudo grub-reboot 'Windows 10 (loader) (on /dev/sdh1)'

Then all I have to do is reboot the computer and it will go through the default countdown timer before booting to Windows 10.

:~$ sudo reboot

After you are done in Windows, simply reboot the computer and it will go back to Ubuntu as it is still the default.

Hope this helps as an alternative way to select your OS.


I believe the confusion here is related to the misunderstanding that path-to-download-package is figurative rather than literal. Assuming that your downloads are going to your default download directory you should be able to install with dpkg -i ~/Downloads/mendeleydesktop_1.17.13-stable_amd64 where mendeleydesktop_1.17.13-stable_amd64 is the name of the file you downloaded. you can get the exact path/to/filename with the command find ~/ -name *mendeleydesktop* | grep Downloads

If this sounds too complicated you an simply issue the command installpath=$(find ~/ -name *mendeleydesktop* | grep Downloads) && dpkg -i $installpath which will set the environment variable installpath equal to the full path to the file found by the find command and then use that to tell dpkg what to install.


WIndows boot loader not appearing in bios boot order after upgrading to ubuntu 19.04

See line 830:

=================== UEFI/Legacy mode:
BIOS is EFI-compatible, and is setup in EFI-mode for this live-session.
SecureBoot disabled. (maybe sec-boot, Please report this message to boot.repair@gmail.com)

So please report above message and get back to us with their reply.

It's been reported a bug in Grub 2.04 utilizes secure boot by default and downgrading to 2.02 fixes the problem:

Grub EFI amd64 no longer start EFI/Microsoft/Boot/bootmgfw.efi


Start Steam in Big Picture mode by default

Go to Settings and then Interface i think then you can toggle "Start into Big Picture mode"


Ex Falso will do the job; I use it to retag and rename my library all the time. To do this, select all of your folders containing music on the left, and then select all of the music you want to rename on the bottom. Go to the Rename Files tab and experiment with settings, using the Preview button to see where music will go. When you're satisfied, hit Save and it will organize them all. :)


In the z readme after line 48, it says:

  Installation:

  Put something like this in your $HOME/.bashrc or $HOME/.zshrc:

. /path/to/z.sh

  cd around for a while to build up the db.

You need to download the z.sh file to a directory of your choosing, then tell your .bashrc where it is, so your terminal can find it. (The same applies for z-shell, which is just another shell system.) Then, after you use bash for a while, z will know your favorite locations.


System slows down when creating new VM with VirtualBox but no obvious change in CPU, Memory or I/O usage in System Monitor

The problem is with the creation of the disk image.

Creating an 8GB fixed size disk image requires writing 8GB of blanks to the disk.

I've tested this on my system and my system consistently slows down as well during the creation of a fixed size disk image; the I/O saturation resulting from the task running at full speed clutters the system visibly:

(this was the absolute peak, it sat on average at around 75 MB/s).

The solution is to be patient and to wait for the task to finish; in general changing the kernel's I/O scheduler can help in case of intensive I/O activities.


All kernel upgrades hang on update-secureboot-policy --enroll-key

With ps you can see what whiptail is asking you. The problem is: Its output is being redirected to /dev/null. Some "higherup" script didn't want the clobber of one of the subscripts it was calling and redirects the output to devnull. But when you have secureboot, the update-secureboot-policy output becomes very important.

In the file /usr/lib/dkms/common.postinst you will find about 30 lines before the end a redirect to /dev/null. Remove the redirect.

On my system the non-normal stopping of the upgrades has mangled the system that it will no longer attempt installing the key. I hope yours is not in that state.....


what would be a better environment for a linux based retail Point of Sales program?

Lemon POS depends heavily on KDE dependencies, as such Kubuntu (Uses the KDE Desktop environment.) would definitely be the place to start looking. Also take the specifications into account as Lemon POS can work on any desktop environment as the needed dependencies will be installed automatically, however if KDE is to heavy for the system Xubuntu or Lubuntu may be a better choice.


You can have Ubuntu alongside of your Windows . even you can install it on a USB Memory Disk or external storage devices . I offering you to use windows and Ubuntu at first if you're newbie . These topics are helpfull if you want to start :

Can I remove Windows Vista from my notebook and only install Ubuntu?
How to partition a disk for installing Ubuntu?


CrashPlan desktop app suddenly terminated after Splash Screen

I have found a working solution (workaround) in an Eclipse related StackOverflow article: https://stackoverflow.com/questions/20203771/eclipse-continue-crash

And @Erigami have found a CrashPlan article:
https://support.code42.com/CrashPlan/Latest/Troubleshooting/CrashPlan_App_Closes_In_Some_Linux_Installations

Solution/Workaround

Have to add -Dorg.eclipse.swt.browser.DefaultType=mozilla JVM parameter to startup config of CrashPlanDesktop.

Open /usr/local/crashplan/bin/run.conf with sudo
Append -Dorg.eclipse.swt.browser.DefaultType=mozilla to end of GUI_JAVA_OPTS variable.
Save the file. It have to looks like this:
SRV_JAVA_OPTS="-Dfile.encoding=UTF-8 -Dapp=CrashPlanService -DappBaseName=CrashPlan -Xms20m -Xmx1024m -Djava.net.preferIPv4Stack=true -Dsun.net.inetaddr.ttl=300 -Dnetworkaddress.cache.ttl=300 -Dsun.net.inetaddr.negative.ttl=0 -Dnetworkaddress.cache.negative.ttl=0 -Dc42.native.md5.enabled=false"
GUI_JAVA_OPTS="-Dfile.encoding=UTF-8 -Dapp=CrashPlanDesktop -DappBaseName=CrashPlan -Xms20m -Xmx512m -Djava.net.preferIPv4Stack=true -Dsun.net.inetaddr.ttl=300 -Dnetworkaddress.cache.ttl=300 -Dsun.net.inetaddr.negative.ttl=0 -Dnetworkaddress.cache.negative.ttl=0 -Dc42.native.md5.enabled=false -Dorg.eclipse.swt.browser.DefaultType=mozilla"

It works! Cheers! ;)

Note

If you reinstall the app, the app automatically upgrades itself, then the run.conf file will be overwritten!


You'll need to upgrade the graphics. Gnome Shell requires hardware acceleration, which Intel's 8xx GPUs do not have.


After I did sudo apt-get install libc6-dev (because), this resolved all the kept-back packages (well, or maybe it was my apt-get dist-upgrade which I did after that, which failed though).


How can I use Google Drive on Ubuntu phone

It is a webapp. You will have to select in it to upload files, and then I think, select the photos individually from the content picker, to be able to upload them. It is the same as if you were using the https://drive.google.com/ site in a browser.


A .exe file is compatible with a Windows system, but this files are not compatible with Ubuntu. At least in a native way.

You can install WINE to install Windows programs. This is a software for running Windows applications in Linux platforms. I should mention that not every Windows program will run correctly with WINE. But you don't loose anything trying.

The apt command is not the way to install EXE files, the correct procedure is the following:

Install Wine
Open the exe file with Wine doing secondary click on the file and selecting Wine Windows Program Loader

The rest depends on the setup method of the software. Example:


problem with localhost And 127.0.0.1 on ethernet network in ubuntu OS 14.04

You can access localhost by typing either http://localhost or the actual ip address of the host (open terminal and run 'ifconfig' to find out correct ip of the specific computer host. ip must be set to static, by the way, in order for you to access always through the same address.
Type http://192.168.61.(machine)


Parse xrandr output to get available resolution

A simpler version of the awk command for the script:

xrandr |
  awk -v monitor="^$MONITOR connected" '/connected/ {p = 0}
    $0 ~ monitor {p = 1}
    p'

Bottom to top:

p tells awk to run the default action (printing) depending on whether it's true or false)
if the line matches the monitor and is connected we set p to true
for all other monitor lines we set p to false


Please open a terminal and do:

sudo apt-get update && sudo apt-get install build-essential git dkms
git clone https://github.com/tomaspinho/rtl8821ce
cd rtl8821ce
chmod +x dkms-install.sh
chmod +x dkms-remove.sh
sudo ./dkms-install.sh
sudo modprobe 8821ce

Your wireless should now be working.

Revision 31 July, 2019 9:40 am EDT


Resolution issue causing login screen loop

You can edit /etc/X11/xorg.conf by hand

Or you can use nvidia xconfig if you have the proprietary driver sudo nvidia-xconfig

Or sudo dpkg-reconfigure -phigh xserver-xorg

ref: http://doc.ubuntu-fr.org/xorg


apt-get install -f wants to remove a lot of programs

I had the same problem and ran this command in my command line

sudo -s
dpkg --configure -a

that should do it but it might take a while


To install to the system rather than your $HOME (and thus make Foxit accessible to all users) simply run the install script with elevated privileges:

sudo ./FoxitReader.enu.setup.2.1.0805\(r225432\).x64.run

Specify a system path in the 'Installation Folder' box that comes up:

And all should be well. The installer does not fully comprehend the use of sudo but rest assured it will be a system-wide installation and available to all users...

References:

How to Install Foxit PDF Reader 8.0 on Ubuntu 16.04 or Any Linux Distro


UnicodeEncodeError when attempting to create a RAID-1 Ubuntu Server

The error message suggests this is a bug in either subiquity or in one of its dependencies.

Please file a bug report at their project site:
https://bugs.launchpad.net/subiquity


How do I search for a file or directory in Ubuntu Server?

You name it: locate!

locate is a program installed by default that let you search for files/dirs by name, into its database updated with a cron job.

Go through the man page to see other interesting options, like regex search.

Moreover, you can use find to search on the current content of the filesystem (not on a database), with a full set of complicated options, that let you refine your search also based on metadata (permissions, modification time, etc.).


With Ubuntu 21.04, can Openbox be customized like the Openbox of other distros (eg BunsenLabs)?

Yes openbox can be customized; as it's a critical package supported by Lubuntu (https://people.canonical.com/~ubuntu-archive/packagesets/hirsute/lubuntu) but note we don't use LXDE and haven't since bionic so GTK makes no sense.. we use LXQt so we maintain it for that. OBMenu isn't a Lubuntu package, so will be upstream Debian's.
In fact obmenu hasn't been available since bionic (https://packages.ubuntu.com/search?keywords=obmenu&searchon=names&suite=all&section=all) so what obmenu where you trying to use? (I see obmenu only available for precise, trusty, xenial & bionic)
obmenu needs python2 so it's gone (as was anything else not ported to python3 in Debian & Ubuntu. Python2 is EOL if you didn't know; https://www.python.org/doc/sunset-python-2/ thus I asked where you got obmenu...
fyi: I'm using Lubuntu impish now, but I still consider my box a Ubuntu one...
lxappearance is a LXDE program, which was supported by Lubuntu until 18.04 for Ubuntu; however with LXDE using deprecated & almost completely unmaintained GTK2; Lubuntu followed LXDE devs to LXQt (Qt5) thus LXDE apps are no longer maintained by the Lubuntu team on later releases.
openbox is still a package we maintain as we still use it (and we concentrate on it's use with LXQt now, not deprecated LXDE). Key is you're talking about 'universe' packages, ie. community supported; lxappearance was a Lubuntu package, openbox still is a Lubuntu package in Ubuntu, but yes they are available for all to download and use.


Make the `diff` command look only for differences from a specified range of lines

diff <(sed -n 'S1,S2p' file1) <(sed -n 'S3,S4p' file2)

where

S1 is start line file1.
S2 is end line file1.
S3 is start line file2.
S4 is end line file2.

Skipping line 1-4:

diff <(sed -n '5,10p' file1) <(sed -n '5,10p' file2)

$ more file1
1
2
3
4
5
6
7
8
9
10

$ more file2
11
2
3
4
5
65
7
8
9
10

Result

2c2
< 6
---
> 65

-> it skipped the diff on line 1.

It might be easier to use a desktop tool for this. Meld is excellent ( topic on AU: https://askubuntu.com/a/2947/15811 ):

  Meld is a visual diff and merge tool targeted at developers. Meld helps you compare files, directories, and version controlled projects. It provides two- and three-way comparison of both files and directories, and has support for many popular version control systems.


GTX 760 software help needed for this nube

You can't install Windows software on Linux as an actual hardware controller. You'll have to stick with x server settings by nvidia


gnome-fallback-mount-helper I do not have this in my list of startup applications.

I'd like to know how I can get rid of this notification as well. It serves no purpose to tell me that it failed to mount it twice, because it is already mounted once. I'm not sure what that even means??? The popup is intrusive, and disrupts my activity, especially if I have to swap many blanks. At the very most, this notification should be in the corner like a notify-send message.


Mobile broadband: tries to connect, disconnects before being done


Why is fglrx's package version higher than fglrx-updates?

This has nothing to do with Canonical, but with availability from other sources. Did you by any chance try to install fglrx from the ati website or from a PPA?

With apt-cache policy <packagename> you can check which version is installed on your system and which version is in the repositories.

Output for fglrx:

fglrx:
  Installed: (none)
  Candidate: 2:8.960-0ubuntu1.1
  Version table:
     2:9.002-0ubuntu1 0
        100 /var/lib/dpkg/status
     2:8.960-0ubuntu1.1 0
        500 http://nl.archive.ubuntu.com/ubuntu/ precise-updates/restricted amd64 Packages
     2:8.960-0ubuntu1 0
        500 http://nl.archive.ubuntu.com/ubuntu/ precise/restricted amd64 Packages

Output for fglrx-updates

fglrx-updates:
  Installed: (none)
  Candidate: 2:8.960-0ubuntu1.1
  Version table:
     2:8.960-0ubuntu1.1 0
        500 http://nl.archive.ubuntu.com/ubuntu/ precise-updates/restricted amd64 Packages
     2:8.960-0ubuntu1 0
        500 http://nl.archive.ubuntu.com/ubuntu/ precise/restricted amd64 Packages

As you can see in the ubuntu repositories both are version 8.960, the 9.002 is only in my list because I installed it in the past from the ati website.

EDIT: You can check which version you have installed by

 dpkg -l | grep fglrx | grep ii

or if you installed without using the package manager

cat /var/log/Xorg.0.log | grep fglrx | grep -A4 'Kernel Module Version Information'


xsane detects scanner but freezes when scanning

I was able to solve the problem by getting rid of the user xsane directory, like so:

mv $HOME/.sane/xsane $HOME/.sane/xsane.bak


No button on login screen for switching between gnome, unity2d

OK. I've recreated greeter in terminal:

Click on the Ubuntu icon right of the username. It must show a menu (something like this):

Then choose Gnome/Unity2d etc.


After doing a bit more digging came across this useful solution.

https://serverfault.com/questions/345833/what-are-perfect-unix-permissions-for-usual-web-project-directories


Hyperthreading on 32-bit but not on 64-bit?

Make sure you don't boot with acpi=off as this disables hyperthreading. You can boot with acpi=ht, which is just like acpi=off, but enables just the required parts of acpi to use hyperthreading.


How to restrict ssh and ftp to certain ip address?

Ubuntu Firewall (ufw).

See if Ubuntu Firewall is active:

$ sudo ufw status

If it's inactive, enable it:

$ sudo ufw enable

Allow SSH connections from a specific IP address:

$ sudo ufw allow from 123.123.123.123 to any port 22 proto tcp

Allow FTP connections

$ sudo ufw allow from 123.123.123.123 to any port 21 proto tcp

View firewall rules:

$ sudo ufw status

Delete above SSH rule:

$ sudo ufw delete allow from 123.123.123.123 to any port 22 proto tcp

Disable Ubuntu Firewall:

$ sudo ufw disable


How do I import contacts from a vcf file on ubuntu-touch?

You have to configure it to know to ping your account first. This was posted on another thread on the subject.

syncevolution --configure --sync-property "username=email@gmail.com" --sync-property "password=secret" Google_Contacts

I don't want to patronize, but keep in mind that you need to replace the "email" in "username=email@gmail.com" with your gmail pseudonym, and "secret" in "password=secret" with your actual password.

I just did this as I was typing and the following commands imported my contacts:

adb shell
sudo -u phablet -i
syncevolution --configure --sync-property "username=email@gmail.com" --sync-property "password=secret" Google_Contacts
syncevolution --sync refresh-from-server Google_Contacts addressbook
syncevolution --sync one-way-from-server Google_Contacts addressbook


I don't think this is related to Nvidia. I am running an AMD video card and since an update a few days ago, Plasma is crashing on login (all user accounts) and attempting to start it manually results in the same.


You may want to look into this answer if your Windows partition doesn't automatically mount itself in Ubuntu.

How to mount NTFS drive at startup

Once it is mounted, drag and drop your files to Ubuntu and then erase Windows. Very simple.


Keyboard not working on my lenovo S10 Netbook

Looks like a bug report has been submitted for the Linux kernel team.
https://bugs.launchpad.net/ubuntu/+source/linux/+bug/677633

A bad solution is here:
http://s10lenovo.com/viewtopic.php?f=47&t=4482

It's bad, but it's a solution.


P3DFFT installation - "libfftw3.a not found"

The first thing to note is that the argument to --with-fftw must be the top level path to the FFTW3 header files and libraries. So for example if the headers are in /usr/include and the libraries are under /usr/lib (the default, when package libfftw3-dev is installed from the Ubuntu repository), the value should be given as --with-fftw=/usr

The additional issue in this case is that the provided configure script appears to be hard-wired to look in only the lib and lib64 subdirectories:

   3315         if test -e $withfftw/lib/libfftw3.a ; then
   3316                 FFTW_INC="-I$withfftw/include"
   3317
   3318                 FFTW_LIB="$withfftw/lib/libfftw3.a"
   3319
   3320         elif test -e $withfftw/lib64/libfftw3.a ; then
   3321                 FFTW_INC="-I$withfftw/include"
   3322
   3323                 FFTW_LIB="$withfftw/lib64/libfftw3.a"
   3324
   3325         else
   3326                 as_fn_error $? "libfftw3.a was not found in given location!" "$LINENO" 5
   3327         fi

The use of a lib64 subdirectory is an old convention that pre-dates Debian's Multiarch framework - the modern location for 64-bit libraries would be lib/x86_64-linux-gnu

There may be a 'clean' way to re-configure that (perhaps using autoreconf) however I don't know it - if you don't mind using a quick'n'dirty fix, then it should be sufficient to fix the search location using sed:

sed -i.bak 's:lib64:lib/x86_64-linux-gnu:g' configure

and then re-run ./configure


Whiptail detects hyphen in name as a command

Let's consult man whiptail:

  whiptail interprets  arguments  starting  with  a  dash  "-"  as
  being
         arguments.   To  avoid  this,  and  start  some text in, for example, a
         menubox item, with a dash, whiptail honours the  getopt  convention  of
         accepting  the  special  argument  "--"  which means that all following
         arguments with dashes are to be treated  verbatim  and  not  parsed  as
         options.

Therefore, the following approach should work like a charm:

whiptail --title "Choose Benchmark Options" --checklist -- Choose: 20 30 15 -info "System Information" off


Problems streaming UPNP/DLNA from Ubuntu machine

What software are you using as a client?  Or are you looking for a software recommendation?

If you are after a software recommendation, Ubuntu's default movie player (Totem) can act as a DLNA player if you install the totem-plugins-extra package.  Once the package is installed, start the movie player and pick Plugins... from the Edit menu.  Check the checkbox next to Coherence DLNA/UPnP Client and you should be good to go.

Open the movie player's side bar and select Coherence in the drop down menu.  You should now be able to browse the DLNA servers on the local network and start playing movies or songs by double clicking on them.


On a dual boot after some days it crash on booting

Disable Fast Startup in Windows and try again.

Also check your BIOS for Fast Boot, Secure Boot. These should be disabled.

  Why disable fast startup? Leaving fast startup enabled shouldn't
  harm anything on your PC — it's a feature built into Windows — but
  there are a few reasons why you might want to nevertheless disable it.

  One of the major reasons is if you're using Wake-on-LAN, which will
  likely have problems when your PC is shut down with fast startup
  enabled. Others would like to save the hard drive space that is
  usually taken up with the hibernation file, and Linux users will
  likely see complications with dual boot and virtualization.
  Furthermore, some users have even reported that power buttons on their
  keyboard will not work and fans in their PCs will continue spinning.
  These problems are by no means across the board, but they can prove to
  be frustrating. Finally, Windows 10 updates might not install properly
  if you have fast startup enabled.


Cleanup after upgrade server 13.04 to 13.10

My noobish 2 cents :

The isc-dhcp-server service can be used to start and stop dhcpd with the right parameters.
Files used :
/etc/dhcp/dhcpd.conf
/run/dhcp-server/dhcpd.pid
/etc/default/isc-dhcp-server (be sure to set NICs here)

After the upgrade from 13.04 to 13.10 I had to reboot before the 'service isc-dhcp-server stop' command would function.
I assume that's some kind of flaw, since it's not just me.

Some commands that gave me more questions than answers :

Before reboot, after upgrade to 13.10

root@dhcp:~# service --status-all | grep dhcp
 [ - ]  isc-dhcp-server
 [ ? ]  udhcpd

root@dhcp:~# ps -AF | grep dhcp
dhcpd     1196     1  0  6216  7068   0 14:20 ?        00:00:00 dhcpd -user dhcpd -group dhcpd -f -q -4 -pf /run/dhcp-server/dhcpd.pid -cf /etc/dhcp/dhcpd.conf
root      2270   888  0  2362   896   0 16:57 pts/0    00:00:00 grep --color=auto dhcp

root@dhcp:~# service isc-dhcp-server stop
stop: Unknown instance:

root@dhcp:~# service isc-dhcp-server restart
stop: Unknown instance:
isc-dhcp-server start/running, process 1753

Multiple times 'service isc-dhcp-server restart' gave me the same stop: Unknown instance message.

After reboot :

root@dhcp:~# ps -AF | grep dhcp
avahi      430     1  0  8089  1700   0 16:59 ?        00:00:00 avahi-daemon: running [dhcp.local]
dhcpd      777     1  0  5171  7636   0 17:00 ?        00:00:00 dhcpd -user dhcpd -group dhcpd -f -q -4 -pf /run/dhcp-server/dhcpd.pid -cf /etc/dhcp/dhcpd.conf eth0 eth1 bond0
root      1314   931  0  2363   896   0 17:00 pts/1    00:00:00 grep --color=auto dhcp

root@dhcp:~# service isc-dhcp-server restart
isc-dhcp-server stop/waiting
isc-dhcp-server start/running, process 1515

... and no change to

root@dhcp:~# service --status-all | grep dhcp

[ - ] for isc-dhcp-server and [ ? ] for udhcpd

Before and after reboot, dhcp was and is up & running.
Something seems off.


Which is a normal temperature for a laptop?

On the Intel site, Link to your CPU, after Tjunction you have 105ºC. This means that it stands up to that temperature.

Normal may be a matter of opinion, but for me, normal is between 50ºC to 70ºC for low usage and up to 80ºC if all the processors are working close to 100%. If somehow the 90ºC are passed I would say that something is wrong.


sudo rm -r --no-preserve-root /    # Attempts to delete your filesystem


Starcraft 2 installer: invisible buttons followed by stuck progress bar

I had the same problem installing SC2.  I read online that the buttons are clickable but invisible, so you can progress through the install if you can figure out where the buttons are.  I found this to be true, but was never able to finish the install this way because I couldn't find the invisible button on the install page with Reynor's revolver in the background.

I haven't had a chance to try it, but I just found a list of recommended wine-tricks options to install before trying to install SC2 with Wine.  It's at the bottom of the page here:  http://gameolosophy.com/games/adventure/starcraft/starcraft-ii-on-ubuntu-11-04/

Hope it helps.


Unable to find wine windows program loader even after installing wine

It happens most of the time when you install wine from the software center.

I would suggest to remove your current version and install by using the command

  sudo apt install winehq-stable

Last time I checked it installs the wine--4.0 version. If everything fails then I would suggest you follow guide provided by WineHQ Wiki


Multimonitorsetup: Move starter to bottom on single monitor

After seeing the updated setup image I might know how to do what you want, atleast I am sure of one of the two

super edit: well i read it a bit wrong so the answer is wrong and sadly enough i don't think it is possible what you are asking


Package Operation Failed. Installation or removal failed

libqt4-svg is a flashplugin-installer package; try an update with the fix option or upgrading the package from terminal:

sudo apt-get update -f
sudo apt-get upgrade libqt4-svg

If that doesn't work, your solution may be listed on the man page for apt-get.  Here's how to view it and a few to try:

man apt-get
sudo apt-get dist-upgrade
sudo apt-get check
sudo apt-get autoclean

Next, try rebooting and then an update via terminal:

sudo reboot
sudo apt-get update

If that doesn't work, take a look at your software sources.  In particular, look for old packages you may want to remove from the Other Software tab.

click the Dash Home
type Software Sources and hit Enter
from the top menu: Edit/Software Sources

This may also answer your question: update and upgrade ubuntu 11.10.


Yes, it is normal to have the BIOS time in UTC.


How do I get the current running version of a package in deb file's postinst and preinst script?

According to the Debian Policy Manual the postinst script is called with the old version number as second argument:

postinst configure most-recently-configured-version

So within your postinst, you simply need to check that argument.

And for preinst:

  Run the preinst of the new package:

  If the package is being upgraded, call:

new-preinst upgrade old-version

  [...]

  Otherwise, if the package had some configuration files from a previous version installed (i.e., it is in the “Config-Files” state):

new-preinst install old-version

  [...]

  Otherwise (i.e., the package was completely purged):

new-preinst install


what to do when monitor does not have edid information?

I have had the same issue with one of my monitors.  It would not pull the EDID from the monitor at all.  I had to manually add the refresh and sync info to my /etc/X11/xorg.conf file.

One way that I know of to get the HorizSync and VertRefresh for your monitor (HDTV) is to run the nvidia-xconfig.  Don't run the application with your existing xorg.conf file, as it might pull incorrect information.

I got my info by running the following:

sudo nvidia-xconfig -c /dev/null -o xconfig_mine.conf

This created a file called xconfig_mine.conf in the directory I was working in.  Contained in that file was the following information:  (it might be different for your configuration but the Unknown VendorName and ModelName should be there)

Section "Monitor"
    Identifier     "Monitor0"
    VendorName     "Unknown"
    ModelName      "Unknown"
    HorizSync       28.0 - 33.0
    VertRefresh     43.0 - 72.0
    Option         "DPMS"
EndSection

The above info is that for my monitor that it cannot detect properly.

I copied that info, and I added it to my /etc/X11/xorg.conf file above the Section "Screen" part.  After that was added, I rebooted my system, then my xrandr application was able to see all sorts of resolutions that my monitor supports (even ones that it doesn't support).  So, after adding that info, I was then able to get my monitor to max at the resolution of 1280x1024 which it does support.

Hope this helps!


Ubuntu 20.04 Fractional scalling "cuting" elements

It's actually a confirmed bug: https://bugs.launchpad.net/ubuntu/+source/mutter/+bug/1875285


Yes, you can add any directory to the system path. One way to do this is updating the PATH (environmental variable) definition. You can do this in your .bashrc by adding the following lines:

PATH="/your/script/dir:${PATH}"
export PATH

I like to add my scripts to $HOME/.local/bin/ (which is a hidden directory) so my home dir stays cleaner.

Your directory will not get inserted into the PATH variable right away, unless you run source .bashrc.

You can add multiple directories to the path, remember that. Please consult BASH documentation if you do not understand the code.

The previous method will only work for your user. If you need to add a script directory for all users do as bodhi.zazen and add your scripts to /usr/local/bin.


Chances are you still have the snap version of docker installed. Run this:
snap list

And see if docker is listed. If it is, then run
sudo snap remove docker

Now docker should be completely removed, both as snap and deb package.


First you need to the zstorage/home filesystem to a different mountpoint like /zstorage/home to transfer the files from /home to /zstorage/home.
To transfer the data, best would be to do this while no user is logged in and you are logged in as root directly to not have any operations in the home directory. To copy the data, use either of the two commands as follows, whereas rsync is better if the copy process is interrupted and has to be rerun.

cp -a /home/* /zstorage/home/
rsync -axHAX --delete /home/ /zstorage/home/

After the copy process, you can mount the ZFS filesystem to /home, but as you already mentioned ZFS by default rejects mount points that contain something. You can alter that with the command as follows.

zfs set overlay=on zstorage

The property is normally inherited to child filesystems, but you can check it with zfs get overlay zstorage. Now you should be able to mount the ZFS filesystem on /home.
To do that, you may want to change the mount point in ZFS as follows.

zfs set mountpoint=/home zstorage/home

It also might be that /home is a separate mount point, in that case you need to remove, comment or alter the corresponding entry in /etc/fstab.

You also might want to keep the original data and overmount /home while testing your new setup and delete it later when everything is as expected. Just in case something goes wrong or you want to go back.

During boot, the ZFS filesystems should be mounted automatically without the need to configure /etc/fstab.


Add the Banshee Official PPA, update the local repository index and install the banshee package and then install

sudo add-apt-repository ppa:banshee-team/ppa
sudo apt-get update
sudo apt-get install banshee


How can I either lock items in the launcher OR restore a set of items in the launcher?

The current configuration of most areas of the desktop can be viewed using Dconf Editor, or using the command line utility gsettings:

gsettings get com.canonical.Unity.Launcher favorites

Example output:

['application://nautilus.desktop', 'application://firefox.desktop', 'application://libreoffice-writer.desktop', 'application://unity-control-center.desktop', 'unity://running-apps', 'application://gnome-terminal.desktop', 'unity://expo-icon', 'unity://devices']

You can then use to restore it to that state (try removing things from the launcher, you can see any changes), using the set option (note the quotes ") with the output from the get command:

gsettings set com.canonical.Unity.Launcher favorites "['application://nautilus.desktop', 'application://firefox.desktop', 'application://libreoffice-writer.desktop', 'application://unity-control-center.desktop', 'unity://running-apps', 'application://gnome-terminal.desktop', 'unity://expo-icon', 'unity://devices']"

So if you get the launcher in the state you want, and use the get to get it, you can then set it back later with the set command. You could add this in gnome-session-properties and then it should set itself on login:

See also: https://askubuntu.com/a/367590/178596


The NFS-server is probably running with root_squash:

  Very often, it is not desirable that the root user on a client machine is also treated as root when accessing files on the NFS server. To this end, uid 0 is normally mapped to a different id: the so-called anonymous or nobody uid. This mode of operation (called 'root squashing') is the default, and can be turned off with no_root_squash.

It basically maps root to a different user with least privileges. This is the default setting on NFS.

Talk with you server administrator, or if you are the server administrator, add option no_root_squash to the /etc/exports on the server.


You can use ufw and fail2b together, but as indicated earlier, the order of (ufw) rules is what is important.

Out of the box, fail2ban uses iptables and inserts rules first in the INPUT chain. This will not do any harm or conflict with ufw.

If you wish to fully integrate fail2ban to use ufw (rather then iptables). You will need to edit a number of files including

/etc/fail2ban/jail.local

jail.local is where you define your services , including what port they are listening on (think changing ssh to a non-default port) and what action to take.

**Please note*: Never ever edit jail.conf, your changes should be made in jail.local! That file begins with this:

# Changes:  in most of the cases you should not modify this
#           file, but provide customizations in jail.local file,
#           or separate .conf files under jail.d/ directory

Using ssh as an example, note the definition of a non-default port as well =)

[ssh]
enabled = true
banaction = ufw-ssh
port = 2992
filter = sshd
logpath = /var/log/auth.log
maxretry = 3

You then configure fail2ban to use ufw in (one .conf file for each service)

/etc/fail2ban/action.d/ufw-ssh.conf

The syntax is

[Definition]
actionstart =
actionstop =
actioncheck =
actionban = ufw insert 1 deny from <ip> to any app OpenSSH
actionunban = ufw delete deny from <ip> to any app OpenSSH

Note: You configure fail2ban to use ufw and to insert new rules FIRST using the "insert 1" syntax. The delete will find the rule regardless of order.

There is a nice blog post that goes into more detail here

http://blog.vigilcode.com/2011/05/ufw-with-fail2ban-quick-secure-setup-part-ii/

[EDIT] For ubuntu 16.04+
by default a "defaults-debian.conf" in /etc/fail2ban/jail.d with content

[sshd]
enabled = true

will activated a the ssh protection of fail2ban.
You need to put it at false.
Then create a jail.local like you would do in general, mine would be like this:

[ssh-with-ufw]
enabled = true
port = 22
filter = sshd
action = ufw[application="OpenSSH", blocktype=reject]
logpath = /var/log/auth.log
maxretry = 3

There is already a ufw.conf in the fail2ban default installation so no need to create one.
The only specific change for you jail.local would be at action line where you need to put the application concerned for the protection and what you want to get as result.
ufw tend to detect automatically a certain amount of app running using the network. To have the list just type sudo ufw app list. It's case-sensitive.
 reload fail2ban and you'll no longer see the fail2ban chain and if any IP get a block you'll see it in sudo ufw status


I purged TZData and now Lubuntu won't boot! Help!

You could spend hours trying to recover your Lubuntu system with no guarantee of success or you can just reinstall in a half hour and know that that will work.  Save any files that you don't have backups for onto a thumb drive or similar and in future note what apt is telling you it will remove.  To save files, boot into a live session, like with the default Ubuntu disc, mount your partition that contains /home and copy your files out of there onto a thumb drive.  Then reinstall.


The oauth python module is outdated, deprecated, and unmaintained. You should use python3-oauthlib instead.


Where does a .deb file go after installation?

DEB file is actually an archive with control information telling dpkg what to do with those files and other stuff ans Zacharee1 has already said. In addition to his answer, you can check where a deb file goes by using this command (after installation)

dpkg -L package-name

If the deb file name is dolphin_3.23_amd64.deb, the first part before _ is the package name.

This is the output of dolphin package

→ dpkg -L dolphin
/.
/etc
/etc/xdg
/etc/xdg/servicemenu.knsrc
/usr
/usr/bin
/usr/bin/dolphin
/usr/bin/servicemenuinstallation
/usr/bin/servicemenudeinstallation
/usr/lib
/usr/lib/x86_64-linux-gnu
/usr/lib/x86_64-linux-gnu/qt5
/usr/lib/x86_64-linux-gnu/qt5/plugins
/usr/lib/x86_64-linux-gnu/qt5/plugins/kcm_dolphingeneral.so
/usr/lib/x86_64-linux-gnu/qt5/plugins/kcm_dolphinviewmodes.so
/usr/lib/x86_64-linux-gnu/qt5/plugins/dolphinpart.so
/usr/lib/x86_64-linux-gnu/qt5/plugins/kcm_dolphinnavigation.so
/usr/lib/x86_64-linux-gnu/qt5/plugins/kcm_dolphinservices.so
/usr/lib/x86_64-linux-gnu/libkdeinit5_dolphin.so
/usr/lib/x86_64-linux-gnu/libdolphinprivate.so.5.0.0
/usr/share
/usr/share/doc
/usr/share/doc/dolphin
/usr/share/doc/dolphin/copyright
/usr/share/doc/HTML
/usr/share/doc/HTML/en
/usr/share/doc/HTML/en/dolphin
/usr/share/doc/HTML/en/dolphin/locationbar-breadcrumb.png
/usr/share/doc/HTML/en/dolphin/preferences-startup.png
/usr/share/doc/HTML/en/dolphin/index.cache.bz2
/usr/share/doc/HTML/en/dolphin/nepomuk-search.png
/usr/share/doc/HTML/en/dolphin/viewproperties-dialog.png
/usr/share/doc/HTML/en/dolphin/preferences-services.png
/usr/share/doc/HTML/en/dolphin/locationbar-context-menu.png
/usr/share/doc/HTML/en/dolphin/preferences-general-behavior.png
/usr/share/doc/HTML/en/dolphin/locationbar-editable.png
/usr/share/doc/HTML/en/dolphin/toolbar-navigation.png
/usr/share/doc/HTML/en/dolphin/grouping-view.png
/usr/share/doc/HTML/en/dolphin/preferences-viewmodes-icons.png
/usr/share/doc/HTML/en/dolphin/locationbar-places-icon.png
/usr/share/doc/HTML/en/dolphin/toolbar-view-appearance.png
/usr/share/doc/HTML/en/dolphin/nepomuk-search-more-options.png
/usr/share/doc/HTML/en/dolphin/preferences-navigation.png
/usr/share/doc/HTML/en/dolphin/default-ui.png
/usr/share/doc/HTML/en/dolphin/toolbar.png
/usr/share/doc/HTML/en/dolphin/index.docbook
/usr/share/doc/HTML/en/dolphin/locationbar-kioslaves-menu.png
/usr/share/doc/HTML/en/dolphin/preferences-trash.png
/usr/share/appdata
/usr/share/appdata/org.kde.dolphin.appdata.xml
/usr/share/config.kcfg
/usr/share/config.kcfg/dolphin_generalsettings.kcfg
/usr/share/config.kcfg/dolphin_directoryviewpropertysettings.kcfg
/usr/share/config.kcfg/dolphin_compactmodesettings.kcfg
/usr/share/config.kcfg/dolphin_detailsmodesettings.kcfg
/usr/share/config.kcfg/dolphin_iconsmodesettings.kcfg
/usr/share/config.kcfg/dolphin_versioncontrolsettings.kcfg
/usr/share/applications
/usr/share/applications/org.kde.dolphin.desktop
/usr/share/kxmlgui5
/usr/share/kxmlgui5/dolphinpart
/usr/share/kxmlgui5/dolphinpart/dolphinpart.rc
/usr/share/kxmlgui5/dolphin
/usr/share/kxmlgui5/dolphin/dolphinui.rc
/usr/share/lintian
/usr/share/lintian/overrides
/usr/share/lintian/overrides/dolphin
/usr/share/kservicetypes5
/usr/share/kservicetypes5/fileviewversioncontrolplugin.desktop
/usr/share/dbus-1
/usr/share/dbus-1/services
/usr/share/dbus-1/services/org.kde.dolphin.FileManager1.service
/usr/share/kservices5
/usr/share/kservices5/kcmdolphinservices.desktop
/usr/share/kservices5/dolphinpart.desktop
/usr/share/kservices5/kcmdolphinnavigation.desktop
/usr/share/kservices5/kcmdolphingeneral.desktop
/usr/share/kservices5/kcmdolphinviewmodes.desktop
/usr/lib/x86_64-linux-gnu/libdolphinprivate.so.5
/usr/share/doc/dolphin/changelog.Debian.gz

After installing a deb file, the generated files that went to bin directory can usually be executed. Here we can see 1 entry /usr/bin/dolphin, which means you can use dolphin command to summon it.


Permission denied error when installing django

sudo rm -rf /usr/lib/python2.7/dist-packages/django
sudo pip install Django==1.5


Problems unraring a split file in ubuntu 12.04

If you try to open a split archive file, and you don't have all the parts of the file in your present working directory, you're going to get an error message saying that parts of the archive are missing. However if you just want to extract the first part(s) of the split archive, you can do it using the Archive Manager application which is installed by default in Ubuntu.

The files in a split archive that has missing parts will be extracted by default to a hidden folder, so you will have to use the keyboard combination Ctrl + H to view the hidden folder.

You can't extract the files from part of a split archive unless you have all of the previous parts of the archive.


Ubuntu live USB won't start with CSM disabled

Okay after removing quiet from the kernel options I saw that the error message was fb : switching from nouveaufb to EFI VGA and I saw a thread on the internet that said adding nomodeset to kernel options was solving the problem and it does indeed whatever it is.


Why do I see a purple then black screen when booting and a 'failed to load module "nv"' error when running startx in tty1?

nv is deprecated open source driver.
Make sure you don't have it in xorg.conf, and try blacklisting it with:

  echo "blacklist nv" | sudo tee -a "/etc/modprobe.d/blacklist.conf"


How can I re-open the TrueCrypt window after it's been closed?

For me, this didn't help. I had to also remove the Truecrypt lock file as per these instructions.

In terminal enter:

rm ~/.TrueCrypt-lock-USERNAME

Where you replace USERNAME with your username.


How to setup automatic port forwarding server

You can use ssh for port forwarding.  read the ssh man page by executing man ssh in Terminal.

Example:

ssh -f servername -L [bind_address:]port:host:hostport

-L [bind_address:]port:host:hostport

Specifies that the given port on the local (client) host is to be
             forwarded to the given host and port on the remote side.  This
             works by allocating a socket to listen to port on the local side,
             optionally bound to the specified bind_address.  Whenever a
connection is made to this port, the connection is forwarded over
             the secure channel, and a connection is made to host port
             hostport from the remote machine.  Port forwardings can also be
             specified in the configuration file.  IPv6 addresses can be specified by enclosing the address in square brackets.  Only the
             superuser can forward privileged ports.  By default, the local
             port is bound in accordance with the GatewayPorts setting.  However, an explicit bind_address may be used to bind the connection
             to a specific address.  The bind_address of ``localhost'' indicates that the listening port be bound for local use only, while
             an empty address or `*' indicates that the port should be available from all interfaces.


The Click On Edit Connection > DSL > ADD

--------------------------------------OR--------------------------------------

Connect your ethernet wire to the port at the back of your computer.
Fire up the terminal and type in sudo pppoeconf
It should detect your modem.
Keep on pressing enter. Fill in your user name and password when indicated.
It should be easy to stick on to defaults.
You should be prompted back to your terminal when it would say pppoe loaded. Simple. That's the end of terminal.
Now go to System>Networking. Click on it
Activate the Wired connection.
Highlight the wired connection and click on properties.
Check the box "enable the connection"


Doing

sudo nano /proc/sys/kernel/sysrq

And writing a 0 to it will allow the sysrq keys to be disabled during normal operation. However, it's worth noting, that until that file is read during the boot process the sysrq keys will still be available (but by the time you log on, it will not be)


How can I change the default port of Remote Desktop (VNC)?

Using a little information from the (now dead) Dave's Tech Blog, you can adjust the port setting by going into gconf-editor.

Under desktop > gnome > remote access there is a key that says alternative_port and is set to 5900.  Just change the value to what you need.  Then enable the key use_alternative_port.

The other option is if your router/firewall support uPnp you can adjust Vino to make the adjustment in the same section of gconf-editor.

Reference: How do I use the gconf editor?


I used around 29GB for a recent Ubuntu 4.8 Yakkety kernel build for x86-64, so I'd recommend at least 35GB for source, generated objects and deb packages.


Finding device printer's device URI during driver installation

For others who struggle with this:

The problem was the printer's network connection.

I don't know how it was lost. To find the ip address/URI on this printer:

Menu
Network
WLAN
TCP/IP
IP Address

Now I have two printers with different URIs that both work:

socket://##.#.#.###
ipp://BRW3468956A95AA.local:631/ipp/print

The output of gmelodie's lpinfo command is now:


If you use xfce4-screenshot to take the screenshot, then you have the Capture the mouse pointer option. Enable it and the mouse will be in the screenshot; disable and the pointer will not show in the screenshot.

(It seems to me that this is independent of  xfce windows are missing toolbar, focus is broken.)


Convert DVD to MKV (et al) without transcoding/recompression

I tried mkvtoolnix and it did it instantly, maybe because of copy-on-write feature of Btrfs I use.


Unity shell not starting after upgrade from 12.10 to 13.04

I had this problem too, don't worry I found out a trick to get it off the base ubuntu drivers.

First when GRUB opens go into Ubuntu somenumbershere... (Advanced) and go into recovery mode. Next you will see a DOS-like window with a few options. Press the down arrow a few times until you get to a option with a name like 'Start in graphics safe mode'. Restart and go into ubuntu. If it starts up correctely you should see your fully-loaded ubuntu desktop. From there you can choose another driver your for integrated graphics and get out of graphics-safe mode :)

I had to guess on some parts as im not in front of ubuntu right now, post any questions.


What will be the default set of package management tools in future versions of Ubuntu?

The Software Centre is a graphical application. As it stands at present there would be very little point in effort being put into a CLI version of the Software Centre when polished alternatives exist.

It is certainly possible Synaptic will be removed from a default install in the next few cycles.

Note that it was decided not to merge the Update Manager into the Software Centre.


sudo mkdir -p /home/nicholas/.cache/chromium/Default
   sudo chown $USER:$USER /home/nicholas/.cache/chromium/Default


If you are talking about this PPA - https://launchpad.net/~python-snippets-drivers/+archive/python-snippets-daily - there are packages only for Lucid and Maverick.  No packages yet for Natty.

Suggest either contact the package owner (one Jorge O Castro!) or try editing your software sources and changing "natty" to "maverick" as per this AU answer


How to kill an application that locks/freezes the system when that app does not show in System Monitor

I guess the quickest way is to use the terminal, there you just need to type

ps -aux | grep 'bleachbit'

and the output will be a list of all the processes related to bleachbit (except for the last one, which is the search for the program using the grep command above). Of each row of the output, the second column is the pid of the application (or a secondary process launched by it).

Then, again in the terminal, type

kill pid1 pid2 pid2

where pid1, etc stand for all the pids the output of the first command showed.

In case your system freezes before you can launch a terminal, you can press Ctrl+Alt+F1 to go to a tty (basically, just another terminal). Type your login info and you'll get a full-working terminal where you can do all of the above. In case you want to exit from this tty press Ctrl+Alt+F7.


How can I tell when Ubuntu 16.04 has finished formatting a USB?

Ubuntu 16.04 does not show any information while it's formatting a pendrive from the file explorer window. Just leave it plugged in until the light stops blinking, and then some more (for good measure).


Problems after updating BIOS (dual boot Win/Ubuntu)

Usually a BIOS update shouldn't pose a problem in a dual boot setup with Ubuntu and Windows. It is however generally a good idea to make sure you have up to date backups of your data on an external drive - just in case.
By the way, HP has started to distribute BIOS updates via LVFS. Currently they aren't supporting many devices but if your device is supported (check here) you'll even be able to update your BIOS from Ubuntu via the Software Center.


Why is Unity a "slow" desktop environment?

The answer depends heavily on 3 major factors contributing to the feeling of "slow" or better yet, less FPS:

Version of Ubuntu (Updated, not just left as it came when it was released)
Video card (Ati, Intel, Nvidia)
Driver version (Proprietary, Open Source, Actual Version)

I'll explain each point:

Version of Ubuntu

For the version of Ubuntu, it is known that using 11.10 with Unity will suck. Literally make the PC suck at even opening Gedit or Nautilus in most cases. Trying to play a game in either OpenGL or through Wine with DirectX or OpenGL will result on less FPS than normal, even compared to any other DE. This drastically changes in 12.04 and then again in 12.10 where the FPS count starts to go up.

Since the latest is the 12.10, I should mention that for some, using 12.10 without upgrades does not address several key problems that were fixed in Compiz and Unity around a month after release. So any 12.10 user has to upgrade to receive this benefits. This is because the 2 most important parts that are talked about when FPS and OpenGL performance comes to mind are Unity and Compiz (Compiz being the most important one when it comes to a performance impact).

The benefits and enhancements that both, the Compiz project is getting throughout the 0.9.8 Series and the 0.9.9 Series and Unity is getting in the 7.x Series are actually very impressive.

Tests in Phoronix and some of my own showed that for Nvidia cards (The only tests I could actually do were with Nvidia cards) the performance has gone up. And not just 3 or 4 FPS but about 20 to 70 FPS depending on the Video card and Driver.

This is important, since, depending on the Ubuntu version the user is using, it will also depend on the Compiz and Unity version available for it, and the performance cost that comes with it.

Since Unity needs Compiz, this will be the biggest cause of low FPS count, but not much as before, or at least 2 versions ago. Running the Benchmark utility of Compiz while playing video games in Wine or Open Source ones gave me very good FPS in 12.10 and even more while I am testing 13.04 with the latest 313.xx series of Nvidia.

It should be noted that video performance is one of the points that will be dealt in 13.04 (And to some big degree in 12.10 and 12.04) because of a commitment that Ubuntu has for it's users and Steam (Valve). Not only is Ubuntu and Valve working on this, but Nvidia and Intel have joined also with many updates that have jumped the FPS count time and time again. If you are following the improvements that are coming to the 3.7 and 3.8 Kernel you will see some of them.

Video Card & Driver Version

It has been known that performance wise, Nvidia is on top of it, followed by Intel and Ati (This is not to be confused with ease of use, since Intel is much better at that). The latest drivers for Nvidia (For example the 306.64, 310.19 and 313.09) have all brought OpenGL performance improvements specifically for Unity. Specially the 313.09 which is used to improve Compiz even further.

Now, not only is Nvidia doing a lot of work to improve the road for Compiz/Unity. Intel is also hard working (Very hard) on several key features for Mesa, which should improve performance in general for all Intel video cards, specially the 965, 2000 HD, 3000 HD and 4000 HD Series. Lastly Ati/AMD has also several updates already made that will fix many bugs and issues with Compiz.

So in general, having the latest driver for each will improve performance but having an Nvidia card will enhance it more, followed by Intel and Ati.

After reading all of this, what changes are being made to improve the performance in general, well here are some:

Nvidia is working since several versions ago on improving Unity performance with more than a 50% enhancement in general over older versions
Intel is working with Mesa to improve Unity performance
Ubuntu and Valve are working on improving performance for Compiz and Unity
As seen in Launchpad, there are several fixed made to Compiz to improve responsiveness and better performance in general (Including memory and cpu usage)
As seen in Launchpad, Unity has received many fixes in regards to most problems encountered by end users
Compiz has lowered by more than 50% the amount of memory it used a year ago.
Unity feels faster and lighter compared to the version used a year ago.
There is some work done by Sams Spilsbury for the latest Compiz and Unity that will address some common problems known with Unity.
Kernel versions 3.7 and 3.8 will bring video improvements in general

So as you can see, there is much work that is being done to improve Unity and Compiz. To be fair, comparing Unity to Xfce or Lxde is not fair. This is like comparing a bike to a car. Both can do some things better. Compiz offers for example some very neat effects that Xfce or Lxde do not and even though most of us do not use them, they are an option (Like the cigar lighter inside the car).

Same goes for comparing KDE, Gnome3 and any other DE to low end DE. They are low end for a reason. They tend to avoid making huge changes that will impact performance, while high end DE will try to add features that might take more resources at the beginning. For example, having widgets, the ability to rotate a window to any degree possible, having a blur effect that hides the background or having an animated background at that. There are options that some uses enjoy that are offered by some Desktops that others DE do not need or use since they are more oriented towards a low end system.

With this in mind, anybody that has tested KDE since the 4.0 release knows what huge improvements it has received up till the latest 4.9 version. Huge ones indeed. Anybody that has tested Gnome 3.0 up to the latest 3.8 release knows of the huge changes in performance it has received and anybody that has tested Unity from the 3.x up to the 6.x (And soon 7.x) will know how the performance has jumped. I for one miss gnome2 for example, but there are several cases where I can't use gnome2 for since Unity is much friendlier and quicker in helping me achieve some of this cases.

So what tips I could give to improve performance?

Well install the Compiz Config Settings Manager (ccsm)

and play with the OpenGL plugin:

Some of this options will enhance performance, others I needed to avoid video problems. If anybody finds the question about this I will be happy if they edit this answer to include a link to it here. I can't find it right now but I know there was an answer that talked about this.

Other is updating the drivers and if possible, using Nvidia. Other than that, waiting for 13.04 will be a worthwhile.

For some reviews, here are benchmarks from Phoronix that check how Unity is performing on 11.04, 12.04, 13.04 and 13.10:

Desktop Benchmark 11.04

Desktop Benchmark 12.04

Desktop Benchmark 13.04

Desktop Benchmark 13.10

And this is what has happened with Nvidia over the past months

Also some articles about Ati/AMD HERE, HERE, HERE and HERE

Last, Intel, Mesa and Opengl HERE, HERE and HERE


how to boot from linux mini iso to first hard drive

This is solving the issue

label hd
menu label ^Boot from first hard disk
localboot 0x80


No smb.conf file after installing samba 4.0.9

I had this problem and an error report eventually came up which identified my situation exactly - I had done;

sudo apt-get remove samba --purge
sudo apt-get autoremove
manually deleted contents of /etc/samba including smbd.conf
reinstalled samba

What I did NOT do but should have done before reinstalling samba was

sudo apt-get purge samba-common

If you do this, then reinstall, the samba directory and conf file will be reinstalled.


Short answer: yes, but you need to use cinnamon for remote sessions. Local users can use Unity or whatever they want.
Symptoms: in remote session: xterm runs, gnome-terminal/nautilus does not.
Short fix:
sudo DEBIAN_FRONTEND=noninteractive \
    apt install --assume-yes cinnamon-core desktop-base

sudo bash -c 'echo "exec /etc/X11/Xsession /usr/bin/cinnamon-session-cinnamon2d" > /etc/chrome-remote-desktop-session'

Long answer.
I recently tried to get chrome-remote-desktop on Ubuntu 20.04, and found that most of the instructions either ignore issues with sessions (gnome-terminal does not open, etc); or patch /opt/google/chrome-remote-desktop/chrome-remote-desktop with
FIRST_X_DISPLAY_NUMBER = 0, etc, which is not helpful if I want to sign in with multiple accounts at the same time.
There are Google instructions on installing chrome-remote-desktop on virtual instance:
https://cloud.google.com/solutions/chrome-desktop-remote-on-compute-engine
which insist on disabling the display manager. I decided to follow that guide but without disabling display manager. And it worked!
Step-by-step:

Create additional [local] user accounts. Account which is used to setup remote access won't be accessible for regular sign in (at some point I was getting an error message from remote desktop where it blamed a bug in display manager; I tried gdm3, lightdm, and sddm with no luck).

Note: if you forgot to create an additional [local] account you can "unlock" it by visiting https://remotedesktop.google.com/ on another machine and deleting remote device you set up.
2.
# Install cinnamon
sudo DEBIAN_FRONTEND=noninteractive \
    apt install --assume-yes cinnamon-core desktop-base

# Select default session
sudo bash -c 'echo "exec /etc/X11/Xsession /usr/bin/cinnamon-session-cinnamon2d" > /etc/chrome-remote-desktop-session'

# Download remote desktop.
wget https://dl.google.com/linux/direct/chrome-remote-desktop_current_amd64.deb

# apt install will install it together with dependencies.
sudo apt install ./chrome-remote-desktop_current_amd64.deb

# Allow this user to setup machine for remote access.
# You will be logged in by this user when using chrome remote desktop.
# It is possible to list multiple users in this group, and access your machine with multiple remote sessions simultaneously.
sudo usermod -a -G chrome-remote-desktop $USER

# Install Google Chrome (if not installed yet)
wget https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb
sudo apt install ./google-chrome-stable_current_amd64.deb

Go to https://remotedesktop.google.com/, and setup this machine for access.

Reboot.

There are extra steps listed at
https://cloud.google.com/solutions/chrome-desktop-remote-on-compute-engine
(like enabling clipboard), but I did not try it.
I was able to login to my machine with two users simultaneously using remote desktop (and run gnome-terminal in the cinnamon session), and third user running Unity desktop directly on machine.


How to recover disk space that is not visibly available?

Depending on the filesystem, 5% of the space on your disc are reserved for the superuser and not shown by df.

You can increase/decrease this with tools like e2fstune (if your filesytem is something like ext2/3/4).


After installing Ubuntu on my HP desktop, it fails to boot up, any ideas whats wrong?

I had the same problem when I try install Ubuntu in my Utrabook HP Pavilon (500 GB HDD, 32 GB SSD).
I installed with USB drive

After try install some times, the problem to me is that I was not creating the boot loader partition.

The configuration that worked is

Before install:

Disable the fast boot and the Secure Boot
Enable the Legacy BIOS

In installation:

My partitions configuration are:

HDD : /home, /boot, /boot/efi (boot loader), /swap
SSD : /

After  to install enable the fast boot.
With this configuration, my Ubuntu installed with successful!
Sorry my bad English :)
I hope  I helped you!


Show tree of directory with files content

I'm not aware of an easy way to do that, but I wrote a script that does something similar. Instead of a fancy tree listing like tree does, I made it flat, like find.

Output (in an empty git repo like your example):

.git/
.git/branches/
.git/config
==> start .git/config <==
[core]
        repositoryformatversion = 0
        filemode = true
        bare = false
        logallrefupdates = true
==> end .git/config <==

.git/description
==> start .git/description <==
Unnamed repository; edit this file 'description' to name the repository.
==> end .git/description <==

.git/HEAD
==> start .git/HEAD <==
ref: refs/heads/master
==> end .git/HEAD <==

.git/hooks/

...

(The ==> ... <== header/footer is inspired by tail)

Here's the script:

#!/bin/bash

# Globs include hidden files, are null if no matches, recursive with **
shopt -s dotglob nullglob globstar

for file in **; do
    # Print filename with an indicator suffix for filetype
    ls --directory --classify -- "$file"
    filetype="$(file --brief --mime-type -- "$file")"
    # Only print text files
    if [[ $filetype == text/* ]]; then
        printf '==> %s %s <==\n' start "$file"
        cat --show-nonprinting -- "$file"
        printf '==> %s %s <==\n' end "$file"
        echo
    fi
done

It's not pretty, but it works. Color makes it pretty at least:

#!/bin/bash

shopt -s dotglob nullglob globstar

for file in **; do
    ls --directory --classify --color=yes -- "$file"
    filetype="$(file --brief --mime-type -- "$file")"
    # Only print text files
    if [[ $filetype == text/* ]]; then
        printf '\e[32m==> %s %s <==\e[m\n' start "$file"
        cat --show-nonprinting -- "$file"
        printf '\e[31m==> %s %s <==\e[m\n' end "$file"
        echo
    fi
done

Screenshot:


Trash folder in the wrong location with bound partitions

Add umask=0 at the end of mount-options line. I've tested it with ntfs partition in my PC. It should make nautilus delete folder to .Trash-1000 folder.

The line should now becomes like this

/dev/sdb1 /mnt/dos ntfs permissions,locale=en_US.utf8,uid=1000,umask=0  0 0

Replace the uid=1000 with the original uid of your user. You can see it by using id -u command.


I want to have a configuration in my Ubuntu system so that if the cpu processing exceeds 90% it gives a beep sound. Is this possible?

Yes. I wrote a script that plays a notification sound when CPU load average exceeds 90% (accounting for all cores).

The system speaker is, by default, disabled on Ubuntu systems, hence using one of the standard notification sound seems a better choice for this.

To run it, simply download the script (save it as notify-highload.sh), and copy to your home directory. Then, from a terminal, run chmod +x ./notify-highload.sh, followed by ./notify-highload.sh -ag &.

If you want it to run every time on start up, add the script to your Startup Applications.

  Also, where else can this beep sound be used? like can it be used if the Hard Disk space exceeds 80%.

Yes, it can. I wrote a script available here.

I will add a few more later on.


If you have installed GNOME (3.8) from the standard Ubuntu 13.10 repositories, there is no need to uninstall before upgrading.

If you have installed the more recent version of GNOME 3.10 through the GNOME PPA, you should remove it first with the ppa-purge utility following the instructions in the linked article. This will downgrade the GNOME packages to the versions in the official Ubuntu repository so that the distribution upgrade can proceed smoothly.


How to increase resolution in ubuntu 15.10? using xrandr and updating nvidia drivers didn't work

I just solved the problem accidentally...
For future generations, here is the solution:
After installing the bumblebee pack as explained here I rebooted ubuntu and forgot to boot it with "nomodeset". Somehow, now it works without it and everything is good ;)


Why 'sudo service networking restart" do not work?

Many thanks for user douggro (comment from Mar 9 '14 at 22:05)!

Answer for me was:

sudo service network-manager restart


Here is the port of touch for Galaxy tab 2 P3110, it is no longer updated (since 2013).

As this is an old device, Samsung have released seven new revisions of the Galaxy tab since this one, there is no support for it, you would have to port it your self, using this post.