Can I get my laptop fn-keys to work in Ubuntu?

I belive it is important to know what keys are you having trouble with...
I had a problem adjusting brightness on my acer aspire one and it was solved modifying grub... What problems do you have?

Also, this appears similar to your problem and it is answered already...
samsung new series 9, not all function keys working


Cannot switch to radeon graphics card on HP Pavilion g7 1019eg on Ubuntu 18.04

Can't comment yet, so i'll write here:

use DRI_PRIME=1 *command* if you want to run some apps with Radeon GPU.

But if you seeking permanent switch, i don't know and i'd like know too.


Broken packages, synaptic and Libre Office broken, when upgrading to 12.04

Have you already tried-

sudo apt-get -f install

Run this code in terminal, it is used to fix broken packages. What exactly does sudo apt-get -f install do?


You may be victim of a bug in the latest Firefox 86.0, which does not seem to affect too may people, though. According to this support thread, the issue, "bug 1694670", would be solved in 87.b03, but hopefully will also be solved very soon in a dot release of 86.0.
For now, the only solution may be to downgrade to the previous version of Firefox until an update fixes the issue for you.


Antivirus for Ubuntu 18.04 with real-time protection

There are few antivirus software for Ubuntu but they are old such as clamav and comodo but you can check out Sophos.


Meizu Pro 5 Ubuntu edition - temperature units

The unit of temperature in the weather scope and the weather part in the today scope is related to the language setting of your phone (System Settings - Personal: Language & Text - Display language).

There is only one issue, and this has been reported as a bug already (as pomsky pointed out in his comment), for which however a work-around is available:
Up until OTA-8, choosing English-Canada gave us the chance to have the phone set to English and still showing temperatures in Celsius. Since OTA-9 this is not working anymore.

Work-around, if you want your phone to be set to English using Celsius as unit for temperature: Switch your language to English-Australia.


Which Ubuntu distribution should I install on my PC

Version 14.04 is the newest stable version of ubuntu and is probably the best stable version out right now.

If you have more than 2GB of ram, go with the "amd64" (even though you have intel this is for all 64 bit systems) version. If less than 2GB of ram, you are probably better off with version i386 instead.

As far as flavors go, the installation media will allow you to "try ubuntu without installing" and all you have to do is choose this option before you start. You should try each of these flavors out to see which one works best on your setup and which one you like to use the best.

http://releases.ubuntu.com/14.04/

Other flavors:

ubuntustudio

Gnome Shell

Xubuntu

Kubuntu

Lubuntu

Ubuntustudio, Xubuntu, and Lubuntu all run really well on new or older machines and are optimised for performance with little required resources. Gnome Shell Ubuntu standard (Unity) and Kubuntu use more resources but provide a more interactive desktop and user experience.


Transfer files between two remote SSH servers

If you are on an Ubuntu version that is still supported, then
your scp command will provide the -3 switch which enables
copying files from remote1 to remote2 via localhost:

me@local:~> scp -3 user1@remote1:/path/to/file1 user2@remote2:/path/to/file2

You can also omit the -3 switch, but then you will need the
public key (id_rsa.pub) of user1@remote1 in the
file authorized_keys of user2@remote2:

me@local:~> scp user1@remote1:/path/to/file1 user2@remote2:/path/to/file2

scp then under the hood does a ssh user1@remote1 first and from there
scp /path/to/file1 user2@remote2:/path/to/file2. That's why the credential must be
distributed different from the -3 solution.

In other words:

scp -3 remote1:file1 remote2:file2 transfers the file from
remote1 to localhost and then back to remote2.
The data travels remote1 → localhost → remote2.
The localhost is the 3rd party in this scenario, hence -3.
For this to work, you will need the credentials from localhost
on both remote1 and remote2 because localhost connects
to both of them.
scp remote1:file1 remote2:file2 copies the file directly from
remote1 to remote2 at the speed with wich they are connected
to each other. localhost is not involved here (besides issuing
the command).
The data travels remote1 → remote2.
For this to work, you will need the credentials from localhost
only on remote1 but additionally you need the credentials
of remote1 on remote2 because localhost connects to remote1
only and then remote1 connects to remote2.

If possible I would choose the second approach. As some comments already
say: usually often the network cable between remote1 and remote2 is
far thicker than the cable between them and localhost.


what does a STAT of I mean for ps -aux? "I" does not appear on the man page

It does appear in the man page:

PROCESS STATE CODES
       Here are the different values that the s, stat and state output specifiers
       (header "STAT" or "S") will display to describe the state of a process:

           D    uninterruptible sleep (usually IO)
           I    Idle kernel thread
           R    running or runnable (on run queue)
           S    interruptible sleep (waiting for an event to complete)
           T    stopped by job control signal
           t    stopped by debugger during the tracing
           W    paging (not valid since the 2.6.xx kernel)
           X    dead (should never be seen)
           Z    defunct ("zombie") process, terminated but not reaped by its parent

       For BSD formats and when the stat keyword is used, additional characters
       may be displayed:

           <    high-priority (not nice to other users)
           N    low-priority (nice to other users)
           L    has pages locked into memory (for real-time and custom IO)
           s    is a session leader
           l    is multi-threaded (using CLONE_THREAD, like NPTL pthreads do)
           +    is in the foreground process group


Can I configure one monitor landscape and one in picture mode at the same time?

Yes, I'm using 11.04 with nVidia open drivers. I've got external monitor working out-of-the-box without any problems at all. Different resolution, extended desktop. Instead of using directly xrandr I'm using disper.


How do I change the theme and window border color?

You said,

  Is it possible to customise the colours for the desktop theme and window appearance in Pangolin 12.04 as it was possible in Narwhal?

I assume, you are referring to the customization window in the theme in Natty Narwhal and previous distributions. Since, Gnome 3 is released, those easy customization options are removed default.

But, the good news is, the corresponding keys in gconf and hence dconf is available still now. So, you can change those keys using dconf-editor (dconf-editor or gsettings should be used instead of gconf, since settings are migrating to dconf).

I've tested in Narwhal and found the corresponding keys, the path is  /org/gnome/desktop/interface and

the keys are as follows:

bg_color - It refers to the window color. This corresponds to left color selection in Windows row  i.e 1st row in Narwhal.
fg_color - This controls the text colors in windows, menus, title bars etc. This is the right side color selection in Windows row (It does not change the text color in input boxes, nautilus folder pane etc, text in editors etc).
base_color - This controls the background colors in input boxes, nautilus folder pane, editor's background, search bar, address bar in browsers etc. Corresponds to the left color selection in Input boxes row in Narwhal.
text_color - This controls the text colors (foreground colors) in the above settings, such as input boxes, nautilus folder pane, editor's text, search bar, address bar's text etc. Corresponds to the right color selection box in Input boxes row in Narwhal.
selected_bg_color - This controls the background color i,e the color of any selections, when you select with your mouse etc. Corresponds to the Selected Items row's left-most settings in Narwhal.
selected_fg_color - This controls the text colors withing selection. Corresponds to the Selected Items row's right settings.
tooltip_bg_color - This I think self-explanatory. It controls the background colors of a tooltip. Corresponds to the  Tooltips row's first settings.
tooltip_fg_color - This controls the tool tip text color. Corresponds to the right settings in Tooltips row in Narwhal

How to set those colors:

You can easily set those colors in dconf-editor. Install it via  terminal with the command:

sudo apt-get install dconf-tools

or via Software Center

Now, Open dconf-editor by typing the name in dash. To do so, Press Super and type dconf-editor and Click on the icon.

Go to the path org -> gnome -> desktop -> interface and select gtk-color-scheme and input value there. Don't forget to put a ; after each key-value pair. For example, If you want to change the window color(bg_color) and window text color(fg_color) with some values, the line should be like this:

bg_color:#2f568f;fg_color:#000000;

Generate color value:

To generate color value, you can use the Appearance Window in System Settings. To bring it. Right Click on Desktop -> Choose Change Desktop Background and in the Window, click the little color box below the big Monitor image. There you can see a custom color box. click there.

Alternatively, you can use agave color generator. It is a very convenient and tiny tool to generate color value. Install it with terminal using the commmand:

sudo apt-get install agave

or using Software center

Type agave in the dash to open it after pressing Super

Changing window border color:

Changing window border's color of default Ambiance and Radiance themes aren't supported. Because, those themes use images as window borders. If you really want to have the ability to change the window border, I suggest you to use old colorable window borders such as Crux, Esco, Human etc.

Some are included in the default Ubuntu installation. You can use those by using Ubuntu-tweak.

How do I install Ubuntu-Tweak?

After installation, open it by Pressing Super and typing "Ubuntu tweak" in the dash. Then go to Tweaks -> Themes and then change Window Theme.


I changed my .xinitrc file and can't log into Ubuntu, how to fix it?

Go to tty1 using Ctrl+Alt+F1 keyboard shortcut, login with your username and password and delete the file:

rm ~/.xinitrc

Finally, restart lightdm:

sudo service lightdm restart

or

sudo service lightdm force-reload


Is there a way to start a bash script after boot only when wlan0 is connected

In Ubuntu you can use upstart for this. Save the following as /etc/init/yourscript.conf

start on net-device-up wlan0

exec  your_script


How to fix missing libwayland-egl.so.1 and libuser-accounts.so in ubuntu 14.04.3 LTS?

I had a same problem with Cinnamon 2.8.6 on Ubuntu 14.04.4 LTS I managed to fix it by running:

sudo apt-get install libwayland-egl1-mesa-lts-trusty

Hope that helps.


Ubuntu 12.04 Startup Disk Creator will not write 16.04 LTS iso image

Startup-Disk-Creator works best when running on the same version as the ISO being used.  It does not even successfully create a bootable ISO for Ubuntu 16.04 when run on a 14.04 system, so failure on 12.04 is no surprise.  The bugs on this behavior are years old, do add yourself to the "does this affect me" lists.  As you have discovered, dd is the common workaround, and with perfect media, it works fine.

The problems Startup Disk Creator has result from using some files from a running system instead of just files from the ISO.  These files can be the wrong version, and can fail.  Another issue the the apparent reliance upon filesystem links, which are in the ISO's iso9660 filesystem, but cannot be used on a FAT filesystem.  Just copying the files from the ISO (loop mounted) to the USB (FAT filesystem) misses the "ubuntu" link, and results in a kernel argument reference to "/cdrom/preseed/..." which does not exist.  Removing that reference in the grub.cfg will result in a UEFI bootable USB.

The newer mkusb media creator does the dd copy, with more safety features to ensure you select the correct target.


I can not connect to the Internet with cable

This could be many things, like for example your cable doesn't work.
If it does what does /etc/network/interfaces say? how about running ifconfig, if you dont see a eth0 somewhere in the previous you can try

sudo -s
echo "auto eth0" >> /etc/network/interfaces
echo "iface eth0 inet dhcp" >> /etc/network/interfaces
ifup eth0

if you did get something from those, maybe you just dont have a IP, you can try running dhclient and test your connection.

Another possible scenario is that you dont have drivers for your network card (probably not the case) but just in case what do you get by running lspci -k


How can I select an ISO file to use with Cubic?

The mini.iso doesn't have filesystem.squashfs on it. filesystem.squashfsis actually a compressed version of the OS that will be installed, and this is what Cubic allows you to modify. The mini.iso doesn't have this (which is why it is so small), and it downloads required files during the install process. So you would not use Cubic to modify mini.iso.


Can I Recover The Files in the Directory /usr from a btrfs Snapshot?

Thanks to Btrfs and the good snapshots (at least it looks good to me, CoW snapshot of the whole /)

You need to mount the snapshot (it works just like a subvolume) and they copy the files over properly (using rysnc)

Steps (I recommend doing this from a Live DVD/USB system):

mount the snapshot to a temporary mount point, for example /mnt/snapshot

mount -t btrfs -o subvol=apt-snapshot-xxx block_device /mnt/snapshot

then you'll be able to access the contents, old /usr should be under /mnt/snapshot/usr
mount your /usr to a temporary location, for example /mnt/usr
Copy the contents over (be careful with the trailing / of source) from snapshot to your current /usr

sudo rsync -axHAX --progress /mnt/snapshot/usr/ /mnt/usr

Reboot and it should be good.


This seems to be a bug. Maybe you can boot from the Livecd, and try to reinstall GRUB.

Use live cd and choose to install Ubuntu.
Don't Format partitions
already created.
Chose mount point for each partition, and then select continue. The
grub installer will be reinstalled correctly.

Or Try to Commit: _GRUB_HIDDEN_TIMEOUT_ and _GRUB_HIDDEN_TIMEOUT_QUIET_ in /etc/default/grub will help on this: Then try to run 'sudo update-grub' after changes to /etc/default/grub.

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


How can I replace Google Chrome's low resolution notification icon?

Edit: see below for update on replacing notification icon

If you're chrome binaries are installed in the typical location, you'll find them in /opt/google/chrome.  In that folder you should find the file chrome_100_percent.pak which contains the notification icon.  Here's the steps I used to extract it, using information from this stack overflow question:

Checkout the code to the grit-i18n project with

svn checkout http://grit-i18n.googlecode.com/svn/trunk/ grit-i18n-read-only
This will give you a folder in your CWD called grit-i18n-read-only.  CD into this folder

cd grit-i18n-read-only
Copy the data_pack python module to this folder

cp grit/format/data_pack.py .
Edit data_pack.py in your preferred editor.  After the initial imports, add the following line:

sys.path.append(os.getcwd())
Towards the end of the file in the main function, remove the line

print '%s: %s' % (resource_id, text)

(the Stack Overflow answer states this occurs at line 160, in my experience the current version has it at line 201)
In its place, insert the following lines indented appropriately (3 times):

file = open(str(resource_id), "wb")

file.write(text)
Run the data_pack.py utility on the chrome pak file (I copied it to the grit-i18n-read-only folder first):

./data_pack.py ../chrome_100_percent.pak

This will result in a lot of new files in the current directory, all named as numbers with no extension.  Your file browser (e.g. nautilus) should be able to determine the file types and show image thumbnails.  I found the notification icons named as 6866 & 6867.

Edit

While there are some simpler answers below, I managed to hack together some code to re-package the resources which you could attempt after editing the icons.  This would produce a new .pak file, which I haven't attempted to use myself, so I can't say for certain this would successfully result in new notification icons.

In the main function in data_pack.py, I commented out all the code in the else block and added the following lines:

# Read in the modified icon resource files
file = open('6864', 'r')
icon1 = file.read()
file.close()
file = open('6865', 'r')
icon2 = file.read()
file.close()
file = open('6866', 'r')
icon3 = file.read()
file.close()
file = open('6867', 'r')
icon4 = file.read()
file.close()

# Write resource pak of only notification icons
iconData = {6864: icon1, 6865: icon2, 6866: icon3, 6867: icon4}
WriteDataPack(iconData, 'tmp.pak', BINARY)

# Create copy of original pak without notification icons
dataPack = ReadDataPack('chrome_100_percent.pak')
# List of icon resources to remove
toRemove = set([6864,6865,6866,6867])
whiteList = set(dataPack.resources.keys()).difference(toRemove)
whiteListFile = open('whitelist.txt', 'w')
for i in whiteList:
  whiteListFile.write(str(i)+'\n')
whiteListFile.close()
newDataPack = RePack('tmp2.pak', ['chrome_100_percent.pak'], 'whitelist.txt')

# Merge the two paks together
combinedPack = RePack('chrome_100_percent_new.pak', ['tmp2.pak', 'tmp.pak'], None)

Then, just run ./data_pack.py.  This assumes chrome_100_percent.pak is in the current directory, and should give you a new chrome_100_percent_new.pak file which you could attempt copying over /opt/google/chrome/chrome_100_percent.pak.

I believe some additional icons in the resource pak related to the notification icon have been identified; editing the above to include those should be pretty straightforward.

Final Edit

Now that I'm back home and had the chance to work on this some more, I managed to successfully replace chrome's notification icon.  As @Glutanimate noted, you're stuck with 16x16 resolution, so I'm not sure how much improvement you can actually achieve, but I suppose that's subjective.

I simply opened the aforementioned icons (6864 - 6867) in GIMP, which detected them as Grayscale PNGs.  I pasted a new icon into the same file in GIMP, thus attempting to keep the same image properties (e.g. grayscale).  I then exported these as PNGs, unchecking ALL of the options that GIMP offers but maintaining a compression level of 9.  The resulting files had .png extensions, so I removed those and replaced the originals.  I then re-ran data_pack.py, having already made the modifications detailed above.

I kept a backup copy of the original pak with mv /opt/google/chrome/chrome_100_percent.pak /opt/google/chrome/chrome_100_percent.bak and moved my modified .pak file in its place.  I would make sure chrome is closed when doing this, and double-check that there are no chrome processes running, and I believe chrome has a new setting to allow background processes even when the browser is closed by default now.

Lo and behold, my notification icons in Unity reflect my changes.

Finally-Final Edit: OK, I lied - I attempted a 32x32 PNG and it seems to have worked just fine.  So, there you go.  Here some result screenshots.

Original Icon: You'll probably recognize the default 'no unread notifications' icon in my panel here between my dropbox and weather icons:

New Icon: My 32x32px modified version in the same location:

(Source: Batch icons from Adam Whitcroft)


About the installation of Moses tool on ubuntu 11.04

Try running

make NO_TCL=X MACHINE_TYPE=i686 World

instead. When there are spaces around the =, make tries to parse the ‘empty string’ before it as a variable name, causing the “empty variable name” error message that you saw.


Program works in Ubuntu 17.04 and 17.10 but not in Ubuntu 18.04

Three options here:

Get newer version from new BitBucket repository:

cd ~/Downloads
wget https://bitbucket.org/wahibre/mtn/downloads/mtn_3.3_ubuntu18_amd64.deb
sudo apt-get install ./mtn_3.3_ubuntu18_amd64.deb

It launches normally:

$ mtn
mtn: no input files or directories specified

Movie Thumbnailer (mtn) 3.3
Compiled with: Lavc57.107.100 Lavf57.83.100 Lavu55.78.100 SwS4.8.100 GD:2.2.5
...

Try to get build dependencies with

sudo apt-get install build-essential libavcodec-dev libavformat-dev libswscale-dev libgd-dev

then patch source code to reflect modern changes of the APIs.
Create schroot with previous (but supported) Ubuntu 16.04 LTS version and launch your application here:

First of all get the software:

cd ~/Downloads
wget https://datapacket.dl.sourceforge.net/project/moviethumbnail/movie%20thumbnailer%20linux%20binary/mtn-200808a-linux/mtn-200808a-linux.tgz
tar -xf mtn-200808a-linux.tgz
cd mtn-200808a-linux/

then setup schroot:

sudo apt-get install schroot debootstrap -y

cat <<EOF | sudo tee /etc/schroot/chroot.d/xenial.conf
[xenial]
description=Ubuntu 16.04
directory=/srv/chroot/xenial
root-users=$USER
type=directory
users=$USER
EOF

sudo mkdir -p /srv/chroot/xenial
sudo debootstrap xenial /srv/chroot/xenial

cat <<EOF | sudo tee /srv/chroot/xenial/etc/apt/sources.list
deb http://archive.ubuntu.com/ubuntu xenial main restricted universe multiverse
deb http://security.ubuntu.com/ubuntu xenial-security main restricted universe multiverse
EOF

(it will end with small 250 Mb /srv/chroot/xenial folder).

then run your application:

user@bionic:~/Downloads/mtn-200808a-linux$ schroot -c xenial
(xenial)user@bionic:~/Downloads/mtn-200808a-linux$ ./mtn
mtn: no input files or directories specified

movie thumbnailer (mtn) 200808a copyright (c) 2007-2008 tuit, et al.
...


How to fix the computer after forced shutdown while running wubi.exe?

You need to basically fix your windows bootloader. You can try from these results, based on your Windows version.

You will need to basically boot into your windows installation CD and run a command bootrec /fixmbr in its command line.


There may be a problem with the .Xauthority file for that account - see Cannot login to my user account


Initial download (pre installation) happening at dial-up speed. Only 2+ hours to go!

It is not at dialup speeds. It is at least 8 times faster. Dial-up is in (kilo)bits per second, but the number you are getting is in (kilo)bytes per second. It will indeed take 3 hours but if your connection is DSL or low-end cable, it is using a good amount of your bandwidth efficiently.

Why is this?

You are getting bits(b) and bytes (B) confused. There are 8 bits in one byte. Therefore, a 1Mbps connection should ideally get 125Kbps, but the speed will be anywhere from 50-100 KBps. On dial-up, it would take over 24 hours.

700MB at ~70KBps
≈700000KB at 70KBps
≈10000Sec
≈3 hours


In my case, the boot loader was installed on my USB.

I fixed it by booting into Linux with the USB and then run grub-install on the drive (/dev/sda in my case) again, which will install and configure grub to the drive.


Python 3 has introduced a number of backwards incompatible changes. That is why your python 3 code does not run without error when using the python command. To answer your question "how do I make sure that I am only using one version of python in ubuntu", you should note that the two python versions live in peaceful cohabitation. They can coexist. In a terminal just use the command python to run your python 2 code and python3 to run your python 3 code.

In response to Rahil's comment on why Ubuntu ships with two python versions:

A lot of software was written for python 2 and is not "ported to" or adapted for python 3 yet. There is also some software in Ubuntu that still needs python 2. In the future this will most likely no longer be the case.
There are quite a number of python third party packages (bits of software that you can reuse in your own software or toolbelt). Not all of these packages have been converted to python 3 either.


500 OOPS: vsftpd: refusing to run with writable root inside chroot()

Run echo "allow_writeable_chroot=YES" >> /etc/vsftpd.conf && service vsftpd restart


You can fix that in Settings - Universal Access - Typing - Repeat Keys - there you can adjust Delay and Speed.


realtime syslog analytics deployment not working

The "juju deploy 'bundle' " syntax is available only for Juju 2.0 for Juju 1.25 deploying a bundle is done using "juju quickstart 'bundle' ". Here is what deploying the bundle using quickstart looks like on my local environment.

#> juju quickstart realtime-syslog-analytics
juju quickstart v2.2.4
contents loaded for bundle realtime-syslog-analytics/bundle (services: 9)
reusing the already bootstrapped local environment
retrieving the environment status
connecting to wss://10.0.3.1:17070/environment/bd6ed64e-1f10-4911-88f4-bc682cc05ab0/api
environment type: local
bootstrap node series: xenial
charm URL: cs:trusty/juju-gui-130
service juju-gui already deployed
reusing unit juju-gui/0
juju-gui/0 is ready on machine 1
unit placed on 10.0.3.165
machine 1 is started
the Juju GUI is ready: retrieving service configuration

Juju GUI URL: https://10.0.3.165
username: admin
password: adm-098d7faa6a744fa1ab86bd23f4e3e852

connecting to the Juju GUI server
requesting a deployment of bundle realtime-syslog-analytics/bundle with the following services:
  flume-hdfs, flume-syslog, namenode, plugin, resourcemanager, rsyslog-forwarder, slave, spark, zeppelin
bundle deployment request accepted
use the GUI to check the bundle deployment progress
more details about this bundle can be found at
  https://jujucharms.com/realtime-syslog-analytics/bundle
opening the browser at
https://10.0.3.165/?authtoken=62249182ecb8485399bbff1e5663a07e
done!

Run "juju quickstart -e local" again if you want
to reopen and log in to the GUI browser later.
Run "juju quickstart -i" if you want to manage
or bootstrap your Juju environments using the
interactive session.
Run "juju destroy-environment local [-y]"
to destroy the environment you just bootstrapped.

Here is a short video tutorial on what quickstart is and how to use it https://www.youtube.com/watch?v=LVknLr1spPo

To deploy a bundle in an existing environment

Supply the environment using the -e <environment-name> flag.

juju-quickstart -e amazon realtime-syslog-analytic

Or use the juju-gui, select the bundle from the Juju GUI and deploy it.


bad wifi connection with Lenovo X240 under Ubuntu 14.04 --- intel wireless 7260

You could try this:

iwconfig wlan0 retry short 21

iwconfig wlan0 retry long 21

If the driver is working well, this should help, if not..

Try reorienting the antenna (turn the laptop 45 degrees or so and see if it makes a difference)


You can change the appearance of virtually all widgets, the ~/.gtkrc-2.0 file overrides the settings of whatever Gtk theme you are using. For this reason, it usually is best to modify the theme directly (They are located in ~/.themes/ and /usr/share/themes/) or else whenever you change your Gtk theme (System -> Preferences -> Appearance -> Themes -> Customize... -> Controls) it will be overridden by ~/.gtkrc-2.0.

For more information on Gtk theming, check out the Gtk Theming Tutorial.


Merging individual files from two folders sequentially (never asked question)

Assuming that by "merge" you mean concatenate the files' contents, you could do something like this:

#!/bin/bash

while IFS= read -r -d '' -u3 file1 && IFS= read -r -d '' -u4 file2; do
  cat "$file1" "$file2" > "${file1##*/}${file2##*/}"
done 3< <(printf '%s\0' "Folder 1"/*) 4< <(printf '%s\0' "Folder 2"/*)

This will create files in the current directory, whose name is the concatenation of the two constituent filenames. It assumes that you want to merge files in the order in which they sort in your locale. The null delimiters make it safe for any legal filenames (which may be overkill for your application).


As Jacob Vlijm said:

It's simply done by using gksu except for sudo:

#!/bin/bash
gksu monodevelop


Depending on the servers settings, idle connections may be dropped.

To prevent this from the client side, use ssh option ServerAliveInterval.

Use this in your ~/.ssh/config

Host xyz
    ServerAliveInterval 120

or using command line option ssh -o ServerAliveInterval=120 ...

Alternatively, you can change the setting from the server side in ssdh_config:

ClientAliveInterval ...


Is not working because you are doing in the wrong way. Try:

find /home/seabass/Documents/hello

respective:

find /home/seabass/Documents/test

Or:

find /home/seabass/Documents -name hello

respective:

find /home/seabass/Documents -name test

See man find and find --help for more informations.


How to restore accidentally removed Launcher icon for external drive in Unity?

1. Command line:
You can do that by the command:
gsettings set com.canonical.Unity.Devices blacklist "[]"

Explanation
By removing the icon from the launcher, you blacklisted the device from the launcher. With the command above, you "empty" the blacklist.
If you want to to have a more selective way to set which device to keep in the launcher, first run:
gsettings get com.canonical.Unity.Devices blacklist

The output will be like:
['<device_1>', '<device_2>']

To restore device_1 in the launcher:
gsettings set com.canonical.Unity.Devices blacklist "['<device_2>']"

2. GUI
Alternatively, you can restore your icons with dconf-editor. You might have to install it first:
sudo apt-get install dconf-editor

(Or simply install it via Software-Center)
Then open the editor, browse to: com > canonical > unity > devices:

Then you can either set the blacklist to "default" settings (which is none), or remove devices from the blacklist selectively.


How to change the default printer in evince?

The default printer can be set through the System/Administration/Printing. Give it a try, set your default printer and re-start evince in order to gather the appropiate default printer where to send your stuff.

Good luck!


Will the new snap package make `Ubuntu Make` obsolete?

The long term idea is to have Ubuntu Make packaging snaps. The whole UI and tests have been carefully designed to cope with that case.

So, what would happen is Ubuntu Make running daily on some server, grabbing latest upstream. If version changes, it will package it as a snap and then run the same exhaustive testsuite.

If all tests pass (no regression), then, the new snap package is published!


Error in creating new project in Kdevelop

Install the package cmake. This contains the CMake build system as used by most of the KDevelop example projects.


My IBus pinyin broke with 14.04 release upgrade

I found this post that fixes the same problem for me:

run ibus-daemon -drx

and possibly a restart after that.


What's the relation between Juju project and Ubuntu/Canonical?

Yes, Canonical is the owner.

From Wikipedia:

Juju (formerly Ensemble) is an open source service orchestration management tool developed by Canonical Ltd., the company behind Ubuntu. Juju allows software to be quickly deployed, integrated and scaled on a wide choice of cloud services or servers.

From Canonical.com:

Juju is the Ubuntu project’s service orchestration tool,
    which simplifies the installation and management of cloud applications.

See here for references:

Canonical projects list

Wikipedia article on Juju


What's the difference between login as user and changing users using su through root?

SSH starts a login shell. su, by default does not.

In particular, this means that the ~/.profile (or similar file) for that user is not sourced. So changes made in ~/.profile won't take effect. It might also be the case that:

even if you start a login shell, different changes were made in root's ~/.profile, which might pollute the user's environment.

/etc/profile and /etc/profile.d/* may apply settings differently for different users (not by default, though)

there might be different settings for different users in SSH configuration.
PAM configuration is different. For example, /etc/pam.d/ssh has:

session    required     pam_env.so user_readenv=1 envfile=/etc/default/locale

whereas /etc/pam.d/su has:

session       required   pam_env.so readenv=1 envfile=/etc/default/locale

This means SSH loads ~/.pam_environment, but su doesn't. This is a big one, since ~/.pam_environment is the shell-independent place for environment variables, and it is applied if you login from the GUI, the TTY or SSH.

To start a login shell, run either of:

su - <username>
sudo -iu <username>

Example:

# su muru -c 'sh -c "echo $HOME $PATH"'
/home/muru /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games
# su - muru -c 'sh -c "echo $HOME $PATH"'
/home/muru /home/muru/bin:/usr/local/bin:/usr/bin:/bin:/usr/local/games:/usr/games
# sudo -iu muru sh -c 'echo $HOME $PATH'
/home/muru /home/muru/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
# sudo -u muru sh -c 'echo $HOME $PATH'
/root /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
# ssh muru@localhost 'echo $HOME $PATH'
/home/muru /home/muru/devel/go/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games

Even with SSH, if you run a command instead of starting a shell, a login shell won't be run (note the absence of ~/bin in the SSH test, which is present in su - and sudo -i). To get the true result, I will run my shell as a login shell:

# ssh muru@localhost '$SHELL -ilc "echo \$HOME \$PATH"'
/home/muru /home/muru/bin:/home/muru/devel/go/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games

This is also why sudo su and sudo -s are crappy ways of getting a root shell. Both these ways are polluted by the environment.

Related:

Unix & Linux: su vs sudo -s vs sudo -i vs sudo bash


You actually can do this with netcat, I believe it is already installed in most cases on linux, and it's dead simple.

On PC 1, type: nc -l 55555

On PC 2, type: nc $IP 55555, where $IP equals the local IP address of PC 1 [e.x. 192.168.2.50]

Once you do this, in the same box, from PC 2, type something and press enter.   Then go over and look at PC 1, and your message will be there!  It works both ways.

You can also choose a different port than 55555, or if you opened your firewall, you can do this through the internet via your external IP.


Section of the screen gets distorted and pixelated after a few hours

Well, if there is nothing wrong with screenshot (I can't see it either), most probably problem is with hardware. Dell do have excellent bootable diagnostics software, you should try it. If it founds some problems, warranty service can help (if warranty is still valid).


Lookup DNS entry by hostname without FQDN

As mentioned in this post, you must add the the DNS domain name (Zone) to /etc/network/interfaces in the following way:

dns-search domain.com


Just deleted 100GB of files, no extra free space. How do I get it back without rebooting?

Ahh, deleting large files on ext3 takes a while since it has to zero out a lot of indirect blocks ( though I could have sworn the rm command blocks until it is done ).  Yes, you certainly should upgrade to ext4.  It shouldn't be scary when you have a backup, and you do have a backup right? ;)

Don't forget; raid is not for preventing data loss, it is for preventing downtime due to mechanical failure.


It looks as though the kernel option nolapic solves this issue. Whether or not disabling lapic is safe is something I still need to look into.


If you enter /etc/network, and run ls -la, you will notice that interfaces is not formatted like a directory. This is because it is a file containing text.

So, you don't "enter" it, you "edit" it. For example, by running sudo nano /etc/network/interfaces


You need to install the drivers found by the Additional Drivers tool.

Follow these simple steps:

Plug your computer network cable to the router and make sure you have internet via the cable;
Open the Unity Dash and look for Additional Drivers. Open the application found.

In the application there will be listed drivers for your system that are not open-source or are provided by packages not regulated by Ubuntu. Select your wireless adapter from the list and press the Activate button on the right bottom corner of the application.

It should look something like this (maybe these are not your exact models, have a look)


How do I make the webcam on a Compaq Presario CQ60 notebok work?

am using Compaq Presario CQ60 Notebook also and i was having the same problem. You just have to download "Camorama" and here is the code using Terminal

"sudo apt-get install camorama"

Its a small program and it should be complete in a matter of seconds. lauche it and create a folder in "Pictures" directory or wherever you would like to save you photos. go to "Edit" properties of Camorama (On top if you are using ubuntu 11.01" and then click "Preferences" which seem to be the only option under that menu.  click "Local Capture" tab and then "Browse..." button found after "directory for captured pics" textbox. select the folder you created. Thats it you are done


Gnome indicator applet not showing same items on two computers

Only one notification area can be displayed at a time. That means that because you have a notification area in AWN, the notification items will not show up in the panel. To get the icon into your panel, remove the notification area applet from AWN.


EDIT: pactl load-module module-alsa-sink control=PCM should result in pulseaudio seeing a new output device that will control the PCM volume. If changing this device allows for proper control of audio output volume, you can add a line load-module module-alsa-sink control=PCM to /etc/pulse/default.pa

PCM (pulse code modulation) occurs at ALSA kernel level, and is responsible for sampling and conversion of digital signals from software to analog ones heard out of your hardware (PCM Playback channel), as well as analog ones coming in from your microphone (PCM Capture) to their digital form.

Linux audio output and volume control allows for a lot of versatility, but it can make thinks more complicated and more difficult to troubleshoot as well. For output, the flow is more or less like this:

START:Application audio you wish to hear produces digital audio data

  > Pulse app and libraries (user control with pavucontrol happens here and changes are then sent to the pulse engine server)

     > Pulse engine server (the core of Pulseaudio package)

         >  ALSA Kernel API (alsamixer control, PCM, MIDI and Sequencer API)

              > ALSA kernel driver processes data to make it understandable to our hardware

END: Speaker output

I think pactl from pulseaudio package should get you started and on the right track, please try

$pactl set-sink-volume $(pactl info | grep -i Sink | cut -d ':' -f2) 25%

and let us know if the audio volume gets set to 1/4 of the range, or again jumps to 100%.


The contents of your /etc/fstab file suggest that only two block devices get mounted - your Ubuntu partition, /dev/sda1 and your memory swap partition, /dev/sda5 , both of which are on the same disk /dev/sda

What you need to do to automount the secondary hard disk is to edit the /etc/fstab in accordance with output of blkid (the first 3 lines).

Run pkexec gedit /etc/fstab in terminal, to edit that file with super-user privilege. Add the following line:

UUID=4270461f-dacc-4ea1-846b-b79b19870ae2 /media/SECONDARY ext4 noatime,nodiratime,user=1000,rw 0 0

Save and exit the gedit text editor

Note, you should create /media/SECONDARY folder before reboot with sudo mkdir /media/SECONDARY. SECONDARY doesn't have to be the name, you can change it to whatever you want, but keep in mind to change it in /etc/fstab as well.

Note also the option user=1000 . Assuming you are the only user on your system, 1000 is default for first user ever created, hence that option. Verify your user id with id -u command. Change accrodingly

As for your original issue, I am not familiar with Ubuntu's disks utility, so I don't know possible reason for it not working. I would assume it performs the same task as editing /etc/fstab manually.


desktop doesn't load after messing with gtk

Start by entering recovery mode and log in with your user name and passwd. Or log in via the cd as you did.

try reinstalling ubuntu-desktop with,

sudo apt-get install --reinstall ubuntu-desktop


Fresh install of Ubuntu 17.10 - how can I move home directory to another hard drive?

Use gparted or another partitioning tool to create the partition you want to use for /home. Record the UUID of the new partition.

Copy all you files from /home to the new partition (this includes the folder /user). Don't forget the hidden folders.

Edit /etc/fstab and add the following lines:

# /home partition
UUID=<uuid recorded earlier> /home   ext4    defaults        0       2

Next, reboot your system

After confirming that your new /home partition is working correctly, you can delete the contents of the old home folder since only the folder /home is necessary for the mount point.

Note: if you formated with something other that ext4, change it to match the file system used.


Easy database tool (the more gui the better)

Install openoffice.org-base
After installation it will be found under Applications>>Office>>OpenOffice.org Database


What are Risks of Not Using HTTPS in local network of ownCloud in Ubuntu?

This depends on how much you trust your local network.  Http isn't inherently dangerous, however the data leak could be.  If you have a small network where you manage the machines and services it could be trusted, no problem.

If you could use ssl, you should, but if you can't like in your scenario, I wouldn't hesitate to use owncloud with http for local clients.

The other consideration is the sensitivity of the data on owncloud.  If it's music, pictures, typical storage data, it would seem like less risk.  If you're storing and transferring tax documents, trade secrets, nsa files, you should use https.

Keep in mind, https only encrypts the data while in transit, the files on your client and server are not encrypted while being stored unless you set that up seperately.


What to do with an Ubuntu disk image that appears as a WinRAR file?

The file probably did not actually have a .rar extension. It probably showed no extension, and when you double-clicked it, it opened in WinRAR. That looks like this:

And when you opened it, it probably looked something like this (the files inside may have been different, though, as it appears you downloaded the alternate CD):

This happens when these two conditions both hold:

Windows is configured to Hide extensions for known file types, which is the case by default.

It's not necessary to change this setting, but if you want to do so, Folder Options is in Control Panel (in Windows Vista and later, it's in the Appearance and Personalization category).

WinRAR is installed, and configured to open ISO images.

It's not necessary to change this either, but if you want to after installing WinRAR, open WinRAR and go to Options > Settings... and click the Integration tab. You can adust file associations there. You can also adjust them in the Default Programs applet in the Control Panel (it's in the Programs category).

This is unrelated to how you obtained the ISO image. The problem is that you're opening the ISO image as an archive. You don't have to use WinRAR on the ISO image. Instead...
If you want to install Ubuntu alongside Windows (or replace Windows with Ubuntu):
Burn the ISO image to a CD/DVD or write it to a USB flash drive, then boot from that. See:

How to burn a DVD on Windows
How to create a bootable USB stick on Windows
How do I install Ubuntu?

If you want to install Ubuntu inside Windows using Wubi:
You can install a Wubi system from a pre-downloaded ISO image by downloading wubi.exe from the Ubuntu website (this is a very small file), then make an empty folder, and put wubi.exe and your ISO image (which, as explained above, may not show any file extension) in that folder. Then run wubi.exe. Make sure wubi.exe and the ISO image file are for the same version number of Ubuntu.

However, you need the desktop CD/DVD image for this. You seem to have downloaded the alternate CD, which is not suitable for this purpose.
And for readers wishing to install Ubuntu via Wubi on computers that shipped with Windows 8 preinstalled: at least currently that is not supported and will not work. (But you can still create a regular (non-Wubi) Ubuntu installation.)

As a related but somewhat different situation, sometimes users confuse an ISO image and the program that opens it. See Ubuntu image download either downloaded or opened Roxio instead. Why? (In contrast, here the confusion is between an ISO image and another file type opened by the program set to open ISOs.)


textlive-bibtex-extra and biber conflict

Based on this bug report, it looks like what you've found (and what I've also just encountered) is a bug that didn't get fixed in time for 16.04 .

Someone on that page suggested a workaround which involves downloading biber from source.  You can consider that until it is finally fixed?

(Just tried it myself and confirmed that it works.)

(Edit:  Note that it seems (the older) biber version 2.4 should be used.  A newer version doesn't seem compatible with the biblatex that comes with Ubuntu 16.04)


Moving the comment from Grzegorz into a Community-wiki answer.

This problem occurs because Xubuntu uses Ctrl+F5 to switch into fifth workspace (if you don't have as much workspaces, then simply nothing happens), in fact whole F1-F12 range is reserved.

There are two possible solutions:

Redefine (clear) shorcut in Xubuntu (via Settings→Settings Manager→Window Manager→Keyboard) or
Use alternative i.e. Ctrl+Shift+R.


failed to start resolvconf-pull-resolved.service

Uninstall resolvconf with:
apt-get remove resolvconf

in ubuntu recovery mode(press shift when starting, then go advanced options, then ubuntu(recovery mode), go to root)
This is a bug , and should be fixed in the latest version of
resolvconf.

We believe that the bug you reported is fixed in the latest version of
resolvconf, which is due to be installed in the Debian FTP archive.


AttributeError: module 'PIL.Image' has no attribute 'VERSION' python2 pip

This is a known versioning issue between cinnamon and pillow >= 6.0.0. You can find more info here. As a previous commenter said, you can find the error in /usr/share/cinnamon/cinnamon-settings/bin/imtools.py. However, changing Image.VERSION to PIL.VERSION will not fix the issue for pillow >= 7.0.0. You must instead change the line to if Image.__version__ == '1.1.7':.


Err http://ppa.launchpad.net raring/main amd64 Packages

This ppa doesn't suport raring, only has support up to precise. You can see it here:

http://ppa.launchpad.net/network-manager/ppa/ubuntu/dists/

Remove the ppa from your sources:

sudo rm -vf /etc/apt/sources.list.d/nameoftheppa.list

sudo apt-get update && sudo apt-get upgrade

Of course, you'll need to find out what is the "nameoftheppa" to delete it, you can find them all under /etc/apt/sources.list.d/ and open them for reading:

nautilus /etc/apt/sources.list.d/

Have a look at the .list files and see which one has network-manager http on it.


Grub Freezes on Dualboot only when switching to windows

I was facing the same issue when I had both OS's installed in Legacy mode. I managed to solve the problem following these steps:

Delete Ubuntu partitions and reset Windows Boot Manager as default.
Convert disk from MBR to GPT partition style (to shift from BIOS to UEFI) and reconfigure the firmware to boot in UEFI mode.
Reinstall Ubuntu alongside Windows in UEFI mode.

Don't know if you are in Legacy mode too but hope this helps!


Add the following before the first line of your script:

[ -d /media/andy/MAXTOR_SDB1/Ubuntu_Mate_18.0 ] || mkdir -p /media/andy/MAXTOR_SDB1/Ubuntu_Mate_18.0

In other words make sure the directory is there before you try to copy something to it.


I think you may take a look in http://cdimage.ubuntu.com/ubuntu-touch/daily-preinstalled/current/
This is what I have found while I was trying to port Ubuntu Touch to my device.

Hope it helps.


If you're building on a 64-system and you're targeting 32-bit, the following command fixed this issue for me:

sudo apt-get install libssl-dev:i386


The Android version of the phone needs to be repartitioned before Ubuntu can be installed on it.

You can follow How to Install Ubuntu on bq Aquaris e4.5, to get your phone configured such that you can flash Ubuntu onto it with ubuntu-device-flash.


how to stop configuring network services

This is a know bug . Check out launchpad for more details about the bug.

There is a workaround for this issue. You may need to reinstall the network-manager and ligthdm . Please refer this blog for more details about this workaround


Touchpad click again after single click in 1 second, but another user no problem

I don't known "what's time I turned it on." I'm sorry.

Topic resolved.


Use vim instead of vi. The feature you're looking for is called syntax highlighting. It should be enabled by default in vim, and it's typically not enabled in vi.


How to fix it

For that error, you need to install development files for version 1.2 of libSDL and libSDL-image:

sudo apt-get install libsdl1.2-dev libsdl-image1.2-dev

It may also ask you for Guile, just install that one as well:

sudo apt-get install guile-1.8-dev

Then run ./configure again.

What was the problem

The software that you were trying to install, libgraph, has some dependencies. It uses other pieces of software and expects you to have them already installed. When you run ./configure, you check that you have everything you need before proceeding with the next step (make).

The error you got said that you don't have the headers for libSDL that are needed to compile libgraph. Of course, you can get the libSDL sources from the Internet and install them. But those have dependencies of their own, and it would be a rather tedious process. Instead, you can just install them from Ubuntu's repositories.

How to find out the required package name

apt-cache search libsdl | grep dev

For Ubuntu 17.10 and above

Follow the same steps as above except that you will need to install guile using

sudo apt-get install guile-2.0-dev

as guile-1.8 is no longer officially supported


rEFInd breaks standby mode on MacBook Air 5.2

I'm rEFInd's developer. I've heard another report similar to this, but I'm unable to replicate it myself, since my one Intel-based Mac is an elderly 32-bit model that doesn't exhibit this behavior. Since the problem doesn't manifest within rEFInd itself, I can't simply create a debugging version to give to somebody like you who does have the problem; it's going to take hands-on fiddling with the hardware to identify the cause of the problem and find a solution. The solution could be something like an alternative installation method for rEFInd or a code change to rEFInd, but whatever it is, I'm afraid that I can't find it unless/until I get a computer that has the problem. I have no plans to buy any new Macs in the near future, so this will have to wait indefinitely or for somebody else to find a solution.


Halt the 'shred' command in bash script if it encounters errors

I'm making a script to use shred.
I have the same problem of you, but its possible to do that:
# My device become the variable "$dev"
dev=/dev/sdd

# Running Shred using my variable and put the output 2 & 1 (msg and error) in a file, then put & to launch in background
# The log file will be shred_sdd.log
# ${dev:5} means /dev/sdd without the first 5 characters, because '/' is nod good in a file name
shred -fvzn1 "$dev" >"shred_${dev:5}.log" 2>&1 &

# So while the pid concerning sdd is running, check word 'error' in the the shred_sdd.log, if yes then write a message and kill the PID, else wait 60 sec before re-checking
while ps aux|grep "shred.*${dev}"|grep -v 'grep' >/dev/null; do
< "shred_${dev:5}.log" grep -i 'error' >/dev/null
if [ $? = 0 ]; then
  echo "Too much sector defect on the device ${dev}, shred can not continue"
  PID=$( ps aux|grep "shred.*${dev}"|grep -v 'grep'|awk '{print $2}' )
  kill -9 "$PID"
  break
else
  sleep 60
fi
done

You can use a fonction to do the same task with all devices
# Variables of my devices (You can use lsblk, depends your configuration)
devices=$(lsscsi -t | grep disk | grep sas | awk '{print $NF}')

function_shred() {
# Put the code here that I wrote previously
}

for dev in $devices; do
function_shred &
done


Can I get the classic "run command" window

This answer is not exactly to get the classic Alt+F2 Run command windows.

But we can achieve something simillar to good old "Run command" window using the below programs

  Compizconfig Settings Manager
  gmrun

If you dont have these packages installed. Here is the steps:

Open terminal and type

sudo apt-get install compizconfig-settings-manager
sudo apt-get install gmrun

Now open Compizconfig-setting-manager using dash. Navigate to

General -> Commands (Enable commands)

Open Commands tab -> In Command line 0 enter the value gmrun

Open Key Bindings tab -> In Run Command 0

Click on Disabled icon and make it Enabled(tick mark)
Click Grab key combination and use your desired key(I choose Alt+R

Done now you can use Alt + R to open the "Run Applications" box


Some updates require a password authentication

Copied from source https://wiki.ubuntu.com/SecurityTeam/FAQ

  Why does update-manager no longer prompt for the user's password?

  As of Ubuntu 11.10, update-manager no longer prompts for the user's
  password to apply updates. This was decided to improve usability and
  to make it easier for users to apply security updates and therefore
  increase system security. The rationale is as follows:

  Like in previous releases, by default only people in the admin group    are allowed access to perform security updates.
  Only updates for already installed software can be applied without a    password. Installing additional software still requires people to
  enter their password.
  The password prompt had become an irritant for some people such that    they would just press 'Cancel' instead of installing the
  updates. The    password prompt decreased system security for those
  users.
  People that did dutifully apply updates became conditioned to enter    their privileged password perhaps daily. When the user is prompted
  for the password, it should mean something and the frequency of
  update-manager updates meant that some people no longer thought about
  why they were entering their password. For these users, the password
  prompt had the potential to reduce security.

  For environments where this change is deemed not appropriate, this
  functionality can be disabled by the administrator via PolicyKit or by
  creating users that are not in the admin group (a recommended practice
  to begin with).

This probably also answers our question, why it does prompt.


What is the font in Ubuntu which is just called "Sans"?

Font names in Ubuntu are managed by library named fontconfig. fontconfig has a notion of aliases; four of those aliases are sans, sans-serif, serif, and monospace. To see what actual fonts are pointed to by those aliases use the command fc-match:

$ fc-match sans-serif
DejaVuSans.ttf: "DejaVu Sans" "Book"
$ fc-match sans
DejaVuSans.ttf: "DejaVu Sans" "Book"
$ fc-match serif
DejaVuSerif.ttf: "DejaVu Serif" "Book"
$ fc-match monospace
DejaVuSansMono.ttf: "DejaVu Sans Mono" "Book"

To modify the meaning of the standard aliases sans, sans-serif, serif and monospace you must create or edit a per-user configuration file, ~/.config/fontconfig/fonts.conf (or ~/.fonts.conf, depending on fontconfig version and system configuration). (You can of course edit the system-wide configuration file, but that would be rude.) For example,

<?xml version='1.0'?>
<!DOCTYPE fontconfig SYSTEM 'fonts.dtd'>
<fontconfig>
  <alias>
    <family>serif</family>
    <prefer><family>Liberation Serif</family></prefer>
  </alias>
  <alias>
    <family>sans-serif</family>
    <prefer><family>Liberation Sans</family></prefer>
  </alias>
  <alias>
    <family>sans</family>
    <prefer><family>Liberation Sans</family></prefer>
  </alias>
  <alias>
    <family>monospace</family>
    <prefer><family>Liberation Mono</family></prefer>
  </alias>
</fontconfig>

See a worked out example at How to Set Default Fonts on Linux on Season of Code.


How do I automatically respawn GNOME Do when it crashes?

You should be able to start it with a bash script that's basically "while(1){gnome-do}", ensuring that when gnome-do crashes, it gets run again. As long as gnome-do is run synchronously, it should work just fine. even if the system gets into a state where it can't be launched successfully, the impact would be small. If you want to ensure that even that is not a problem, insert a command using zenity. This would notify you that there was a problem, and require you to hit enter to start gnome-do again.

create a script with the following and launch it from the "Startup Applications" application found under the System Preferences menu.

while true
do
  gnome-do
  zenity --info --text="gnome-do crashed ... press enter to restart"
done


HTML5 version of Angry Birds not rendering properly in any browser

Switching to "NVIDIA accelerated graphics driver (version 173)" from the "version current" in the Additional Drivers dialog resolved the issue.


Disable middle click on Elan touchpad and xinput on Ubuntu 17.10

Of course I figure it out right after posting :) Putting the answer here just in case anyone else sees this

Find your touchpad ID:

adam@adam720:~$ xinput list | grep -i elan
⎜   ↳ ELAN0651:00 04F3:3052 Touchpad            id=14   [slave  pointer  (2)]

Find the ID of the middle click property:

adam@adam720:~$ xinput --list-props 14 | grep  -i middle
    libinput Middle Emulation Enabled (320):    1
    libinput Middle Emulation Enabled Default (321):    0

Toggle the middle click property. In my case it was set to 0, so I set it to 1:

adam@adam720:~$ xinput --set-prop 14 320 1

In the example above 14 is the ID of the touchpad and 320 is the ID of the property.

Now, this worked, but it also raises some questions that I can't answer.

Why was Middle Click Enabled set to 0 by default, and why did 1 turn it off?
What is "Middle Click Enabled Default" and why does it error out if you try to set it?

EDIT!
I wanted to make this persistent across reboots but I ran into a problem. The device and prop IDs change on boot. So, I wrote a script that looks for the device and prop IDs and then sets the middle button prop to off accordingly. I doubt anyone else will ever need it, but just in case I put the script on github


It is actually pretty simple. All you need to do is run:

./run.sh

or

sudo ./run.sh

The computer will tell you which one to use. Just run the first one and it will give you a message like "You need Root Permissions", then run the sudo one.


Map network drive to Win7 share from Ubuntu

Finally found the fix here: http://www.dedoimedo.com/computers/windows-7-samba-errnomem.html

Need to make two registry changes

1) HKLM\SYSTEM\CurrentControlSet\services\LanmanServer\Parameters, change "Size" from 1 to 3

2) HKLM\SYSTEM\CurrentControlSet\Control\Session Manager\Memory Management, change "LargeSystemCache" from 0 to 1

Made the changes, rebooted, and was able to successfully access my Windows 7 shares from the Ubuntu VM


How to change the login screen background from terminal?

Changing the login screen in Ubuntu 10.10

Open a terminal and to activate the Appearance window upon login enter the command

sudo cp /usr/share/applications/gnome-appearance-properties.desktop /usr/share/gdm/autostart/LoginWindow

Close the terminal. Log out of your current session. At the login screen, the Appearance window will show up.
Make changes and login. To deactivate the Appearance window upon login enter the following command in a terminal.

sudo unlink /usr/share/gdm/autostart/LoginWindow/
gnome-appearance-properties.desktop


The ServerName directive is used in order to define the default domain name that will be accepted by the virtual host (and ServerAlias for the synonymous of the default domain name). Also you do not need to specify network interface IP adders (or a domain name) within the <VirtualHost> tag, while you are doesn't have any special goals - i.e. serve different content for the same domain name accessed by different server's IP addresses, etc.

<IfModule mod_ssl.c>

    <VirtualHost _default_:443>

        ServerName example.com
        ServerAlias www.example.com www2.example.com

        # Other configuration directives...

    </VirtualHost>

</IfModule>

Unless there is not FQDN that points to your server's public IP address, you need to setup a local DNS or you need to edit the hosts files of your LAN devices in order to access your (web) server by a domain name within the LAN. For more details, please read the following references:

Apache2 Docs: Name-based Virtual Host Support
Creating additional Virtual Host Ubuntu Server
How to set a domain to ip address?
Setting up vhost on VirtualBox with Ubuntu 16.04
apache virtual hosts not working


Will ubuntu alter my other partitions on my PC

it deals with the entire disk and all partitions, try opening gparted while inside the live environment and resizing the windows 7 partition, then open the installer, and on the prompt where is asks if you want to erase disk and use entire disk for ubuntu, or install alongside, select "something else", go get a cup of coffee, then select the partition in the list that says "free space" and corresponds in name to the empty area on the diagram, click the change button, select "exxt4", "format" and use as "/", then just follow the prompts


Could not load host key: /etc/ssh/ssh_host_ed25519_key in /var/log/auth.log

You can generate the missing hostkey via:

ssh-keygen -A

ed25519 is a bit faster and more secure. It's not necessary and, aside from logspam, this doesn't have that much effect. You could, indeed, comment out HostKey /etc/ssh/ssh_host_ed25519_key, without much effect. But, at the same time, `ed25519 is a good host-key format to support.


Need help mass renaming files using command line that contain a certain string

You can use the rename command, with appropriate regular expressions e.g.

s/^\d+_-_//

for 'replace an initial sequence of digits followed by underscore hyphen underscore'; and

s/_/ /g

to replace underscores with spaces. So

rename -nv 's/^\d+_-_//;s/_/ /g' *.avi

The -n makes it run in test (dry run) mode - test it in your directory and if you are happy that it's doing the right thing, run it without the n


Why can I not drag and drop files from nautilus file manager to firefox in Ubuntu 18.04 LTS?

Go to Preferences > Views > Experimental
Is "Use the new views" checked? If so, uncheck it and you should be able to do drag-and-drop.

Note that, even with the "new views" enabled, drag-and-drop is still possible from the "list view", but not from the "icon view".

edit In recent versions of Nautilus, the 'Experimental' section in the preferences as disappered, and the "new view" seems to be the only one available now, :-/ Note however that it is only for the "icon view". As stated above, switching any Nautilus window to "list view" enables drag-n-drop to other apps. If you want to do it from the Desktop, you have to open it in a window ("Show Desktop in Files").


First check your account is activated or not. Have you got any
  notification on your another mail account which you filled on
  registration time on yahoo.


Ubuntu regolith Login loop after 19.04 to 19.10 upgrade

Ok so if you have read this post after you installed the 19.10 update, then dont wworry can still fix it using option 2 from this link:

https://github.com/regolith-linux/regolith-desktop/wiki/HowTo:-Upgrade-to-Ubuntu-19.10-(Eoan-Ermine)

Connect laptop via cable LAN.
first you will need to enter grub menu.

Press shift for old bios or press ECP for Ufei. then press ESC again when it says press any key.

once in go to the second option.
Then boot to recovery.
Then enable networking.
then boot terminal.
once your there follow option 2 instructions.

Every back to normal.

Thank you@Justice for Monica


Noo linux distro contains drivers for any of surface machines. Only way to make it work is with those guys
https://github.com/jakeday/linux-surface


When you call the script, a new child shell is invoked to run it. Its proxies are set, but the proxy of the parent process (your shell) can't be changed from a child process. Try sourcing the script, i.e. call it like

. setproxy 21

Then the script will be interpreted by your current shell.


libvirt-python stopped installation of devstack using stack.sh under Ubuntu 12.04

The issue is due to low version of "libvirt". If you update the Ubuntu 12.04 packages from "trusty", the problem will be solved.

By default Ubuntu downloads packages from "precise", but openstack needs some  lib files from "trusty", for example this "libvirt". Below steps solved this issue.

sudo -s
apt-get install ubuntu-cloud-keyring
echo "deb http://ubuntu-cloud.archive.canonical.com/ubuntu trusty-updates/juno main" > /etc/apt/sources.list.d/cloudarchive-juno.list
apt-get update
exit

Note: deb http url can be used from any other valid archive of Ubuntu sites.

Make sure to check the libvirt version

$ libvirtd --version
libvirtd (libvirt) 1.2.2

The output should be greater than 0.9.11. The stack.sh stopped due to this check condition, you can find the same in the query.


Lightdm won't start after upgrade from 14.10 to 15.04

The issue was that I had no drivers for video. I didn't have xserver-xorg-core installed. (I also reinstalled unity).

sudo apt-get install xserver-xorg-core
sudo apt-get install xserver-xorg-video-intel

And then I had an issue with login screen (Ubuntu gets stuck in a login loop)

chown username:username .Xauthority


How to completely wipe Ubuntu 11.10 from HDD?

In windows, use "disk management" to reformat the drive.
Note: You will lose all data stored on the drive.


You are looking in the wrong place. If what you want is a keyboard that can replace the android keyboard (with word prediction), there are plenty:

Florence & xvkbd

Florence is especially nice if you use GNOME.

Other options are available as well.

Unfortunately, what you REALLY are looking for is word prediction from your already existing dumb keyboard. See, on android and other screens, you input using virtual keyboards. On Desktops/Laptops, you have ACTUAL keyboards, which are different, and functionality can't be added to them once produced.

Virtual keyboards can be replaced, upgraded and functionality added. So, both the systems have that.

Lastly, a hybrid does exists, TextSuggest , a program that shows completions for the word selected or (optionally) currently being typed (from its description).
You have to hit a global shortcut for it showup, much like tab-completion on terminals.


Ubuntu 12.04, Php5-fpm, Apache2, Postfix: impossible to send a mail with PHP

As I was unable to make Postfix working, I finally used Exim4.

At the beginning, test emails with php worked out of the box, except for emails sent by Wordpress. Exim4 gave this message : Unrouteable address.

The solution

I made a mistake in the configuration. Instead of giving the name of the machine (ns3098501.ip-94-23-10.eu) I gave "libre-factory.com", which is the name I use for the Wordpress network.

Once I did a new configuration with the good name, it worked.

Please notice that the path to sendmail is set to default "/usr/sbin/sendmail -t -i" and that it works well.


The bug is Unity? :) bug report here:
http://sourceforge.net/p/parcellite/bugs/118

And it is fixed in SVN.

And BTW, thanks for the great vid - makes the developer's life easier.


Type in the Terminal sudo apt-get install build-essential and then press key TAB instead of pressing ENTER.


KDE Plasma black screen and cursor after suspend/screen timeout

I had this problem after installing a bad widget (or "plasmoid", whatever that is?).

Just switch to another virtual terminal Ctrl Alt F6, for example to use virtual terminal 6 (or 5 if 0-indexed.)

Then run kpackagetool5 for KDE Plasma 5 to see your installed widgets

kpackagetool5 -l -t Plasma/Applet

It will yield a list of anything you have installed and most importantly, where they are on your system. This should be in your user directory ~/.local/share/plasma/plasmoids. Just move them out of there and restart Plasma to see if that fixes it for you. In my case, this amounted to doing

mkdir ~/plasmoids
mv ~/.local/share/plasma/plasmoids/* ~/plasmoids
systemctl restart lightdm

It is also possible to use kpackagetool5 but I avoid using tools that have versions in their name out of principle.

kpackagetool5 -t Plasma/Applet --remove nameofwidget


Eclipse desktop shortcut keeps disappearing at every startup?

Install the desktop file using the following,

sudo desktop-file-install /usr/share/applications/eclipse.desktop

Create a link file using the below command to open eclipse in command mode.

sudo ln -s /opt/eclipse/eclipse /usr/local/bin/

That’s it , Now you can launch eclipse.


Clippy's ancient, he must've retired by now :pIt was removed from the default Office 2003 installation and the feature got completely removed in Office 2007. It's available in LibreOffice, but only gets triggered at certain actions, and has been replaced by a light bulb since a few years ago.

To get help in LibreOffice, you just go to the Help menu, and choose LibreOffice Help.

  The Help Agent

  The Help Agent starts automatically when you are performing a task that might require some assistance.
  The Help Agent appears in a small window in a corner of the document. To view the help for the task, click inside the Help Agent window.


lxd init fails on Ubuntu 16.04 Xenial Xerus

When you run the command lxd init and there is an error, you get a reason,

$ lxd init
Error: Failed to connect to local LXD: Get http://unix.socket/1.0: dial unix
/var/snap/lxd/common/lxd/unix.socket: connect: THE_REASON

Reason no such file or directory means that the LXD service did not start yet (may need to wait a bit or just manually start it).
Reason permission denied means that your current account does not below to the group lxd, therefore is not permitted to access the socket /var/snap/lxd/common/lxd/unix.socket.

In this case, run groups to see whether your account is member of the lxd group. If you are member of the lxd group, then you need to log out and then log it. If you are not member of the lxd group, then run

$ sudo usermod --append --groups lxd myusername

and then log out and login again.


How to disable notification from network-manager

12.10 - Dconf
Run these commands:
gsettings set org.gnome.nm-applet disable-disconnected-notifications "true"
gsettings set org.gnome.nm-applet disable-connected-notifications "true"

Or open dconf-editor and scroll down to org ▸ gnome ▸ nm-applet and check disable-connected-notifications and disable-disconnected-notifications settings there.

11.10 and 12.04 - Gconf
Gconf-editor lets you edit the network manager notifications.
To alter these settings, install gconf-editor from the software-center.
Scroll to / ▸ apps  ▸ nm-applet  and check disable-connected-notifications and disable-disconnected-notifications settings there. Check the attached image for clarifications.


18.04 Can't connect to some company internal sites with VPN

Fixed. In VPN connection I had to modify the settings for IPv4 and IPv6.  I had to change them both from "Automatic" to "Disabled".


Here is how to install the quantal emacs24 release on 12.04 :

sudo -s
cp /etc/apt/sources.list /etc/apt/sources.list-original
echo "deb http://archive.ubuntu.com/ubuntu quantal main restricted multiverse universe" >> /etc/apt/sources.list
aptitude update
aptitude install emacs24
cp /etc/apt/sources.list-original /etc/apt/sources.list


How can I clone my HDD to a smaller SSD?

The dd method should have worked though there should have been no need for those parameters. Since you have pv it can also be simplified as:
# pv /dev/sdc > /dev/sdb

No need for dd, though dd should have worked. This needs done as root because of the IO redirection. If you want to do it with sudo you'll need to do it in a shell:
$ sudo sh -c 'pv /dev/sdc > /dev/sdb'

or indeed use dd after all:
$ sudo pv /dev/sdc | sudo dd of=/dev/sdb

If you do that and you think it hasn't worked, please show us the partition table of sdb afterwards.
$ sudo fdisk -l /dev/sdb

And please do have backups! One error and all data is gone…


15.04 liveusb "install ubuntu" app wont work

check your cd  image or iso file. or re-download it from ubuntu official website.
make bootable cd or pendrive. help

try boot from cd or pendrive and use try ubuntu.
after successfully loaded you will found install ubuntu option on the desktop or left sidebar.
try to install.


How to install "tree" with command-line?

Use this command in Terminal:

sudo apt-get install tree

The command apt-get update only updates the package lists. You need apt-get install and the package name to install a new package.

And yes, sudo is required as you need root privileges in order to install and remove software.


system files that require elevated privileges will require sudo, otherwise you wouldn't need it. .vimrc is likely to be a essential system or program file. Just like how you would need sudo to alter any of your roor files in /etc/~ and whatnot.


There will be a feature to download all your files easily, prior to all the files being deleted. Developers are working on the feature, and it will be deployed as soon as it is tested and working. You will be able to then download all of your files as a single .zip file.


virtualbox shared folder is owned by root and not writable

The solution is easy, just mount the shared folder for the standard user:

sudo mount -t vboxsf folder share -o uid=1000,gid=1000

1000 is the default ID of the default user. This can be checked by id username


What are the benefits/problems about upgrading Python to a newer version

The main reason you'd want to install Python 3.x is to run Python 3 programs.  With that said, you would still need Python 2.x installed if you wanted to run programs designed for that language since there are incompatibilities between the two.

As far as picking a single default Python interpreter for the base install (with the other needing to be installed afterwards if needed), the main reason you might want to pick 3.x is that this is where the language evolution takes place.

As has been announced, there won't be a Python 2.8 so any useful language extensions added to the 3.x branch of the language are not going to be back-ported to the old language.

Programs depending on Python 2.x are not going to go away any time soon, but the code in the default install is a much more manageable quantity.  So switching over should be possible in a much shorter time frame.


Shared .purple directory with other user

You are not pidginarch when doing touch so it requires sudo. So

sudo touch test

would be to do it.

By the way: I would not create a directory in / myself but probably use /usr/local/ and then the sub-directory in there that is suitable for the file itself.


How to enable autologin on Lubuntu 16.04 LTS (LightDM)

I found the solution in this thread about Lubuntu 16.10: Lubuntu 16.10: How to make login through greeter without typing password work

Open new configuration file with Leafpad (or your preferred editor)

sudo leafpad /etc/lightdm/lightdm.conf.d/10-autologin.conf

Paste the following lines

[Seat:*]
autologin-guest = false
autologin-user = yourusername
autologin-user-timeout = 0

[SeatDefaults]
allow-guest = false

Replace yourusername with the name of the user you want to have logged in automatically


Monitor turns off while installing 12.04

I had this issue as well. The way that I got around it for the install was to press f6 at the boot prompt and choose nomodeset. then press esc and type xforcevesa on the command line in the boot prompt and then press enter.


Will apt-get dist-upgrade blow away my PostgreSQL server setup?

No, it shouldn't overwrite any databases. As for the settings, the new package may have updated settings files (eg. for a new default value or a completely new setting) but it should always ask you for a confirmation about overwriting the settings. That dialogue will also have an option to compare the new and old settings file and an option to keep the old settings. Since you have a backup, it is safe to install the update.


What I think has happened is that the GRUB bootloader got overwritten when Windows was installed.

This seems to be the quickest way to fix it:

Boot Ubuntu live via a CD or another method
Open a terminal in the live session and run

sudo add-apt-repository ppa:yannubuntu/boot-repair
sudo apt-get update
sudo apt-get install -y boot-repair && boot-repair

this installs the boot repair utility, which will reinstall GRUB, and hopefully fix your problem
Type boot-repair into the console
Using the recommended repair will attempt to fix the problem, and if it fails it will generate a pastebin link which you can post on the original question to provide further details.

Further reading: https://help.ubuntu.com/community/Boot-Repair


A recent update seems to have fixed the problem.


Programming language API sidebar in gedit

I am not sure if that can be achieved in gedit, but there are several alternatives for this case, such as Bluefish which imho is the most lightweight and will give you the reference information in autocompletion popup as shown in the Edit Preferences.

Give it a try, it isn't that different from or more resource-demanding than gedit.

A php file highlighted and html reference information in a popup.

An html file highlighted and html reference information in a popup.

Edit/Preferences Language support config.

Supported languages, which include but are not limited to Javascript


Try this:

sudo dpkg --remove --force-all davmail

If that doesn't work:

sudo rm -rf /var/lib/dpkg/info/davmail*
sudo dpkg --remove --force-remove-reinstreq davmail

You should now be davmail-free!


Because Firefox 3.6 doesn’t support all the html5 specifications, no browser today does. Look at http://html5readiness.com/ which browser supports what features. No it doesn’t matter a whole lot, html5 is still in the development stages.


Check in LibreOffice Writer to see if the following Microsoft True Type Core Fonts have been installed:

⠀Andale Mono
⠀Arial Black
⠀Arial
⠀Comic Sans MS
⠀Courier New
⠀Georgia
⠀Impact
⠀Times New Roman
⠀Trebuchet MS
⠀Verdana
⠀Webdings

If all of these fonts appear in the font list in LibreOffice Writer, then the Microsoft True Type Core Fonts have been installed successfully. If not, see this answer


Run sudo  apt install -f. It should fix all of your broken packages. It usually deletes them, so make sure that it isn't deleting any packages that you need before you confirm the fix.


What graphic card i use & how to switch between my cards?

Following command gives you graphics detais.

glxinfo | grep OpenGL

The output will be like

OpenGL vendor string: Intel Open Source Technology Center
OpenGL renderer string: Mesa DRI Intel(R) G41 x86/MMX/SSE2
OpenGL version string: 2.1 Mesa 9.0.3
OpenGL shading language version string: 1.20
OpenGL extensions:

The second line gives you your driver's name.
You may also try

glxinfo | grep OpenGL | grep renderer

Which will give only driver's name.


Upgrading to newest nVidia drivers on a laptop that uses Optimus? (Ubuntu 15.04)

ubuntu is getting good at bundling vendor graphics drivers so having to download and install manually is not necessarily the go to solution.  Try this :

System Settings -> Software & Updates -> Additional Drivers

give it time to do its probes/lookups and it will respond with list of pre-loaded drivers from which you can pick an Nvidia if you wish.  This does work.


Printer prints garbage and "/usr/lib/cups/filter/pstopdf failed" at CUPS web interface

Finally after a lot of pain. I discover that the problem was the serial to USB cable (in order to connect the serial printer to an USB port). I tried with two different serial to USB cables, but the problem persists and finally I conclude that The printer works erratically if is not connect to a "real" serial port.

I tested the printer under identical conditions in a PC with a serial port and it works perfect, just installing the driver provided by epson and giving chmod 777 to /dev/ttyS0. At the job list sometimes I see the error: "/usr/lib/cups/filter/pstopdf failed". But the printer prints ok, like no error occurred.


How to connect/forward HTTP proxy through ssh?

Open a socks proxy from B:

ssh -D 1080 -f -q -N user@A

Tell your browser to use it:


time problem in dual boot in windows 7 while ubuntu 14.04 shows correct time

If they were off by the same before you changed the file then I would try to go into your BIOS (or BIOS like environment) and seeing if the time is wrong in there. That is were both Ubuntu and Windows gets the time from. You would then change the file back to what it was before.

If you do not know how to get to BIOS it is most likely by hitting a f key before you get to the boot menu, but every computer is different.


BASH Script hangs after some processing on Ubuntu


Ubuntu Touch Apps don't recognize Ubuntu MultiTouch, utouch

You should never have been able to use the evdev multitouch protocol, at least in production, because the evdev devices are typically readable only by root. X11 apps used the XI 2.x protocol for their multitouch support.

As far as I know, Mir (the display server library that Ubuntu Touch uses) forwards all the appropriate touch events on to the clients, but my detailed knowledge of the stack ends there.

I'm pretty sure Qt5 has multitouch support, and that's presumably how apps are expected to get multitouch events. Are those events not getting through?


How do I edit all autostart applications?

Show Hidden Startup Apps:

sudo sed -i "s/NoDisplay=true/NoDisplay=false/g" /etc/xdg/autostart/*.desktop

4 Tricks to Speed Up Ubuntu

https://www.youtube.com/watch?v=vwBoHZuauL8


If you need Python 2 just type idle in terminal.

If you need Python3 type idle3.

I have both Python2 and Python3 installed and also idle and idle3.


There is an app called SubtitleEdit. It uses tesseract as backend for OCR stuff. I successfully run it on Arch Linux (it's available in repos) so not sure how to install it on Ubuntu, probably you'll need to build it from source.

There is also vobsub2srt. It is command line only tool which also uses tesseract. You can install it from ppa on Ubuntu.


How to isolate file permission and file name from results of ls -l?

The stat command is made for this ex.:
stat -c '%A %n' *.txt

or
stat --printf '%A\t%n\n' *.txt

where the format specifiers have the following meanings
   %A     access rights in human readable form
   %n     file name


If you're ok with using the command line, I would install adb, the Android debugging bridge. It's reliable and simple to use, but may be a little off putting for new users.

(http://androidforums.com/lg-spirit-4g/692656-install-adb-windows-ubuntu-12-04-12-10-a.html)

You will need to enable developer options on your Nexus 7 by tapping 7 times on the Build Number item in Settings -> About Phone. This will enable a new option, Developer Options, from there enable USB debugging.

When you're connected via USB, with adb you can verify that adb can see your device with;

adb devices

You should see the following;

* daemon not running. starting it now on port 5037 *
* daemon started successfully *
List of devices attached
XXXXXXXXXXXXXXXXXX device

Where XXXXX is an alpha numeric string unique to your device. If you don't see the string, you haven't configured adb correctly.

You will be able to transfer files to your device using adb push

adb push myfile /sdcard/

and get files off using adb pull

adb pull /sdcard/remotefile /home/username/


According to http://www.kernel.org,  3.16 is still not stable.
Better try 3.15.8,  the latest  Stable version


Use nethogs :)
Install it by typing sudo apt-get install nethogs.
To start the app type:
sudo nethogs [network interface name e.g. eth0, eth1 or ppp0 etc.]  To find this name use the command ifconfig and check which of the interfaces are associated with valid ip address..


Openning link in Slack oppens up new instance of Firefox, which shows up as 'child' of Slack

Did you install Slack using snap?
I had this problem and removed the snap install
sudo snap remove slack
then reinstalled from the .deb download from here: https://slack.com/intl/en-nz/downloads/instructions/ubuntu
sudo apt install ./slack-desktop-4.7.0-amd64.deb
and the problem went away.
I can't pretend to understand why(!) but it fixed the problem for me.


There is a lot to say about (creating) Debian packages, and information can be overwhelming.

The example below is to make the (very) first start, and create a Debian installer, as basic as it possibly gets, suited for "home" purposes.

Debian packages

A Debian package is in principle a scaled version of your system, seen from the perspective of the root directory. Directories are exactly organized like on your computer.
Looking inside a .deb installer file with archive manager, you can see where files and (possibly) directories will be installed:

In this example, files will be installed in /etc, /usr and /opt (the folder DEBIAN contains installation files, see further below)

Browsing deeper into /usr, you can see the .desktop file (represening your application in Dash) is installed in /usr/share/applications/

When an application is installed, the contents of this scaled version is "projected" on to your "real" system.

A simple example; create a first installer

Say you have a small application (script in this case), that you want to install into the directory /opt, together with its application icon. To represent the applications in Dash, you will also need a .desktop file.

Our example application will only show you a window, saying you succeeded:

The "application":

Copy the script below into an empty file, save it as ididit (don't use the sh extension)

#!/bin/sh
zenity --info --text 'It seems you succeeded making your first Debian installer...'

The icon:

Simply download the icon below as ididit.png

The .desktop file

[Desktop Entry]
Name=I did it!
Exec=/opt/ididit/ididit
Icon=/opt/ididit/ididit.png
Type=Application

Copy it and save it as ididit.desktop

Now create the scaled directory:

Create an empty project folder somehwere, named (e.g.) ididit_1.0-1
Inside this project folder, create the directories:

/opt/ididit
/usr/share/applications
/DEBIAN

The last directory will not be installed, but contains files, needed by the package manager (see further below).
Copy both your script, named ididit (no sh extension), and the icon, named ididtit.png into your newly created directory:

[.../ididit_1.0-1]  /opt/ididit

Make the script executable.
Copy the .desktop file into the directory:

 [.../ididit_1.0-1]  /usr/share/applications

The /DEBIAN directory contains files, used by the package manager. It can contain a varying number of files, postinst scripts etc. (look here and here for more information). Since this is meant to be an example as simple as possible, we'll keep it to just one necessary (minimized) file: the control file:

Package: ididit
Version: 1.0-1
Section: unknown
Architecture: amd64
Depends: zenity
Maintainer: Your Name <your_email>
Description: This is my first Debian installer.

Copy it into an empty file, save it as control in the DEBIAN folder.

note: replace Architecture: amd64 by Architecture: i386  if you use 32bit.
Run the following command to make your first installer:

dpkg-deb --build /path/to/ididit_1.0-1

The Debian installer will be created in the same directory as your project folder.

Now you can install it by:

sudo dpkg -i <package>

And uninstall it by:

 sudo dpkg -r <package>

If all went well, you can run it from Dash.

If you install it by Software Center, it will complain about the "bad quality" of the package, since we skipped a number of files etc. To see exactly what the complaints are, you can run in a terminal:

lintian /path/to/package

As mentioned, this is only a small instruction on how to make a first working Debian installer. It might encourage you to develop your skills further into creating lintian- proof Debian installers.

More to read: Ubuntu packaging guide (and many, many other sources.)


Mouse double-click time is too short in lubuntu

To change the double-click interval in Lubuntu (confirmed to be working on 14.04):

Create a (hidden) file:

~/.gtkrc-2.0

(~/ is your home directory, files starting with . are hidden by default, press Ctrl+H to make hidden files visible)
Open the file with Leafpad / run in a terminal window:

leafpad ~/.gtkrc-2.0

add a line to the file:

gtk-double-click-time=600
(or any other value you'd like)

Close the file, log out and back in, test if the value is what you like.


sqlplus command not found on ubuntu 14.04

Check your $PATH variable. Add $ORACLE_HOME/bin to it. Or wherever the Xe places its binaries.


Why does a desktop launcher does not start my app, while the .desktop file is working?

I have figured out the answer: there were two .desktop files, a correct one in /usr/share/applications and an incorrect one in /home/.local/share/applications (path was not correct). Replacing the incorrect one by the correct one solved the issue.

I probably got mixed up in the installation and then forgot the incorrect .desktop file. It prevented me to launch the app from the launcher or the Favorites, even when I pinned it in the Favorites after launching it correctly with the command line.

Thank you for all who helped!


Files: Name column basically useless in list view. Feature or bug?

Since the default file manager does not seem to support what I want, I looked into alternative file managers and installed Nemo (note that this is more difficult at the moment, see below). It is similar enough while having many more features and not displaying the above mentioned annoying issue (at least for version 1.x, see below).

Alternatively, PCManFM seems to actually not have this issue. The name column won't get truncated by default, while allowing manual resizing. It does not have an as beautiful the UI though (but still good enough).

Installing Nemo on Ubuntu 13.10 is not as easy. There exists a PPA which provides a seemingly compatible version of Nemo 2.0 for Saucy Salamander (ppa:gwendal-lebihan-dev/cinnamon-stable). It worked fine at first, being more useful than the default Nautilus, although still having this issue but only with even narrower windows. However, this will also install Cinnamon 2.0. And this currently breaks Unity in 13.10. I experienced that after a restart, where I was not able to login before removing all cinnamon/nemo packages first. So beware!

The otherwise official repo at https://launchpad.net/~noobslab/+archive/nemo provides Nemo (version 1.x, currently 1.7.4) for Ubuntu. As of now there is no version for saucy, however. But I was able to install the version for raring by downloading the deb packages for:

gir1.2-nemo-3.0
libnemo-extension1
nemo-data
nemo

All but the actual nemo package installs fine. Nemo has a dependency on libgnome-desktop-3-4 but Ubuntu 13.10 has libgnome-desktop-3-7. So what I did was extract the deb package, modify the DEBIAN/control file, repackage it and install it. As a last step I had to link the dynamic library for 3-7 to 3-4 because Nemo expects this library.

# extract the raring package
mkdir nemo
cd nemo
dpkg-deb -x ../nemo.deb .
dpkg-deb -e ../nemo.deb

nano DEBIAN/control
# modify libgnome-desktop dependency from 3-4 to 3-7
# repackage
dpkg-deb -b . ../nemo~saucy.deb

# link the libraries
sudo ln -s /usr/lib/libgnome-desktop-3.so.7 /usr/lib/libgnome-desktop-3.so.4

# install nemo~saucy.deb


Dual Monitor with Nvidia graphics: damaged 'Displays'

Use Nvidia-Settings and enable twinview. Apart from seeing noise in video player windows after resume from hibernate I experience no issues on my notebook with a 9400 chip.


'E: Unresolved dependencies.' when trying to install new packages

This means that the Lazarus packages have dependencies that cannot be satisfied in your version of Ubuntu. Thus apt-get decides that it's best to remove it than to leave it in a broken state.

For instance, Lazarus wants libgdk-pixbuf-2.0-0, which is not available in your version of Ubuntu (Lucid). Also, the version of libgtk2.0-0 it needs (2.24.0 or greater) is only available from Ubuntu 11.04 onwards.

What this indicates is that the Lazarus package was created in a newer version of Ubuntu.

Now, you say it works, so it's apparently not entirely incompatible with the libraries you have installed. So it's a problem with the software's packaging, rather than with the binaries themselves. If it works with older versions of, say, libgtk, the package should not require a newer version. This would have to be fixed by the Lazarus people.

There are two ways to fix the packaging problem:

Try to find a version of the Lazarus package for Ubuntu 10.04 (may be outdated and lack features you need).
Upgrade your Ubuntu to a newer release, it's very likely that Lazarus will install without conflicts there.


Custom shortcuts in Ubuntu 14.04 with gnome fallback session not working

You can always use configuration editor like dconf-editor (sudo apt-get install dconf-editor), it'll automatically create default setting or a copy from another desktop setting (e.g. Ubuntu Desktop) if you happen to login on it for the first time.

For manually edit window manager keybindings, it should be here: org.gnome.desktop.wm.keybindings, or just search for it.

You'll need to type the keyword/value manually tho', it is a low-level editor.


To completely remove your touchpad drivers, remove xserver-xorg-input-synaptics via

sudo apt-get remove xserver-xorg-input-synaptics

this command removes also xserver-xorg-input-all, but that's only a meta package.

  Description-en: X.Org X server -- input driver metapackage  This
  package depends on the full suite of input drivers for the X.Org X
  server  (Xorg).  It does not provide any drivers itself, and may be
  removed if you wish to only have certain drivers installed.


I'd like to USE the application - I DO NOT want to see it's icon wiggle!

If you're more comfortable using a search based graphical launcher but you feel unity is a little slow, I recommend you take a look at synapse.

It provides pretty much the same functionality as dash, but I find it to be a lot faster. It also provides the functionality you ask for.


gpg2 is unaware of secret and public key on smartcard

it should suffice to have the Smartcard's Public Key in keyring.pgp or similar file name on local machine:

Export Public Key from Smartcard with gpg2, or
import public key from keyserver, must have been exported previously with gpg2


How do I build a Hyper-V enabled kernel in a Ubuntu 12.10 guest VM on Server 2012?

Ubuntu 12.10 has LIS (Linux Integrated Services) 3.1 . This is  the same in 12.04 and is limited. MS relased 3.4 last automn 2012 but works on RedHat and CentOS but not for Debian based OS (like Ubuntu).

Should be any genius programmer around to make LIS 3.4 to work with 12.04 and 12.10 ? Please Ô please !


You're missing the trailing backslash at the end of some lines (and you have an eccessive newline at the end of the last line you want to insert):

sed -i '/the specific line/i \
#this\
##is my\
text' file

% cat file
foo
the specific line
bar

% sed -i '/the specific line/i \
#this\
##is my\
text' file

% cat file
foo
#this
##is my
text
the specific line
bar


setup Remmina for remote desktop connection

In order to be able to use Remmina, you need first to activate certain options of the "Desktop Sharing" screen (Dash -> Desktop Sharing) on both computers:

On the Desktop Sharing Preferences:

Activate the option "Allow other users to view your desktop"
Activate the option "Allow other users to control your desktop"

For security's sake, also:

Activate the option "You must confirm each access to this machine"
Activate the option "Require the user to enter this password" and provide a password

Once the configuration is done, you can simply open Remmina, create a new connection and specify the connection to the other computer using VNC  (virtual network computing) protocol and using the password you used in the "Desktop Sharing" screen. Hint: You can ignore the field "user".

Regards


Installing software error: no installation candidate

This happens when you are trying to install a package about which apt does not have any idea.

The packages that you are trying to install can be found in Ubuntu Software Center: doxygen-gui and graphviz. So, possible reasons for receiving these errors can be:

Your version of Ubuntu is "end of life" in which case you should follow this post
You don't receive packages for some repository components (I think main or universe). See how you can change repositories in Ubuntu here: https://help.ubuntu.com/community/Repositories/Ubuntu.


How do I turn off autolist in tcsh terminal

You need to use unset autolist.

Using set autolist=false will actually set the variable; since tcsh just checks if the variable is defined (the value can be anything from empty, to false, to 42, etc).


How do I make Nautilus windows stick for drag & drop?

While you're dragging hold your mouse over the taskbar icon of the nautilus window, and it'll be raised to the top so you can drop your files in it.


How often does ubuntu update their python versions after CVEs?

So long as you installed a package through one of Canonical's official channels and are running a supported release of Ubuntu (or are part of the Extended Support program), they take care of updates. You will not need to do anything beyond sudo apt upgrade. That said, some updates may take longer than others depending on the severity of the issue.
You can find specific information about CVE-2021-3177 on the security website, including which versions have the bug and the status of the update.


Based to all comments above, try this:

sudo apt-get autoclean
sudo apt-get update
sudo apt-get dist-upgrade
sudo apt-get install npm