Is it possible to ping a remote Linux machine without using ssh?

knockd may be your answer.

Server part:

Install knockd --> sudo apt-get install knockd
Edit configuration file --> sudo nano /etc/knockd.conf also you can use gedit or vi.
The configuration file should look like this after the edit:

[options]
        LogFile     = /var/log/knockd.log
        Interface   = wlan0
[sendMessage]
        sequence    = 1111,2222
        seq_timeout = 5
        command     = /usr/bin/env sh -c "echo 'Hello, World' | wall"
        tcpflags    = syn

Where Interface is the listening network interface, sequence is the port knocking sequence and command is the command to be executed when knocked.
Edit startup file --> sudo nano /etc/default/knockd
In this file you only need to change START_KNOCKD=0 to START_KNOCKD=1
Reload knockd to apply changes with sudo /etc/init.d/knockd reload

Client part:

Simply telnet in that order the server ports and the command will be executed

telnet MYSERVER 1111
telnet MYSERVER 2222

You can also use the knock utility:

knock MYSERVER 1111 2222

Final notes

You can also view those connections in the Logfile specified, (i.e. /var/log/knockd.log)
You can use a more complex port combination (i.e. 5555,5050,3333,3030)
You can read the entire documentation at the developer's webpage
You can read a great tutorial on the ubuntu community


During system restart telnet service isn't start automatically

You will need to add it to startup.
How to enable or disable services?
This answer here explains how to do that.


How can I set a per terminal bell with xterms?

I am quite sure this is not possible without modifications to the source of pulseaudio plugin x11-bell (or perhaps compiz, which might be your windows manager). If configured properly before compilation, xterm rings the bell through XkbBell(3), which passes the display and window to any program listening to XkbBellNotify events. If configured differently, xterm uses XBell(3) which does not pass this information.

Unfortunately, even if xterm is configured properly, both pulseaudio and compiz discard the display and window information (pulseaudio only uses the percentage information to set the volume).


cryptswap1 messages after reseizing root partition

I had a similar issue and found that reinstalling ecryptfs-utils and updating grub worked for me:

$ sudo apt install ecryptfs-utils --reinstall
$ sudo update-grub


1.Open Network Connections

2.If there is no item for Ethernet. click Add to add a new wired connection.
  Once a connection is created, you can edit it to meet your network configurations


Ubuntu 18.04 Dual Display with one Display switched through KVM Switch (Keyboard Video Mouse Switch)

I had to save the EDID.bin of each monitor to a file and use it in the configuration.
Usually this should be possible in the xorg.conf, but for me only the file /usr/share/X11/xorg.conf.d/10-nvidia.conf  worked.

Section "OutputClass"
    Identifier "nvidia"
    MatchDriver "nvidia-drm"
    Driver "nvidia"
    Option "AllowEmptyInitialConfiguration"
    ModulePath "/usr/lib/x86_64-linux-gnu/nvidia/xorg"
EndSection

Section "Device"
    Identifier     "Device0"
    Driver         "nvidia"
    VendorName     "NVIDIA Corporation"
    BoardName      "GeForce GTX 1070 Ti"
    Option         "ConnectedMonitor" "HDMI-0,DP-0"
    Option         "CustomEdid" "HDMI-0:/etc/X11/edid.bin.DP-0:/etc/X11/edid-2717.bin"
    Option         "IgnoreEDID" "false"
    Option         "UseEDID" "true"
EndSection

Section "Screen"
    Identifier "Screen0"
    Device "Device0"
    Monitor "Monitor0"
    Option "metamodes" "HDMI-0: 2560x1440  +0+0, DP-0: 2560x1440  +2560 +0"
    DefaultDepth    24
    SubSection     "Display"
               Depth       24
    EndSubSection

EndSection

Now everything works. But take care the 10-nvidia.conf will be overwritten if you change your nvidia driver!


How to make it possible (in Ubuntu 14.04) to change name of a file with just 2x clicking on it?

You can press the F2 key on your Keyboard after clicking on the file you want to Rename.

Just a reminder,  as some keyboards have take over the F1-keys by the FN key, therefore you might have to press FN + F2.

Good Luck!


From http://en.wikipedia.org/wiki/Ubuntu_Foundation

  The Ubuntu Foundation is a purpose
  trust founded by Mark Shuttleworth and
  Canonical Ltd. to ensure the long-term
  maintenance of the Ubuntu Linux
  distribution independently of the
  commercial activities of Canonical
  Ltd. Its initial funding commitment is
  $10M
  Its current advisory board is made up
  of chairman Mark Shuttleworth, founder
  of Canonical Ltd., and representatives
  of the Ubuntu Community Council and
  the Ubuntu Technical Board.[1]

  Although it was originally announced
  that the Ubuntu Foundation would
  employ core members of the Ubuntu
  community[2] as of 2008, the
  Foundation remains dormant. Mark
  Shuttleworth describes it as an
  "emergency fund" in the event that
  Canonical's involvement in the Ubuntu
  project ends.


Changes in /etc/network/interfaces do not make any change

Try the command: sudo /etc/init.d/networking restart


Is there such a thing as active-panel tracking with i3?

Have you checked the command line tool xev? It basically outputs all sort of X events done within a window(typing, button up, button down, dragging, moving cursors etc.) Hope this helps.


Intel wireless works only when acpi=off on 16.04

To get both ACPI and wireless working use acpi=force option instead of acpi=off.


'ssh localhost' gives 'Permission denied (publickey).'

Please, check /var/log/auth.log for possible errors during connection. This line

  Oct 25 09:49:47 me-myubuntu sshd[16442]: User me from localhost not allowed because not listed in AllowUsers

indicates the problem.


How do I set Handbrake to default to mkv Matroska format?

Settings like the format are tied to the individual presets. You can either modify / create a preset, or make one of the default Matroska presets your default.

It looks like the preset management has moved a bit between versions. Here it is in 0.9.9 (xubuntu 14.04):

NOTE: in screenshot above the arrow points to all 3 buttons below the preset list.

Here it is in 1.0.1 (manjaro update 2017-01-30):


Maximize window vertically if screen edge is hit ubuntu 17.04 mate

You need to change the setting at plugin Grid --> Corners / Edges --> Top Edge. You should set it to Maximized.


What I've got from that page is that the fix has been released, but for "touchpads that don't support multi-finger or sending correct finger width, the jumpy cursor problem is still there". It might be your case.

Do not forget you may also install gpointing-device-settings (click the link to install) to configure your touchpad settings if the default app does not fit your needs.


xubuntu - is it better than xfce on ubuntu?

I have had experience with it and I can't see where your problem is coming from. I currently have the equivalent of K/L/X/Ubuntu and Gnome Shell and more - and neither desktop usually majorly affects the other.

However, you did say that what you do requires a lot of memory, and this could be a part of the issue, as the system may be a little unstable (no matter the Desktop environment or what is installed) when it begins to run out of memory.

Another possibility is simply that you may be changing things and not noticing (I have known people to change panel items by accident for example) - or, your system may simply be encountering bugs.

To sum it all up, your problem is not from running XFCE and Unity on the same system.


Capture mode: Video camera
Video device: /dev/video0 (1st camera)
Audio device: hw:0,0 (if you would like to record mic, otherwise leave blank)
Click Play
Menu View → Check Advanced Controls to record on the main control bar.
Press Record the red dot button to start/stop recording. (Records are stored by default in your Videos folder)


How do I install PostgreSQL 9.6 on any Ubuntu version?

For the following Ubuntu versions, you can install with the given commands, as per the official PostgreSQL Apt Repository.

Ubuntu 17.04 - 17.10

Version 9.6 comes with the distribution.

sudo apt-get install postgresql-9.6

Ubuntu 14.04, 16.04

sudo add-apt-repository "deb http://apt.postgresql.org/pub/repos/apt/ $(lsb_release -sc)-pgdg main"
wget --quiet -O - https://www.postgresql.org/media/keys/ACCC4CF8.asc | sudo apt-key add -
sudo apt-get update
sudo apt-get install postgresql-9.6


Two moments here:

VICE is packaged for all Ubuntu releases - see search on packages.ubuntu.com - on 18.04 LTS you will get 3.1.0.dfsg1-1 version from multiverse pocket. So you can simply install it with:
 sudo add-apt-repository multiverse
 sudo apt install vice

You can compile newer 3.3 version of VICE if you install all needed dependencies with APT by following installation instruction:
 sudo apt-get install build-essential bison flex libnet1 libnet1-dev \
 libpcap0.8 libpcap0.8-dev libgtk-3-dev libvte-dev libasound2-dev xa65 \
 libglew-dev texinfo

And finally install it to the system with checkinstall:
 ./configure --enable-native-gtk3ui --with-alsa --enable-ethernet
 make -j3

 sudo apt install checkinstall
 sudo checkinstall make install


Any way to change PDF from Portrait to Landscape without rotating it?

No, this is not how PDF files are designed. They are designed to mimick a paper print copy. Thus, flow of the content and layout is static.

Other formats such as epub exist that can adapt layout of the content to changing dimensions of the screen/window.


Splitting data based on semi colon and picking up unique IDs

You should be able to do this with sed.  Something like this might do:

sed -En 's/^(.*; )?(ZINC[^;]+).*$/\2/p' < input.txt

A brief rundown of what it is doing:

tell sed to use extended regular expressions, and not print lines by default.
the s/.../.../p syntax tells sed to perform a regexp search and replace, then print matching lines.
The first part of the regexp ^(.*; )? says to start at the beginning of the line either match any characters up to a "; " (i.e. some number of semi-colon delimited items), or nothing at all (i.e. if the ID is the first item).
(ZINC[^;]+) matches your ZINC... ID, accepting any non-semi-colon character as part of the ID.
.*$ matches the remainder of the line.
The replacement for the match is \2, which is the second parenthesised group in the regular expression (i.e. the ZINC... ID).  Since the regexp matches the entire line, we're left with just the ID.

If the format is as you've described, this is probably enough.  If it is more complex (e.g. with special quoting rules), you should probably look for a tool that understands the format.


Intel Core i7-3612QM multi-core CPU not being utilised properly

It's not possible to spread a single threaded processes over multiple cores evenly. A single threaded process can only run on one core at a given time and the kernel might move the process/thread to another core while the programm runs.
If one process is running at 100% on one core all the time you should check for that process and why it is utilizing one core.


nginx/apache is not particularly relevant to setting up email user ids and servers.

Check the contents of /etc/mailname.  This should be where the nsoo1234.ip-12-34-23.eu is set.  Change the name to the domain in this file you want to use.

Setting up a mail server for reliable delivery takes a bit of work.  If you are just sending, you can configure your mail server as a smarthost, and use your ISP's relay server.

Incoming mail requires DNS configuration to work correctly.  You may find my post on Running an Email Server helps.  You should also consider setting up SPF (Sender Policy Framework) record in DNS to discourage use of your domain(s) to send spam.

I prefer to use exim4 instead of sendmail.  Others prefer to use postfix.  In most cases any of the three will work as a drop in replacement for the others.  Their construction and configuration are significantly different, but the functionality is the same.


Can't install unrar to open .rar files: Connecting to www.rarlab.com (www.rarlab.com)|5.135.104.98|:80... connected

You've already installed unrar when you ran the apt command.

Just run it from the terminal (see man unrar):

unrar e myrar.rar

If you want to make rar files, install the rar package:

sudo apt install rar


Remove the repository and re-add it again:

Remove the repository

sudo apt-get install ppa-purge
sudo ppa-purge ppa:plushuang-tw/uget-stable

Add the repository

sudo add-apt-repository ppa:plushuang-tw/uget-stable
sudo apt update

Install uget

sudo apt install uget


Answer found on ubuntu forums here: http://ubuntuforums.org/showthread.php?t=710623

.gnome2/gedit/plugins/ is the right directory (or /usr/lib/gedit-2/plugins/ if you want them installed systemwide).

Your plugin should have a .gedit-plugin file and a .py file or a folder containing .py files with maybe a glade file. the .gedit-plugin must be in the root of the plugins directory (e g: .gnome2/gedit/plugins/).

If it still doesn't work try to run gedit from a terminal and look at the output, you may find some useful debug info.


You may just need to install the libreoffice-writer package (parts of libreoffice are available in multiple packages, see here). This can be done with:

sudo apt-get install libreoffice-writer

You should also be able to do it via Synaptic, Software Center


I formatted my Seagate hard disk using Ubuntu and now I am unable to see it in files

The problem might be that the disk doesn't contain any recognizable partitions. If that's the case, you should be able to use the fdisk command to remove any unrecognizable partitions and create a new (good) one. Hope that's helpful!


Do the latest Intel Core i3/i5/i7 processors just work?

Yes, both the 2nd and 3rd generation (latest) i3/i5/i7 processors and built-in graphics will work out of the box in Ubuntu 12.04. The 2nd-gen usually have the suffix -2xxx and HD3000 graphics while 3rd have -3xxx and HD4000 graphics. e.g. i3-2310M is 2nd-gen i3, while i5-3520M is 3rd-gen i5.

However, many laptops also come with a second discrete (separate) graphics card from AMD/Nvidia (called hybrid graphics), and you will need to install the drivers for those for optimal performance. But it's an easy process, and can be done with two clicks from Settings...Additional Drivers.


Installing ubuntu next to windows 10, screen freezes after installing question

Oke I managed to turn some settings to "legacy" and that fixed it for me. I saw somewhere else that perhaps turning some settings to "legacy" would fix it, and it did. It was after I toggled something called CSM or CMS (not sure anymore). So look for that if you're having the same problem.


How do I install Adobe Acrobat Reader from the repository?

It's a bit more manual to install Adobe Acrobat Reader in Ubuntu 14.04, but it's not hard.

Open a terminal.

Type:

cd ~/Downloads && wget -c http://ardownload.adobe.com/pub/adobe/reader/unix/9.x/9.5.5/enu/AdbeRdr9.5.5-1_i386linux_enu.deb

That downloads the DEB file from Adobe and puts it into your Downloads folder.
Next type:

sudo dpkg -i AdbeRdr9.5.5-1_i386linux_enu.deb

That will install Adobe Acrobat Reader.

If you are on a 64 Bit machine, you may need to add the missing libraries that Nim mentioned:

sudo apt-get install libgtk2.0-0:i386 libnss3-1d:i386 libnspr4-0d:i386 lib32nss-mdns libxml2:i386 libxslt1.1:i386 libstdc++6:i386

If you want Acrobat Reader as your default application for PDF's, then type:

mimeopen -d *.pdf

It will display a list of programs (it displayed 3 for me). Select the number that has Acrobat Reader. It will open Acrobat Reader and say it can't open '*.pdf'. Ignore that error and close Adobe Reader. You should be set now.

UPDATE:

For 18.04, the i386 files get installed this way:

sudo apt-get install libgtk2.0-0:i386 libnss3:i386 libnspr4:i386 libnss-mdns libxml2:i386 libxslt1.1:i386 libstdc++6:i386


How to restart X Window Server from command line?

NOTE: This will forcefully quit all graphical programs, you'll lose any unsaved work, and you'll be logged out. Non-graphical programs will not be affected.

TL;DR: on systems with systemd (Ubuntu 15.04 and newer)

sudo systemctl restart display-manager

This will restart the appropriate display manager service (lightdm till 17.04, gdm3 after, sddm in Kubuntu, etc.). You can replace display-manager with lightdm, gdm3, sddm, etc. if needed, but this should be enough.

For other Ubuntu versions, first find which display manager your ubuntu is having with following command:

cat /etc/X11/default-display-manager

Than depending on what display manager, you can use one of the following commands:

Default Ubuntu (with LightDM)

sudo systemctl restart lightdm

Gnome (with GDM)

sudo systemctl restart gdm

KDE (with KDM)

sudo systemctl restart kdm

Note: From 12.10 to 15.04, Kubuntu also uses LightDM.
For MDM (e.g. for Mint Cinnamon)

sudo systemctl restart mdm


Seems like you installed Ubuntu with the encrypted installation. You could learn more about encrypting your disk here: https://help.ubuntu.com/community/EncryptedFilesystems  Then, the only thing that you could do is backup all your data and reinstall without encrypting the disk (if you don't really want to have your disk encrypted).


Can I run Ubuntu 13.04 on a Benq Joybook A52?

Yes, you can. The minimum requirements for Ubuntu 13.04 32-bit are:

1 GHz Pentium 4 Processor
512 MB of RAM
5 GB HDD Space (Minimum)
DVD Drive or an USB port

You don't need to care about drivers for the beginning. Maybe, in the future, you will be interested about this post: Shall I install ATI drivers, or keep the open source ones for now?


Desktop loads, but no dash. Ubuntu 15.04

have you tried ctrl+alt+f2 for a terminal, then login

now type:

sudo service lightdm stop

then:

sudo service lightdm stop

lastly:

sudo service lightdm start

This is how to manually restart the display manager. Let us know if this helps.


Mount count is not reset after automatic fsck run at boot

After a bit of investigation, I found that the problem was in the systemd-fsckd service, from the systemd package. At the time of writing, the versions which are available in wily and xenial seem to contain the offending code (225-1ubuntu9 and 229-4ubuntu4 respectively).
Solution
As the service is not necessary for the correct working of the system, a straightforward solution is just disabling it by running this command:
systemctl mask systemd-fsckd.service systemd-fsckd.socket
The downside is that now Plymouth won't report fsck progress. In fact, it won't even tell the user that a filesystem check is under way.
Explanation
A bit of background from the man page of the service:

systemd-fsckd.service is a service responsible for receiving file system check progress, and communicating some consolidated data to console and plymouth (if running). It also handles possible check cancellations.
systemd-fsckd receives messages about file system check progress from fsck through an UNIX domain socket [...]

The issue with this service is that it uses a hardcoded timeout of 30 seconds while doing an epoll_wait on the socket for progress information. If fsck doesn't report progress in less than 30 seconds, then systemd-fsckd closes the socket and exits with success without logging anything as far as I could see.
The next time that fsck writes in the (now closed) socket to report progress, it dies with a SIGPIPE. As fsck never finishes, the mount count is not reset then.


I have faced a similar situation, may be this helps. I have received a certificate in .p7b format. First, I converted it into .pem format. Then, I imported it into Firefox (or your browser). After that, I could access my application using that certificate.
Now, in order to convert a .p7b into .pem do as follows.
openssl pkcs7 -inform der -in yourCert.p7b -print_certs -out yourCert.pem

Hope this helps.


Screen become black after upgraded from 17.04 to 17.10

Try booting into recovery mode.
From there continue the software upgrade:

dpkg –configure -a

After that try to load Ubuntu with a normal boot.
Finish Software Updates:

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


Cant install ubuntu 14.10amd 64 alongside windows10 home edition

First go to diskmgmt.msc in windows (win+r), than shrink your partition as much as you want, leave it nonformatted, go back to ubuntu installation, choose something else, format and flag the empty space you have created in windows like the link, afterwards you should be ready to go.


By setting t_Co to 256 what you'll get is a degraded version of Solarized.

It's better to update your terminal color palette instead for more precise colors.

set t_Co=16
let g:solarized_termcolors=16

By setting t_Co and solarized_termcolors to 16 we tell Vim and Solarized to use terminal's color palette.


Boot from the Windows 10 DVD or USB and try using the repair utilities. If successful, it will probably make Ubuntu not able to boot anymore, but that is easy to fix.
If (1) does not work, or if it does work in making Windows boot, but Ubuntu does not boot, use boot-repair-disk.


There is no single license for Ubuntu. Ubuntu is a distribution of thousands of different packages that each have their own license.

For example the Linux Kernel itself is released under the GPLv2, but other components like some binary drivers that may come with Ubuntu are proprietary.

This page explains this a bit further.


how to get phpmyabmin to work on ubuntu 15.04

PHPMyAdmin doesn't work out-of-the-box once installed: you need to configure Apache first. Add the following line to /etc/apache2/apache2.conf:

Include /etc/phpmyadmin/apache.conf

Then restart Apache:

sudo service apache2 restart


Ordering of the commands used to install from a ppa

The && operator executes the following command only upon success of the previous command / chain of commands.

So the implications for those cases are:

The script executes every command regardless
The scripts executes sudo add-apt-repository example/program and sudo apt-get update regardless and sudo apt-get install example-program only upon success of sudo apt-get update
The scripts executes sudo add-apt-repository example/program regardless, sudo apt-get update only upon success of sudo add-apt-repository example/program and sudo apt-get install example-program regardless
The scripts executes sudo add-apt-repository example/program regardless, sudo apt-get update only upon success of sudo add-apt-repository example/program and sudo apt-get install example-program only upon success of sudo add-apt-repository example/program

So, to answer your question, in this case just chain all of them, since you need everything to succeed:

sudo add-apt-repository example/program && sudo apt-get update && sudo apt-get install example-program

Also, add-apt-repository and apt-get can be set to automatically answer yes to all queries using the -y argument, so to fully automate everything:

sudo add-apt-repository -y example/program && sudo apt-get update && sudo apt-get install -y example-program


How to update MySQL Server, MySQL Client and phpMyAdmin to the latest stable versions on my local machine running on 64-bit Ubuntu 12.04 LTS?

I would expect from an Ubuntu LTS release such as yours to have the latest stable version of all those software you mentioned.
You are 2-years into the 5-years support period of your release,
so I think this is a reasonable expectation.

Upgrading to 14.04 doesn't seem like a great idea.
Upgrading is a sensitive operation not to be taken lightly,
potentially a major hurdle.
The support period of 14.04 will end one year earlier than the current,
so you would have to upgrade one year earlier.

To update the software you listed, you can use this command:

apt-get install names_of_packages

This will upgrade only the selected packages.
If you don't mind,
it's good to keep your entire system up to date, with:

apt-get upgrade

If, on the other hand, the version of Apache/MySQL bundled with 12.04 is really too old for you,
then you might want to consider installing the latest version from source.
However at this point the benefits of this approach over upgrading to 14.04 become questionable.

In any case,
before you do any major changes (apt-get install or apt-get upgrade don't count as major changes, they should be safe),
I recommend to create a clone system (in VirtualBox or other),
export your current settings and reimport in the clone and test carefully.


Roughly explained, RAM is used by two things:

Loaded programs
Harddisk cache to speed-up read- and write-access

If a program is started but doesn't use some parts of its allocated RAM, it will be swapped to disk to make space for harddisk cache to improve harddisk performance.

The aggressiveness of swapping out programs is called swappiness. You can find is a more in-depth explanation here on how to configure it.


Mount and share a drive with bindfs in fstab permissions

Well since nobody is willing or able to help, I have meanwhile worked out the issue using als, but just in case you have the same problem, here are a few notes:

No matter what you set in als, thunar file manager will not display the right permissions in its properties so ignore those or you will think you did something wrong.  Give the terminal some time to load and process files on larger directories, it may do nothing for a while, and you may think it is done and close it (I don't know if that will stop any processing) but you should see it working through the files until it returns a prompt again.  If you want to start with a clean slate, and completely wipe all ownership and permissions on the whole drive, partition or directory first, files and all recursively then start with:

{sudo chown -R nobody:nogroup /path/to/directory/or/mountpoint}

Do not leave it like that for long if you have safety concerns though. Unmount, remount, if its a drive. Pick an owner, make a new group and add those you want to give access to (don't use a users group), chown again to give that user and the group ownership.  If you add users to that group some day down the road, they will have the same permissions assigned automatically. Use acl to set read, write and execute permissions.

In most modern Linux distributions, als is enabled by default on ext3 and ext4 partitions and needs not be added to fstab options.  There are quite a few guides to using als so look them up, I found a GUI to make it easier called "eiciel" and when run with root permissions {gksu eiciel} it will let you set the permissions for the group with ease.

Since so many think that sharing a drive amongst friends and family reeks of communist hippie commune gone amok, and don't get why anyone would want to do it, I just may write an EASY TO FOLLOW and THOUROUGH guide on the matter, as it seems to be fashionable around here to assume that everyone is familiar and comfortable in a terminal interface from the stone age!  FYI I am not a programmer, just a measly electrical engineer, and I had to go through a load of sites with, useless, partial and outdated and non descriptive information, to gather enough info to do it right without hosing the computer.


In Wired Connection settings save option is getting grayed out

Found the solution: It's a GUI problem: When adding static IP you may end up with an 'invisible' blank line in the list of IP addresses which prevents saving settings - just click below your IP address and delete the blank entry.


How about using the find command's built-in -delete action? that should be whitespace safe

find . ! -name '*-out*' -type f -delete

Otherwise, you could do a null-terminated while loop - make sure you quote the filename variable as well

while read -rd $'\0' f; do rm "$f"; done < <(find . ! -name '*-out*' -type f -print0)


Yes of course you can.

From within OpenSuse (gparted should be able to do this) or from a live CD you can create a partition that is big enough for Ubuntu (roughly at least 15+ Gb) and install using this empty partition.
Ubuntu's installer will ask you what to do with OpenSuse and as long as you do not touch those partitions and use the new empty one you will be able to add Ubuntu to your setup.

Example with Ubuntu 10.10 and 11.04:

Similar to this you will get OpenSuse in it.

At the end of the installation you'll probably will be prompted what to do with grub (the bootloader). If you reinstall grub at this time it will add both OpenSuse and Ubuntu to it but you can also do this manually from within OpenSuse after install (also useful in case the installer does mess it up and only adds Ubuntu.


xdotool type error. Can't type a field starting from - (hyphen/dash) with . (dot) in the same field

Although I can't find it documented in the manual page, xdotool type appears to accept a GNU style -- sequence to indicate the end of option arguments i.e.

xdotool type -- -14.7873


how to get a DisplayLink display adapter working in Ubuntu 13.10

While the framerate is a little sluggish at times and there can be misidentifications of the the display dimensions occasionally, it is working in Ubuntu 14.04, so upgrading is one solution.


Left mouse button stops working randomly

I have exactly the same problem on a Sony Vaio with Xubuntu 16.04, but the left mouse button stops working about every third hour, both on the touchpad and on the external mouse. To date I have been logging out and in again to fix it. Recently I found this alternative.

sudo modprobe -r psmouse
sudo modprobe psmouse proto=imps

Works fine for the external mouse, but the touchpad gets slow and stops scrolling. However, after entering the commands the hanging never bothers me, not even after a full workday.


you can try install 'nodejs' or 'node' :

apt-get install nodejs

or

 apt-get install node


Gtk-Message: Failed to load module "gtk-vector-screenshot" - Xubuntu 14.04

You will need to restart your X11 session after installation to make it work and also when you want it completely removed after uninstall.

Guru bonus gibberish:

The program hooks a shim of itself into every X11 application by filling an environment variable that can only be set once at X11 start-up. The preloading happens in

  /etc/X11/Xsession.d/52load-gtk-vector-screenshot-gtk-module

Which reads:

# This file is sourced by Xsession(5), not executed.

if [ -z "$GTK_MODULES" ] ; then
    GTK_MODULES="gtk-vector-screenshot"
else
    GTK_MODULES="$GTK_MODULES:gtk-vector-screenshot"
fi

export GTK_MODULES


why does the fdisk command work inside virtual box but not inside linux shell on windows?

There are several issues that may be happening here. The most likely one is that VirtualBox does not provide the disk drive as a serial interface. Potentially it virtualises the old IDE drive.

To check that, open a terminal and execute:

ls -l /dev/disk/by-path/

You will see several links with the associated paths. Note what the links link to (it maybe something like ../../hda) These are the drives that your system sees.

Alternatively, if those disks are already mounted (and at the very least one should be) you can run

mount -l -t ext4

This should list all the ext4 partitions that are currently mounted (i assume here that you have formatted your drive as an ext4 partition, if you have for whatever reason chose a different file system, you can ommit the -t type and try to find your partition or provide the file system format that you have used).


Winff exits with "Unrecognized option" error

You didn't follow the guide properly because your ffmpeg configure only contains --disable-yasm. The presets are probably for encoding with libx264, but since your ffmpeg configure is lacking --enable-gpl --enable-libx264 you do not have support for this encoder.

The libavcodec-extra-53 package will not affect your compiled ffmpeg, so it does nothing in this case.


The thing is that actual binaries are stored in /bin and /usr/bin. What you see appearing in dash is .desktop files which are sort of like shortcuts to programs. In those files there is a liine Name which is how it appears in dash and other search tools, like gnome-do

Now here's the problem: The .desktop files for unity-control-center and gnome-control-center have line Name exactly the same, as System Settings

Now, do this grep -s 'Name' /usr/share/applications/* | awk '/-control-center/'
You should see

/usr/share/applications/gnome-control-center.desktop:Name=System Settings
/usr/share/applications/unity-control-center.desktop:Name=System Settings

Speaking of 15.04 , this has nothing to do with this Ubuntu version. I've had it in 13.04 and 14.04. It's just a small quirk that can be easily corrected by editing one of the .desktop files


arp is displaying weird IP addresses in the 169 range

Addresses in the 169.254.x.x range are self assigned link local IP addresses. It usually happens when a device is unable to acquire an IP from a DHCP server. Those entries aren't necessarily hurting anything however you can flush the arp cache:

sudo ip -s -s neigh flush all

Should flush the arp cache.

Otherwise you can use arp from net-tools to delete a specific IP from arp cache:

sudo arp -d <ip address>

(-d is for delete).


Getting Wifi to work on Ubuntu 12.10 for MacBookPro

With some old versions of ubuntu on my laptops (PCs) after installing I usually pluged the Ethernet Cable because the Wireless adapter won't work, after updating the OS using the Ethernet connection the problem usually fixes.


what is the hostname (FDN0 or IP address of the server that ubuntu Whoopise and apport use?

I  don't know the port that it uses, but I know the website and IP address it sends the bug reports to. It sends them to https://daisy.ubuntu.com which is 162.213.33.132 .


How to enable hibernate on ubuntu 20.04 LTS

To enable Hibernation in 20.04:
Increase swapfile size to match RAM size up to 8GB.

Check the swap that is in use:
sudo swapon -s

If swap partition(s) are found:
sudo swapoff -a
sudo nano -Bw /etc/fstab

Add # before the UUID of the swap partition(s):
# UUID=XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX   none   swap    sw     0       0

Add a line for the swapfile, if one does not exist:
swapfile   none    swap     sw      0       0

Create the swapfile:
sudo fallocate -l XG /swapfile*

where X is swapfile's size in GB:
sudo mkswap /swapfile
sudo chmod 0600 /swapfile
sudo swapon /swapfile

Reboot:
sudo reboot

Add resume location and offset to grub.cfg:

Edit /etc/default/grub:
GRUB_CMDLINE_LINUX_DEFAULT="quiet splash resume=UUID=XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX resume_offset=XXXXX"

Use UUID from root.

Use offset from:
sudo filefrag -v /swapfile |grep " 0:"| awk '{print $4}'

Update GRUB:
sudo update-grub

Test hibernation:
sudo systemctl hibernate

A hibernate button can be added using GNOME extensions.
Note that there is a slight possibility of getting holes in a swapfile when creating it with fallocate. /var/log/syslog can be searched for the phrase swapon: swapfile has holes to ensure there will be no data loss.
A swap file can alternatively be created using dd:
sudo dd if=/dev/zero of=/swapfile bs=1G count=8

An error when using dd may overwrite your HDD.


Ubuntu 18.10 Asus GL504GV fn keys (screen and kb backlight) not working

After some more tries I get to a good enough "solution" (at least to me)

1.- Screen brightness:

I made my own script to increase/decrease screen brightness and assign it to C^F7 and C^F8. It's not the solution I was looking for, but now I can change screen brightness

#!/bin/bash

BASEPATH=/sys/class/backlight
DEVICE="intel_backlight"
cd $BASEPATH
MAX=`cat ${DEVICE}/max_brightness`
CURRENT=`cat ${DEVICE}/actual_brightness`
PERCENT=`echo $MAX/100 | bc`

echo $PERCENT
if [ "$#" -ne 2 ]; then
    echo "Error: wrong parameters"
    echo "Run: # set-brightness.sh inc/dec percentage"
    exit -1
fi

MODE=$1
DELTA=$2
if [ "$MODE" = "inc" ]; then
    # Increase brightness an x%
    NEW_BRIGHT="$(( $CURRENT + ( $PERCENT * $DELTA ) ))"
    if [ $NEW_BRIGHT -gt $MAX ]; then
        NEW_BRIGHT=$MAX
    fi
elif [ "$MODE" = "dec" ]; then
    # Decrease brightness an x%
    NEW_BRIGHT="$(( $CURRENT - ( $PERCENT * $DELTA) ))"
    if [ $NEW_BRIGHT -lt 0 ]; then
        NEW_BRIGHT=0
    fi
else
    echo "Option: $MODE does not exists. Please use inc or dec"
    exit -1
fi
# Set the new bright
echo $NEW_BRIGHT
echo $NEW_BRIGHT > ${DEVICE}/brightness
exit 0

2.- The KB problem still unsolved, but now I finally have white lights with the led bar and asus logo disabled.

To change the lights just follow the next steps

Open windows
Install Asus Aura Core from the windows store
Chenge the lightning setup on Asus Aura and save the changes

This way the changes are stored and loaded after booting.

Any of this "solutions" are the solutions I'm looking for, but I hope this can help others with the same issues.


if that did not fix your problem you could take a USB put ubuntu on it (make sure this is a live session), install boot repair, and run boot repair on your system it should fix most boot problems.


My keyboard layout changes uncontrollably

"epo" is probably there since you selected "Esperanto" as the language when you installed Ubuntu.
It's easiest to change it manually. Open the file for editing
gedit admin:///etc/default/keyboard

and replace "epo" with "de". Then save and reboot.


Can I install Ubuntu Server via a USB stick?

Yes! You can install Ubuntu by USB.

Take a look at these questions for more help:

How do I install Ubuntu to a USB key? (without using Startup Disk
Creator)
Installation/FromUSBStick - Ubuntu help


I found same kind of issue in post #284981 and same solution worked for me:

sudo chown -hR $USER:$USER .gnome2
sudo chown -hR $USER:$USER .gnome2_private

Credit should go to Paulo who provided the solution.


Cannot open Ubuntu installation LIveUSB in desktop

The ONLY way for regular users to run the Ubuntu installer is to boot from the USB.

Trying to open the installer in an existing Ubuntu/Windows/Mac session simply won't work.

Shut down your machine and boot from the USB.

There are advanced ways to install without booting from a USB Installer, but those are highly technical and not advised for regular users.


Ubuntu 14.04 screen corruption on live desktop (AMD 7970)

Your problem should go away as soon as you install the proprietary AMD drivers (fglrx) from the Additional drivers tab in Software & Updates. Of course you need to be able to install Ubuntu first and be able to actually see those settings:

If you are using a regular Ubuntu DVD or USB-Stick press F6 in the boot menu and select nomodeset. If you are using UNetbootin select your boot entry and press TAB to edit the boot-options. Add nomodeset to the existing line and press ENTER to boot.

If you still get corrupted windows try the same with vga=771 instead of nomodeset. Now you can install Ubuntu. Of yourse your installed version of Ubuntu will get the same corrupted windows, so for one single boot you need to add the boot-option that worked for you to the boot line in GRUB. You can edit the boot line by pressing e.

After you successfully booted into your fresh install, go to Software & Updates and select your driver like this:

After a final reboot the corruptions should be gone.


How to circumvent hard link creation permission to directories on the same file system

As long as you stay on a current kernel (it is a feature by the kernel rather then one of the filesystem) there is nearly no way around this limitations.

  Limitations of hard links

  To prevent loops in the filesystem, and to keep the interpretation of .. (parent directory) consistent, many modern operating systems do not allow hard links to directories. UNIX System V allowed them, but only the superuser had permission to make such links.

The Open Group Base Specifications Issue 7 (excerpt)

...Linking to a directory is restricted to the superuser in most historical implementations because this capability may produce loops in the file hierarchy or otherwise corrupt the file system. This volume of POSIX.1-2008 continues that philosophy by prohibiting link() and unlink() from doing this. Other functions could do it if the implementor designed such an extension...

Because there is no longer a system call like link() which don't checks the oldpath being a regular file the only way out may be creating a similar function to linkat() doing it your desired way.


After a bit of further research, I came up with the mkiosk addon

It has an option to show the navigation bar, you can set an admin password and you can achieve "no printing" by not installing CUPS at all:

sudo apt-get remove cups

In it's default setup, it has no admin password, so set up one. Also, you will need to change the home page to anything other than the default, in order to deny the access to the preferences, history etc. You can reach the mkiosk settings by hitting F1 on your keyboard and entering the admin password (the first time it does not have one).

I tested the addon fullscreen mode and that seems to work well. Give it a try.


The problem with this device is that it does two things: reading smartcards and handling fingerprint authorization.

The smartcard part works out of the box, hence the Ubuntu certification, but as far as I can tell there is zero support for the fingerprint reader and Broadcom has shown no interest in releasing specs for the device.  This means it won't be supported until someone goes through the trouble of reverse engineering the Windows driver.

Given how tepid the interest is for fingerprint readers on laptops I wouldn't hold my breath.


Try aliasing the network card eg: if it is currently eth0 in /etc/network/interfaces you can add an alias eg: br0 and set the network parameters for your internal network on this
Read The Documentation  Ubuntu Help Server Guide 12.04 - for further complete docs for your situation


Newly mounted disk space not recognised by DUA

It seems that you have added the added space as a new partition, sda3.
In /etc/fstab you are trying to mount sda3 as /, but you have already mounted sda1 on / earlier in fstab.

From your question it is not clear to me how you wanted to use your new disk space. But either you will have to mount sda3 on a valid mountpoint (an empty directory) or expand your existing / (root) file system. In the case you will have to:

Boot your system on a live media.
Start gparted
Delete sda3
Move the swap partition to the right into the free space
Expand sda1 to the right


Custom small sized wallpapers in Ubuntu 17.10

You may try using (GNOME) Tweaks. You may install it by running

sudo apt install gnome-tweak-tool

Launch Tweaks and go to Desktop section and select "Centered" in Adjustment under Background:

To fill the rest of your background with while colour, run

gsettings set org.gnome.desktop.background primary-color '#FFFFFF'

(Or follow the advanced option of my answer here:
Change background color to pitch black , for white you'll have to use #FFFFFF instead of #000000).


I found a workaround by adding the kernel parameters radeon.dpm=1 amdgpu.dpm=1:

Edit the file /etc/default/grub (e.g. by running sudo nano /etc/default/grub) and change the line starting with GRUB_CMDLINE_LINUX_DEFAULT to :

GRUB_CMDLINE_LINUX_DEFAULT="quiet splash radeon.dpm=1 amdgpu.dpm=1"

After that, update GRUB configuration using

sudo update-grub

and reboot for the changes to take effect.


Nautilus can't mount Active Directory share

Until I find a better fix, I've decided to forget about mounting network shares in Nautilus, and to use a script to do a standard mount instead. I include the script, if anyone's interested:

    #!/bin/bash
    echo Enter network user:
    echo -n "Name [$USER]: "
    read USR
    if [ "$USR" = "" ]; then
        USR="$USER"
    fi
    echo -n "Password: "
    read -s PWD
    echo

    SERVER="your server name here"
    SHARES="your share names here"

    for SHR in $SHARES; do
        ERR=$(sudo mount -t cifs -o rw,username=$USR,password=$PWD,uid=$USER //$SERVER/$SHR ~/Shares/$SHR 2>&1)
        if [ "$ERR" = "" ]; then
            ERR="OK"
        fi
        echo $SHR: $ERR
    done


How to configure iptables file to allow only specific ipaddress on all port and deny all other ipaddress?


LTSP doesn't really care about the network as long as it can PXE boot. Unfortunately the idea of netbooting off of a wireless network is just something that isn't generically supported across multiple vendors, this seems to suggest that certain hardware supports it:

https://superuser.com/questions/310915/is-possible-to-boot-on-pxe-over-a-wifi-device

I've set up LTSP on a normal ethernet network, and even those "ethernet over power" 200mbit devices, which happen to support PXE just fine. The superuser question mentions some support for this on macs, so maybe a good place to start investigating is if LTSP supports or can support this:

  Apple has built drivers for those Wi-Fi chipsets, as well as a UI for joining a Wi-Fi network, into the EFI bootROM on those models. As far as I know this is an Apple proprietary scheme, not PXE-based.

One thing you might want to investigate is scripting logging into a remote LTSP server from the local Macs, they wouldn't be true "thin clients" would it would get you up and running.

Still, having deployed LTSP at a school, if you're doing this at scale (I did about 200 clients) you'll want/need a very fast gigabit network anyway; if you have rooms worth of laptops that you were hoping could all hop on the WiFi and get a full remote desktop with great performance, then that's really not going to happen anyway.


Why is my battery indicator wrong on Samsung Series 9?

It seems you are a victim of a known acpi bug (see here).  Some users report that powering down and disconnecting the battery (pinhole on the underside of the notebook) temporarily fixes the problem, as does upgrading the BIOS.  But the problem eventually comes back.  I know of no permanent workaround at the present time.

There is also a Kernel bug report about this (it is not Ubuntu specific) here.


You probably won't find a CD that will (naturally) support that size file, and overburning isn't recommended due to issues.

I'd recommend using a DVD instead, or if that's not an option, a USB drive.

EDIT: I'd emphasize trying to get a DVD... I personally had many issues with using my 8 GB USB drive.  The first time I attempted a DVD install was fully successful.


How do I know what sound system is being used?

Different applications can make use of different "sound systems".  For some applications, you can choose the sound backend at run time (e.g., via a preference setting); for other, this has to be a compile-time choice (therefore, it's up to the package maintainer to select one).

Applications that come in the main Ubuntu repository have been compiled with PulseAudio support, so you can control the sound inputs and outputs via System -> Preferences -> Sound or padevchooser.

Still, some applications do not support PulseAudio and only offer a choice of ALSA/OSS: older versions of Skype and Adobe Flash are the primary example, but also the free music player Aqualung.

So, in the end, the answer is: it's application-specific, and you might need to dig into the application preferences or upgrade/recompile to get them working the way you want.


Ubuntu 16.04 shut down goes to log screen (always after suspend)

The same solution to this question worked for the question here, essentially do this:

sudo apt install ecryptfs-utils --reinstall
sudo update-grub


What's the "right thing to do" when latest version of some gnu software is not available via apt-get

You can build it from source using checkinstall, read this wiki page for details: https://wiki.debian.org/CheckInstall

TL;DR checkinstall creates a .deb package, which you can then uninstall either via apt or dpkg.


How to get a recursive ftp directory listing without write permissions?

Apparently you can pipe a command directly to ftp:

echo "ls *" | ftp hostname > ls.txt

Make sure to quote ls * somehow or to disable globbing otherwise * will expand in the current shell.


What to do when ubuntu 16.04 LTS stops responding

Try to use virtual console by command:

ctrl + alt + F1

here you can check your processes by top command.

Exit from console: ctrl + alt + F8


Should I be asked for my password when a bug report is sent?

Sometimes, but not usually.
Reporting Crashes in System Processes
Most of the time when an application crashes or you report a bug manually, you don't have to put in a password for information to be automatically gathered and sent to Launchpad.
However, when a program or service that runs as root crashes, collecting data about that crash requires accessing data that is only accessible as root. In Ubuntu, you can perform actions as root by authenticating with your password, provided that your account has administrative capabilities. (This is facilitated by sudo or one of its graphical frontends, or by PolicyKit.) If your account does not have administrative capabilities, then you will not be prompted to report a crash in a root-owned process until you log in with an account that has administrative capabilities.
When you're logged in as an administrator and you're prompted to report a crash in a root-owned process, you see a password dialog like this:

This is one of the two situations where you may have to enter a password to report a bug in Ubuntu.
Once you've authenticated, then the crash-reporting process continues the same way as for regular non-root processes.
Filing Bug Reports for Crashes
Before Ubuntu 12.04 LTS, when Apport crash reporting was enabled, you would be asked to submit a bug report to contain the data gathered automatically. This is still what happens in alpha and beta versions of Ubuntu (and versions before 12.04 LTS). But starting with Ubuntu 12.04 LTS, Apport is set up by default so that, if you are running a stable version of Ubuntu and a crash occurs, it will automatically (with your permission) submit the information to a database that doesn't require you to fill out a bug report. This is potentially less useful than having a bug report, but it means that information can effectively be gathered from many more users--plus, bug reports are often most valuable for alpha and beta releases where the bugs are more likely to be fixed as a result of the report.
However, if you re-enable bug filing for crashes, or you report a bug by invoking ubuntu-bug manually with a package name or process ID, then you will be given the opportunity to file a bug report. Bug reports in Ubuntu are filed on Launchpad. So once data for the bug are collected and submitted to Launchpad, a Launchpad page to file the bug report with those data automatically attached will appear in a web browser. (Unless your default web browser doesn't work and that's what the bug is about, of course.)
If you're not logged in to Launchpad, then you'll be brought to the Launchpad sign-in page in your web browser, to report the bug. This is the second of the two situations where you may have to enter a password, to report a bug in Ubuntu.


How to install applications by default to another drive

Is it as simple as partitioning /usr/, /lib/, and /bin/ to another disk?

Yes. And maybe /var/, /etc/ and /opt/ too (depending on usage).

I would not bother. The only 3 things I would leave of the SSD are tmp filesystems, swap and the directories inside your users /home/. The 1st 2 you do during mounting. The 3rd you can do by editing /home/$USER/.config/user-dirs.dirs.


When it starts booting press esc to stop it for a while, and then press F6 to turn on nomodoset

I have the same laptop as you and it works fine.


Compiz does have interactive effects like water, writing in fire, and snow. If you have the graphics for it look into it-
CompizFusion

Also this may help,
http://ubuntuforums.org/showthread.php?t=1099655 says that xwinwrap could be used to diplay movies or screensavers.

Here they say there might be some for KDE,
http://ubuntuforums.org/showthread.php?t=1073107&page=2

Just recently found that you can run VLC in wallpaper mode, How do I set a VLC instance to run as a Live Wallpaper


Can't start without X server in order to install video drivers

Ubuntu 11.10 uses lightgdm and not gdm.

i had to do this once and used sudo stop lightdm & sudo start lightgdm


Catkin_make fails while compiling UVC Camera at 25%

The Raspberry Pi is running out of CPU power. Run catkin_make -j1 to create fewer threads. This will prevent the Pi from crashing.


Well , I'm running Ubuntu 12.10 and I remove firefox 17 to install firefox 16.0.2.
You can try this:

Open a terminal and type: cd /var/cache/apt/archives
Search for the Firefox's 16 deb packages eg:  ls -l | grep 'firefox' | grep
'16.0.02'
In my case I have 4 deb package for firefox 16

 4. Now, I removed firefox 17 with: sudo apt-get remove firefox

 5. Finally I installed the firefox 16 packages with:

sudo dpkg -i `ls -l | grep 'firefox' | grep '16.0.2' | awk '{print $9}' | xargs`

Or once you have the list with the firefox 16 deb packages , you can  install each .deb package with sudo dpkg -i packagename.deb

Hope this will helpful.

Regards.


Two interfaces - internet access problem

System can have only one gateway at the moment. Only can you do is to force some traffic aka ssh, ftp, .. or to specific network to go on different interface

Route traffic to specific port via specific interface

Example:

Here we shall take port 4444 as the service for routing. Use mangle table of iptables for modifying the 4444 packets.

sudo iptables -t mangle -A OUTPUT -p tcp –dport 4444 -j MARK –set-mark 0×1

We are marking all packets with destination port 4444 as ’0×1′ .

To delete this entry from iptables we can use -D instead of -A.

Next, create a new IP route table in /etc/iproute2/rt_table by just giving an entry

100 4444table

Write rule for 4444 packets.

ip rule add fwmark 0×1 lookup 4444table

Add route at new table 4444table. Here we shall use ’192.168.1.1′ as the gateway for 4444.

We copy all entries except default gateway entry from main table.

sudo ip route show table main | grep -Ev ^default | while read ROUTE ; do ip route add table 4444table $ROUTE; done

Add default gateway entry for 4444 packets to table 4444table

sudo ip route add default via 192.168.1.1 table 4444table

Use ip route show table 4444table to show all routes at 4444table.

Or routing by destination

Destination ip 132.45.65.60

Again use mangle table of iptables for modifying the packets for 132.45.65.60

sudo iptables -t mangle -A OUTPUT -d 132.45.65.60 -j MARK -set-mark 0×1

We are marking all packets router to ip 132.45.65.60 as ’0×1′ .

Now save and restart iptables.

service iptables save
service iptables restart

Next, create a new IP route table in /etc/iproute2/rt_tables by just giving an entry

100 132table

Write rule for packets to destination ip 132.45.65.60

ip rule add fwmark 0×1 lookup 132table

Add route at new table 132table. Here we shall use 192.168.1.1. All other traffic will go through the default gateway.

Copy all entries except default gateway entry from main table.

sudo ip route show table main | grep -Ev ^default | while read ROUTE ; do ip route add table 132table $ROUTE; done

Add default gateway entry for 132.45.65.60 packets to table 132table

 sudo ip route add default via 192.168.1.1 table 132table

Edit 1

If you have to set metric aka with metric interface without metric have "priority"

auto eth0
  iface eth0 inet static
    address 192.168.1.202
    netmask 255.255.255.0
    gateway 192.168.1.1

auto eth1
  iface eth1 inet static
    address 10.10.0.10
    netmask 255.255.255.0
    gateway 10.10.0.1
    metric 800

With this setup if available default gateway will be 192.168.1.1 and traffic will go trough eth0. When you do ifdown eth0 or disconnect cable from eth0, second best will be gateway 10.10.0.1 with metric 800 and traffic will go trough eth1. When you connect cable or ifup eth0 default gw will be again 192.168.1.1.

Like I say.

System can not have two default gateways in one moment. If have network will not work.


Whenever I try to update my apps, I get an error message and it tells me to try apt --fix-broken install

https://bugs.launchpad.net/ubuntu/+source/libglvnd/+bug/1791542

You can either wait for the fix or update as per the link.

The nvidia-340.106 driver will be updated to 340.107


Is there a way to write to .ods files from Command line?

.ods files are binary so you can't use a text editor as you'd like.  There is another possibility you might consider, but it is not free (albeit fairly cheap).

If you get insync, it can sync a folder with google drive.  One of it's very nice features is it can convert .ods files to-and-from Google spreadsheets.

I do this currently.  When I want to run calc locally, I do that.  When I want to make a quick tweak or am on the road, I use Google to make the edit.

I'm not sure what etiquete here is for posting product links, so if you google for "insync google drive" you can find it.


If you try to connect on a tab that is already connected,
FileZilla should ask you if you want to abort current connection or establish a new one in a new tab.

There are two options to open new tab explicitly

File > New Tab
Keyboard shortcut: CTRL(control) + T

Tested on Ubuntu 17.

Other OS: This also works on Windows, on Mac it may be Cmd ⌘ + T


There is a package called laptop-mode-tools, which allows extending the life of battery. Another one is pm-powersave from pm-utils package. You can get either with

sudo apt-get install laptop-mode-tools

or

sudo apt-get install pm-utils

pm-powersave is mostly command line, have to be enabled with sudo pm-powersave true. laptop-mode-tools has a graphical front-end to it, written in PyQT.

For more info on both , check out this and this.


Install the following tools in Ubuntu to enable MTP support

sudo apt-get install mtp-tools mtpfs

On your Android phone, go to Settings->Storage.

Click the menu on the top right and go to USB Computer Connection. Select Media Device(MTP).

Now you should be able to access your phone storage.


Suspend not working due to backlight issue

I was able to find info on this problem here. I resolved the issue on my system (HP Pavilion m6-1035dx w/ AMD Trinity A10-4600M APU) by creating a file /etc/pm/config.d/radeon containing the following:

QUIRK_S3_BIOS="true"
QUIRK_S3_MODE="true"

Then reboot.

If this doesn't resolve the problem for you, then check out the link that I gave at the top.


Installed Ubuntu 12.04 LTS 64-bit results in 32-bit OS

From the output of uname -a, it was clearly shown that you had installed Ubuntu 32 bit.

3.11.0-18-generic #32~precise1-Ubuntu SMP Thu Feb 20 17:54:21 UTC 2014 i686 i686 i386 GNU/Linux


Force Samba to Require Credentials from Windows Client

I can think of one scenario where this could happen:

[1] You created a user on your samba server named: luca

[2] That user name also exists on Windows.

[3] You made the samba password for luca match the login password for luca on the Windows box.

Windows smb clients always pass the current users login user name and password when they access a server - it does this automatically. It's not that your share didn't require credentials it's that they were passed and accepted already.

The second part of the question about edit permissions - change your share definition to this:

[xshare]
      comment = X's Samba Share
      path = /home/x/share
      read only = no
      browsable = yes
      valid users = x, luca
      force user = x

The share will allow access to x and luca only but once they are in everything they do will be as user x - for that share. Note: I removed the "security = user" option from your share definition becase it belongs in the [global] section.


You would log the traffic with

sudo iptables -I OUTPUT 1 ! -d 10.0.101.0/24 -j LOG

Change "10.0.101.0/4" to your netmask

Keep in mind, order is important in iptables, so you may need to put the log in another location or add logs for routing (POSTROUTING), as you wish.

Also keep in mind that this is going to fill your logs. Unless you plan to monitor the logs you may wish to use an alternate method, such as snort (you can configure snort to alert you to certain traffic) or a http proxy (squid if you in a large organization).

You may want to limit your logs

sudo iptables -I OUTPUT 1 ! -d 10.0.101.0/24 -m limit --limit 5/min -j LOG

See also https://help.ubuntu.com/community/IptablesHowTo


Screwed up system by installing both open jdk 8 and open jdk 9

Try selecting proper versions by running these commands:

sudo update-alternatives --config java
sudo update-alternatives --config javac


Errors running apt-get update after upgrading to 11.10

Found here

  Here's the (easiest) solution:

  Type the following commands in the Terminal:

$ sudo -i
# apt-get clean
# cd /var/lib/apt
# mv lists lists.old
# mkdir -p lists/partial
# apt-get clean
# apt-get update

  Credits: ubuntugeek.com


HP ProBook 4540s is overheating while using Ubuntu

Install your display driver....
I have the same laptop with AMD Radeon HD 7650M 1GB VGA. Go to the System Settings> Additional Drivers, and install the graphics diver, if you are using AMD hardware like me.
This should work also if you have a Nvidia card.


Lubuntu 17.04 xrdp. Can connect from network. No remote access

You can try to use the following step by step guide (http://c-nergy.be/blog/?p=10365). This one is for Lubuntu 16.10 but should be valid for Lubuntu 17.04.

In short,

install the xrdp package by issuing the following command
sudo apt-get install xrdp
From command line, issue the following command
echo "lxsession -s Lubuntu -e LXDE" >~/.xsession
Optional - restart your machine and give it a try

Hope this help
Till next time
See ya


Custom Ubuntu 16.04 Installer with Pinguy Builder Cannot log in using Live CD

This Solved it for me:

The problem is that VirtualBox sets up users (vbox_sf for shared folders) as userid 999. But casper (the app that controls the "live cd system") hard codes the Pinguy Builder userid as 999 also! So this means that the "live" user isn't ever created (since 999 already exists!). The solution is to give a different uid to the casper created user.

This terminal command will make the change for you automagically:

sed -i -e 's@user-uid [0-9]*@user-uid 990@' /usr/share/initramfs-tools/scripts/casper-bottom/25adduser

To interpret this command, in the 25adduser file, I am changing "user-uid 999" to "user-uid 990". You can just manually make that edit if you want but thought others may enjoy the sed one-liner to do it automagically.

After this fix, I am no longer faced with the "login screen" when starting the live system: it auto-logs-in just as it should!

There really should be a casper patch to move away from the hard-coded uid, maybe it could be a Pinguy Builder variable in /etc/PinguyBuilder.conf but for now the hack to change that uid to something OTHER THAN 999 seems to work!

Reference: http://disq.us/p/12n951t


No sound in shadow-grounds survivor ? (64bit)

I am guessing you have 64 bit Ubuntu installed. If so, open a terminal and type:

cd Installfolderlocation/survivor/lib32/

obviously replace "Installfolderlocation" with the path you chose to install the game to.

mv libasound.so.2 libasound.so.2_old
ln -s /usr/lib32/libasound.so.2 libasound.so.2

These commands will rename a sound library shipped with the Game, and replace it with a symlink to the corresponding library shipped with Ubuntu.

Sound should work afterwards. (Tested on Ubuntu 11.04 64bit.)


Upgrade 20.04 to 20.10 fails, missing updates

You're on an LTS (long time support) version. There is some safety built in the system that you don't inadvertently upgrade to a non-LTS version.
To overrule this, just for this upgrade, do:
sudo nano /etc/update-manager/release-upgrades

and change Prompt=lts to Prompt=normal.
Then do sudo do-release-upgrade and your upgrade should proceed normally.


How to add /var folder to Ubuntu One storage to sync?

Ubuntu One only syncs folders that are in your /home, by design. Multiple reasons exist, including that Ubuntu One does not need super user rights, or to avoid messing with how programs are installed.


Why does 'quickly package' fail with "An error has occurred when creating debian packaging"?

You are probably using a version of the python-distutils-extra package from the precise-proposed pocket in the archive, that is newer than the stable release and that it is known to cause trouble with the latest Quickly version.

Try to downgrade it by running the following command, and then re-run the Quickly packaging command:

sudo apt-get install python-distutils-extra=2.32-2


The two other common locations for modules that I've seen are:
/opt/local/lib/node_modules
/usr/local/include/node_modules

Hopefully one of those two contain the web pack you're looking to remove. If not, search the file system:
sudo find / -iname "node_modules" -type d

This will list all directories named node_modules. Using -iname makes the search case-insensitive.


Where do I get the update-java-alternatives command. What package does it come from?

The update-java-alternatives command is in the java-common package. Red Hat systems don't seem to have it.

By the way, if you ever want to use a command but you don't know what package provides it, try installing apt-file and use its searching powers.


You may need gcc which allows you to compile code.

sudo apt-get install gcc should help. sudo apt-get install build-essential might also be required. I'll admit I'm no expert with this! but the error suggests missing packages.


I know this was several months ago, but it comes up as about the first google result.

I bet you it's the classic issue that you need to add your user to the vboxusers group.
If it isn't, it needs to be, add it, log out and back in again and it should work.


The Ubuntu 18.04 ISO file can be downloaded from the official Download Ubuntu Desktop webpage or from the terminal using the following command:

wget -c http://releases.ubuntu.com/18.04/ubuntu-18.04-desktop-amd64.iso

The name of the official Ubuntu ISO file is ubuntu-18.04-desktop-amd64.iso. I prefer using wget to download the Ubuntu ISO file because it automatically resumes interrupted downloads from the same place when the download was interrupted, so you never need to download anything twice if there is a temporary glitch in internet connectivity.

Maybe 18.04_Live_x64 is an ISO file already, and you can rename it to 18.04_Live_x64.iso and then burn a DVD. To avoid wasting a DVD, try renaming it to 18.04_Live_x64.iso and then making a bootable Ubuntu 18.04 live USB flash drive using the built-in Startup Disk Creator application. If the Ubuntu 18.04 live USB flash drive boots successfully then it's OK to either burn a DVD from 18.04_Live_x64.iso with the Brasero DVD burner application or else use the Ubuntu 18.04 live USB flash drive to install Ubuntu 18.04.


Use old installable usb and lots of updates or a new installable usb?

Use the existing USB to install  Ubuntu 14.04 and update Ubuntu 14.04 immediately after installing it to install the security updates. There will be less total megabytes to download that way.


I use this GPU in my machine (dual boot windows and Ubuntu) but do not play any games with it (I leave that to Windows for now). I don't have any issues with over heating or glitches, everything is smooth; the fans seem to spin up when warm and down when cool so everything should be fine for you.


How do I create systemd service unit configuration file for MySQL server?

Service files are actually in /etc/systemd/system rather than /usr/lib/systemd/system

If you want to find out why your service is failing you can either try systemctl status mysqld or for a more complete log look into the journalctl command e.g. journalctl -u mysqld -S today.


Cannot seek mkv files in Totem Ubuntu 14.04

Try installing ubuntu restricted extras if you have not already

sudo apt-get install ubuntu-restricted-extras

 Also check this


Using Modifiers of Perl-compatible Regex (PCRE) in grep

For the modifiers imsxadlup you can use the (?X) for as described in Extended Patterns:

$ echo FOO | grep -P '(?i)foo'
FOO


I run two DHCP servers in one subnet at home (in case one box is not available).

In /etc/dhcp3/dhcpd.conf on the server I declare as the primary I have this:

failover peer "dhcp-failover" {
  primary; # declare this to be the primary server
  address 10.11.12.1;
  port 647;
  peer address 10.11.12.2;
  peer port 647;
  max-response-delay 30;
  max-unacked-updates 10;
  load balance max seconds 3;
  mclt 1800;
  split 128;
}

And in /etc/dhcp3/dhcpd.conf on the server I declare as the secondary I have this:

failover peer "dhcp-failover" {
  secondary; # declare this to be a secondary server
  address 10.11.12.2;
  port 647;
  peer address 10.11.12.1;
  peer port 647;
  max-response-delay 30;
  max-unacked-updates 10;
  load balance max seconds 3;
}

Hope that helps.


How to get exit status of anacron jobs to catch errors?

It is possible to get exit status from syslog.

To get all anacron log lines:

grep 'anacron' /var/log/syslog

To get only anacron log lines from failed jobs:

grep -E 'anacron.*exit status' /var/log/syslog


Problem installing reader software for Estonian ID card for ubuntu 14.04

The error message means that you, literally, tried to execute the install-esteid-ubuntu.sh script as root user. Obviously so, because you prepended sudo to the command:

sudo sh install-esteid-ubuntu.sh

Instead try the following command, as mentioned in the official installation instructions:

sh install-esteid-ubuntu.sh

This should then successfully start the script, and the script will ask you for the superuser password when it wants to run individual commands as a superuser. It will need that, but will buckle if you want to pre-emptively run the whole thing as superuser …


To have partition with documents automounted during boot, you should have partition entry in your /etc/fstab file. Let me assume that you have / on /dev/sda1, swap on /dev/sda2 and Documents partition on /dev/sda5. Then your /etc/fstab should look like this:

# /etc/fstab: static file system information.
#
# Use 'blkid' to print the universally unique identifier for a
# device; this may be used with UUID= as a more robust way to name devices
# that works even if disks are added and removed. See fstab(5).
#
#
# / was on /dev/sda1 during installation
UUID=b632398e-9f06-46f7-8fe9-3e61266354a6 /               ext4 notail          0       1
# swap was on /dev/sda2 during installation
UUID=b1585d95-2256-474d-87ba-ed797c7b8845 none            swap    sw              0       0
/dev/fd0        /media/floppy0  auto    rw,user,noauto,exec,utf8 0       0

To make Documents partition automount during boot, you have to add such entry there:

/dev/sda5 /mnt/Stuff  ext4 defaults,uid=1000,gid=46          0       0

If you have UUID of /dev/sda5, it is preferrable to put UUID= instead of /dev/sda5 on the first position. uid and gid are numeric IDs of your user account (usually 1000) and group plugdev (always 46). You can omit these options since defaults already contains needed permissions.

Now, when your drive is mounted, you can make symbolic link to your documents:

mv ~/Documents/* /mnt/Stuff/Documents
rmdir ~/Documents
ln -sd /mnt/Stuff/Documents ~/Documents

Hope this helps.


Ubuntu 12.10 upgrade and web app do not work

There are a lot of people who can't get the web apps to work, and it has already been reported on Launchpad: https://bugs.launchpad.net/ubuntu/+source/webapps-applications/+bug/1068662


I can't connect to localhost from other computers

Thank you everyone, I think it was the firewall, by disabling the firewall as given in the site https://help.ubuntu.com/12.04/serverguide/firewall.html with the command:

sudo ufw disable

I could open the index page from mobile.


Check your M4A file with this command:

file /path/to/file.m4a

The output should look something like this:

ISO Media, MP4 v2 [ISO 14496-14]

If this is so, then you are missing the codec ubuntu-restricted-extras.

Install the package with this command:

sudo apt-get install ubuntu-restricted-extras

Then try again.


How to get the Input and output in a terminal to a text file?

You can use script to make typescript of terminal session. It will record all the inputs and output to a file. To start recording type in terminal,

$ script

Go on doing your regular job. To end the recording use Ctrl+D. All the typescript will be saved in the file typescript located at the directory where you opened the terminal.

To save all the log in your desired file, use

$ script /path/to/mylogfile.txt

Usually script comes with default Ubuntu installation.


I need a file: /etc/apache2/sites-available/default-ssl

Ask and ye shall receive.

<IfModule mod_ssl.c>
<VirtualHost _default_:443>
        ServerAdmin webmaster@localhost

        DocumentRoot /var/www
        <Directory />
                Options FollowSymLinks
                AllowOverride None
        </Directory>
        <Directory /var/www/>
                Options Indexes FollowSymLinks MultiViews
                AllowOverride None
                Order allow,deny
                allow from all
        </Directory>

        ScriptAlias /cgi-bin/ /usr/lib/cgi-bin/
        <Directory "/usr/lib/cgi-bin">
                AllowOverride None
                Options +ExecCGI -MultiViews +SymLinksIfOwnerMatch
                Order allow,deny
                Allow from all
        </Directory>

        ErrorLog ${APACHE_LOG_DIR}/error.log

        # Possible values include: debug, info, notice, warn, error, crit,
        # alert, emerg.
        LogLevel warn

        CustomLog ${APACHE_LOG_DIR}/ssl_access.log combined

        Alias /doc/ "/usr/share/doc/"
        <Directory "/usr/share/doc/">
                Options Indexes MultiViews FollowSymLinks
                AllowOverride None
                Order deny,allow
                Deny from all
                Allow from 127.0.0.0/255.0.0.0 ::1/128
        </Directory>

        #   SSL Engine Switch:
        #   Enable/Disable SSL for this virtual host.
        SSLEngine on

        #   A self-signed (snakeoil) certificate can be created by installing
        #   the ssl-cert package. See
        #   /usr/share/doc/apache2.2-common/README.Debian.gz for more info.
        #   If both key and certificate are stored in the same file, only the
        #   SSLCertificateFile directive is needed.
        SSLCertificateFile    /etc/ssl/certs/ssl-cert-snakeoil.pem
        SSLCertificateKeyFile /etc/ssl/private/ssl-cert-snakeoil.key

        #   Server Certificate Chain:
        #   Point SSLCertificateChainFile at a file containing the
        #   concatenation of PEM encoded CA certificates which form the
        #   certificate chain for the server certificate. Alternatively
        #   the referenced file can be the same as SSLCertificateFile
        #   when the CA certificates are directly appended to the server
        #   certificate for convinience.
        #SSLCertificateChainFile /etc/apache2/ssl.crt/server-ca.crt

        #   Certificate Authority (CA):
        #   Set the CA certificate verification path where to find CA
        #   certificates for client authentication or alternatively one
        #   huge file containing all of them (file must be PEM encoded)
        #   Note: Inside SSLCACertificatePath you need hash symlinks
        #         to point to the certificate files. Use the provided
        #         Makefile to update the hash symlinks after changes.
        #SSLCACertificatePath /etc/ssl/certs/
        #SSLCACertificateFile /etc/apache2/ssl.crt/ca-bundle.crt

        #   Certificate Revocation Lists (CRL):
        #   Set the CA revocation path where to find CA CRLs for client
        #   authentication or alternatively one huge file containing all
        #   of them (file must be PEM encoded)
        #   Note: Inside SSLCARevocationPath you need hash symlinks
        #         to point to the certificate files. Use the provided
        #         Makefile to update the hash symlinks after changes.
        #SSLCARevocationPath /etc/apache2/ssl.crl/
        #SSLCARevocationFile /etc/apache2/ssl.crl/ca-bundle.crl

        #   Client Authentication (Type):
        #   Client certificate verification type and depth.  Types are
        #   none, optional, require and optional_no_ca.  Depth is a
        #   number which specifies how deeply to verify the certificate
        #   issuer chain before deciding the certificate is not valid.
        #SSLVerifyClient require
        #SSLVerifyDepth  10

        #   Access Control:
        #   With SSLRequire you can do per-directory access control based
        #   on arbitrary complex boolean expressions containing server
        #   variable checks and other lookup directives.  The syntax is a
        #   mixture between C and Perl.  See the mod_ssl documentation
        #   for more details.
        #<Location />
        #SSLRequire (    %{SSL_CIPHER} !~ m/^(EXP|NULL)/ \
        #            and %{SSL_CLIENT_S_DN_O} eq "Snake Oil, Ltd." \
        #            and %{SSL_CLIENT_S_DN_OU} in {"Staff", "CA", "Dev"} \
        #            and %{TIME_WDAY} >= 1 and %{TIME_WDAY} <= 5 \
        #            and %{TIME_HOUR} >= 8 and %{TIME_HOUR} <= 20       ) \
        #           or %{REMOTE_ADDR} =~ m/^192\.76\.162\.[0-9]+$/
        #</Location>

        #   SSL Engine Options:
        #   Set various options for the SSL engine.
        #   o FakeBasicAuth:
        #     Translate the client X.509 into a Basic Authorisation.  This means                                                                              that
        #     the standard Auth/DBMAuth methods can be used for access control.                                                                               The
        #     user name is the `one line' version of the client's X.509 certific                                                                             ate.
        #     Note that no password is obtained from the user. Every entry in th                                                                             e user
        #     file needs this password: `xxj31ZMTZzkVA'.
        #   o ExportCertData:
        #     This exports two additional environment variables: SSL_CLIENT_CERT                                                                              and
        #     SSL_SERVER_CERT. These contain the PEM-encoded certificates of the
        #     server (always existing) and the client (only existing when client
        #     authentication is used). This can be used to import the certificat                                                                             es
        #     into CGI scripts.
        #   o StdEnvVars:
        #     This exports the standard SSL/TLS related `SSL_*' environment vari                                                                             ables.
        #     Per default this exportation is switched off for performance reaso                                                                             ns,
        #     because the extraction step is an expensive operation and is usual                                                                             ly
        #     useless for serving static content. So one usually enables the
        #     exportation for CGI and SSI requests only.
        #   o StrictRequire:
        #     This denies access when "SSLRequireSSL" or "SSLRequire" applied ev                                                                             en
        #     under a "Satisfy any" situation, i.e. when it applies access is de                                                                             nied
        #     and no other module can change it.
        #   o OptRenegotiate:
        #     This enables optimized SSL connection renegotiation handling when                                                                              SSL
        #     directives are used in per-directory context.
        #SSLOptions +FakeBasicAuth +ExportCertData +StrictRequire
        <FilesMatch "\.(cgi|shtml|phtml|php)$">
                SSLOptions +StdEnvVars
        </FilesMatch>
        <Directory /usr/lib/cgi-bin>
                SSLOptions +StdEnvVars
        </Directory>

        #   SSL Protocol Adjustments:
        #   The safe and default but still SSL/TLS standard compliant shutdown
        #   approach is that mod_ssl sends the close notify alert but doesn't wa                                                                             it for
        #   the close notify alert from client. When you need a different shutdo                                                                             wn
        #   approach you can use one of the following variables:
        #   o ssl-unclean-shutdown:
        #     This forces an unclean shutdown when the connection is closed, i.e                                                                             . no
        #     SSL close notify alert is send or allowed to received.  This viola                                                                             tes
        #     the SSL/TLS standard but is needed for some brain-dead browsers. U                                                                             se
        #     this when you receive I/O errors because of the standard approach                                                                              where
        #     mod_ssl sends the close notify alert.
        #   o ssl-accurate-shutdown:
        #     This forces an accurate shutdown when the connection is closed, i.                                                                             e. a
        #     SSL close notify alert is send and mod_ssl waits for the close not                                                                             ify
        #     alert of the client. This is 100% SSL/TLS standard compliant, but                                                                              in
        #     practice often causes hanging connections with brain-dead browsers                                                                             . Use
        #     this only for browsers where you know that their SSL implementatio                                                                             n
        #     works correctly.
        #   Notice: Most problems of broken clients are also related to the HTTP
        #   keep-alive facility, so you usually additionally want to disable
        #   keep-alive for those clients, too. Use variable "nokeepalive" for th                                                                             is.
        #   Similarly, one has to force some clients to use HTTP/1.0 to workarou                                                                             nd
        #   their broken HTTP/1.1 implementation. Use variables "downgrade-1.0"                                                                              and
        #   "force-response-1.0" for this.
        BrowserMatch "MSIE [2-6]" \
                nokeepalive ssl-unclean-shutdown \
                downgrade-1.0 force-response-1.0
        # MSIE 7 and newer should be able to use keepalive
        BrowserMatch "MSIE [17-9]" ssl-unclean-shutdown

</VirtualHost>
</IfModule>


Old versions of BackInTime (< 1.1.0) where a bit tricky if you want to restore files on a different machine (with different host/user name). Please install the current version from our PPA. This is much more user friendly. It comes with a restore function for the config and won't need to trick the host/user name anymore.

Open a Terminal with CTRL+ALT+T and type:

sudo add-apt-repository ppa:bit-team/stable
sudo apt-get update
sudo apt-get install backintime-qt4

Now you can either restore the old config with the Restore Config button in Settings or just delete the current config (rm ~/.config/backintime/config in Terminal). BackInTime will automatically search for the old config on next start.


How to make Ubuntu detect headphones without the "Select Audio Device" prompt every time?

As someone pointed out in the comments, there's a GNOME extension for this and after searching a bit, I found it in this answer, and the extension is available here


Ubuntu 12.04 boot-repair gets in infinite loop

First, disable Secure Boot in your firmware. That might enable you to boot the live CD (or installer, for that matter) in EFI mode.

If that doesn't help, then I recommend you try my rEFInd boot manager. This lowest-risk way to do this is to download the USB flash drive or CD-R image and try booting from it. It should give you options to boot both Windows and Ubuntu. If both work, boot into Ubuntu and then install the Debian-package version of rEFInd. It should then launch from the hard disk when you restart the computer in EFI mode.


Please follow the instructions here to create a ssh key and upload to your Ubuntu account. While taking ownership of the device with the Ubuntu One email address (during first boot), your account name will be used to setup a new user with your ssh key as your login credential.


Delete Ubuntu Desktop With Applications Ubuntu 18.04

sudo apt install ubuntu-unity-desktop

Answer yes to the question for lightdm default.

sudo shutdown -r now

Remove GDM and restore automatic login

sudo apt remove gnome-shell

Restart the computer

If you choose automatic login, go in user account, unlock and set the switch off and on again. Lock user account and restart.

unity --version


It worked with gedit.

gedit ~/.bashrc brought up the bashrc file from which I was able to remove those lines. Upon saving and opening a new terminal, I could see no such lines.


S/PDIF Input won't play(Fender Mustang Micro plugged in via USB)?

Usually there is an application of some type used between the input signals and the output signals of the audio subsystems of the computer.  This can be something as simple as
arecord -t wav | aplay -t wav

which should pull a wav type stream from the standard input to the standard output.
More complex solutions provide possibilities to do many other things.  Using Audacity one could get the input signal, record it, apply effects to the sound, and play it back.  More complex applications might involve jack to route the sound signal through the computer, and a DAW sign as Ardour or LMMS to process the sound signal.


How does one remove a certificate authority's certificate from a system?

Run

sudo dpkg-reconfigure ca-certificates

That should give you a list where you can deselect CAs.

The list of CAs is stored in the file /etc/ca-certificates.conf. If you edit this file manually you need to run

sudo update-ca-certificates

to update the actual certificates in /etc/ssl/certs/ (if you use dpkg-reconfigure that is done automatically).

See /usr/share/doc/ca-certificates/README.Debian for more information.


Cannot get a meaningful response to the command 'gem list '

Oh, the header:

*** LOCAL GEMS ***

always displays. If you have no gems installed, that is all that displays.
If you have any gems installed, they will be listed below this header.
(Discovered this by trying the same command on a different system -
evidently I had no gems installed in the Ubuntu system - thought I did).


Data doesn't get transferred correctly to USB, why?

It sounds like (given your description of fast transfers) that it's copying through a buffer but that hasn't been flushed to disk before you unplug it. This is fairly common.

You can force all your system disks to sync with their buffers by running sync. This is a blocking command so you won't be able to type while it's working.

"Safely Eject Device" (or however that's worded) should be running a sync (that's what it means) but if you are using that, it sounds like that isn't working and you should report a bug.


How do I revert from the nvidia-381 driver to xserver-xorg-video-nouveau?

I am not sure if it is the most efficient method but this is what I did.

1) Use ubuntu live usb  to download the  latest driver from NVIDIA and save the file in the disk on your computer.

2)Reboot into recovery to root terminal.

3)sudo apt-get remove nvidia*

4)cd to the place where you have saved the driver

5)chmod 777 NVIDIA-Linux-{version}.run

6)$ sudo sh NVIDIA-Linux-{version}.run

This is what worked for me.


Bootloader/Grub can't boot but recovery works but still can't boot

SD cards are accessed by circuitry on the computer's motherboard (or an SD card reader attached by USB, etc.). This circuitry requires drivers, and not all of them are well-supported in Linux. The nature of your error smells to me like a buggy driver. If so, you may just have to live with it until a driver fix is released. Filing a bug report may help, but you'll need to be very specific about what type of hardware you've got. (Typing sudo lshw > lshw.txt and attaching the resulting lshw.txt file may be helpful.)


Opening LibreOffice Draw file from FTP (curlftpfs) fails

There is no solution to this issue:

  Several GUI application (gedit, leafpad,...) use open(O_RDWR) + seek
  mode for saving files  which cannot be supported by the FTP protocol.
  Therefore saving files might throw an error. Hopefully future kernels
  will provide special errno's to make it easier to  deal with less
  capable file-systems.

Which is what https://github.com/JackSlateur/curlftpfs says.

The best solution is perhaps to just use LibreOffice's inbuilt File → Open Remote... functionality.


Copying a long command from history in terminal

Press Ctrl + R and start typing a text from a command that you want to get from the history. The latest command with the text that you typed in will appear. Press Ctrl + R again to move to the next command, which contains entered text, until you get the command you are searching for. Then you can move within command with right and left keys and change it as you like. When you are done, just press Enter. You don't need to copy the command as you can recall it anytime.


Which distro should I install to avoid Amazon?

The official derivatives of Ubuntu really are Ubuntu. If that makes you not want to use them, there's nothing wrong with that, but for other OS recommendations I'd suggest asking in a community that's not all about Ubuntu--our suggestions for non-Ubuntu OSes might lack some important insights. Furthermore, there are many OSes in the world, even many that are substantially similar to Ubuntu, so what you're looking for might be a broad discussion, rather than answers to a narrowly scoped question. With that said...

If you want to know which official derivatives of Ubuntu ship without software that automatically sends personal data to Canonical to search Amazon, that question can certainly be answered. The functionality you're trying to avoid is provided by the unity-lens-shopping package. This is a Unity lens, and it is absent by default in derivatives that don't use Unity at all.

(Of course you can also simply uninstall that package and log out and back in, but I understand that's not the solution you're looking for.)

Ubuntu flavors not shipping with Unity (and thus also not with unity-lens-shoppping) currently are:

Ubuntu GNOME (GNOME 3 with GNOME Shell, not Unity)
Kubuntu (KDE Plasma)
Lubuntu (LXDE)
Mythbuntu (currently uses Xfce)
Ubuntu Studio (currently uses Xfce)
Xubuntu (Xfce)

I've listed these in the same order as they appear here, and excluded Unity-based flavors.

While I encourage you to seek other sources of information about other distributions, two distributions similar to Ubuntu are very popular: Debian, our upstream distro (i.e., Ubuntu is a derivative of Debian), and Linux Mint, a popular unofficial derivative of Ubuntu. (Linux Mint also offers a version based directly on Debian instead of Ubuntu.)

While they don't have huge user bases, I'd consider two unofficial derivatives of Ubuntu (besides Mint) to be particularly notable: Trisquel GNU/Linux, which includes only free software (the current stable version is based on Ubuntu 12.04); and Ubuntu MATE, which uses the MATE desktop and might get official status.

I understand this answer does not give everything you're looking for, and I reiterate the need to consult people and resources outside the Ubuntu community for a balanced picture of which OSes may be most appropriate for your needs. However, I think the question of which "Ubuntus" ship without Amazon search integration is of interest to many people; perhaps some of them will be helped.


How to check if an LXD container runs unprivileged?

yes, is enough that you see that your UID is different than root and other users in your host for the processes running in your container. (setuid/setgid mapping magic)


From Ubuntu run cat /boot/grub/grub.cfg | grep menuentry. Starting from zero, count down to the Windows entry, so if it's the eighth entry, you count to 7.

Then edit grub:

sudoedit /etc/default/grub

Change the GRUB_DEFAULT=0 line to GRUB_DEFAULT=X where X is the number you counted to. ControlX, then Y to save and exit. Then run:

sudo update-grub

And when you reboot that entry should be selected.

Note: This method didn't used to be recommended because the list would grow as more kernels were added in updates but now Ubuntu has a more fixed kernel list. If you manually add extra entries in the future you may find that you need to change which is set as the default.


According to the Unix Filesystem Hierarchy Standard, /opt and /usr/local are to be used as follows:

  /usr/local:

  "The /usr/local hierarchy is for use by the system administrator when installing software locally. [...] It may be used for programs and data that are shareable amongst a group of hosts, but not found in /usr."

  /opt:

  "/opt is reserved for the installation of add-on application software packages. [...] Programs to be invoked by users must be located in the directory /opt/<package>/bin or under the /opt/<provider> hierarchy."

So to answer your two questions:

  "/opt or /usr/local what is the recommended one?"

Borrowing from this answer (which goes into more detail than I ever could), /opt is intended for prebuilt packages containing prebuilt binaries that are ready for unpacking. If you are compiling Eclipse yourself, /usr/local would be the correct place.

  "/usr/bin or /usr/local/bin?"

/usr/bin is intended for software provided by your distribution. If you are building Eclipse yourself, the installation prefix should be set to /usr/local.

Important note: under normal circumstances, both /usr/local and /opt are owned by root and are not world-writable. If you are not the system administrator, then you will need to get them to install the files or use your home folder.


Can I install oracle 11g on both windows and ubuntu running on dual boot?

I've tried it again and ended up with a working oracle11gXE on Ubuntu. But my oracle11gEnterprise on windows showed that it is missing some Listener. Apparently the listener automatically stops when system boots.
I am certain about using correctly each and every step. The only thing I'm fuzzy about is that the same defaults 8080@1521.
I had to choose my way therefore and now, this answer is written on Ubuntu 14.04 :D


gedit open second file onwards in a new window. Ubuntu 19.10

Edit the /usr/share/applications/gedit.desktop by changing the following line :

Exec=gedit %U

by adding the --new-window option :

Exec=gedit --new-window %U

It would define to always open gedit on a new window.

P.S : Here is my entire gedit.desktop file with this option, that worked well on 18.04 :

[Desktop Entry]
Name=Text Editor
Comment=Edit text files
Exec=gedit --new-window %U
Terminal=false
Type=Application
StartupNotify=true
Icon=gedit
Categories=GNOME;GTK;Utility;TextEditor;
X-GNOME-DocPath=gedit/gedit.xml
X-GNOME-FullName=gedit Text Editor
X-GNOME-Bugzilla-Bugzilla=GNOME
X-GNOME-Bugzilla-Product=gedit
X-GNOME-Bugzilla-Component=general
X-GNOME-Bugzilla-Version=3.28.1
X-GNOME-Bugzilla-ExtraInfoScript=/usr/share/gedit/gedit-bugreport.sh
Actions=new-window;new-document;
Keywords=Text;Editor;Plaintext;Write;
X-Ubuntu-Gettext-Domain=gedit

X-AppStream-Ignore=true

[Desktop Action new-window]
Name=New Window
Exec=gedit --new-window

[Desktop Action new-document]
Name=New Document
Exec=gedit --new-document

You can note that the New Document option won't open a new window, you can add again this --new-window option to it (so it would be Exec=gedit --new-document --new-window instead of Exec=gedit --new-document)


What is the correct way to unmount an NTFS external drive under Ubuntu 18?

Use Safely Remove Drive via Nautilus (aka Files)

I did some tests with Ubuntu 18.04 LTS using the default Natilus app. I copied a 10GB file from the internal drive to an external drive. As soon as the file copy operation was completed I safely removed the external drive either from the desktop icon or from within Nautilus.

Right clicking and selecting "Safely Remove Drive" from the desktop icon is not the best way. The desktop icon vanishes and there is no notification when it is safe to remove the drive.
Unmounting the drive by pressing the eject icon on the Nautilus gives similar results as above. The desktop icon vanishes. The icon on the left panel of Nautilus remains. There is one notification: Unmounting XXXX. Disconnecting from filesystem. However, there is no notification when it is safe to remove the drive.
Right clicking the name of the external drive in the left panel of Nautilus and selecting "Safely Remove Drive" gives better results:

First, even though the desktop icon for the external drive vanishes immediately, the icon in Nautlus does not.

Second, there is a notification that says: Writing data to XXXX. Device should not be unplugged.

Third, When it is safe to remove the drive the icon from the Nautilus also goes away. Plus, there is a second notification: XXXX can be safely unplugged. Device can be removed

If there is not a whole lot of data to be written to the external drive, then you don't get the first notification.

Hope this helps


How to list files without directories with specific time

use -not -type d instead of grep -v '^d'

find /home/$USER -mmin -600 -not -type d

or simply -type f


Ubuntu 20.04 - Port forwarding with iptables causing "temporary failure in name resolution" when using sudo

The problem is that devonServer cannot be resolved. If that's the name of the local host, check that it appears in /etc/hosts (or add it if it's not there) in a line like:
127.0.0.1 devonServer


Can a broken power supply freeze Ubuntu?

With an hardware failure, the software can reach some random behavior.

I would suggest to check your system logs files (using gnome-system-log application for example) and look at if some errors were reported when you observed the issue.


Permission denied copying files from an old HDD drive

I worked it out.

sudo chown [new-owner] -R [folder]

-R does it recursively to all subfolders.
Phew!