With a launcher for a terminal application, how can I keep the terminal open after the program is complete?

Assuming your command is called mycommand, I'd change my launcher to run this:

gnome-terminal -e "mycommand|less"

If you want a more permanent, perhaps cleaner solution, open up gnome-terminal, go to Edit, Profile preferences and click the Title and Command tab. Change the "When command exits" option to "Hold the terminal open".

When you execute commands, it should now leave the terminal open when something runs.

Edit: If you don't really care about the terminal, you could just use xterm's hold flag:

xterm -e "mycommand" hold


In order to change the default audio output device from the command line, you can use the pacmd Pulse Audio command-line utility.

I found the need to do similarly today, wanting to switch between headphones and speakers, both plugged into separate audio cards. Here's the shell script I wrote to do so:

#!/usr/bin/env bash

sinks=($(pacmd list-sinks | grep index | \
    awk '{ if ($1 == "*") print "1",$3; else print "0",$2 }'))
inputs=($(pacmd list-sink-inputs | grep index | awk '{print $2}'))

[[ ${sinks[0]} = 0 ]] && swap=${sinks[1]} || swap=${sinks[3]}

pacmd set-default-sink $swap &> /dev/null
for i in ${inputs[*]}; do pacmd move-sink-input $i $swap &> /dev/null; done

Notes:

This swaps between the first two audio output devices that the pacmd utility lists. If you have more than two audio devices and want to swap to a different one, you'll need to replace the logic on line 7 with some conditionals.
Just swapping the default sink device does not do anything for the applications currently running — they will continue to output to the previous device. This script also moves the sink destination for all existing inputs. I.e., if you run this script with music playing on one device, it will instantly swap to the other. If you'd like the existing applications to continue on the previous device, comment out the last line (and line 5, if you'd like).


take a look here, there is development, but it looks it is in alpha. A general list of devices with ubuntu touch can be found here.


plymouth always has a theme and is always used in the boot of Ubuntu, its just not obvious because servers use the details theme which is in the plymouth package itself.

/lib/plymouth
/lib/plymouth/themes
/lib/plymouth/themes/details
/lib/plymouth/themes/details/details.plymouth

Before running down the theme rabbit hole though, make sure you have added quiet back into your grub prompt. By default, servers do not have quiet because administrators want to see the text that commands output as they start up (this was a change made in 11.04). You'll need the tool debconf-utils to check it, then do:

debconf-get-selections | grep grub | grep quiet

If you see noquiet in there, then that may be what is stopping your logo from appearing. Also if you see nomodeset that will stop graphical boot. You can fix this with

sudo dpkg-reconfigure grub-pc

BE CAREFUL as those settings are vital to your system being bootable, so possibly consider doing a backup before changing them.

Now, if you do have quiet mode on, and you want to have another theme chosen, you need only install it, and it should be set as the default. If you'd like to manually check what the default is, you can use the tool update-alternatives

$ update-alternatives --list default.plymouth
/lib/plymouth/themes/default.plymouth
$ update-alternatives --display default.plymouth
default.plymouth - auto mode
  link currently points to /lib/plymouth/themes/ubuntu-logo/ubuntu-logo.plymouth
/lib/plymouth/themes/ubuntu-logo/ubuntu-logo.plymouth - priority 100
  slave default.plymouth.grub: /lib/plymouth/themes/ubuntu-logo/ubuntu-logo.grub
Current 'best' version is '/lib/plymouth/themes/ubuntu-logo/ubuntu-logo.plymouth'.

If you'd like to make the graphical logo appear on your server boot, it should be as easy as doing

sudo apt-get install plymouth-theme-ubuntu-logo

If that doesn't cause the default alternative to change to the output above, then you can always force the issue with:

sudo update-alternatives --config default.plymouth

Though that may just tell you there is only one choice. If you have plymouth-theme-ubuntu-logo installed, and you've removed nomodeset, and you have quiet as a boot option, and you still get no plymouth theme then your graphics hardware may just be incapable of providing a graphical boot for your server. plymouth-theme-ubuntu-text should at least give you the version and loading dots.


Can I deploy a charms inside a virtual machine?

Currently Juju supports deploying into a LXD container as an option. For example:

juju deploy mysql --to lxd:25

This will deploy mysql to a lxd container on machine 25 (assuming you have one.) If you're not explicit, Juju will use an entire physical machine, for example:

juju deploy mysql

That command will use up an entire physical machine. In the case of virtualization, if you're using VMWare or OpenStack as a cloud then that machine could possibly be a VM.

There currently is no option to deploy to a VM inside an existing machine, for most workloads LXD will be more performant and allow for more density.


Use single quotes instead of double quotes to prevent the shell from replacing the $? when defining the alias:

alias status='echo $?'


How to customize the colors of Qt applications in Ubuntu (16.10)?

It is possible to set a style sheet when launching a Qt application (as you have detailed in the question):

{application_name} -stylesheet {path_to_style_sheet}

This should work, however it is possible that the developer of the application is forcing a particular style within the application code so it will not always work.

The reason you are receiving the error message Could not parse application stylesheet is because the test style sheet you have produced is not a valid Qt style sheet.

The Qt documentation provides information on creating your own style sheets and links to these are below:

Qt4 - Qt4 Style Sheet Documentation.
Qt5 - Qt5 Style Sheet Documentation.

Given that you have received an error message relating to parsing, I would assume that it will work if you provide the path to a valid style sheet as a command line argument.

You may find it difficult creating a style sheet if you are not familiar with the standard Qt widget class names. Further information on these can be found here.


Built kernel won't boot, missing AHCI driver?

Now, because of the UUID error I feel it is necessary to verify the information in /etc/fstab because this is where the file system information (UUID) is mounted from.

First, boot into an older kernel or a live-disk session.

Execute the following command to find the UUID for your root partition.

sudo blkid -o list

The output should be similar to this example:

/dev/sda1      ext4     home      /                 bac7229a-e019-5679-931d-5e14f15ff4bc
/dev/sda2      ntfs     c         (not mounted)     40Ajghyr-65uB-EA5C-7y8y9t6g54j5
/dev/sda3      ext4               (not mounted)     640565a9-310b-5d6r-8d8v7-e887do893f80
/dev/sda5      ext4               (not mounted)     e777547b-3a3a-7tgd-9a12-2769wsrbd92
/dev/sda6      swap               <swap>            d72b694e-4976-3333-hso5-7894e6s9d2

Now, use 'nano', 'vi', 'gedit', 'mousepad' or whatever your favorite text editor is to edit or confirm the listed UUID for your root partition in /etc/fstab. For this example, I'll use nano:

sudo nano /etc/fstab

Now, according our information, our /etc/fstab information should look something like this assuming you are using a non-encrypted, single partition setup mounted at " / " :

# / was on /dev/sda1 during installation
UUID=bac7229a-e019-5679-931d-5e14f15ff4bc /         ext4    errors=remount-ro 0       1
# swap was on /dev/sda6 during installation
UUID=d72b694e-4976-3333-hso5-7894e6s9d2 none        swap    sw              0       0

If the information in /etc/fstab was incorrect and you have updated this information accordingly, all you need to do now is reboot because /etc/fstab is loaded post grub and is not directly associated with the configuration of of your initrd.img.

(The system will read the information in /etc/fstab and will automatically load the correct partitions from there)

If this does not fix your problem or if the information in /etc/fstab is accurate, you may need to run:

sudo update-initramfs -v -c -k all

You may want to substitute "all" with a specific kernel version if you do not want to update all of the existing initrd images ( this way you can update just the image that will not boot ). See here for more info: https://stackoverflow.com/questions/9645073/how-to-make-an-initrd-img-in-ubuntu

If all goes well, don't forget to run:

sudo update-grub2

before you reboot.

Please post any errors.


Shell Script to Run Commands to All Subdirectories

You can iterate subdirs with a for-loop like this

#!/usr/bin/env bash

for dir in /the/path/*/; do
    awk 'tolower($0) ~ /01_node_setup/{line=$0} END{print line}' "$dir/his_file"

    if [[ -f "$dir/sysconfig.out" ]]; then
        awk '/Drive Model/{getline line} END{print line}' "$dir/sysconfig.out"
    else
        awk '/Pair0 DIMM0/{print;exit}' "$dir/node0/trans_file_prev"/*setupsys*
    fi
done >> /home/xtee/sst-logs.out

I changed your greps into awks that should be more portable. I believe they should produce the same output. The important parts are the quotes around the paths.


Evince doesn't support bookmarks, but does keep your location in the file.  IE if you open a pdf, scroll down to page 42, then close evince, next time you open that pdf, it will start on page 42.

evince is the default pdf viewer for most versions of Ubuntu.


You can --force-all the installation, (and libclassicclient will work) but after this installation, you will have dkpg message :

dpkg: error processing package libclassicclient

each time you will install a new package ...

To remove this warning just remove the file :

/var/lib/dpkg/info/libclassicclient.postinst

May be, you will need to create the simlink by hand. To do so, cd to /usr/lib.
If a link libsqlite3.so exists , delete it and re-create it :

cd /usr/lib
rm libsqlite3.so
ln -s libsqlite.so.0 libsqlite3.so

That's all...


How to disable avahi-daemon in Ubuntu 16.04 LTS?

Since 16.04 is a systemd system, you need to do

sudo systemctl disable avahi-daemon.socket
sudo systemctl disable avahi-daemon.service

Also, the cups-browsed.service "Wants" avahi to start, so you'll either have to disable that, too, or comment out the line in /lib/systemd/system/cups-browsed.service:

Wants=avahi-daemon.service

Then you don't need to uninstall anything.

This won't take effect until reboot, but you can do

sudo systemctl stop avahi-daemon.socket
sudo systemctl stop avahi-daemon.service

If you want to stop it right away.


Typing several foreign characters with a single keyboard layout in Ubuntu

Virtual keyboard

It helps to find the special characters (and identify the layout in general), if you use a virtual keyboard, for example onboard.

See this link,

Hungarian accented letters without the physical keyboard

This makes it easier, when you switch keyboard layout between languages.

Suggested method

I think you might prefer to use US English keyboard with international symbols, which is described at the following link,

Making Umlauts in ubuntu 17.10 on a ThinkPad430


Can I use UBUNTU SERVER AS A REGULAR COMPUTER?

On load you will see a terminal line
If you run apt-get install ubuntu-desktop
you will end up with the functional equivalent of Desktop Edition. While also having all that the server package has


How can i Recover Windows 8 after deleting?

There is no way to recover the Windows 8 system if you have deleted it.

However, if you happened to have made a bootable clone of the Windows 8 system before deleting, you could boot into the external drive, make a partition so you can dual boot Ubuntu and Windows 8, and restore to that newly created Windows 8 partition.

If you do not have any backup, then you must follow mdpc's advice and reinstall from the Windows 8 Install DVD.


Documentation for GNOME application code?

So you want to contribute to (upstream) Gnome 3? I am asking, because you're posting at Ask Ubuntu and standard Ubuntu uses some GTK+/Gnome libraries as base but doesn't ship the complete Gnome Desktop environment. Unless you are using Ubuntu Gnome.
But even then, there is a difference between working on the Distribution and working on the Upstream project. Since a distribution always uses a "snapshot" or older version of Gnome, fixing bugs often means getting the patches from upstream or just changing configuration etc.
Anyway, if you want to contribute to Gnome, they actually have some good "getting started" pages: GNOME: Get involved
Look at this for example: GNOME Wiki: Welcome to the Newcomers Guide!
Check out "Finding Tasks" etc.
Your first step will be to get the latest version, build and run it successfully, so you can test. Then I'd start with a small, manageable application and check out the issue/bug-tracker.


GNOME does not show the option to use dedicated graphics card on right click

GNOME requires switcheroo-control in order to detect whether the system has a hybrid graphics configuration. Check this for more on that.

The fix was as easy as running one command:
sudo apt install switcheroo-control, and once it was installed, everything worked as expected, so the "Use dedicated graphics card" appeared in the right-click menu, and the GPU showed up in System Settings. It did not require a reboot or restarting the session.

I still wonder why this package was not installed during the Ubuntu installation...


Let's examine an example.

File relative_urls.list:

> cat relative_urls.list
/users/449/oli
/users/449
/help/badges
/help/badges/185/curious
/unanswered
/questions/tagged/12.04
/questions/tagged/boot
/questions/tagged/oracle
/questions/tagged/internet_explorer
/questions/tagged/outlook

We'd like to check if these documents available on the site http://askubuntu.com.

Possible solution:

> cat relative_urls.list |while read i ; do curl --head -s "http://askubuntu.com"$i |grep -q '^HTTP.*200' && echo "OK '$i'" ||echo "fail '$i'" ; done

And the result is:

OK '/users/449/oli'
fail '/users/449'
OK '/help/badges'
OK '/help/badges/185/curious'
OK '/unanswered'
OK '/questions/tagged/12.04'
OK '/questions/tagged/boot'
OK '/questions/tagged/oracle'
fail '/questions/tagged/internet_explorer'
fail '/questions/tagged/outlook'

If you prefer another definition of availability of url, you can change grep command to something more relevant to your conditions.

Important thing is that curl shows whether an url is served by a web server. There is no reliable method to determine existence of directory on a web server's file system via http.


How to install Ubuntu on a laptop alongside Windows Vista?

You should install your Windows Vista. Next you should run Ubuntu form disc or pendrive and just install it. During the installation you will have check box "Instal next to Windows Vista".

And that is pretty all you need to do :)


Problems after installing ATI proprietary driver

From the above forums post, boot to recovery mode and run the following commands

apt-get remove --purge xorg-driver-fglrx fglrx-kernel-source
apt-get update
dpkg-reconfigure xserver-xorg

Reboot and X should work.

You can try to install the proprietary drivers, check to see if your card is supported first

Supported hardware : http://wiki.cchtml.com/index.php/Hardware

Installation guide : http://wiki.cchtml.com/index.php/Ubuntu_Oneiric_Installation_Guide


Screen not refreshing after Nvidia driver install on Ubuntu 12.04

I managed to fix that issue. Since the buffering seems to be an issue I tried the following:

In Compizconfig-settings-manager-> advanced search-> workarounds (in plugins on right)-> Force full screen redraws (buffer swap) on repaint (tick)

enabling this setting alone seems to solve my issue completely :)


The easiest way to install Python 3.5 is with anaconda

https://docs.continuum.io/anaconda/install


WiFi works perfectly on Windows, but drops on Ubuntu

The problem was fixed in this forum thread:

http://ubuntuforums.org/showthread.php?p=10428524#post10428524

It turns out all I had to do was install the wicd network manager.  But thank you for your responses.


VirtualBox 5.0.40 crashes the whole host since update to kernel 4.13.0-26-generic

Upgrading to VirtualBox 5.2 using oracle repository worked for me.

Here are the steps (legacy doc here):

1) Add oracle repository :

sudo add-apt-repository "deb http://download.virtualbox.org/virtualbox/debian xenial contrib"

Modify this command to suit your ubuntu version if you are not using Ubuntu 16.04 (xenial).

2) Add GPG keys for repository :

wget -q https://www.virtualbox.org/download/oracle_vbox_2016.asc -O- | sudo apt-key add -
wget -q https://www.virtualbox.org/download/oracle_vbox.asc -O- | sudo apt-key add -

3) Check GPG keys :

sudo apt-key finger Oracle

should give show the following fingerprints :

B9F8 D658 297A F3EF C18D  5CDF A2F6 83C5 2980 AECF
Oracle Corporation (VirtualBox archive signing key)

7B0F AB3A 13B9 0743 5925  D9C9 5442 2A4B 98AB 5139
Oracle Corporation (VirtualBox archive signing key)

4) Install VirtualBox 5.2

sudo apt update && sudo apt install virtualbox-5.2

In my case I had errors and I had to remove virtualbox-dkms package and run /sbin/vboxconfig :

sudo apt remove --purge virtualbox-dkms
sudo  /sbin/vboxconfig

Depending on your desktop environment, the launcher menu icon may have disappeared. In that case, recreate it manually; the command is simply virtualbox.


Ubuntu 13.10 32 bit - Install screen prevents install

Darent, thanks for making my links visible.

I got up this morning and seeing no answers, created a dvd for Ubuntu 12.04 LTS - 32bit.  The install went perfectly and I am now exploring the Ubuntu Desktop.

Thanks again.


Prevent Internet access to particular user accounts... with netplan?

netplan is a management interface for configuring network interfaces (addresses, routes, and so on).  It does not handle iptables configuration, just as the tools it replaces (ifupdown) did not.


Trouble configuring OpenVPN connection from Mullvad

You are running into a very common problem. You have forgot to use sudo.

So instead of:

vim /etc/NetworkManager.conf

do:

sudo vim /etc/NetworkManager.conf

Replace vim with nano or whatever editor you use.


How can I build a scrollable, colored syslog viewer with less, ccze, grep?

That's because you're doing it the wrong way around. It's less that is scrollable so that needs to be the last command in the pipeline:

grep error /var/log/syslog | ccze -A | less -R

The options used are:

  -A, --raw-ansi

  If one wants to enable raw ANSI color sequences instead of using
       curses, this option does just that.

This makes ccze use ANSI color codes instead of curses. While less can deal with ANSI escapes with the -R option (see below), curses are more of a problem. Using the -A option of ccze neatly sidesteps that issue.

  -R or --RAW-CONTROL-CHARS
            Like -r, but only ANSI "color" escape sequences are output in "raw" form.  Unlike -r, the screen appearance is maintained
  correctly in most  cases.
            ANSI "color" escape sequences are sequences of the form:

  ESC [ ... m

  where  the  "..." is zero or more color specification characters For the purpose of keeping track of screen appearance, ANSI
  color escape sequences
            are assumed to not move the cursor.  You can make less think that characters other than "m" can end ANSI color  escape  sequences
  by  setting  the
            environment variable LESSANSIENDCHARS to the list of characters which can end a color escape sequence.  And you can make
  less think that characters
            other than the standard ones may appear between the ESC and the m by setting the environment variable LESSANSIMIDCHARS to the
  list  of  characters
            which can appear.


What is the difference between Multiverse and Partner sources

Multiverse

non free
licensing requirements
no support

Partner

proprietary
closed source
support

Can multiverse software be closed source? If not, how and why can non free software be open source?

Yes, it contains "software restricted by copyright and legal issues". That can include closed source.
Private software can be open source and non-free.

What are "licensing requirements"? An example would be great.

mp3, mp4 support are the most common examples in multiverse. We can use them. For Ubuntu to have it installed by default Canonical would need to pay a license.

Closed source does not imply proprietary?

That is the wrong way around: proprietary does not imply closed source. vBulletin is an example. It is proprietary but pay a license and you get the source that you can alter but not distribute.

How is proprietary different from non free?

non-free: anything not in compliance with the Debian Free Software Guidelines
proprietary: anything that does not follow the Free Software Foundation guidelines.

Partner software gets support from whom? Enterprises which have contracts with Canonical stating they will provide support? Is this what partners are?

From the partners.
And yes. See ubuntu.com/partner for a list of them (both hardware and software).

More on this can be found on the wikipedia page for Ubuntu


Filesystem - No space left error, but there is space

"After running a python script who created more than 65 million of files" here is your problem.

The ext4 file system Ubuntu uses has only a limited number of so-called "inodes", which is determined when you format a partition. You need at least one inode per file or directory on the file system.

Now if you create huge numbers of small files, you'll exhaust the available inodes faster than the available storage space. Both equally result in the same symptoms of a seemingly full disk though.

You will need to get rid of those tons of tiny files and e.g. put them on a different drive, in a zip file, or delete them altogether.

Unfortunately the number of inodes can not be changed dynamically, as far as I know. If you really need more on your current partition, you'll probably need to back up your data and reformat everything.

Related:

Running out of inodes
How can I create an EXT4 partition with an extra large number of inodes?
Drawbacks of increasing number of inodes in EXT4


GRUB disappeared after recent Ubuntu 12/Win7 install?

As Mitch has suggested you will need to run "Boot Repair"

You will need to do this using a Live CD/USB see here https://help.ubuntu.com/community/RecoveringUbuntuAfterInstallingWindows for full instructions


Ring Switcher in Unity - Mouse combinations don't work

Install compizconfig-settings-manager using Ubuntu Software Center or apt-get.
Hit Alt+F2 and type ccsm and hit Enter.
Go to "Ring Switcher" and select the shortcut you want.


How can I discover where apt-get has installed applications?

Via dpkg-query:

dpkg-query -L maven
dpkg-query -L ant

or with a filter using grep

dpkg-query -L maven | grep '^/usr/bin'

sample output

$ dpkg-query -L mc
/.
/usr
/usr/share
/usr/share/applications
/usr/share/applications/mc.desktop
/usr/share/doc
/usr/share/doc/mc
/usr/share/doc/mc/README.Debian
/usr/share/doc/mc/NEWS.Debian.gz
/usr/share/doc/mc/changelog.Debian.gz
/usr/share/doc/mc/copyright
/usr/share/pixmaps
/usr/share/pixmaps/mc.xpm
/usr/share/menu
/usr/share/menu/mc
/usr/share/mc
/usr/share/mc/bin
/usr/share/lintian
/usr/share/lintian/overrides
/usr/share/lintian/overrides/mc
/usr/bin
/usr/bin/mc
/usr/lib
/usr/lib/mc
/usr/lib/mc/extfs.d
/usr/lib/mc/extfs.d/patchfs
/usr/lib/mc/extfs.d/lslR
/usr/lib/mc/extfs.d/debd
/usr/lib/mc/extfs.d/mailfs
/usr/lib/mc/extfs.d/ulha
/usr/lib/mc/extfs.d/hp48+
/usr/lib/mc/extfs.d/ualz
/usr/lib/mc/extfs.d/a+
/usr/lib/mc/extfs.d/uc1541
/usr/lib/mc/extfs.d/changesetfs
/usr/lib/mc/extfs.d/bpp
/usr/lib/mc/extfs.d/ucab
/usr/lib/mc/extfs.d/audio
/usr/lib/mc/extfs.d/uha
/usr/lib/mc/extfs.d/deb
/usr/lib/mc/extfs.d/urar
/usr/lib/mc/extfs.d/uarc
/usr/lib/mc/extfs.d/uzip
/usr/lib/mc/extfs.d/dpkg+
/usr/lib/mc/extfs.d/ulib
/usr/lib/mc/extfs.d/uar
/usr/lib/mc/extfs.d/uzoo
/usr/lib/mc/extfs.d/README
/usr/lib/mc/extfs.d/apt+
/usr/lib/mc/extfs.d/iso9660
/usr/lib/mc/extfs.d/rpms+
/usr/lib/mc/extfs.d/deba
/usr/lib/mc/extfs.d/rpm
/usr/lib/mc/extfs.d/gitfs+
/usr/lib/mc/extfs.d/patchsetfs
/usr/lib/mc/extfs.d/uarj
/usr/lib/mc/extfs.d/u7z
/usr/lib/mc/extfs.d/s3+
/usr/lib/mc/extfs.d/README.extfs
/usr/lib/mc/extfs.d/uace
/usr/lib/mc/extfs.d/trpm
/usr/lib/mc/cons.saver
/usr/lib/mc/mc.sh
/usr/lib/mc/mc-wrapper.sh
/usr/lib/mc/mc.csh
/usr/lib/mc/ext.d
/usr/lib/mc/ext.d/text.sh
/usr/lib/mc/ext.d/video.sh
/usr/lib/mc/ext.d/image.sh
/usr/lib/mc/ext.d/archive.sh
/usr/lib/mc/ext.d/package.sh
/usr/lib/mc/ext.d/sound.sh
/usr/lib/mc/ext.d/web.sh
/usr/lib/mc/ext.d/misc.sh
/usr/lib/mc/ext.d/doc.sh
/usr/lib/mc/mc-wrapper.csh
/usr/lib/mc/fish
/usr/lib/mc/fish/ls
/usr/lib/mc/fish/hardlink
/usr/lib/mc/fish/unlink
/usr/lib/mc/fish/mkdir
/usr/lib/mc/fish/append
/usr/lib/mc/fish/README.fish
/usr/lib/mc/fish/send
/usr/lib/mc/fish/fexists
/usr/lib/mc/fish/ln
/usr/lib/mc/fish/rmdir
/usr/lib/mc/fish/utime
/usr/lib/mc/fish/get
/usr/lib/mc/fish/chmod
/usr/lib/mc/fish/mv
/usr/lib/mc/fish/chown
/usr/lib/mc/fish/info
/etc
/etc/mc
/etc/mc/mc.emacs.keymap
/etc/mc/sfs.ini
/etc/mc/mc.default.keymap
/etc/mc/mc.keymap
/etc/mc/filehighlight.ini
/etc/mc/edit.indent.rc
/etc/mc/mcedit.menu
/etc/mc/mc.menu
/etc/mc/mc.ext
/etc/mc/mc.menu.sr
/usr/share/mc/bin/mc.sh
/usr/share/mc/bin/mc-wrapper.sh
/usr/share/mc/bin/mc.csh
/usr/share/mc/bin/mc-wrapper.csh
/usr/bin/mcdiff
/usr/bin/mcedit
/usr/bin/mcview


Since the --exclude option only acts on filenames, there's no direct way to do it. You could try round-about ways like using find to print the name of all directories:

inotifywait --exclude "echo -n (;$(find . -maxdepth 1 -mindepth 1 -type d -printf '%P|');echo )" .

Note that I didn't specify -r, since that will cause newly created subdirectories to be watched too.

This might break with some special characters.

You could also try:

find . -maxdepth 1 -mindepth 1 -type d -printf '@%P\n' > list_of_directories
inotifywait --fromfile list_of_directories .

inotifywait will exclude any files or folders in list_of_directories which begin with @ (all of them do).

If you're using inotifywait with the recursive option, let find list all nested subdirectories as well by removing the -maxdepth restriction (also applies to the first command):

find . -mindepth 1 -type d -printf '@%P\n' > list_of_directories
inotifywait --fromfile list_of_directories . -r

The -mindepth is retained to prevent find from matching ., and thus excluding the current directory as well.


Issues with libs on Ubuntu 16.04 (On Amazon EC2 Instance)

Upgrading kernel should work, but you have to note that it is looking at all installed kernels, not just the running kernel.

I had good luck with:

AWS-RunShellScript—

#!/bin/bash
package-cleanup --oldkernels --count=1 -y || purge-old-kernels --keep 1 -qy

Possible remediation for cron: upgrading by way of debian package.

dpkg -i http://http.us.debian.org/debian/pool/main/c/cron/cron_3.0pl1-130_amd64.deb
dpkg -i http://http.us.debian.org/debian/pool/main/z/zlib/zlib1g_1.2.11.dfsg-1_amd64.deb

This did not work for another package I was stuck with (man-db), which ... wound up having a rabbit-hole of dependencies... so I'm now looking at upgrading to 18.04LTS (which still hasn't fixed cron, but everything else seems good).


No desktop after using janitor in ubuntu tweak

Please refer to https://askubuntu.com/a/17614/44518
Or
https://askubuntu.com/a/202020/44518

This should help you getting this sorted out.


NVIDIA driver installation. Need to update after each kernel update

Yes it is. The following installation guide provided here by eromod will install NVidia Drivers and CUDA so that you don't need to update them manually (will be done by apt update/upgrade):

sudo add-apt-repository ppa:graphics-drivers/ppa

sudo apt update

sudo ubuntu-drivers autoinstall

reboot

sudo apt install nvidia-cuda-toolkit gcc-6

nvcc --version


Is there an app to lower the battery charge max?

Install TLP and configure the upper charge threshold.


Your system's libpam is actually in /lib/i386-linux-gnu/libpam.so, so if your DB2 expects to find in in /lib it will fail.  Try adding the i386-linux-gnu to LD_LIBRARY_PATH, or even put an explicit link in /lib .


From man rsync:

CREDITS
       ...
       This program uses the excellent zlib compression library written
       by Jean-loup Gailly and Mark Adler.

From the zlib homepage:

  zlib is designed to be a free, general-purpose, legally unencumbered -- that is, not covered by any patents -- lossless data-compression library ...

Beyond verifying zlib, which is a very well-known, widely-used compression library, there's nothing much you can do.


How can I initiate Nautilus file operations from the command line?

The short answer is, you can't. Nautilus is not built to allow that sort of thing and you can go through the source code of nautilus and look at the file copy/move sections to see how it works.

Part of this lack of integration was the motivation behind the progress indicator design. It would replace the nautilus progress window and several other progress inconsistencies and allow multiple programs to show their progress to the user in the same way:

https://wiki.ubuntu.com/Ayatana/ProgressIndication

More work and advocacy for these new designs would help, allowing integration of all sorts of tools.


Maybe you want to use kernel backports.
I was messing around with this driver with kubuntu 12.10, 13.04 and 13.10 alpha one year ago.
Now with the current kernel in 13.10 the device works!


It means exactly what you said: there is no other computer associated with that progress. If you were connected to another machine on a service, that computers IP address and the port used for the connection would show up under the  foreign address column.


I assume you've already installed Java. If not, you can execute the following command to install the OpenJDK JRE (an open source alternative for Oracle's Java):

sudo apt-get install openjdk-7-jre

Follow the these instructions to start Universal Media Server at startup.

Open your Dash
Search for Startup Applications and open it
Click on Add
Enter the following:

Name:    Universal Media Server
Command: java -jar /path/to/ums.jar
Comment: Start Universal Media Server

Replace /path/to/ums.jar by the actual path to ums.jar.
Click on Add


Installing Windows 10 32-bit in virtual box not working

By downloading the .iso files, I was able to install it that way. Booting the the usb was causing the issue.


You can use QChart.js - QML bindings for Charts.js (a simple HTML5 Charts javascript library using the canvas element)

I forked the project here to support resize events (for a desktop use).
I basically need to reset the canvas context to allow resize events to properly redraw the surface with an updated window size (See http://qt-project.org/forums/viewthread/37313)

QML example:

The following snippet creates the above pie chart page:

import QtQuick 2.0
import QtQuick.Layouts 1.1
import Ubuntu.Components 0.1
import "."
import "QChart.js" as Charts

MainView {
    id: root
    width: units.gu(50)
    height: units.gu(80)

    PageStack {
        id: pageStack
        Component.onCompleted: push(page0)

        Page {
            id: page0
            title: i18n.tr("Test Results")

            ColumnLayout {
                spacing: units.gu(2)
                anchors.margins: units.gu(2);
                anchors.fill: parent

                Label {
                    fontSize: "x-large"
                    text: "Summary"
                }

                Chart {
                    id: chart_pie;
                    Layout.fillHeight: true
                    Layout.fillWidth: true
                    chartAnimated: true;
                    chartAnimationEasing: Easing.Linear;
                    chartAnimationDuration: 1000;
                    chartType: Charts.ChartType.PIE;
                    chartOptions: {"segmentStrokeColor": "#ECECEC"};
                    chartData: [
                        {value: 15, color: "#6AA84F"},
                        {value:  3, color: "#DC3912"},
                        {value:  5, color: "#FF9900"}];
                }

                Column {
                    id: legend
                    Row {
                        spacing: units.gu(1)
                        Text {
                            text: "█"
                            color:"#6AA84F"
                        }
                        Text {
                            text: "15 tests passed"
                        }
                    }
                    Row {
                        spacing: units.gu(1)
                        Text {
                            text: "█"
                            color:"#DC3912"
                        }
                        Text {
                            text: "3 tests failed"
                        }
                    }
                    Row {
                        spacing: units.gu(1)
                        Text {
                            text: "█"
                            color:"#FF9900"
                        }
                        Text {
                            text: "5 tests skipped"
                        }
                    }
                }

                Button {
                    id: button
                    Layout.fillWidth: true
                    color: "#009E0F";
                    text: "Save detailed report";
                    font.bold: true;
                    onClicked: {
                        button.color = "#009E0F"
                        chart_pie.repaint();
                    }
                }
            }
        }
    }
}


When I add myself "vboxusers" group I an no longer in the "admins" group

Your second command is right.

By default, usermod -G replaces all supplementary groups the user is in (the primary group is generally named the same as your username, and specified separately; don't mess with that though). By also using -a it appends the groups you give.

So this should work (and does, for me, just tried it):

usermod -aG vboxusers myusername

If running that command takes you out of any other group then you've found a bug. Note you have to relogin to see the effects.


What version of your Ubuntu ? workstation(desktop) or server edition ? If your Ubuntu version is workstation do not type script in /etc/network/interfaces, it can be make your network manager not works . Use the network manager to set static ip in your system . open terminal -> type : nm-connection-editor -> chose your interfaces which to edited -> settings -> ipv4 -> method -> static . Look at the picture to use network manager .


I think the answer is simple, I just selected the single display option in among the three display options in display settings in devices. Though I was worried what's unknown display in each setting, I tried selecting that too and the screen went blank, but the changes revert back if we don't confirm, so I know we shouldn't select that option in single display. I think the other two can be selected when there's another display device attached, don't know why it was selected by default.


Ubuntu 18.04 boots only through recovery (old laptop with Intel Mobile 945GM)

Regular ubuntu no longer supports 32bit processors like yours unfortunately, you may want to consider trying Lubuntu 18.04 which still does.


Proof Identify stolen computer getting computer identification info from Launchpad bugs and comparing

Rather than doing something complicated, do you have the laptop's serial number? If you do, you could use that as proof. Alternatively, you could, as Web-E said, use the computer's MAC address.


Resolved by reset task parameters. In printer configuration: Printer>properties>task options> then reset "maintain" ("maintenir jusqu'à" on the screen shot).


Disable Unity shortcuts

Install ccsm
 sudo apt-get install compizconfig-settings-manager

Go to Desktop category → Ubuntu Unity plugin → Switcher tab
Click on each shortcut, uncheck Enable, then OK

Go to Desktop category → Desktop Wall → Bindings tab
Same way, disable the shortcuts that you want.

Close ccsm, It is effective right after closing.

ccsm shortcuts have priority on custom one from system settings. You can use dconf to see the underlying setting changed when you make the above steps using GUI.
$ dconf watch /
/org/compiz/profiles/unity/plugins/unityshell/alt-tab-prev
  'Disabled'

/org/compiz/profiles/unity/plugins/unityshell/alt-tab-prev
  'Disabled'

/org/compiz/profiles/unity/plugins/unityshell/alt-tab-forward
  unset

/org/compiz/profiles/unity/plugins/unityshell/alt-tab-forward
  unset

So better to make a wrapper script to disable unity switcher shortcuts, launch x2goclient, then enable them back after closing x2goclient.
dconf write /org/compiz/profiles/unity/plugins/unityshell/alt-tab-prev "'Disabled'"
dconf write /org/compiz/profiles/unity/plugins/unityshell/alt-tab-forward "'Disabled'"
...
x2goclient
dconf reset /org/compiz/profiles/unity/plugins/unityshell/alt-tab-prev
dconf reset /org/compiz/profiles/unity/plugins/unityshell/alt-tab-forward
...

Disable LXDE shortcuts
Old answer that could be useful for some.
The shortcut you mention belong to OpenBox. Which is launched with predefine settings for Lubuntu. (At least this is the case for Lubuntu 14.04).
~$ pgrep -a openbox
4772 openbox --config-file /home/lubuntu/.config/openbox/lubuntu-rc.xml

We should unbind them from OpenBox or any tools already binded them.

Open its configuration file for editing
 leafpad ~/.config/openbox/lubuntu-rc.xml

Then comment the shortcuts  you want using XML comment tags <!-- -->
or delete them.

New customized shortcut forwarded to x2goclient
After that setup global shortcuts to forward shortcut to x2goclient window using wmctrl & xvkbd.

System Settings → Keyboard → Shortcuts tab

Add new custom shortcut with command
 bash -c 'wid=$(wmctrl -l | awk "/X2Go Client/ {print $1; exit}"); echo $wid; if [ "$wid" ] ; then xvkbd -window $wid -xsentevent -text "\A\t"; fi'

for AltTab


How do I make Youtube videos stream faster on my ubuntu?

The commands would be

sudo iptables -I OUTPUT -p tcp --dest 173.194.55.0/24 -j DROP
sudo iptables -I OUTPUT -p tcp --dest 206.111.0.0/16 -j DROP

Use at your own risk as it might stop other Youtube functions as they are Google infrastructure servers.


After shutting down laptop from ubuntu 16.04 it getting hot

first test that the suspend functionality works without closing the lid

systemctl suspend

you should see the system suspend , it should wake up when you press a key or move the mouse.

then try hibernating without closing the lid

systemctl hibernate

If both of those work and your laptop isn't getting hot then it would seem like the lid sensor is either faulty or not being setup properly.

If either of these don't work then it would seem your problem is that its not actually suspending or hibernating when you close the lid, maybe you have some services running that won't suspend, an external monitor or an experimental hardware driver.

Work your way through this guide if its not suspending or hibernating
https://wiki.ubuntu.com/DebuggingKernelSuspend


nginx fails to update after upgrade to 16.04 server

This will likely fix it. I had this, and a couple of other problems myself.

Move to /etc and copy the nginx directory for safety:

cd /etc
cp -R nginx/ nginx-bak/

Remove the old version of nginx:

apt-get remove nginx nginx-common

Install the new nginx:

apt-get install nginx

Answer no to any prompts to overwrite configs.
To enable and run nginx:

systemctl unmask nginx.service
systemctl start nginx.service


How to resize root partition (/) without LVM

Make sure that you have a good backup of your important Ubuntu files, as this procedure can corrupt or lose data.
Keep these things in mind:

always start the entire procedure with issuing a swapoff on any mounted swap partitions, and end the entire procedure with issuing a swapon on that same swap partition

a move is done by pointing the mouse pointer at the center of a partition and dragging it left/right with the hand cursor

a resize is done by dragging the left/right side of a partition to the left/right with the directional arrow cursor

if any partition can't be moved/resized graphically, you may have to manually enter the specific required numeric data (don't do this unless I instruct you to)

you begin any move/resize by right-clicking on the partition in the lower pane of the main window, and selecting the desired action from the popup menu, then finishing that action in the new move/resize window

Do the following...
Note: if the procedure doesn't work exactly as I outline, STOP immediately and DO NOT continue.

boot to a Ubuntu Live DVD/USB, in “Try Ubuntu” mode
start gparted
resize (reduce) the right side of p11 by the amount that you wish to add to p10 (~10G)
move the p11 partition all the way right
resize the right side of p10 all the way right
click the Apply icon


How to add legal banner in /etc/issue and /etc/issue.net in Ubuntu?

One of the easiest way to protect and secure SSH logins by displaying warming message to UN-authorized users or display welcome or informational messages to authorized users.

A legal banner contains some security warning information or general information, that alerts the user.  It can be used for security, legal info, company policy, etc.

One way to display messages is using issue.net file.  issue.net : Display a banner message before the password login prompt.

To display Welcome or Warning message for SSH users before login. Use issue.net file to display a banner massages. Open the following file with the editor.

vi /etc/issue.net

Add the banner message of your choice, and save the file.  Next you would open the master ssh configuration file and enable banners.

vi /etc/ssh/sshd_config

Search for the word “Banner” and uncomment out the line and save the file.

#Banner /some/path

It should be like this.

Banner /etc/issue.net (you can use any path you want)

Next, restart the SSH daemon to reflect new changes.

/etc/init.d/sshd restart

Now try to connect to server you will see banner message you just added.

Source:Tecmint


Qualcomm Atheros QCA8172 No network traffic is shown

After a few days searching I can see my problem is a kernel problem in ubuntu and an old drive version for my ethernet card, like is showed here:

Answer 1

and confirmed in Launchpad:
L1 and
L2


ls command to view particular string in filename within directory

If you want to be absolutely precise:

ls stacov_????????.[0-9][0-9]o

in shell globbing ? indicates any single character.


If you are just wanting to test drive an OpenStack deployment the easiest way to get started is here: http://www.ubuntu.com/download/cloud/install-ubuntu-openstack

This enables you to deploy a full OpenStack cloud powered by Juju, MAAS, and Landscape (which gives you 10 free virtual and 10 free bare metal seats)


how to transfer hard drive from on pc to another, HDD contains grub (dual boot win10 and ubuntu gnome)

Before proceeding please backup any documents on your computer to an external drive. You could do this by either putting the SSD back into the old computer or using a Live CD.

Whilst not the same issue, the instructions on the below page should fix the problem you're getting.

https://help.ubuntu.com/community/RecoveringUbuntuAfterInstallingWindows

Any problems, let me know! :)


Correct place to put colors of prompt (PS1)

.bashrc is considered the proper place for such configurations.

For details see:

https://help.ubuntu.com/community/CustomizingBashPrompt

If you have concerns or someting to the contrary you read somewhere, you would need to express them or post a link for better advice.


How to see if a specific process is running or not for 1 hour in shell

You can use a while loop; here i am using pgrep to check if the process is running:

#!/bin/bash
counter=0
while :; do
    [ "$counter" -eq 6 ] && break
    if pgrep <process_name> &>/dev/null; then
        echo "Success !!"
        (( counter += 1 ))
        sleep 10m
    else
        echo "Process not running..exiting !!"
        break
    fi
done

Replace <process_name> with the actual name of the process you want to track.


find: paths must precede expression: )xargs

xargs attempts to construct an argument list from its stdin (standard input). Often, the stdin of xargs is the output of some command that has been piped to xargs. To create a useless example, we can waste a lot of characters listing the files in our home directory, instead of just typing ls -A ~ like this:

echo ~ | xargs ls -A

The pipe operator | takes the stdout (standard output) of the command to the left of it, and passes it as the stdin of the command to the right of it. It's important to remember that stdout is just a stream of text, which may cause problems when passed to the second command by xargs if it contains spaces or special characters. When we use find, whose output is filenames, with xargs, to avoid errors caused by special characters, we conventionally use

find -print 0 | xargs -0

This causes find to append the null character to each filename and xargs to interpret the list as null-delimited instead of space-delimited. The null character cannot appear in filenames, so there is no chance that a filename will be interpreted as two filenames if we delimit with the null character.

Since you missed out the pipe character | that separates and connects the two commands find and xargs, find thought that )xargs was one of its arguments, and since it did not begin with - or follow a valid test beginning with -, it decided that )xargs must be a path you want to search, but paths must precede expression, the syntax of find requires the path to search to be given before other arguments.

Many people prefer to use -exec with find instead of piping to xargs (see What is the difference between find with -exec and xargs?), for example:

find /path -tests ... -exec some_command {} +

This may be more suitable in your case, particularly since the mv command expects its last argument to be the destination. You could use xargs -I {} mv {} /path/to/destination but it would be more readable and perhaps more efficient to specify the destination with -t

find /home/tony/Desktop/unsorted_files/ -maxdepth 1 -not \( -type d -or -iname "*.jpg" -or -iname "*.gif" -or -iname "*.docx" \) -exec mv -t /home/tony/Desktop/dregsfolder -- {} +


The two major open source speech-recognition engines in Ubuntu are Julius and Pocketsphinx. Both of these are quite low-level research projects, and you'll need to do a lot of reading and experimenting to be able to use them: they're not simple install-and-go projects. Simon Listens, as mentioned above, is a simple install-and-go project, and the Simon Listens project has a specific installation for Ubuntu -- http://www.cyber-byte.at/wiki/index.php/Installation#Ubuntu has instructions on how to enable it -- but that only works with 10.04, not the recently-released 10.10. (Hopefully the Simon Listens project will make a 10.10 version available soon.)


18.04 - No Internet Connection - Realtek RTL8111

The steps I took to solve this isse were:

I had to disable the r8189
I needed to install the r8168 from mtorromeo https://github.com/mtorromeo/r8168
Execute: ethtool -s eth0 speed 100 duplex full autoneg on
I needed to add the above into my startup scripts by creating:

#!/bin/sh -e
ethtool -s ens133 speed 100 duplex full autoneg on
exit 0

adding it to rc.local


Asus ROG Zephyrus Keyboard Backlight not working

I can confirm the Zephyrus keyword isn't working for 17.04

I had the same problem, and I was able to solve it, but I'm using Gentoo with 4.12-8 vanilla sources.

My solution was adding blacklisting asus-nb-wmi, for that, you need the following text inside /etc/modprobe.d/blacklist.conf file

blacklist asus-nb-wmi

I hope it works! The problem seems to be related because asus-nb-wmi adds one fake (or wrong detected) keyboard device, and hid_asus also adds other device, so desktops seems to be using the first one which is wrong. blacklisting will avoid the bad one and keep the other correctly.

This solution will add suspend, airplane mode, keyboard lights, screen lights, screen keys and volume. That doesn't fix the numeric keyboard.

Regards


How to rename multiple files that have different names to file1, file2, file3, etc?

Use rename utility to do this:

rename -n '$_ = sprintf "file%d.txt", ++$::count' *

Notes

-n makes the command show you what will happen if you run it. If the output was what you  want, run it without -n to actually rename the files.
replace the * with what you want to rename, for example: dog*.txt to only rename dog1.txt, dog2.txt ... to file1.txt, file2.txt, etc.
$_ is a default input (file names) which we should modify.
using = we are modifying it
with sprintf we are defining a schema started by file followed by %d means a number and ended to the .txt.
the number (%d) will be assigned using ++$::count, which is a simple counter iterated after each rename.

The idea comes from here.


How do I copy and paste from local machine?

For VMware make sure that VMware tools are installed.

VMware Tools is a suite of utilities that enhances the performance and management of the virtual machine. Without the tools installed, your guest machine will lack the following benefits:

High video resolution
Adequate color depth
Correct display of network speed
Unrestricted movement of the mouse
The ability to copy and paste and drag-and-drop files
SoundVMware

For VirtualBox make sure that Guest Additions are installed.


vsftpd - restrict users to home directory

You're looking for the allow_writeable_chroot configuration option, but this does not exist in the version of vsftpd shipped with 12.04. See bug 1065714 for a similar enquiry and details of why we can't have this in 12.04.

  Turning off chroot_local_user is not an option as they can then browse all the other users directories.

Have you considered switching to private user directories by default? If you don't want users to be able to browse other users' directories, then a more secure way of achieving this is with the permission mechanism baked in to the system, rather than through each individual service. See the user management section of the server guide for details on how to do this. Would turning off chroot_local_user then be an option for you?


how to reinstall ubuntu software updater

xkill does not uninstall the software. It should not need to be reinstalled.
You have some alternatives:

Simply logout and login. That should restore Software Updater.

Use a terminal instead: Run update-manager to launch Software Updater

If you meant to say that the software-update icon on the top bar is now missing, logout/login or run 'update-notifier'


You need the python-numpy (or python3-nympy) package. Run

sudo apt-get install python-numpy

and try again.


What are these "unknown key 'BUS'" errors during boot?

The log messages tell you they are from udev, and the errors are in the two files /lib/udev/rules.d/10-blackberry.rules and /etc/udev/rules.d/15-huawei.rules.  The question is from where did those two configuration files originate?

Files in /etc/ are configuration files.  As the system administrator you may edit them.  Did you create 15-huawei.rules?  If so, then it is your responsibility to update it.  If it was installed by a package, then first see if an update is available and if not then file a bug.

Files in /lib/ are installed by packages, and are not intended to be modified by the system administrator.

Run the command

dpkg -S /lib/udev/rules.d/10-blackberry.rules

and

dpkg -S /etc/udev/rules.d/15-huawei.rules

to determine what package, if any, provided those two files.

The udev package's Changelog shows "The long deprecated keys: SYSFS=, ID=, BUS= have been removed".  You have two files that use those keys,  which are no longer valid.  Either you don't really need those configuration files (do you have Blackberry and Huawei devices and plug them into your computer?) or they simply need to be updated to match the current version of udev.


After trying to set a static IP address, my computer can't recognise the network card

You have an incorrect device name in your .yaml file.
Use this for a static address:
network:
  version: 2
  renderer: networkd
  ethernets:
    enp3s0:
      addresses: [192.168.1.17/24]
      gateway4: 192.168.1.1
      nameservers:
        addresses: [192.168.1.1]
      optional: true

Or this for a dynamic address:
network:
  version: 2
  renderer: networkd
  ethernets:
    enp3s0:
      dhcp4: true
      optional: true

sudo netplan generate
sudo netplan apply
reboot


Extended ubuntu-server VM's memory. Still not enough available size

Your root partition is sda3 and it is using lvm (Logical Volume Management). So far you have not changed its size. What you have changed is the size of the device sda3 lives on, that's sda. sda will have a load of unallocated space. You need to do two things.

The first is to expand sda3 into the unallocated space you have provided.
The second is to make use of that additional space.

This is a good reference https://www.tecmint.com/extend-and-reduce-lvms-in-linux/


What program do I use to open the .iso file I download to use for installing ubuntu?

It is confusing at first.

When you download the .iso with firefox, you would save the file rather then opening it.

If you do not have any CD burning software installed, windows does not know what to do with an .iso, it thinks it is an archive (zip) file.

You do NOT extract or unzip the iso.

You have several options at this point

Install ubuntu with the wubi installer

follow the instructions on this page :

https://wiki.ubuntu.com/WubiGuide

You can also use unetbootin to "install" the ubuntu iso to a flash drive. You would then re boot your computer and during the boot process boot from the flash drive.
Burn the ubuntu .iso to a CD

https://help.ubuntu.com/community/BurningIsoHowto

You can then either re-boot or run the wubi installer

http://www.howtogeek.com/howto/9142/easily-install-ubuntu-linux-with-windows-using-the-wubi-installer/

==== STOP ====

You sound very new to Ubuntu and before you do much else I highly suggest you back up any data you do not want to loose. Although data loss is rare it can happen if you click the wrong button when installing Ubuntu.
Understand the difference between installing Ubuntu in the standard method, ie partitioning your hard drive, and wubi.

I already gave you a link for wubi, here is a link for a standard install

https://help.ubuntu.com/community/GraphicalInstall

Understand how Linux identifies partitions. Windows uses letters, such as C:\

Linux uses /dev/sda

See : http://ubuntuforums.org/showthread.php?t=282018

I know it may seem overwhelming at first, but understanding those few items will help prevent a mistake and potential data loss.

good luck to you.


Running a single executable with sudo adds two processes in process list

When you do:

sudo ./lwdpi -i enp5s0

sudo is the parent process, it fork(2)s a child, which then do execve(2) with ./lwdpi as the executable name
so lwdpi is sudo's child process

This results in two processes as you can see, one is sudo and another is lwdpi.

The best way to see the details is to check the PPID (parent process ID) too:

ps -eo pid,ppid,args | grep '[l]wdpi'

you'll see that lwdpi's parent is sudo itself.

Here is sudo's process model, from man sudo:

  When sudo runs a command, it calls fork(2), sets up the execution
  environment as described above, and calls the execve system call in
  the child process.  The main sudo process waits until the command has
  completed, then passes the command's exit status
       to the security policy's close function and exits.

  If an I/O logging plugin is configured or if the security policy explicitly
  requests it, a new  pseudo-terminal (“pty”) is created and a second
  sudo process is used to relay job control signals between
       the user's existing pty and the new pty the command is being run in.  This extra process makes it possible to, for example, suspend and
  resume the command.  Without it, the command would be in what POSIX
  terms an “orphaned process group” and it would
       not receive any job control signals.

  As a special case, if the policy plugin does not define a close function and no pty is required,
  sudo will execute the command directly instead of calling fork(2)
  first.  The sudoers policy plugin will only define a
       close function when I/O logging is enabled, a pty is required, or the pam_session or pam_setcred options are enabled.  Note that
  pam_session and pam_setcred are enabled by default on systems using
  PAM.


How do I show hidden files just for some directories?

The Nautilus file manager for Ubuntu is capable of doing this on a per-folder basis:

  If you want to see all hidden files in a folder, go to that folder and either click the view options button in the toolbar and pick Show Hidden Files, or press Ctrl+H. You will see all hidden files, along with regular files that are not hidden.


How can i delete Ubuntu from the computer?

Sorry to hear about that! There's no need of killing any computer! Simply install another operating system (OS). Any OS you like. During the install process it will probably ask you where you want it installed. Choose erase ENTIRE disk and install. After erasing entire disk, it will probably ask you for a new partition. Create a new partition any way you see fit and install OS to it. That's all!


bluetooth file transfer "there was an error"

You can see the error message using:
journalctl -r -t obexd

which for example could be:
obexd: Transfer Error: Unsupported Media Type

which indicates that the file format is not accepted by the destination device (in this case the workaround would be: zip it and send the zip file).


Google chrome doesn't render the fonts properly.

I faced the same problem. Following steps fixed the issue.

Install gnome-tweak-tool:
sudo apt-get install gnome-tweak-tool
Open Advanced settings from dash.
Select "Fonts".
Select "Grayscale" or "None" for the "Antialiasing" setting.

This issue is with the recent version of chrome. If you don't want to do the above steps I would recommend you to downgrade the chrome version.


I'm using 10.10 and have similar problems.

Run iwconfig and see if your ESSID is set. If not, run

iwconfig wlan0 essid "network name"

where you replace "network name" by the essid of your network.

This works for me. It seems that Network Manager doesn't do this correctly
for hidden networks.


Ubuntu 14.04 Elantech touchpad too sensitive

You probably solved your problem, but I'm posting for posterity's sake: changing the Synaptic Finger setting to 5 16 216 solved it for me.


Single home partition for two separate systems - one 32bit, the other 64bit

You can not share a single /home-partition with two different versions of Ubuntu.

Many files and folders are stored in the home-directory. One part of this files and folders are your private data, such as in the folders ~/Documents or ~/Downloads. Another part of files and folders are configuration-files (most of them are hidden by default and you will not see them in the file-manager unless you enable the option show hidden files) and here the problem starts. Possibly some of the configuration-files are valid for both versions of Ubuntu, but not all of them.

You may easily share your private data by creating links to the old data-folders in the /home-directory of the new version.

If you just want to install 16.04x64 over 14.04 (overwriting) then you can surely use the old /home-partition. You only need to set the mount-point for the partition and untick the formatting-checkbox during install, so your data are not deleted.

If you want to use both versions you could use a different user-name to install the new version of Ubuntu. If you use different user-names you could share the /home-partition, as both versions would have it's own sub-directory in the /home-folder, (/home/old_name and /home/new_name).

A problem is that it will be difficult to access the data-folders (like Documents, Downloads, etc) in /home/old_name when you use the new version of Ubuntu with a different user-name, you are not the owner of these files  in this case.


configuring stock tackpad gestures on 19.04

Not an exact answer (I am newbie to Ubuntu) but as a guide into a possible solution...

I got three finger gestures working using this answer (posted for 18.04 LTS): https://askubuntu.com/a/1044184

which uses a combination of:

libinput-gestures
xdotool
fusuma (ruby-gem)

For my purposes the default configuration was just fine.
But for there is also some description on customization in the post.

I added fusuma -d to autostart following this answer:
https://askubuntu.com/a/48327

(answer also posted on: Dell XPS 13 9350 touchpad multi finger gesture on Ubuntu 19.04)


Is there a good folder icon for "Programming" I can use in Ubuntu?

You can look through the different icons for you theme: In what directory(s) are the default ubuntu icons located?  Mostly located in /usr/share/icons

There are a few ones that might work in /usr/share/icons/Humanity/catagories/48

Also, you can use any icon you want, Here is one I made custom that might work:

To use, right click on a folder -> Properties -> click on the folder picture -> select a replacement picture


Why auto complete does not work for directories in terminal ?

The filepicker autocomplete path stub needs to be separate from any other string. In your example:

command --argument=/path/stub<TAB>

Bash is just going to see the --argument and bug out. You could probably improve it by making it parse through that but that's not entirely trivial.


Sound stopped working on Dell laptop Ubuntu 18.04

I had a similar problem. My issue is if I go to the Windows boot and then restart the computer, Ubuntu will have no sound. And it will continue to have no sound until I actually shut down the PC, the turn it on into the Ubuntu boot. This is the only way I was able to "fix" my problem.


What is the live session user password in Kubuntu 15.04?

try username: ubuntu and leave the password blank. Also other problem with it is also that running programs are gone when you log in again.


Apparently, works after renaming ~/.config to ~/.config.bak and restarting the machine.


Why Kodos is not part of the available packages in Ubuntu Quantal 12.10?

Old deps for python-qt3 et al were replaced with -qt4, you can either update your repository refs or install manually (make sure to resolve the deps).

Build-Depends: debhelper (>= 7.0.50~), python, pyqt4-dev-tools.

http://ppa.launchpad.net/phobie/updates/ubuntu/pool/main/k/kodos/kodos_2.4.9+20120813-0ubuntu0px1.dsc

Here's the .deb pkg: http://ppa.launchpad.net/phobie/updates/ubuntu/pool/main/k/kodos/kodos_2.4.9+20120813-0ubuntu0px1_all.deb


dpkg: error processing package liblmdb0:amd64

Try to fully reinstall this package:

apt-get install --reinstall liblmdb0


System freezing during 20.04 installation

Awesome thanks for the prompt heynnema! My BIOS was outdated, so it's good now. Guess what? Everything works now, don't know if it was the microcode revisions or what but that did the trick. Now writing this from within 20.04.Remember kids, always keep your bios up to date :)


How to delete the particular Linux from Linux dual boot system?

Can you not manually mount read only? Auto mounts are read write and then can fail if not writable.  Use your drive sda, sdb etc for sdX and partition for Y.

sudo mkdir /mnt/bodhi
sudo mount -o ro /dev/sdXY /mnt/bodhi


Update settings and refresh PCManFM using command line?

"Mistakes are the proof that you are trying" - (unknown)

Yes, I made a silly mistake and that too when I knew everything in back off my mind. My colleague pointed out to me and I am like "Oh No!! How did I missed that ??". Anyway.

The solution here is given by following the two steps below.

1) After changing the settings (using sed command) kill the PCManFM process.

killall pcmanfm

2) Restart the PCManFM process.

pcmanfm --desktop --profile lubuntu --display :0 &

Donot forget to restart it as background process (see the & in the above commnad).


nvidia control panel reporting 60hz on 144hz monitor. how to make ubuntu output 144hz?

Found an easy fix

xrandr --output DVI-D-0 --mode 1920x1080 --rate 144


how to unninstall ubuntu but bootmgr is missing and i want to install win xp

Run the Windows XP install on you usb stick, after Windows loads, go into My computer. There should be a disk that stands as your partition. Delete that and you should be good. Thats how I've done it in the past.


Fn+F5/6 Brightness shortcut not working - Asus laptop - Ubuntu 14.04

OP's answer removed from the question and edited slightly:

  I found the solution on this webpage (in
  French).

  It tells us to

sudo -H gedit /etc/default/grub

  then find this line

GRUB_CMDLINE_LINUX_DEFAULT="quiet splash"

  and add a parameters acpi_osi= and acpi_backlight=intel, so the
  edited line reads:

GRUB_CMDLINE_LINUX_DEFAULT="quiet splash acpi_osi= acpi_backlight=intel"

  save the file, and then to make changes effective, run

sudo update-grub

  finally you turn off / restart your monster and it should work!!*

  I should mention that I still have the
  /usr/share/X11/xorg.conf.d/20-intel.conf file as described in the
  first article I
  linked to in my question.**

* CW post author's note: You may want to try the boot parameters individually first, rather than together. acpi_backlight=intel should be tried alone first as it has less wide-ranging effects. Don't forget to run sudo update-grub after each change made to /etc/default/grub and then reboot to see if it has been effective.

** CW post author's note 2: my own experience (and the fact that it didn't work for OP earlier) strongly indicates that this file did not do anything good. If you are following this answer, I recommend you do not try to create this file in combination with the edit to /etc/default/grub, unless that method did not work, and the 20-intel.conf solution did not work when tried separately.


17.04 can't connect to wifi using TL-WD8200ND v1.1 usb adapter

The correct entry change to /etc/NetworkManager/NetworkManager.conf is:

 [device]
 wifi.scan-rand-mac-address=no

In other words, not =o but =no. Please change the file, proofread carefully, save and close the text editor.

Second, you have two possibly conflicting drivers loaded. Let's blacklist one:

sudo -i
echo "blacklist rtl8192cu"  >>  /etc/modprobe.d/blacklist.conf
exit

Next, I recommend that your regulatory domain be set explicitly. Check yours:

sudo iw reg get

If you get 00, that is a one-size-maybe-fits-all setting. Find yours here: http://en.wikipedia.org/wiki/ISO_3166-1_alpha-2 Then set it temporarily:

sudo iw reg set IS

Of course, substitute your country code if not Iceland. Set it permanently:

gksudo gedit /etc/default/crda

Use nano or kate or leafpad if you don't have the text editor gedit.

Change the last line to read:

REGDOMAIN=IS

Proofread carefully, save and close the text editor.

After making these changes, reboot and let us hear the result.


How do I use REISUB with an Apple slim aluminum keyboard?

This answer also posted here.
After 3 or 4 hrs of hard searching, reading, and trial and error, here's a more thorough and generic answer which should work for any Apple/Mac laptop or keyboard, not just the "Apple slim aluminum keyboard." In my particular case, however, I'm using this solution for a 2008 MacBook white running Xubuntu 16.04 LTS.
Many thanks to Bengt Olsson for his excellent instructions here which gave me the necessary start to figure out the missing details.
This solution is done in the user space, and does NOT require recompiling the kernel like some suggestions.

Download source for keyfuzz, and extract it (I can right-click it and go to "Extract Here" to extract it in my GUI file manager, for instance). To read more about keyfuzz, see here. It is released under the GNU GPL 2.0 or later open source license (yaaay open source!).

Dont' use a directory too deep (or with spaces possibly) or else the ./configure command below will fail.

Install dependencies, or else running ./configure below may spit out some errors:
sudo apt-get update
sudo apt-get install lynx xmltoman gengetopt

Compile and install keyfuzz with the usual commands:
./configure
make
sudo make install

Navigate to /dev/input/by-id and find your Apple keyboard that ends in -event-kbd:
cd /dev/input/by-id
ls

For me it's:

usb-Apple_Computer_Apple_Internal_Keyboard___Trackpad-event-kbd

Add the following line to your /etc/rc.local file, to cause this command to run each time your computer boots up and loads this user. Notice we are using the Apple keyboard entry we just found above. This command uses keyfuzz to map F12 or F13 on your Apple keyboard or laptop to the system "Magic SysRq key", for soft reboots.

To map F12 to SysRq: 458821 99. Many thanks to "pjjjv" for figuring that out here!
To map F13 to SysRq: 458856 99.
Since my MacBook 2008 does not have F13, I am using the F12 option above. Also remember to use your proper keyboard entry we found above. The command I added to rc.local for my case is:
echo "458821 99" | keyfuzz -s -d /dev/input/by-id/usb-Apple_Computer_Apple_Internal_Keyboard___Trackpad-event-kbd

Here is my entire /etc/rc.local file, with the appropriate entry:
#!/bin/sh -e
#
# rc.local
#
# This script is executed at the end of each multiuser runlevel.
# Make sure that the script will "exit 0" on success or any other
# value on error.
#
# In order to enable or disable this script just change the execution
# bits.
#
# By default this script does nothing.

echo "458821 99" | keyfuzz -s -d /dev/input/by-id/usb-Apple_Computer_Apple_Internal_Keyboard___Trackpad-event-kbd

exit 0

Reboot.

Now I can press Alt+F12 (or you can use Alt+F13 as described above) and issue REISUB to soft-reboot your computer. Works perfectly on my MacBook 2008 laptop running Xubuntu 16.04 LTS.
Note that you can see the results returned by issuing REISUB as you press each key by first jumping to an alternate session with Ctrl+Alt+F1 (F1 through F6 work actually) before issuing the command. To get back to your main X Window session use Ctrl+Alt+F7.
If you get a result that says

This sysrq operation is disabled

that's normal for several of the commands, as they pose a potential security risk. The Boot one should still work, however, allowing you to soft-reboot your computer. Here is some more information on this, from mniess here:

Starting with Ubuntu 12.10 a more fine-grained control of which Magic- SysRq features are enabled is possible. Just edit the file /etc/sysctl.d/10-magic-sysrq.conf.

The file is well documented and tells you exactly how to enable which features. The current default was picked for security purposes and should only be changed if you know why you need to (for security implications see bug #194676).


18.04 Server - can't install much of lamp suite through standard repos with apt

Package phpmyadmin is in Universe repository. You may have to enable this first:

sudo add-apt-repository universe
sudo apt update
sudo apt install phpmyadmin mc xrdp


Attempt to read or write outside of disk 'hd0' after trying to install alongside

Take these steps:

Clean file system:-

Boot into recovery mode
Select fsck to clean your file system

Now if you wish to still dual boot.

Insert the install USB and follow the instruction and please select to install along side the current OS.

Source:

Dual booting two Ubuntu versions


Change server mail from postfix to sendmail virtualmin

At first Virtualmin runs perfectly with Postfix. So long you did not setup an external mail server, it is better to keep Postfix with all the other mail services SpamAssasin, Procmail and ClamAV.

To jump over the Read User Mail issue, you have to deactivate it following:

Virtualmin -> System Settings -> Server Template -> Default Template -> Administrators Webmin module and there you can deactivate this feature.

This is only appending for new mail users.

Now Sendmail jumps over this step, but probably you are facing new ones ;-).

Virtualmin is thought to run on every server the mail service. This is very well done together with Postfix. So long you don't have a good reason to change that, I recommend not to switch to Sendmail.

Good luck ;-)
Urs

Ps.
More about Read User Mail and already running mail users:

Solution to deactivate existing mail users


I don't see anything in those listings that would cause such a problem so far as I can see.

However, just to be complete, let me ask: Did you check your mixer settings? Nothing is muted?

Do you have a Live CD handy with which to test the audio? My audio recently flaked out and I spent a bunch of time troubleshooting before I discovered it was a hardware problem (chipset fan died causing overheating; adding a fan fixed all symptoms).

The thing I find most suspicious is that the aplay command apparently worked without error, yet you didn't hear the sound.


Resume/revert changes by interrupted installation

I haven't used any of proposed solutions.

I rebooted and afterwards I ran:
$ sudo dpkg --configure -a

It reverted the interrupted installation and solved the issue.


Tapping on Ubuntu Dock on a touch screen opens two instances of a program

Here is a workaround for Dash-to-Dock...

Save the following patch as ~/Downloads/appIcons.js.patch

@@ -357,6 +367,9 @@ var MyAppIcon = new Lang.Class({
         let modifiers = event ? event.get_state() : 0;
         let focusedApp = tracker.focus_app;

+        if (event.type() == Clutter.EventType.TOUCH_END && event.is_pointer_emulated())
+            return;
+
         // Only consider SHIFT and CONTROL as modifiers (exclude SUPER, CAPS-LOCK, etc.)
         modifiers = modifiers & (Clutter.ModifierType.SHIFT_MASK | Clutter.ModifierType.CONTROL_MASK);

Apply the patch

cd /usr/share/gnome-shell/extensions/dash-to-dock@micxgx.gmail.com
sudo cp appIcons.js appIcons.js.original
sudo patch appIcons.js ~/Downloads/appIcons.js.patch

If Dash-to-Dock is installed locally, replace /usr/share/gnome-shell above with ~/.local/share/gnome-shell.
Verify the patch

diff appIcons.js appIcons.js.original

Reference: https://github.com/micheleg/dash-to-dock/issues/128#issuecomment-432913072


According to https://help.ubuntu.com/community/Printers, there is list of compatible printers.


I found out the reason why this didn't work, i erased the EFI partition, and i was trying to boot in UEFI mode, and (don't know why) even without UEFI boot, it woldn't boot, so i created an EFI partition, and now i can boot to ubuntu :P

before this, i tried to do something (which went wrong):
I had a backup.tgz, and extracted it to my disk, and some files could be overwritten, others couldn't (like hard links), and now, i'm stuck in a login loop -_-

trying to find a solution to this one, i'm a guy who only invents problems :P

another thing i found out:

after disabling UEFI in bios menu, my boot screen is messed up like the image i posted, and if it was enabled it only showed a purple screen (like ubuntu boot screen without the booting options).

it still doesn't show any option at boot screen, but now it's booting, so i changed the timeout for bootscreen and it boots fast ... i updated grub, it said it found my partitions with ubuntu, and memtest, etc, bit still doesn't show up on boot screen ...

the more you mess the more you know :P

Thank you all :)


Procedure to run ubuntu on sony xperia play

Please follow this link and try it once

http://forum.xda-developers.com/showthread.php?t=1872752


Find files with capital letters before the extension and lowercase letters in the extension

Use find to search for files:

find . -regex ".*/[A-Z0-9]+\.[a-z]+"

This performs the search in the current directory (.), recursively going through subdirectories as well.

[.*/] covers the file path
[A-Z0-9] stands for every letter from A to Z (including e.g. Å as mentioned by @vidarlo) and every digit from 0 to 9
+ matches the preceding character or expression one or multiple times
\. is a literal dot
[a-z] stands for every letter from a to z

For some special characters it might be necessary to use e.g. [[:upper:]] instead:

find . -regextype egrep -regex ".*/[[:upper:][:digit:]]+\.[[:lower:]]+"

Edited question

To combine find's tests there's -a and -o, for your example this could help:

find /mnt/ \( -name "*[a-z]*.*" -o -name "*.*[A-Z]*" \) -exec echo {} +


Because 13.04 is so new, a lot of the PPA's haven't been updated with the file structure that 13.04 expects. However, most of the software will still work if you pull from quantal sources instead.

Add the ppa sudo apt-add-repository ppa:yourppa/blah as usual (You're only doing this to get the gpg key really)
Open software centre.
Menu > Edit > Software Sources...
Go to the "Other Sources" tab in the dialog that opens
Uncheck the source that you are trying to install from but note it's location
Close the dialog, and open a terminal
In a terminal sudo nano /etc/apt/sources.list

Add a line that pulls from the quantal version of the repository:

deb http://ppa.launchpad.net/yourppa/blah quantal main

Now sudo apt-get update and try installing your software again.

This is only a temporary fix because eventually (hopefully) the ppa will be updated to include raring releases. So at some point you may want to check the ppa to see if raring has been updated and remove the line from sources.list and recheck the ppa source in the software sources tab.


How to prompt the execution of a custom script after a task has been completed

Here is a lazy man's script to get the job done (considering only one instance of process is running):

#!/bin/bash
while [ -h /proc/"$(pgrep apt-get)"/exe ]; do
    sleep 10
done
echo "DONE"

Replace echo "DONE" with what you want to do next. You can run it as a cron job.

Every process has a directory in /proc assigned with their PID, the full path to executable is symlinked as exe inside that directory. Here we are checking if that file exists and is a symlink.

We could use [ -d /proc/PID ] but that would give us wrong result as when the value of PID is null it will become [ -d /proc ] which always exists, so the script will run indefinitely.


When you install Ubuntu 16.04, and fully upgrade it - it'll become 16.04.6 (the current release). So the end result is almost identical (when compared with a 16.04.3 install fully-upgraded).

However a new 16.04 LTS install comes with the generic 4.4 kernel, where as new installs with releases after 16.04.2 have the HWE kernel enabled by default (4.10 is EOL and you'll find yourself upgraded to 4.15) is useful for later hardware, but in theory is less stable (has had less testing in production).

Excluding kernel, they'll both upgrade to 16.04.6 or result in the same packages installed.  You can also opt to enable HWE if you install with 16.04, then they will be identical.

See https://wiki.ubuntu.com/Kernel/LTSEnablementStack for information about HWE kernels


Wifi not working on ASUS rog zephyrus g14 2021

I have exactly the same problem im Asus TUF Gaming. I have too MediaTec 7961. I have installed windows and then everything was working. But when i came back to Pop OS ( Ubuntu ) internet works only via wired connection. Bluetooth does not work too. Really please for help


Can I re-enable Secure Boot, Fast Start-up, or Bitlocker on Win10 on Dual boot (Grub default) Ubuntu18.4 system?

Secure Boot

Ubuntu installs differently when secure boot is disabled.

When Ubuntu is installed in the UEFI mode with secure boot disabled, it installs \EFI\ubuntu\grubx64.efi.

When Ubuntu is installed in the UEFI mode with secure boot enabled, it installs \EFI\ubuntu\shimx64.efi.

If you enable secure boot after installing Ubuntu, the Ubuntu will not not boot if the shimx64.efi does not exist.

The difference between shimx64.efi and grubx64.efi is that shimx64 is the actual Microsoft signed binary that works with Secure Boot enabled while grubx64 is the normal grub binary (Not signed).

Some third party device drivers can only be installed when secure boot is disabled.

The third party device drivers may not load and thus, some specific devices will not work.

See Is re-enabling Secure Boot in UEFI secure? for more.

Fast Start-up

Fast Start-Up or fast-boot can mean two things.

I assume this is the option in Windows 10.

This is not the UEFI option that skips the boot setup and boot device select menu when the computer boots.

Fast Start-up does not shut down Windows properly, and puts it in a hibernate state when Windows is shut down. This means all the partitions that are accessible by Windows (C:\, D:\, etc) are not properly shut down. Ubuntu will not be able access these drives properly in this state. In particular, you will not be able write files, including copy, move, etc., to these partitions when you use Ubuntu. This will be an issue if you have a common partition that you share between Windows and Ubuntu.

See Unable to mount Windows (NTFS) filesystem due to hibernation this answer for more explanation.

Bitlocker

Enabling Bitlocker in Windows will also make the Windows partition inaccessible from Ubuntu.

There may be ways to get around it. See Use (Windows) BitLocker-encrypted drive on Ubuntu 14.04 LTS

Disclaimer: I have not tried any of these things. So, there may be other consequences of enabling Secure Boot, Fast Start-up, and Bitlocker I am unaware of. Use at your own risk.


You can connect to the Windows XP virtual machine via telnet:

Set up the telnet server on Windows XP:

Inside the command prompt of the Windows XP machine run these commands found from here http://seriss.com/rush.102.42/misc/windows-telnet.html

sc config TlntSvr start= auto
sc start TlntSvr
tlntadmn config sec=-NTLM
tlntadmn config mode=stream

Get the IP address by running:
    ipconfig

and note the ip address of the machine in the format www.xxx.yyy.zzz.

On your Ubuntu machine open up a terminal and type:

telnet www.xxx.yyy.zzz 23

where www.xxx.yyy.zzz is the ip address of your Windows XP machine you noted in step 2. and you will connect to the Windows XP telnet server which will open a CMD.EXEfor you!


Screen goes blank/corrupted/garbled when pressed brightness buttons on dell inspiron 14r in 13.04

Having the same issue on Dell Studio 1558 with AMD Radeon 5470. Hitting brightness keys causes the screen to go black (with open source driver) or fill with random colour pattern (fglrx).


Follow these steps to achieve that:

Please install dconf-editor:

sudo apt install dconf-editor

Launch it and go to org --> gnome --> desktop --> wm -->preferences --> button-layout
Add this configuration to the text box at the bottom:

menu:maximize,minimize,close

Please the image below to help you:

PLEASE MAKE SURE ALL YOU SEE IN MINE IS HOW YOURS IS. Close and you should be good.


Installing Ubuntu 10.04 to external HDD overwrites the MBR of the internal HDD

You have installed Ubuntu on the external hard drive but probably you have installed it's bootloader (GRUB) to the internal hard drive. As I have found out this is a bug in the installer of Ubuntu 10.04.

To verify, the error message you are shown will look like this upon boot without the external hard drive:

The Background

If I recall correctly GRUB and GRUB2 consist of two stages:

The initial code of the bootloader in Master Boot Record (MBR)
The bootloader in the Volume Boot Record

In this case we have the first stage of GRUB in the MBR of the internal drive, but the second stage on the partition where Ubuntu is installed. If we remove the Ubuntu drive, we get the above error message.

1. Fixing the Ubuntu bootloader

Boot Ubuntu, open the System Monitor and look for the entry of the root directory ( / ) under File Systems, note down the Device. The device ID follows this naming scheme:

/dev/sd[a_letter_from_a_to_z][partitionnumber]

We don't need the partitionnumber, so your device ID should look like this: /dev/sdb. Great, now we know on which hard drive in Linux terms Ubuntu is installed and we can install it's bootloader there. Now, open a terminal and type the following commands:

sudo grub-install [your_device]
sudo update-grub

Needless to say [your_device] has to be replaced with your device, in this example /dev/sdb.

2. Fixing the Windows 7 bootloader without a Windows install disk

Since you can boot Windows and most people don't have a Windows install disk at hand, we
download and install EasyBCD. Click the link named Download free for limited, non-commercial use and just press the download button. Don't be scared, there is no registration and no purchase required to use this tool. I recommend disconnecting the External drive at this point. Start EasyBCD and under BCD Deployment select Install the Windows Vista/7 bootloader to the MBR and press the button write to MBR. You're done!

2.1. Fixing the Windows 7 bootloader with the Windows install disk

To be sure: Disconnect the external drive! Now, boot the Windows 7 install disk and follow this How-To: http://www.howtogeek.com/howto/32523/how-to-manually-repair-windows-7-boot-loader-problems/


Ubuntu 14 home/personal use version of Windows Update or apt-get "Must Dos" for Security

A couple of places to start would be to look at The Big Ol' Ubuntu Security Resource
, which seems to be fairly current, and BasicSecurity, which is perhaps a bit more dated.

There are a lot of ideas about security both on this site ad on the web in general, but your question is really broad.


Changing a bash script to on all files together

Before I go any further, I have to mention: use https://www.shellcheck.net/ - it will make debugging shell scripts much easier, and that's one of the tools I've used to answer your question. Now onto the actual problem.

If you look at the error output, you've missed a double quote here:

"Ref"'\t'dCount"'

For exactly the same reason - large amount of quotes and portability of printf - I'd suggest using printf command instead:

printf "Chrom\tPosition\tRef\tAlt\tTumorReadCount\tTumorVariantAlleleCount\tTumorReferenceAlleleCount\tNormalReadCount\tNormalVariantAlleleCount\tNormalReferenceAlleleCount\tVAF\n"

Among other things, please double quote the shell variables. If variable contain spaces, something known as word splitting will occur and produce unintended results, thus breaking your script. There are other security concerns as well.

Another thing - use simple assignments and curly braces when appending text to variables:

outname="${1}.parsed.txt"

The reason for curly braces is this: without them it may be ambiguous to the shell where variable name ends and where plain text begins. Of course your original form with quoted .parsed.txt is fine, too, but curly braces are typically better and clearer.

There's other issues with the code, but I'll leave them to you to review via shellcheck.

Please note: I am not affiliated with shellcheck.net - I merely recommend a good tool that is used by me and other Linux users and does a good job for debugging scripts


How to copy and paste files with CLI and have a status

I'd suggesting using rsync instead:

rsync -aP /source/* /dest/

It's the P argument here doing most of the magic. It should show you an accurate enough progress report for each file.


When on the login screen you can click the keyboard layout indicator (one of the icons at the top right). Hopefully it gives you the opportunity to switch to the desired layout.


Clean up a Fresh Install of Ubuntu 15.04

You can use Modem Manager GUI from the Ubuntu software center to manage your 3G dongle.

Also, you can try the Ubuntu minimal CD install detailed here: Minimal Install


Ubuntu 12.04.1 LTS "Checking battery state... [OK]" and login incorrect

Remember that on the command line you have the default keyboard driver, thus some keys may be different from waht you are used to.

Try the name field to look if the characters are how you need them.


Cannot sign into gmail, all other websites are opening

Open a terminal and type:
ping google.com

You should get something like this.

64 bytes from iy-in-f105.1e100.net (209.85.225.105): icmp_req=3 ttl=50 time=34.0 ms`

Do a control C to stop the continuous output
If just sits their with no output

your not hooked to the internet
or Name resolution is not working.

To check the name resolution part ping google's IP address: ping 209.85.225.105

Expected output:

PING 209.85.225.105 (209.85.225.105) 56(84) bytes of data.
64 bytes from 209.85.225.105: icmp_req=1 ttl=50 time=35.1 ms

Do a control C to stop the continuous output.

If it did not work in first step and this does work--DNS problem report back
If it did not work in ether your Linux software is NOT hooked up to the Internet.


Editors generally edit one whole file at a time...

You could copy/cut the line you want, create a new file, then paste the line there & save?
Or you could make a copy of the file, then delete every line except the one you want to save?
Or you could remember a unique bit of the line, then from a terminal run grep "unique bit" filename > newfile


There is a Launchpad-Bug regarding this issue - see here for more details.

A comment there is mentioning that this issue should be fixed in 0.9-1 which is not true at least for me.

I was able to troubleshoot the broken symlink problem by running:

cd /usr/share/games/slingshot/data
sudo ln -sf ../../../../lib/python2.7/dist-packages/pygame/freesansbold.ttf FreeSansBold.ttf


Hmmm the numbers you provide here are way larger than 170-200MB/s. However they are wrong.

In order to bypass the page cache, causing the reads to go directly from the drive into hdparm's buffers (ie "raw" I/O), you need to use the --direct parameter in hdparm. That is:

$ sudo hdparm -Tt --direct /dev/nvme0n1

That way your results will be lower but close the actual disk's performance.


How do I configure a preseed to skip the language support question?

In the future, if you face such an issue and you're not lucky enough to come across an answer that works, just go through the setup manually. On your new system, install the debconf-utils package:

 sudo apt-get install debconf-utils

This gives you access to the debconf-get-selections command. You can use it to generate a preseed configuration:

sudo debconf-get-selections --installer > preseed.cfg

You should note that, as recommended in the Debian Wiki you should not use the preseed.cfg file above as is, rather search for the entries you need (grep -i language preseed.cfg?) and add them to your own preseed file.


How to edit /etc/resolv.conf on Ubuntu 12.04

In Ubuntu 12.04 and later, /etc/resolv.conf is dynamically generated by the resolvconf utility. (Actually, resolvconf generates /run/resolvconf/resolv.conf and /etc/resolv.conf is a symbolic link to that. That's the default configuration; it is also possible to run with a static file at /etc/resolv.conf but that is non-standard.) Nameserver information (nameserver addresses and search domain names) gets registered with resolvconf by interface configurers (ifup, NetworkManager, dhclient, etc.). On the basis of what has been registered, resolvconf generates an up-to-date resolv.conf file.

Therefore, you can't edit the resolv.conf file directly. If you want to control what ends up in resolv.conf you will have to configure the resolvconf utility. Please see the resolvconf documentation for more information.

The answer to the specific question "What if I want 127.0.0.1 and only one of the two nameserver addresses provided via DHCP?" is:

First, do not add prepend domain-name-servers 127.0.0.1 to /etc/dhcp/dhclient.conf.  The correct protocol is for local nameservers to register their local listen address(es) with resolvconf when they are ready to provide local name service; when they do this there is no need for DHCP clients to do so too. Dnsmasq does the right thing by default. In the case of BIND 9, you have to set RESOLVCONF=yes in /etc/default/bind9 to cause it to register the address 127.0.0.1 with resolvconf.
Second, resolvconf by default truncates the list of nameservers after any loopback address such as 127.0.0.1. To disable this behavior, create a file /etc/default/resolvconf containing the line TRUNCATE_NAMESERVER_LIST_AFTER_LOOPBACK_ADDRESS=no.
Third, resolvconf by default truncates the list of nameservers after three items. There is no point in including more addresses because the glibc resolver ignores any addresses after the first three. To cause resolvconf to truncate the list after two addresses you have to edit the script /etc/resolvconf/update.d/libc to replace this line

[ "$N" = 3 ] && return 0

by the following one.

    [ "$N" = 2 ] && return 0


I have the same issue and, so far, the only workaround I have found, is to update some song's properties and load again the files to U1.
Another way is to delete and upload the songs with the Web interface of U1.

Of course these are not valid solutions because:
1) with the web interface you can upload only a file at a time (impossible job with hundreds of them)
2) changing some song's properties and load again the files don't mean you will succeed. Sometimes it works, sometimes not.

I definitely believe that this is a bug that must be resolved.


When I upgraded to 12.04 I found that there were problems running rdesktop, especially as I was trying to use shared clipboard via RDP, so I tried the current remote desktop package called remmina and have found it to be excellent. The main problem with this option is that it doesn't import all your previously saved rdesktop connections, but they are human-readable if you open the hidden .rdesktop folder in your profile folder.

As for rdesktop working from a command line, did you fresh install U12 or was it an upgrade from 11.10? If new, you must have installed rdesktop manually, in which case the dash ought to work, or if you copied it as an executable then the system won't put it in the dash. Run the Synaptic Package Manager (if a new installation of U12 you need to install it: sudo apt-get install synaptic). If installed properly, rdesktop will have a green box next to it.

Remmina has the added advantage of sharing a local folder via RDP which shows up on the remote MS Windows machine as an extra drive. It's a good way to transfer files to and from the remote machine. Remmina also allows you to easily scale the remote desktop window, even in VNC. This helps me to manage customers' computers from my tiny netbook.


Create a username and password in RStudio Server

Every user in the linux system can login in the rstudio IDE, unless you limit it, for example to certain groups:

# /etc/rstudio/rserver.conf

auth-required-user-group=analysts,admins,rstudio-users

You can check more details at RStudio user documentation


virtual box kernel not found (ubuntu 16.04, vbox 5.02)

Use VirtualBox in secure boot (UEFI)

Using self compiled kernel modules in a secure boot environment is possible. All modules have do be signed and the keys have to be registered in the secure boot BIOS (or boot loader)

Create signing certificate and key

Create a certificate and private key for signing the kernel modules (required package sudo apt-get install openssl).

## Create a signing key and certificate##
## Signing certificate and keys
sign_key=signing_key.priv
sign_crt=signing_key.x509

## Subject for certificate
sign_sub=""
sign_sub+="/O=Your Name"
sign_sub+="/CN=Module Signing Key"
sign_sub+="/emailAddress=Your.Name@somewhere.com"
sign_sub+="/"

## Create certificate and keys
if [[ ! -f "$sign_key" ]] && [[ ! -f "$sign_crt" ]]; then
    openssl req -new -x509 -newkey rsa:2048 -keyout "$sign_key" \
        -outform DER -out "$sign_crt" -nodes -days 365 -subj "$sign_sub"
fi
## Print certificate
openssl x509 -in "$sign_crt" -inform DER -noout -text

Build Linux kernel signing tool

Inside the Linux kernel headers under /usr/src/ is the signing tool for the kernel modules (required packages sudo apt-get install build-essential libssl-dev).

## Build signing tool
gcc "/usr/src/linux-headers-$(uname -r)/scripts/sign-file.c" -L \
   /usr/include/openssl/ -lcrypto -lssl -o sign-file

Signing VirtualBox modules

With the signing tool all VirtualBox modules need to be signed.

## Sign virtualbox modules
vbox_mod=()
vbox_mod+=(vboxdrv)
vbox_mod+=(vboxnetadp)
vbox_mod+=(vboxnetflt)
vbox_mod+=(vboxpci)

for module in "${vbox_mod[@]}"; do
    echo "Signing module $module"
    sudo sign-file sha256 "$sign_key" "$sign_crt" \
        "$(modinfo -n "$module")"
done

Add certificate to secure boot

At last, the certificate needs to be added to the secure boot BIOS (requires package sudo apt-get install mokutil)

## Add key to UEFI keyring
sudo mokutil --import "$sign_crt"

It is recommended to create a script to do that, because with every kernel update, the modules need to be sign again. The certificate and key can be reused, so the UEFI keyring must not be updated all the time.


How to uninstall Ubuntu from Legacy mode?

What you say is wrong, windows 10 can also start in to legacy mode (it depend on the way you install it) I'm sure on this because I had to convert windows 10 mbr partition to GPT to move the boot in UEFI and Ubuntu also support UEFI and legacy boot.

Anyway you could do an installation to run a OS in to legacy at boot and another to UEFI only by the following condition:

Installation reside in different disk (so you can have one with MBR and other with GPT)
your BIOS support feature to boot legacy & UEFI


How do I install the drivers? Or how do I get them to list under "Additional Drivers"?

Your Atheros card does not have a driver installed. From the Hardware ID I got from lspci output, I am assuming that you have an Atheros Bigfoot Killer E2200 Ethernet card and your laptop seems to be the MSI Global GT70 0NC (Nice!) gaming laptop. You need to install the compat-wireless driver. If you have Internet access on the machine, try following the steps mentioned here:

http://ubuntuforums.org/showthread.php?t=2008332

This should help you install the driver and then you can plug your LAN cable into the port.
I don't think that this is a Network-Manager problem.

Hope that helps you! :-)

P.S.: Make sure you use "eth0" and not "etho".


Python 3 is a different package.

Install it using:

sudo apt-get install python3

The run it using:

python3


How do I report a problem with the Ubuntu Guide website?

Apparently, you report it to the project itself by contacting its maintainers directly.

For example:

http://ubuntuguide.org/wiki/User:Perspectoff#Contact

...and

http://ubuntuguide.org/wiki/User:Krampo

It looks like ubuntuguide.org is an independent project, created and maintained by a few volunteers. Although it's a collaborative wiki, I don't think everyone can or is meant to register (not sure why they have the button).