How to download files with a specific extension only from an FTP server?

wget supports recursive download and accept lists which should cover this use case.

wget -r -np -A "*.torrent" ftp://ftp.fau.de/gimp/gimp/

The file-extension should be specified.

The command will recursively download all files ending in torrent from ftp://ftp.fau.de/gimp/gimp/ .

If you want to remove the directory structure and have all files in the current working direcotory add -nd to the argument list.

If you want to skip downloads for files which already exist in the target directory, add -nc to the argument list.


Ubuntu Crashes After Updating Nvidia Card

I hate this answer because it's like blindly smashing with a sledgehammer when I should find the real cause, but it's what I've done when various upgrades muck the desktop environment:

press Ctrl-Alt-F1 to get a non-graphical terminal
login as me
tar cvfz config-files-2013-may-30.tar.gz .config .gconf
rm -rf .config .gconf
exit
pres Ctrl-Alt-F7 to get back to the graphical login
login as me and the .config and .gconf directories are made anew by the display manager.

Obviously step (3) is present in case this makes things worse.

I really hate this answer but it gets me back to work. I hope someone posts a better one.


Utuntu 18.04 - Super + Number keys aren't working when "Dash to panel" is active

I found a fix:

(works as of March 13th 2019, Ubuntu 18.10)

1) Install Dash-to-Panel via https://extensions.gnome.org

You might need to install an addon for Firefox (prompt from website)
You might also need to enable the website for Gnome Shell integration. The site will ask you to visit this page: https://wiki.gnome.org/Projects/GnomeShellIntegrationForChrome/Installation

I know it says "chrome install guide" but the command also enables support for Firefox. The command is at the bottom.

sudo apt-get install chrome-gnome-shell

2) click the blue 'gear and wrench' icon next to the On/Off switch - A settings window for the extension appears.

3) Go to the "Behaviour" tab

4) At the bottom, enable "Use hotkeys to activate app"


debugging in codelite - "GDB: Failed to set controlling terminal: Operation not permitted"

As mentioned in codelite github

  This error message is harmless and can be ignored. If the terminal
  does not "pause" when your code terminates, you can enable this from
  Project Settings->General->Pause when execution ends

  To configure different temrinal, you do it from Ubuntu's terminal,
  like this:

sudo update-alternatives --config x-terminal-emulator


How do I improve GUI performance on AMD E2-3200 APU?

Installing the proprietary drivers from AMD may fix slow graphics. You can install them from the Ubuntu Software Center. Search for "fglrx" and install the package. After a reboot graphics should be better.

As MiJyn commented below, it is necessary to run sudo amdconfig --initial -f after installation. To do that, you need to open a terminal (search the Dash) and paste the command. Press enter and you will be prompted to enter your password. After you did that, you can reboot safely.

Your graphics processor is fast enough to render Ubuntu Unity.


Ubuntu 16.04 libvirt-guests.sh [6917] - running guests on default URI: no running guests

I unexpectedly received a reply from virsh support saying that I could actually disable libvirt-guests, which I didn't realize was possible.

systemctl disable libvirt-guests

Works like a charm!!!

I still however do not know the root cause but at least I can now reboot/shutdown without any issues.


Make Calibre to ask for an application each time

A possible workaround might be that you first open the path to folder ("Path: Click to open" in the righthand pane with the book details). The file manager opens the folder with the containing file and you can right-click and choose your application from there.
It does take a couple of more clicks, though.

There is a plugin "open with" (see here) you could use. Set it to open pdf files with MuPDF, and when you want to open a pdf file with Document Viewer use the method above.
You might also create a custom column that tells you which pdf files are best opened with Document Viewer.


How do I install Chromium from the command line?

You can type in the terminal:

sudo apt-get install chromium-browser


To set scaling in Wine you need to adjust the Wine DPI setting. You can find this is Wine Configuration (winecfg) under the Graphics tab. In this example under 125% fractional desktop scaling, setting the Wine screen resolution to 240dpi scales Wine content appropriately (for my tastes).
You will need to configure this setting for each wineprefix.


Download the free firmware e.g."Update3202.upd" ("2.Datei") including the file "update.upd" (1.Datei) from the Ravensburger homepage (Update 2020) to your hard drive.
Connect the Tiptoi with the USB cable, turn it on. It will appear as new drive "tiptoi" in your file browser (e.g. Nautilus, Nemo, Thunar).
Transfer both update files from your harddrive to your tiptoi drive without changing the names (e.g. in your file browser).
Disconnect the Tiptoi from the computer
Restart the Tiptoi and the update will be installed.


I think you hit a shortcut while typing really fast. You can check shortcuts on nvidia settings or on Ubuntu.
For example there is "resize window" at the bottom.


How to reinstall GRUB bootloader for 14.04 after upgrading to Windows 10

Boot from the live CD or live USB, in "Try Ubuntu" mode.
Determine the partition number of your main partition. GParted (which should already be installed, by default, on the live session) can help you here. I'm going to assume in this answer that it's /dev/sda2, but make sure you use the correct partition number for your system!

Mount your partition:

sudo mount /dev/sda2 /mnt  #Replace sda2 with your partition number

Bind mount some other necessary stuff:

for i in /sys /proc /run /dev; do sudo mount --bind "$i" "/mnt$i"; done

chroot into your Ubuntu install:

sudo chroot /mnt

At this point, you're in your install, not the live session, and running as root. Update grub:

update-grub

If you get errors, go to step 7. (Otherwise, it is optional.)

Depending on your situation, you might have to reinstall grub:

grub-install /dev/sda
update-grub # I'm not sure if this is necessary, but it doesn't hurt.

If everything worked without errors, then you're all set:

exit
sudo reboot

At this point, you should be able to boot normally.

If you cannot boot normally, and didn't do step 7 because there were no error messages, try again with step 7.

Sometimes giving GRUB2 the correct configuration for your partitions is not enough, and you must actually install it (or reinstall it) to the Master Boot Record, which step 7 does. Experience helping users in chat has shown that step 7 is sometimes necessary even when no error messages are shown


This netbook has known issues with the BIOS and tickless kernel operation; the previous kernel parameters "nohz=off highres=off" may work with the newer kernel. I'm having a similar issue with installing 13.04, but it's at least booting.

Edit: These are the instructions for adding the kernel parameters to grub: https://bugs.launchpad.net/ubuntu/+source/linux/+bug/508516/comments/39

Edit 2: After 2 days I can confirm that this fixes the 13.04 kernel on my Toshiba NB305. When running a clean install, you need to select "install ubuntu", then press F6 for advanced options. A menu will open and the GRUB boot command will become an editable line. ignroe the menu (I think I hit ESC) and move your cursor to the right of the "--" then add " nohz=off highres=off" and press enter to boot the installer. After install you should see those options in the /etc/defaults/grub file as well.


How do I update my nvidia modules after updating my kernel?

For me dpkg-reconfigure rebuilds the Nvidia driver with the latest kernel. This then requires a reboot to take effect. My example below uses the older nvidia-304-updates.

sudo dpkg-reconfigure nvidia-304-updates

EDIT: I managed to automate this by writing a script zz-dkpg-reconfigure-nvidia that runs after kernel updates

#!/bin/bash
#
# Reconfigure nvidia driver

DRIVER=nvidia-304-updates

dpkg-reconfigure $DRIVER > /var/log/dpkg-reconfigure-nvidia.log 2>&1

exit 0

I installed the above script by running

sudo install zz-dkpg-reconfigure-nvidia /etc/kernel/postinst.d

Works on my Ubuntu 14.04 kernel 3.13.0-29 to 3.13.0-36 update.


Package dependency problems with broken packages but none listed to fix

None of your packages are broken. The wine dependencies are conflicting with each other. Uninstall existing version of wine (if exists) then install wine1.7 (there won't be such problem with wine1.7)

UPDATE:
To install wine 1.7 on your case type these in your terminal:

sudo apt-add-repository ppa:ubuntu-wine/ppa

sudo apt-get update

sudo apt-get install wine1.7


Ubuntu GNOME vs Ubuntu "normal" with gnome

Ubuntu GNOME edition will give you an experience which resembles more the vanilla GNOME 3 installation. By installing "normal" Ubuntu you'll get Unity, and if you install GNOME on top of that, you'll end up with all traditional GNOME apps as well as "Unity apps". You'll have more applications (some of which are even going to be redundant), but the option to choose between Unity and GNOME-shell before login.


Using dconf or another command line tool how can I make a user with sudo a Gnome Administartor

Nothing found with become GNOME Administrator CLI commands but the first link found with a web search on become GNOME Administrator revealed https://help.gnome.org/users/gnome-help/stable/user-admin-change.html.en which explains the first user account on the system is usually the one that has administrator privileges. This is the user account that was created when you first installed the system. So, instead, try this with other accounts on your system:

Open the Activities overview and start typing Users.
Click Users to open the panel.
Press Unlock in the top right corner and type in your password when prompted.
Select the user whose privileges you want to change.
Click the label Standard next to Account Type and select Administrator.
The user’s privileges change when they next log in.

Please try that process and if it does not work, please click [edit] for your question and so advise.


Blacklist the acer-wmi module :

echo blacklist acer-wmi | sudo tee -a /etc/modprobe.d/blacklist-acer-wmi.conf

Reload the driver:

sudo modprobe -rfv ath5k
sudo modprobe -v ath5k


Guideline to uninstall something and install something

To remove: sudo apt-get purge apache2 mysql php5

For install: Make sure you did sudo apt-get update && sudo apt-get upgrade

Then for Ubuntu 16.04 and later:sudo apt-get install apache2 libapache2-mod-php7.0 php7.0 php7.0-mysql mysql-server

For Ubuntu 15.04 and earlier: sudo apt-get install apache2 libapache2-mod-php5 php5 php5-mysql mysql-server

There are many guides how to install the LAMP-Stack correctly. A good one is this here:
https://www.digitalocean.com/community/tutorials/how-to-install-linux-apache-mysql-php-lamp-stack-on-ubuntu-14-04


ext4 partition ubuntu lost after Windows 7 installation

Installing Windows removed the Grub bootloader.

If you boot from a live USB and in a terminal type sudo grub-install /dev/sda where /dev/sda is your hard disk, you should get Grub back and Ubuntu too.


Here is one site for the latest version
https://www.osdisc.com/products/linux/ubuntu


WiFi often freezes after 17.04->17.10 upgrade

This bug has been reported on launchpad: https://bugs.launchpad.net/bugs/1743279
If you're affected, please tell them in the bug report so they can fix the bug ASAP.

The firmware-6.bin file needs to be updated. Ubuntu currently ships version WLAN.RM.4.4-00022-QCARMSWPZ-2 and the fix for this issue was released in version WLAN.RM.4.4.1-00051-QCARMSWP-1, which means you need some version later than the latter for the card to work properly on >4.12 kernels.

As of today, this bug can be fixed by simply replacing the board-2.bin (not actually required but recommended) and firmware-6.bin files with what's currently in the upstream repository for linux-firmware, or by grabbing the firmware-6.bin from kvalo's repository for the proper version.

Another answer here gave the correct diagnose and procedure, but used an incorrect version of the firmware to be downloaded.

You can grab the correct version from kvalo's repository, which is guaranteed to always work (if you don't require the new board-2.bin as well).

These commands below will automate the replacement of the files:

$ sudo wget https://github.com/kvalo/ath10k-firmware/raw/master/QCA6174/hw3.0/4.4.1/firmware-6.bin_WLAN.RM.4.4.1-00051-QCARMSWP-1 -O /lib/firmware/ath10k/QCA6174/hw3.0/firmware-6.bin

Alternatively, you can grab the files from the current state of linux-firmware
These commands below will automate the replacement of the files from what's upstream (notice these commands might work now but there's no guarantee they will work in the future because the repository's contents can change, although they will hardly ever break things like this).

$ sudo wget https://git.kernel.org/pub/scm/linux/kernel/git/firmware/linux-firmware.git/plain/ath10k/QCA6174/hw3.0/board-2.bin -O /lib/firmware/ath10k/QCA6174/hw3.0/board-2.bin
$ sudo wget https://git.kernel.org/pub/scm/linux/kernel/git/firmware/linux-firmware.git/plain/ath10k/QCA6174/hw3.0/firmware-6.bin -O /lib/firmware/ath10k/QCA6174/hw3.0/firmware-6.bin

Then reboot.


Laptop freezes after connecting external monitor, since 16.04 update

Update of kernel to 4.4.8-wily will solve the problem. It works fine with Intel® HD Graphics 520, so I assume that it should help to all Skylake graphics cards. Instalation instructions here: http://linuxdaddy.com/blog/install-kernel-4-4-on-ubuntu/


resolvconf got uninstalled and can't install it again

You need to fix errors from prior commands before trying new commands.
First and easiest is
sudo apt -f install
or other --fix-broken options? It's issued without package so it corrects existing issues rather than compounding the problem.
From [man apt-get]1

   -f, --fix-broken
       Fix; attempt to correct a system with broken dependencies in place. This option, when
       used with install/remove, can omit any packages to permit APT to deduce a likely
       solution. If packages are specified, these have to completely correct the problem. The
       option is sometimes necessary when running APT for the first time; APT itself does not
       allow broken package dependencies to exist on a system. It is possible that a system's
       dependency structure can be so corrupt as to require manual intervention (which
       usually means using dpkg --remove to eliminate some of the offending packages). Use of
       this option together with -m may produce an error in some situations. Configuration
       Item: APT::Get::Fix-Broken.


pbrun is used to request that an application or command be run in a controlled account.

-u
    username sets the requesting user to be username.

In your case, the command dap is started for the user [username], it's not an option for pbrun.

Sorry @Rinzwind, OP asked:

  Dap is a statistics and graphics program, that performs data management, analysis, and graphical visualization tasks which are commonly required in statistical consulting practice. Dap was written to be a free replacement for SAS, but users are assumed to have a basic familiarity with the C programming language in order to permit greater flexibility. Unlike R it has been designed to be used on large data sets.

Source

You can download the application here. There are also deb files.

cd
wget https://ftp.gnu.org/gnu/dap/dap_3.10-1_amd64.deb
sudo dpkg -i dap_3.10-1_amd64.deb

The command in your question would display:

% pbrun -u guest dap

Dap, Copyright (C) 2001, 2002, 2003, 2004, 2005 Free Software Foundation, Inc.
Dap comes with ABSOLUTELY NO WARRANTY;
for details see the GNU Public License.
This is free software, and you are welcome to
redistribute it under certain conditions; see
the GNU Public License for details.

dap: no files to process


Locking keyboard, mouse and CDROM for baby

how can i disable power button?

You'll need hardware support for that. Or nice "there, I fixed it!" tape. A longer press on this button will inevitably power down the PC very roughly, no matter what OS you run on it or what program you try to have that prevent it.

For just ignoring the simple "hits" on it, go to your power settings and let it do nothing on pressing it:

Above screenshot is in KDE, but similar settings should be available in your Desktop Environment too (e.g. Unity, GNOME, ...) See this answer for Unity.

  Locking keyboard, mouse

Have you tried setting a password to your screensaver? Or set up a custom shortcut to activate the screen locker (default Ctrl+Alt+L)?

  CDROM

Use

eject -i on

to lock the optical drive :)


Ubuntu cloud images, as other cloud images, are provided with a no-pass user. This allows only ssh access to the VM.

You should create a ssh key pair (http://man.openbsd.org/ssh-keygen) and pass the public key through the hypervisor when instantiating the VM.

Then, login using ssh -i pathToPrivateKey ubuntu@machineaddress.


Skype/14.04: no sound output in conversations

Obeying this workaround i am able to not only talk but also to listen to my interlocutor what makes $kype a far more useful application, indeed. The fresh dude advises instead of simply running it by entering skype in terminal (respectively pushing the blue colored button) to just launch it this way:

  env PULSE_LATENCY_MSEC=30 skype

Tested on Trusty Kubuntu. Tux 4 president!


You can simply sudo apt-get remove ffmpeg just be aware that other software you use may depend on ffmpeg, so, read apt-get output carefully.


how to add all titles to the queue of handbrake automatically?

I don't believe you can do this automatically, but if Simultaneously would serve, Here's an excerpt from the Handbrake Team Documentation

Adding multiple encodes simultaneously

When using the Queue, you may find it beneficial to create multiple Jobs at one time.

If your Source is a Blu-ray, DVD, or other disc or disc-like format with multiple Titles, you may open it with HandBrake and add multiple Titles to the Queue simultaneously.

Additionally, you may open a folder of multiple single-Title videos (excluding discs and disc-like formats) as one virtual Source with multiple Titles using the Open Source dialog, and then add multiple Titles to the Queue.

On Linux, select Add Multiple from the Queue menu, then select the Titles you wish to encode using the presented dialog. Be sure to give each a unique file name.

You may open additional Sources and add them to the Queue in the same manner.

EDIT:

As an alternative you could script write a script that loops through all the files in a given directory and run the same conversion command on all of them utilizing handbrake-cli


KDM

If you are using the KDM:

KDE System Settings > Login Screen > Theme

Install and pick a theme with the user list - here is one: http://kde-look.org/content/show.php/Kubuntu+Sitter+KDM?content=150704

LightDM

If you are using the lightdm-kde-greeter. Earlier: https://www.kubuntuforums.net/showthread.php?57401-Lightdm-KDE

KDE System Settings > Login Screen (LightDM) > Theme - Pick a theme with the user list


The message

  (Wrong sources.list entry or malformed file)

Means that either some entry in your sources.list file is wrong or a line is malformed.

Searched the Web and I found this old bug, it is not exactly old, but Expired.

The solution (workaround is better word) is to examine your sources.list file and remove the word independent from the lines. Try it.

A good and detailed command to see all your sources.list entries is bellow:

find /etc/apt -name '*.list' -exec bash -c 'echo -e "\n$1\n"; cat -n "$1"' _ '{}' \;


How can I change global font colors in Ubuntu 12.04?

I found the solution to my own question:

mv /home/USER/.config/dconf/user /home/USER/.config/dconf/user.old


The "coloring" is called syntax highlighting and it is based on the detected file type. The file type detecting pretty much works on two paths:

from file extension. So a file with extension .py is recognized as Python file. This can be configured via Tools->Configuration Files->filetypes_extensions.conf
from manual choice from inside Document menu. So e.g. "Document->Set Filetype->Scripting Languages->Python source file" for setting Python

In some cases the so called shebang -- the #!/bin/... at the start of a file -- is also used to determine the file type.

In your case, you should ensure you have saved your file with a extension marked as Python and/or choose manually.


Cannot boot to Ubuntu after Windows 7 installation and "boot-repair" does not work

Thank you for pointing me in the right direction - here is the fix for the problem:

Start via Live-CD
Mount Linux partition
$ sudo grub-install --root-directory=/media/ubuntu/e2eec732-eb12-47e4-8c4d-5f50d4ad5986/ /dev/sdb"

Restart
In BIOS change boot priority of devices - prio 1 is Linux
Fixed - grub is loaded first and the Windows can be selected.


Is there a way to statically map MAC addresses to IP addresses for machines in MAAS?

Work is currently under way to enable you to bind an IP address to a machine so that it is always used whenever that machine is brought up.

Similarly, it will be possible to declare additional (unmanaged) machines (MAC and IP) so that you can have DNS and DHCP for them provided by MAAS rather than having them statically assigned and unrecorded in MAAS.


Maybe you can start from the sources of existing plugins that you can find here:
https://gitlab.gnome.org/GNOME/gedit-plugins
Try to compile and hack some existing plugin and you will build more experience to create your own one :)


Lubuntu - Screen looks broken after installing

i created this account just to tell that i had the same problem and managed to find a solution. the system that i am using is a Samsung NC10 netbook with a res of 1280x600

this is the solution. (please tell me if it also works on your computer!)

you need to edit /etc/default/grub

change this line of code

# Uncomment to disable graphical terminal (grub-pc only)
#GRUB_TERMINAL=console

to this

# Uncomment to disable graphical terminal (grub-pc only)
GRUB_TERMINAL=console

and then use

sudo update-grub

and reboot

and the best part is, i got this solution by accident as well.

credits to this forum post at Ubuntu forums for this code.
here's a link to the post

And as always. have a good day!


How to access Apple Time Capsule on Ubuntu 18.04.1

On Ubuntu 18.04, I saw the same screen as you have. Having tried various Google searches I found a command line solution.  It is not a fully automated GUI solution... but this is Linux, right.

First prepare mount point (only one time):

$ sudo mkdir /media/$USER/capsule

Then every time you want to mount the capsule:

If you as I have the same username on both your Mac and Linux systems:

sudo mount -t cifs //10.0.1.1/Data /media/$USER/capsule -o username=$USER,sec=ntlm,uid=$USER,vers=1.0

Else:

sudo mount -t cifs //10.0.1.1/Data /media/$USER/capsule -o username=MyCapsuleUsername,sec=ntlm,uid=MyCapsuleUsername,vers=1.0

You will be asked for two passwords, the first from sudo, i.e. your Linux password, the second from the capsule.

Note, I created an alias in my .bashrc file for convenience.

Note, //10.0.1.1 is the default local IP address of your capsule, assuming you did nothing special when setting it up. You can check your router setup for the correct IP. /Data is the name that you gave your time capsule, it might differ in your case.


Nautilus won't copy files from mounted samba shares

I'd try to add the _netdev mount option ie:_netdev,credentials=..... Another idea -that is probably not related- is adding uid and gid options uid=1000,gid=1000,_netdev,credentials=....There is the option vers for smb version toovers=1.0,credentials=....

The Linux cifs kernel client has been included in the kernel since kernel version 2.5.42. For improved security and performance, SMB3 is the now the default dialect (SMB3.02/SMB3/SMB2.1 dialects are requested by default). CIFS protocol (and other old dialects) can be selected (by specifying "vers=1.0" or "vers=2.02" in the mount options for example). The newest, most secure dialect, SMB3.11 can also be requested (vers=3.1.1).


Make an Ubuntu bootable USB drive for a PC using Mac?

You will need:

A 4GB or larger USB stick/flash drive
An Apple computer or laptop running macOS
An Ubuntu ISO file. See Get Ubuntu for download links

To ensure maximum compatibility with Apple hardware, first blank and reformat the USB stick using Apple's "Disk Utility", but this step can be skipped if you intend to use the USB stick with only generic PC hardware.

Launch Disk Utility from Applications -> Utilities or Spotlight search.

Insert your USB stick and observe the new device added to Disk Utility.

Select the USB stick device (you may need to enable the option View -> Show All Devices) and select Erase from the toolbar (or right-click menu).

Set the format to MS-DOS (FAT) and the scheme to GUID Partition Map.

Check you've chosen the correct device and click Erase.

Warning: Disk Utility needs to be used with caution as selecting the wrong device or partition can result in data loss.

Install and run Etcher
To write the ISO file to the USB stick, use a free and open source application called Etcher. After downloading this and clicking to mount the package, Etcher can either be run in place or dragged into your Applications folder.
By default, recent versions of macOS block the running of applications from unidentified developers. To side-step this issue, enable App Store and identified developers in the Security & Privacy pane of System Preferences. If you are still warned against running the application, click Open Anyway in the same pane.

Etcher configuration
Etcher will configure and write to your USB device in three stages, each of which needs to be selected in turn:

Select image will open a file requester from which should navigate to and select the ISO file downloaded previously. By default, the ISO file will be in your Downloads folder.

Select drive, replaced by the name of your USB device if one is already attached, lets you select your target device. You will be warned if the storage space is too small for your selected ISO.

Flash! will activate when both the image and the drive have been selected. As with Disk Utility, Etcher needs low-level access to your storage hardware and will ask for your password after selection.

Write to device
After entering your password, Etcher will start writing the ISO file to your USB device.
The Flash stage of the process will show progress, writing speed and an estimated duration until completion. This will be followed by a validation stage that will ensure the contents of the USB device are identical to the source image.
When everything has finished, Etcher will declare the process a success.
Congratulations! You now have Ubuntu on a USB stick, bootable and ready to go.

Warning: After the write process has completed, macOS may inform you that 'The disk you inserted was not readable by this computer'. Don't select Initialize. Instead, select Eject and remove the USB device.

Boot your Mac
If you want to use your USB stick with an Apple Mac, you will need to restart or power-on the Mac with the USB stick inserted while the Option/alt ⌥ key is pressed.
This will launch Apple's 'Startup Manager' which shows bootable devices connected to the machine. Your USB stick should appear as gold/yellow and labelled 'EFI Boot'. Selecting this will lead you to the standard Ubuntu boot menu.

Source: Create a bootable USB stick on macOS


Should I install ATI propriety video drivers on Ubuntu 11.04 on my Dell Inspiron 9100?

I would recommend it only if you are using 3D Applications which have a poor performance or simply don't work with the open source drivers.
Yes it increases the performance (a lot).
You can always boot into the recovery mode and install the open source drivers (if you have a blank screen or stuff like that). See https://wiki.ubuntu.com/X/Troubleshooting/FglrxInteferesWithRadeonDriver#Problem:__Need_to_fully_remove_-fglrx_and_reinstall_-ati_from_scratch for detailed instructions.


There are many possible ways. These three below should be the most common. The stuff after # on the command lines are comments explaining what each of them does, you don't need to copy them.
lsblk
This is probably the most simple tool to get a quick overview of what partitions exist. Nested structures (e.g. disk > partition > LUKS container > LVM container > volume) are also nicely displayed as a tree. Runs as regular user, no sudo needed.
You get (amongst others) information about device name, size, type and mount point (if mounted). With the option -f it will show file system type, label and UUID.
It's possible to specify a disk, partition or any similar device to only view information about that instead of listing everything.
Examples:

lsblk                     # default info about all devices
lsblk -f                  # file system info about all devices
lsblk /dev/sda1           # default info about the /dev/sda1 partition and its children only
lsblk -f /dev/sdb         # file system info about the /dev/sdb disk and its children only

See man lsblk for more info.
parted
parted is a more powerful command-line tool, similar to its GUI pendant GParted. It can also modify the partitioning layout. Note that this requires elevated privileges (sudo) to run.
It will show you information about your disk hardware (model, type, size, sector size, ...) as well as a detailed partition table including start and end positions, size, type, file system, flags, label, ...
You can either list everything or specify a disk to print details about.
Examples:
sudo parted -l                 # show info about all devices
sudo parted /dev/sda print     # show info about the /dev/sda disk only

See man parted for more info.
fdisk
fdisk is very similar to parted. It is also able to make modifications, requires elevated privileges and shows basically the same information as well.
Examples:
sudo fdisk -l                  # show info about all devices
sudo fdisk -l /dev/sda         # show info about the /dev/sda disk only

See man fdisk for more info.


Available + used size only 19% of total partition size

What you're seeing is the difference between thick and thin provisioning:

Thick provisioning: The full disk space you request is allocated and reserved for you and for you only. (expensive!)
Thin provisioning: The disk space your request is shared with other users and only the disk space you actually use is allocated to you and the free space is allocated from a shared pool. (cheap and how most CSPs do things nowadays)

As I don't work at OpenVZ, I don't know how they physically allocate your space, but if they use best practices you'll see the Avail column grow if you get between 50% and 85% of actual usage up to your maximum of 54G.


Adding custom keyboard layout to Xubuntu 13.10

The Xkb directory is located at /usr/share/X11/xkb
Besides, it's not XFCE that uses the directory, it's Xkb, a part of Xorg.
To create a new layout just create a file in symbols/ (eg asdf). After that you can switch to the newly created layout with setxkbmap asdf

Next step would be to register the layout, see the files rules/base.xml and rules/evdev.xml.
After registering you can switch to it other than by calling setxkbmap directly: most desktop environments honor those files and all keyboard layouts you see in keyboard settings are actually from those XML files.


How to open a PDF in dual page view, but for Arabic PDF's (Where pages layout should be from right to left)

Actually Acroread works.

If you can't get it in software center, see https://get.adobe.com/uk/reader/otherversions/ . Download .deb package.

Edit → Preferences → International → Enable Right to Left Language Options (Default can be change too)
Qpdfview bug report (fix may be released with qpdfview 0.4.9)

lp bug#1281870

From Menu, View → Right To Left
Shortcut: Ctrl+Shift+r
To add it to toolbar: Edit → Settings → Interface → View Tool Bar: Add rightToLeftMode to comma separated list.
Okular bug report (needs more votes)

kde bug#325650
Evince bug report

gnome bug#724704
To test if the viewer may flip page layout too when launch with RTL (RightToLeft) local ie: RTL GUI, (ar_DZ for Algerian Arabic. Or prefer ar.UTF8 as most application translated to single unified Arabic, no difference):

LANGUAGE=ar_DZ.UTF8 acroread
LANGUAGE=ar_DZ.UTF8 evince
LANGUAGE=ar_DZ.UTF8 qpdfview
LANG=ar_DZ.UTF8 okular


How can I log the activity of a directory?

You could use inotifywait to monitor directories for files that have been accessed, deleted or moved.

Install inotify-tools

sudo apt-get update
sudo apt-get install inotify-tools

Then run:

inotifywait -m -r /mnt

The "-m" option monitors the directory and "-r" is recursive. Unless otherwise specified by "-e" option, all events will be displayed as defined in the inotifywait manpage. The events can be sent to a log file by using the "-o" option:

inotifywait -m -r -o /directory/logfile.txt /mnt


Ubuntu 12.04 and Nvidia Geoforce 840M Gfx card

For completeness - the full answer to this is to use nvidia-prime, as detailed on this Hybrid Graphics Wiki Page

Essentially : Install the nvidia drivers and nvidia prime

 sudo apt-get install  nvidia-319 nvidia-prime

and then restart


How to add new columns to CSVs with the same text in all lines

Using Miller (https://github.com/johnkerl/miller) you can run

mlr --csv -N put '$a="COMPTON";$b="PRECIPITATION";$c="NOT APPLICABLE"' then reorder -f a  input.csv

to have

+---------+------------+--------------+----+-------+---------------+----------------+
| COMPTON | 22/12/1999 | conductivity | 42 | uS/cm | PRECIPITATION | NOT APPLICABLE |
| COMPTON | 06/01/2000 | conductivity | 22 | uS/cm | PRECIPITATION | NOT APPLICABLE |
| COMPTON | 26/01/2000 | conductivity | 26 | uS/cm | PRECIPITATION | NOT APPLICABLE |
| COMPTON | 09/02/2000 | conductivity | 32 | uS/cm | PRECIPITATION | NOT APPLICABLE |
| COMPTON | 23/02/2000 | conductivity | 33 | uS/cm | PRECIPITATION | NOT APPLICABLE |
+---------+------------+--------------+----+-------+---------------+----------------+


Upgrade Ubuntu 16.06 LTS -> 18.04, Printer Brother HL-L2320D Stopped working

Again just to be clear, the upgrade cleaned out some files referred to in this other post. I therefore wasn't able to print with ANY printer, even though it seemd my OS was comunicating with the printer (i.e. it saw it, and when print jobs were sent, the lights would blink, and Id recieve a Filter failed status). This happend with HP printer, Cannon, and my Brother.

Thanks to this post:

Broken ghostscript configuration


"cp: failed to access ‘user@remote/home/file’: Not a directory" when copying a file over ssh, using cp file user@remove syntax

Use scp

DESCRIPTION
     scp copies files between hosts on a network.  It uses ssh(1) for data
     transfer, and uses the same authentication and provides the same security
     as ssh(1).

The basic syntax is essentially the same as that of cp

scp paper.pdf karnivaurus@server.uni.ac.uk:/homes/karnivaurus/foo/

or

scp paper.pdf karnivaurus@server.uni.ac.uk:~/foo/


How do I fix a "failed to list contents of container" error?

Does your OpenStack installation have an object store? You need swift in order to use Juju with OpenStack as Juju uses it to cache items there. That error means you don't have an object store that's available within Keystone


this is what I'll do
make two partitions, one to store data and other for Ubuntu as you have 500 gig make 400 gig for data and leave 100 gig unpartitioned
now start installation and choose to install it in unpartisioned space.  Ubuntu will select the recommended partition format depending on your hardware  The above one is simple but if you want to manually partition then make a partition home folder, one for swap(9gig) and one for the system


Things That Can Be Made In Shell Script?

Bash is Turing-complete. You can implement anything in it that can be implemented in another Turing-complete language, such as Python or C.


How can I get all the URL of the dependencies of a deb package?

You can use apt-get and the --print-uris option to show URI's:

sudo apt-get --print-uris install geany
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following extra packages will be installed:
  geany-common
Suggested packages:
  libvte9
The following NEW packages will be installed:
  geany geany-common
0 upgraded, 2 newly installed, 0 to remove and 0 not upgraded.
Need to get 3,242 kB of archives.
After this operation, 8,894 kB of additional disk space will be used.
Do you want to continue [Y/n]? y
'http://archive.ubuntu.com/ubuntu/pool/universe/g/geany/geany-common_1.22+dfsg-2ubuntu1_all.deb' geany-common_1.22+dfsg-2ubuntu1_all.deb 2153292 MD5Sum:e7dc7ca72d4e3b27ebfeadaea9fb3289
'http://archive.ubuntu.com/ubuntu/pool/universe/g/geany/geany_1.22+dfsg-2ubuntu1_amd64.deb' geany_1.22+dfsg-2ubuntu1_amd64.deb 1089150 MD5Sum:e201bf70fc0ef23b0f64c410125814cb

This is the simplest method and without installing anything extra.

apt-get man excerpt:

--print-uris
       Instead of fetching the files to install their URIs are printed. Each URI will have the path, the
       destination file name, the size and the expected MD5 hash. Note that the file name to write to
       will not always match the file name on the remote site! This also works with the source and update
       commands. When used with the update command the MD5 and size are not included, and it is up to the
       user to decompress any compressed files. Configuration Item: APT::Get::Print-URIs.


actually you can't delete a root folder if  you are not having root authority .

actually to delete a folder and all of its contents even subfolders we have a command like

sudo rm -rf < path of the folder >


Ubuntu freezes in the Ubuntu logo (initialization) when I try to install from USB (dual boot)

I had the same problem with my GTX 950M and my skylane i5.

I solved it changing the boot options in grub (e key) and setting "nomodeset" flag for installing the SO.

Following, i install the privative drivers and the skylane firmware for my processor: https://01.org/linuxgraphics/intel-linux-graphics-firmwares

Hope that helps you.


It looks to me that your system is changing your theme to one that uses the Faenza icons set. Check if you have any themes that use these icons on your system and if you don't want it, just remove it. That maybe will do the trick.

By the way, do you have something in ~/.themes in your Home folder?


How to disable downloading, file transfer and installation option in ubuntu?

You can do this with user permissions. Just set up different groups, with different privileges, for each of the 'roles' you might want to assign people, and then assign their user account to the relevant group.

This answer shows how you can do it with a fairly simple GUI. Just install gnome-system-tools through the software centre or from the command line and you should be able to see how to set things up.


How can I enable remote control/desktop sharing on lubuntu

The right way to configure screen sharing in Lubuntu/LXDE is to install x11vnc and create an auto-start file.

1) install x11vnc:

sudo apt-get update && sudo apt-get install x11vnc

2) set password:

brian@localhost:~# x11vnc -storepasswd
Enter VNC password: ********
Verify password: ********
Write password to /home/brian/.vnc/passwd?  [y]/n y
Password written to: /home/brian/.vnc/passwd

3) Start the vnc server:

sudo x11vnc -auth guess -forever -loop -noxdamage -repeat -rfbauth /home/brian/.vnc/passwd -rfbport 5900 -shared &

4) Create the autostart file in /etc/init sudo vi /etc/init/x11vnc.conf

# description "Start x11vnc on system boot"

description "x11vnc"

start on runlevel [2345]
stop on runlevel [^2345]

console log

respawn
respawn limit 20 5

exec /usr/bin/x11vnc -auth guess -forever -loop -noxdamage -repeat -rfbauth /home/brian/.vnc/passwd -rfbport 5900 -shared

Now every time you reboot the server will be running and you can connect to it from another system with a vnc viewer program:

sudo apt-get update && sudo apt-get install vncviewer


You can install lm-sensors (sudo apt-get install lm-sensors) to check both fan speed and temperature.
Here is the documentation


Unity 2d vs 3d and launcher icon resizing

Fixed it!

Following the instructions on this thread, http://ubuntuforums.org/showthread.php?t=1741783, I removed the nvidia-current and nvidia-settings packages.

sudo apt-get purge nvidia-*

Now I'm able to log into an Ubuntu-3d session. Once in an Ubuntu-3d session, I'm able to resize the dock, and snap windows to the sides of the screen.


Any flavor of Debian or UBUNTU still being made in amd64+mac version?

Use 14.04 amd64+mac LIVE USB to install Xenial.

Install the base 14.04 and don't do the updates, they will be wasted time and bandwidth.

Replace the /etc/apt/sources.lst with Xenials version generated from https://repogen.simplylinux.ch/

Then CTRL-ALT-F1 to a terminal. Login. Run 'sudo -i'. Enter your password.

Run 'apt-get update' then 'apt-get dist-upgrade'

Finish with an 'apt-get autoremove' then 'reboot'

Do not install AMD64-MICROCODE yet as it has problems as of this post.

Enjoy Xenial! Keep your 14.04 AMD64+MAC image in a safe place as this is your gateway to installing new distros. This is not an official fix, it's just a workaround that worked for me. Your mileage may vary.

**If you installed AMD64-MICROCODE by mistake(after rebooting into Xenial your driver manager app will suggest it) and can't boot your laptop anymore. Do not worry, you won't have to reinstall everything all over again. Boot from your 14.04 AMD64+MAC live USB and follow these instructions on this answer: How to restore a system after accidentally removing all kernels?
Except you will also add 'sudo mount --bind /boot /mnt/boot' to the list of special partitions to mount. The command you will run is 'sudo apt-get remove --purge amd64-microcode' then follow the rest of the answer to exit, unmount, and reboot.

*** You can also just do numerous 'do-release-upgrade' until you get to 16.04.  That worked for me as well.


If your input consists of records that are separated by one or more blank lines, then you can use awk or perl in paragraph mode

awk -vRS= '/100%/ {print $1}' file >> newfile

or

perl -00anE 'say $F[0] if /100%/' file >> newfile


Synaptics touchpad disabled after login after recent 18.10 update

According to the Ubuntu help docs, this problem is often solved using the following command:

gconftool-2 --set --type boolean /desktop/gnome/peripherals/touchpad/touchpad_enabled true

You can also enable or toggle the touchpad using synclient instead of xinput.

To enable:

synclient touchpadoff=0

To toggle:

synclient touchpadoff=1
synclient touchpadoff=0

Additionally, you could try using a different device listed like device 16 instead of 11:

xinput set-prop 16 "Device Enabled" 1

click here for additional information


As Google Chrome is a proprietary application it will never be available in Ubuntu repository, but you can install the Chromium web browser that also support the Google Chrome apps and you can also access the Chrome Web Store from it.

To install Chromium run the following command at the Terminal:

 sudo apt-get install chromium-browser

To install Google Chrome go to http://www.google.com/ and search for "Get Google Chrome"


How to make space in /boot/efi without resizing the partition?

Update:
I followed these steps and it's a better way of doing it than moving fonts manually.
apt update && sudo apt upgrade -y
service fwupd start
fwupdmgr refresh
fwupdmgr update

Original comment: In my case I resolved it by simply finding some (probably) unimportant files and moving them to a backup folder outside of /boot/efi. For example, the boot-repair/log files came to around 3 MB, and some of the /EFI/Microsoft/Boot files had folders for languages I would probably never need. This allowed me just enough space to perform the update.
The only problem was that on power up it went straight to Windows, without giving me the grub menu after the BIOS screen. I resolved that, in Windows, by opening a command prompt as system admin, then running
bcdedit /set {bootmgr} path \EFI\ubuntu\grubx64.efi

But I'm sure you're aware of all the warnings, so be careful to do any backups before this.


bash script - tar Cannot stat: No such file or directory, exiting with failure status due to previous errors

Do you have rights to write into DESDIR folder?

Also, to avoid "tar: Removing leading `/' from member names" try this:

tar cpzfP $DESDIR/$FILENAME $SRCDIR

I don't know why, but this works for me.


How to enable installation packages, sudo apt-get update in TTY in 18.04

I would venture to say that you are in need of a complete reinstall. Deleting all configuration files will be extremely hard to fix. Also NEVER delete Python. If you need other versions, learn to use virtual Python environments.


NetBeans has broken interface with OpenJDK

I had the same error. netbeans interface was distorted.

$ sudo apt-add-repository ppa:webupd8team/java

$ sudo apt-get update

$ sudo apt-get install oracle-java7-installer

after :

:/opt$ java -version
java version "1.7.0_72"
Java(TM) SE Runtime Environment (build 1.7.0_72-b14)
Java HotSpot(TM) 64-Bit Server VM (build 24.72-b04, mixed mode)

netbeans returned to work.


When I open a folder in Nautilus all of the files rearrange themselves

I'm going to post this as an answer because I don't see many other options here. So, there is already an open bug report for Nautilus being slow when opening with lots of files (never got a response as to how many files you had on the drive). It's been open for a really long time with no resolution Nautilus Bug Report

Assuming this is your problem, the only solution would be to install a different file manager that doesn't have that problem (Dolphin and Midnight Commander are specifically mentioned in the bug report as not having that issue).

Another possible solution would be to re-install Nautilus. This has worked for people who saw errors displayed when opening Nautilus through the terminal. To do that: sudo apt-get install --reinstall nautilus

Other than that, you could move your files over to your SSD (if you have space), open a new Nautilus browser and see if the problem persists (assumes the problem is in software and doesn't depend on disk read times which will obviously be faster with the SSD). I wish I could have provided a silver bullet to speed up Nautilus, but there doesn't appear to be one. Check the health of your disk also using the "Disks" application and see if that reports any problems with your spinning HDD. Please respond if any of these work for you.


Ubuntu 16. 10 has experienced an internal error

I had a similar problem save for I have 16.04 and my show details only showed the following:

/usr/bin/gnome-software

What I did to fix it was quite a bit of googling which lead me here https://answers.launchpad.net/ubuntu/+question/404433

Eventually I did

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

Haven't seen the problem since then. I hope this helps you out.


Samba 2:3.6.25-0ubuntu0.12.04.2 as PDC (samba3 NT4 domain) Windows machines lost trust after USN-2950-1 update

I have the same problem:

https://serverfault.com/questions/771388/how-can-i-fix-samba-3-6-25-the-trust-relationship-between-this-workstation-and

A workaround is to reinstall the old packages (see the link).


Run the following commands:

rm ~/.local/share/gnome-software/*
sudo apt-get upgrade gnome-software
sudo apt-get update

This will solve the problem


I recommend Referencer. You can download it using apt-get. It supports tagging files with fields such as author, title, journal and publisher, etc. For many research papers it will automatically download the data for you provided there is a DOI identifier inside the file. It can also generate BibTex files automatically.

However, it does not store your references online. I use it with git myself, and it works nicely.


How to configure preferred network for internet?

Go to system settings -> Network -> wired

Then click on options, select IPV4 tab, and click on routes.

Finally enable the Use this connection only for resources of its network

This way Ubuntu will use only Wireless for accessing the Internet


Apparently the script couldn't find the .jar file.
When I run the bash file using the .desktop file, I assume it runs the bash file in the directory of the .desktop file (~/.local/share/applications).

When I give the full path name to the jar, it works fine:

#!/bin/bash
java -Xmx1024M -Xms512M -cp /home/bram/Applications/Minecraft/minecraft.jar net.minecraft.LauncherFrame


I want to copy all pdf files into another directory

not with a for loop but this should work to move the files.

mv /home/username/Downloads/*.pdf /home/username/Downloads/BOOKS

Use this to make a copy of the files:

cp /home/username/Downloads/*.pdf /home/username/Downloads/BOOKS


When I tried to repair my ubuntu, I had the same problem. The message I got was "The recovery media tool only functions on Dell and Alienware systems".

Then, I followed the instruction on Dell support website:
http://www.dell.com/support/Article/us/en/19/SLN297060/EN

Then, I changed the boot sequence and boot ubuntu 14.04 from my usb.
It works! :)

My laptop is Dell inspiron 15


Skype 4.1 keeps crashing on Ubuntu 12.10!

Unninstall Skype and remove the Skype ppa from Software Sources then install Skype from the normal repositories.

Open Software Sources or open Update Manager and select Settings.
Under the Other Software tab look for the Skype repositories and delete them.
Open a terminal (Ctrl + Alt + T) and type sudo apt-get update
Open Ubuntu Software Center and search for Skype. Click Install.

Enjoy.


Setting up local static IP with netplan causes network to sleep

cloud-init
Your /etc/cloud/cloud-init.disabled should be in /etc/cloud/cloud.cfg.d/99-disable-network-config.cfg and have the following contents...
# To disable cloud-init's network configuration capabilities,
# write a file /etc/cloud/cloud.cfg.d/99-disable-network-config.cfg
# with the following content:
#
network: {config: disabled}

swap
You have no /swapfile or swap partition. Let's create one...
Note: Incorrect use of the dd command can cause data loss. Suggest copy/paste.
sudo swapoff -a           # turn off swap
sudo rm -i /swapfile      # remove old /swapfile

sudo dd if=/dev/zero of=/swapfile bs=1M count=4096

sudo chmod 600 /swapfile  # set proper file protections
sudo mkswap /swapfile     # init /swapfile
sudo swapon /swapfile     # turn on swap
free -h                   # confirm 4G RAM and 4G swap
reboot                    # reboot and verify operation

Add this line to /etc/fstab...
Note: Verify that you have no other swap lines in /etc/fstab.
/swapfile    none    swap    sw      0   0

Update #1:
About the swap, I can't do since this is going to be a Kubernetes node, which requires swap to removed.


"command not found" when running a script via cron

To avoid having to type the absolute path to a command, shells introduced the $PATH environment variable, each directory is separated by a : and searches are done from left to right. cron often clears the whole environment, including this $PATH variable. Therefore, the script may behave differently in your cron compared to the behavior in the shell.

Use absolute paths

Run which db2 as db2inst1 user to get the full path for the db2 program. If the output is /usr/bin/db2, your cron command would look like:

/usr/bin/db2 connect to myDB2

Set the PATH variable

Run echo "$PATH" as db2inst1 user to get the $PATH variable and make sure this variable is available in your cron script too. For example, if the output was /usr/local/bin:/usr/bin:/bin, you would put the next line in the top of your shell script:

export PATH="/usr/local/bin:/usr/bin:/bin"


cant tether samsung gs7 (android) to 16.04.1

I got the same problem. And as I see there are no answers although the question is 2 months old. So possibly you're still waiting for a solution.
I realized that the internet routes were not ok. The default route was missing.
You can check that with "route -n". If there is no route to 0.0.0.0, you got the error. You can add the default route with the command "sudo route add default gw XXX.XXX.XXX.XXX". You can get the required IP address XXX.XXX.XXX.XXX by the command ifconfig. Look for inet address and change the number of the last group to 1. For example: 192.168.1.49 to 192.168.1.1. I tried to do this with the network manager, but I failed.
You also need to add a dns server. This should best be done with the network manager. So right click on the connection and add 8.8.8.8 as dns server or any other server you like.
I assume this is a bug in either the Samsung phone or Ubuntu. So this is more or less a workaround.


To back up MySQL DB on one server and restore on another, do I need the same version of MySQL?

It is preferred but not required. If there is an issue between releases you will be notified though (and with a message that states there is a problem with a specific command or table).

The dump contains all the files for exported database but does not create the database itself. So on the server where you restore the database needs to be created if it does not exist.

Example export:

-- MySQL dump 10.11
--
-- Host: localhost    Database: xxxx
-- ------------------------------------------------------
-- Server version       5.0.96-0ubuntu3

/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;

--
-- Table structure for table `xxxx`
--

DROP TABLE IF EXISTS `xxxx`;
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `xxxx` (

There is no creation of the database in the export.


CLI command for powering off Flash-Drive "disk"

To have confirmation that de flash drive is unmounted you can use the command lsblk.  That wil show you al te mounted drives in your system.
Take the command && umount ... out of the script and try running umount manually on the command line. See if this make a difference.
If positive you need to adjust your script. At first I would delete the && and type umount on a new line.
Please note that all access to the flash drive must be closed before unmount can be performed.


terminal run a specific command as it starts up (cmatrix startup)

simply add commands into fish config file

echo 'any command (eg. cmatrix -s)' >> ~/.config/fish/config.fish


Chinese characters don't display in Firefox 57.0

For simplified Chinese:

Go into Preferences.
Go to Fonts and Colors (under the General tab).
Go into Advanced.
Select Simplified Chinese.
Change Serif to WenQuanYi Micro Hei.
Change Sans-Serif to Noto Sans CJK SC.
Change Mono to Noto Sans Mono CJK SC.

These instructions apply mutatis mutandis to traditional Chinese; in this case the Noto Sans typefaces have "TC" in their names. Suit typeface selection to taste; just ensure that chosen typefaces have the requisite characters.


Combination key like ctrl or alt or shift doesn't work on ubuntu 16.04

Those keys are not global. Gnome Terminal for instance uses Shift+Ctrl+C and Shift+Ctrl+V for cut and paste. Use Ctrl+Insert to copy and Shift+Insert to paste.


Ubuntu 18.04 - how to change keyboard shortcuts without Gnome control center GUI?

you can get the current key combination for switching the input-source and input-source-backward by running the below command look for the once matching

gsettings list-recursively | grep input-source

Example:

parrot@i7-4770U:~$ gsettings list-recursively | grep input-source
org.gnome.desktop.wm.keybindings switch-input-source ['<Super>space']
org.gnome.desktop.wm.keybindings switch-input-source-backward ['<Shift><Super>space']
ca.desrt.dconf-editor.Settings saved-view '/org/gnome/desktop/input-sources/xkb-options'
org.gnome.desktop.input-sources show-all-sources false
org.gnome.desktop.input-sources xkb-options @as []
org.gnome.desktop.input-sources per-window false
org.gnome.desktop.input-sources current uint32 0
org.gnome.desktop.input-sources mru-sources [('xkb', 'us'), ('xkb', 'de')]
org.gnome.desktop.input-sources sources [('xkb', 'us'), ('xkb', 'de')]
parrot@i7-4770U:~$

the above result says Super+space and Shift+Super+space are the ones..

you can put your own keycombinations with the below command but it does not guarantee that the key combo will work..

for example:

gsettings set org.gnome.desktop.wm.keybindings switch-input-source "['<Super>i']"
gsettings set org.gnome.desktop.wm.keybindings switch-input-source-backward "['<Shift><Super>i']"

Edit:

if you want to make Ctrl+Shift as a Shortcut for Switching the Layout
you can either use gnome-tweaks like this

But you need to press Shift first and then Control or Control+2 times Shift for the first time..

the commandline way to achieve this is

gsettings set org.gnome.desktop.input-sources xkb-options "['grp:ctrl_shift_toggle']"

again in this way you will loose graphical representation that is not equivealent to changing the input-language via default shortcut Super+Space


What is a secure and reliable alternative to Skype?

Both Teamspeak and Mumble are in my opinion better than Skype. They use less resources than Skype but require a server to run.

So either you set up a server yourself or you find an open server.

Teamspeak and Mumble are basically the same, both require a server to run and both have better sound quality than Skype. They are both available for different platforms although Mumble has better support for Linux.

They have different security options. You can put a server password so that only some users may get onto the server, or you can set different user levels so only some users may enter specific rooms. Both models are good, but I prefer the user levels since this allows everyone to access and use some rooms and also gives specific users more private rooms.

Both Teamspeak and Mumble are popular in Clan games, since it's easy to connect to a server and find people to talk to.

More information about both programs can be found below,

Teamspeak
Mumble


Problem upgrading Ubuntu 14.04 to 14.04.01

Have you installed Ubuntu Server edition? If so try doing

sudo apt-get update
sudo apt-get install ubuntu-desktop

You should get the GUI.


How to fix Fresh Ubuntu minimal server missing locale?

Open a terminal and perform this commands:

sudo locale-gen et_EE et_EE.UTF-8 en_US en_US.UTF-8
sudo dpkg-reconfigure locales


How to clone displays with my laptop and an external HD Monitor

I'm not sure I understood the question well, but to change the view modes for the screen, you can use xrandr. With that you can flip the screen, invert the output (upside down, mirrored), etc. (and it also handles dual screens? maybe?)
Good luck!


How do I fix the Gparted message : Error while reading block at sector xxx?

You have bad sectors on your hard disk.  Back up any important data NOW.  Then run the disk utility and click the SMART diagnostics.  Run the long self test, and when that finishes, look at the values of the following attributes:

Offline_Uncorrectable
Current_Pending_Sector
Reallocated_Sector_Ct

If the uncorrectable count is non zero, or the reallocated or pending counts are more than a few, you need to replace the drive.  If there are only a few pending, then you can attempt to repair them.  First you need to identify the number of the bad sector.  The badblocks utility can be used for this.  Then you can use hdparm --read-sector to try reading from it to make sure you have the right one, and then hdparm --write-sector to try and rewrite the sector with zeros.  That will force the drive to try to correct the sector, or if it can not, will reallocate it from the spare pool, moving a count from the pending_sectors to reallocated.  Repeat for all bad sectors.


Unable to see Desktop in 12.10 after installing AMD Catalyst

If you are using desktop (which looks like from the description), that tutorial was not for you. Hybrid chips are something different. Those are available only if you use some processor like i5/i7 where  graphics is built in with processor (not motherboard)  and mainly found in laptop to save power. The two graphics card are inter-connected (which is not in case of desktop, you connect monitor to either one of them)

Revert back what you did from  the following point, it should work fine.

STEP 2 - Enabling, fixing the bug for direct rendering on the integrated card :  in the tutorial.

OR

Remove all display driver (or perform a clean installation)

Use Addtional drivers in ubuntu to install the required driver.


Cannot click and drag with touchpad after upgrade to 18.04

I was finally able to find a solution: installing the xserver-xorg-input-synaptics package made it all work; it even improved the sensibility of the trackpad.


write commands from windows 7 and in ubuntu server

Oh that's simple :)

do the following

SERVERSIDE

apt-get install openssh-server

Windows side!

install putty

With putty connect to the server using SSH, ofcourse you need the ip first of the server so on the server do ifconfig, put that in putty and you have a SSH tunnel to your server, you logon with your credentials and now you have a Linux cli on windows 7 that controls your server


Unfortunately this is a common problem for me. It turns up with older or GPU on-board computers. Actually I think display resolution is one of the very sore points of the otherwise excellent hardware handling of Ubuntu.

Here is a lengthy procedure with all the stuff to follow. Basically you force the PC to set a certain resolution, because you know the native resolution of your monitor. Do not use this if you monitors change very often.
You will find out the right resolution parameters (no need to understand them), and preserve them in a file called "/.xprofile" in your home directory. In my installation that was usually missing, so I created it. The only content was the resolution setting, which is fine.

Hope it helps

Procedure

When the monitor is just detected as default standard, the screen resolution might be limited to e.g. 1024x768. That is even with the proprietary Linux drivers installed, e.g. on a GTX580 machine. The nVidia desktop panel is just a hollow shell to write driver parameters into a gui instead a text file. It misses all actual parameters, the only input choice is free text.

When the Desktop GUI tool has set a too high resolution for the monitor/projector to display, go to a terminal and delete the file

rm ~/.config/monitors.xml

List available resolutions with xrandr

xrandr

Set another resolution with xrandr. Those last for the current settings. The modes must exist with xrandr.

xrandr --output LVDS --mode 1920x1080 --rate 60
xrandr --output VGA1 --mode 1280x1024

Make sure in your "99-vesahack' file has a high enough video RAM setting. A value too low may be the cause that no higher resolutions are allowed. The value 10000 is considered high enough to cover all modes

sudo nano /use/shared/X11/xorg.conf.d/99-vesahack
   Section "Device"
    Identifier "Screen0"
    VideoRam 10000
  EndSection

The port names differ by driver!

Analog: intel UMS=VGA, intel KMS=VGA1, radeon=VGA-0
Laptop scren: intel ums=LVDS, intel KMS=LVDS1, radeon=KVDS
DVI:  intel ums=TMDS-1, intel KMS=DVI1, radeon=DVI-0
DP1 = display port output
TV = integrated TV output

See the status of available and used resolutions

xrandr -q

Set a new, not yet existing mode with xrandr for the session use the cvt command. It calculates from the current monitor timing the values for a propper display format for the monitor.
The example is to add a mode for HDTV 1920x1080 with 60Hz. Note that the cvt numbers are wrong for that res.

xrandr -q                  / note the name of the connected screen, e.g. DVI-I-1
cvt 1920 1080 60
# 1920x1080 59,.86Hz (VCT 0.48M3) hsync:37.25 kHz; pclk:38.25MHz
Modeline "1920x1080_60.00" 38.25 800 832 912 1024 600 603 607 624 -hsync +vsync      // copy this part with mouse select & click
xrandr --newmode "1920x1080_60.00" 38.25 800 832 912 1024 600 603 607 624 -hsync +vsync
xrandr --addmode DVI-I-1 1920x1080_60.00
xrandr --output DVI-I-1 --mode "1920x1080_60.00"

Possibly omit the '"' around the mode term

Add those lines to the ~/.xprofile file. Create it if it does not exist. In the above example it looks like

$ne .xprofile
    #!/bin/bash
    xrandr --newmode "1920x1080_60.00" 38.25 800 832 912 1024 600 603 607 624 -hsync +vsync
    xrandr --addmode DVI-I-1 1920x1080_60.00
    xrandr --output DVI-I-1 --mode "1920x1080_60.00"
$chmod 755 .xprofile

You can manually start the script as well

sudo ./.xprofile

Remember that the data is different for each pc!


wireless low sensitivity hp pavilion dm1 on ubuntu 11.10

Had the same problem with the same card BCM4313. You don't use the proper driver (brcmsmac), the proper driver is wl.

Install the proprietary one from Broadcom.

Then blacklist in /etc/modprob.d/blacklist.conf

blacklist bcm43xx
blacklist brcmsmac
blacklist bcma
blacklist b43
blacklist ssb

Restart and check that:

lspci -k | grep  wl

Hope it works for you like for me (very strong signal).


Try installing Lubuntu it requires significantly less memory. 256mb is unusable with the default desktop manager Unity.


How do I change my boot animation back to the default after install of Lubuntu-desktop?

If you want to change your boot screen, run the below command:

sudo update-alternatives --config default.plymouth

This will bring up a prompt where you can select which boot animation you want to use. Choose the ubuntu-logo entry, and hit Enter.

When you're done, update your system's cache using this command:

sudo update-initramfs -u

Upon next boot, your boot animation will be back to normal.

(source)


Have installed adobe digital editions but cannot run it under wine

Installation via winetricks worked very well for me.

Install winetricks:

sudo apt-get install winetricks

then run winetricks and follow the instructions. Run ADE from the dash.


Is there another way to restart the sound system if pulseaudio/ALSA don't work?

I've used pulseaudio -k && sudo alsa force-reload a couple of times, and it worked well. The first part kills pulseaudio, the second reloads ALSA. You don't need to restart pulseaudio, because it auto-restarts.


Equivalent of OSX "open" in Ubuntu Unity?

I don't know anything about xdg-open, but I do know something about Emacs. Does async-shell-command not work for you? If not, one of the low-level Emacs async commands should definitely do the trick. See http://www.gnu.org/software/emacs/manual/html_node/elisp/Asynchronous-Processes.html#Asynchronous-Processes for info on that.

If you can't get those to work, lemme know; if start-process can't do it for you, there is a bug in Emacs (or xdg-open is a seriously weird command!)


Freeze when going to fullscreen on Chrome

There is 2 ways to half-solving this problem :

1st - is to disable hardware acceleration in Chrome, but this will decrease performance. (blurry scrolling and vertical lines)

2nd - Open videos in Firefox.

If anyone has a better solution please post here. Tx a lot.


Late reply but:

Reboot with an OSX installation disc or Recovery HD
Start the Terminal
Issue the command:

/usr/sbin/nvram SystemAudioVolume=%01


How do I move my Home directory onto a USB EXT4 drive (18.04)

Copy home to Portable USB drive

Format flash drive to ext4.

As root use Grsync to copy home/{username} from internal drive to the flash drive. Preserving owner, permissions and group works for me.

Copy or write down UUID of the new partition.

Edit /etc/fstab on the internal drive to add the /home UUID:

UUID={UUID from above} /home   ext4    defaults        0       0

It might be a good idea to use an encrypted home when traveling.

Thanks to ubfan1 for hint


My dell xps 9560 has turned into a brick after Kubuntu 17.10 upgrade

I solved!

After hours of googling I realized that, more or less as I was guessing there is a weird incompatibility with recent linux kernels (above 4.10.0-21) and the Dell XPS, but fortunately the problem is not actually in the kernel but in the nouveau driver when a recent linux kernel is used.

I've updated and changed several things on my machine, including a BIOS update (I had 1.2 and now 1.7) by following this post (even if in my case I used the explicit bios upgrade option since by following the author steps I got errors): https://www.calazan.com/ubuntu-users-how-to-upgrade-the-bios-of-your-dell-xps-13-ultrabook/ ...but in the end the real fix has been just to set a parameter in the grub boot settings:

noveau.modeset=0

In order to do that i pressed left shift key during the boot, then pressed "e" and added the setting... later on, in order to make the change permanent:

sudo nano /etc/default/grub

and defined:

GRUB_CMDLINE_LINUX="nouveau.modeset=0"

then:

sudo update-grub

Before disabling the noveau I was experiencing an ACPI failure and the first "fix" I found by googling was to disable acpi (apci=off in boot options)... but this is a bad move, since by disabling the apci (which I discovered is the "Advanced Configuration and Power Interface") you won't be able to leverage the power of the xps, since Hyperthreading (which is an Intel technology for which for each single physical core a virtual one is created) will be disabled (so you'll get 4 usable cores instead of 8!) and moreover you won't be able to properly shutdown the system via software (you need to press the power button "to confirm").

The post that has helped me a lot has been this one: https://rileymacdonald.ca/2017/06/26/ubuntu-broken-boot-on-dell-xps-15-after-kernel-update-upgrade/


Why does cURL think I am downloading something?

Nvm, it was an easy fix:

curl -d "$(curl -s localhost:8080/fetchStrs)" localhost:8080/uppercase,toChars -H "Content-Type: application/json"

-s will do it silently.


Does updating firmware updates the bios in ubuntu 18?

No, it does not. A BIOS generally will only accept firmware updates from a flashdrive formatted in a specific way and with specific files on it in a specific way, when inside the BIOS menu. I'm pretty sure of this, given my experience updating the BIOS and firmware of some computers.


colord problem & my monitor resolution 640*480 with no other options!

First remove current nvidia driver.

sudo apt-get remove nvidia-current

Instruction for installing Bumblebee to turn off  discrete  GPU and enable only when required

Type the following in terminal,

sudo add-apt-repository ppa:bumblebee/stable

then

sudo apt-get update
To install Bumblebee using the proprietary nvidia driver:

sudo apt-get install bumblebee bumblebee-nvidia
Run following

sudo usermod -a -G bumblebee $USER
Reboot.

If you just want to disable nvidia card, no need to learn followings

Usage Instruction :

To run a program with nvidia card, use optirun command prefixed in terminal.
Like to run glxspheres with nvidia card type

optirun glxspheres

To run firefox type : optirun firefox &

Note: If you intend to run 32-bit programs like Wine and using Ubuntu 11.10 Oneiric or later, install 32-bit libraries with:
sudo apt-get install virtualgl-libs:i386 libgl1-mesa-glx:i386 libc6:i386

Linked Questions:

How well will Nvidia Optimus cards be supported in 12.04?

Is a NVIDIA GeForce with Optimus Technology supported by Ubuntu?

Can't use nvidia card/driver on optimus notebook


"rtnetlink answers device or resource busy"

I think it means exactly what it says. The device  wlan0 is busy sending and recieving data to your router or access point, getting email, etc. I suggest that you tell it to stop:

sudo ifconfig wlan0 down

And try again:

sudo iwconfig wlan0 mode ad-hoc essid my-mesh-network ap 02:12:34:56:78:9A channel 1

If you have Network Manager running, you will probably need to stop it first:

sudo service network-manager stop


So I located the different versions of libpng16

locate libpng16.so.16
/home/julien/Software/Sen2Cor-2.4.0-Linux64/lib/libpng16.so.16
/home/julien/Software/Sen2Cor-2.4.0-Linux64/lib/libpng16.so.16.25.0
/home/julien/Software/VirtualGL/libpng-1.6.0/.libs/libpng16.so.16
/home/julien/Software/VirtualGL/libpng-1.6.0/.libs/libpng16.so.16.0.0
/opt/ardour4/lib/libpng16.so.16
/usr/lib/i386-linux-gnu/libpng16.so.16
/usr/lib/i386-linux-gnu/libpng16.so.16.34.0
/usr/lib/x86_64-linux-gnu/libpng16.so.16
/usr/lib/x86_64-linux-gnu/libpng16.so.16.34.0
/usr/local/lib/libpng16.so.16
/usr/local/lib/libpng16.so.16.0.0
/usr/local/lib/libpng16.so.16.34.0
/usr/local/lib.bak/libpng16.so.16
/usr/local/lib.bak/libpng16.so.16.0.0
/usr/local/lib.bak/libpng16.so.16.34.0

I tried to find the lib which did not have the right symbol

/usr/lib/x86_64-linux-gnu$ nm -D /usr/lib/x86_64-linux-gnu/libpng16.so.16 | grep png_set_option
0000000000008e00 T png_set_option

This does not return anything (symbol is absent)

nm -D /usr/local/lib/libpng16.so.16 | grep png_set_option

So I made a symbolic link from the bad lib /usr/local/lib/libpng16.so.16 to the good one /usr/lib/x86_64-linux-gnu/libpng16.so.16

sudo ln -sf /usr/local/lib/libpng16.so.16 /usr/lib/x86_64-linux-gnu/libpng16.so.16

Hope this help, unfortunately this can be broken when updating. Don't forget to backup /usr/local/lib/ before in case you break it

sudo cp -R /usr/local/lib /usr/local/lib.bak

This solution is inspired from this post


Use output redirection to /dev/null and include stderr output.

add-apt-repository -y ppa:ondrej/php5-oldstable > /dev/null 2>&1

The 2>&1 will tell Bash to redirect stderr to stdout.
The command > file stanza will redirect stdout to a file, in this case /dev/null.
/dev/null is the black hole of Linux - you won't be able to recovery anything from there.

Result: full silent execution of your command.

In your updated question you seem to log all output to a file. In that case you can just append the 2>&1 to your current line:

add-apt-repository -y ppa:ondrej/php5-oldstable >> /tmp/output.txt 2>&1

This is because you were looking at the stderr output being printed on the terminal, which you need to redirect to the log as well (otherwise you will miss out on all errors!).


After looking carefully at the outputs from du and similar tools, I discovered that the big directory is /var/lib/schroot.

So I moved it to another place

sudo mv /var/lib/schroot ~/Dati/SDK

and the symlinked it

sudo ln -s ~/Dati/SDK/schroot /var/lib/

Until now, it works.


Closed laptop lid during installation, black screen

I am not sure that any damage has been done, but I don't see how powering off your device could make it worse at this point.

You will need to reinstall Ubuntu though. Install it in the 17G partition, which should be formatted as ext4 and with / as the mount point. The bootloader should also go on the disk (not the partition) to let you choose the OS. The guide you mentioned has good points on this in the troubleshooting section.

If properly done the installation should take less than two hours, or at least you should notice some progress or animation.

(compiled from the comments)


VirtualBox unable to open VM after update

I suspect you have a mismatch between extpack and VirtualBox version. One solution is to remove the extpack. On my system you can see the name of the extension pack with this command:

andrew@ilium~$ VBoxManage list extpacks
Extension Packs: 1
Pack no. 0:   Oracle VM VirtualBox Extension Pack
Version:      5.0.8
Revision:     103449
Edition:
Description:  USB 2.0 and USB 3.0 Host Controller, Host Webcam, VirtualBox RDP, PXE ROM, Disk Encryption.
VRDE Module:  VBoxVRDP
Usable:       true
Why unusable:

And then I can uninstall the extpack as follows:

andrew@ilium~$ sudo vboxmanage extpack uninstall "Oracle VM VirtualBox Extension Pack"
0%...10%...20%...30%...40%...50%...60%...70%...80%...90%...100%
Successfully uninstalled "Oracle VM VirtualBox Extension Pack".

Try these 2 commands on your own system and then your VM should restart...


There is no software certification is available from ubuntu . But if you want to sell your app via software center , It must be verified by canonical(via myapps portal)


find . -type f finds all files of type f in the current directory and its sub-directories recursively where the f means that it finds only files including hidden files. find . -type f is piped by the pipe character | and to execute using xargs another command ( file ) . The file command tests each argument in an attempt to classify it. There are three sets of tests, performed in this order: filesystem tests, magic tests, and language tests. The first test that succeeds causes the file type to be printed.
find . -type f | xargs file interprets the spaces between words in a filename as separators, so it returns multiple results of file for the same file if its filename contains one or more spaces. This is an unwanted result for most users who want file to return only a single result for each file that is found by the find command, even if the file contains one or more spaces in its name. To correct this unwanted result change the command as follows:
find . -type f -exec file {} +

find . -type f -exec file {} + outputs the same results as
find . -type f | xargs file except that it returns only one result for each file that is found by find, even if the file contains one or more space characters in its name.


Updated to 18.04, PC freezes before the login screen (Ubuntu logo)

Finally I was able to solve the issue by uncommenting the line #WaylandEnable=false in /etc/gdm3/custom.conf


Desktop file for my python gtk3 app does not load the app

Does your application assume you are starting it from the folder /opt/NSTrain/? If so add the line

Path=/opt/NSTrain/

to your .desktop file. That tells Unity (or Gnome Shell or from whatever program you are using to start your application) to start your program in the given folder.

Without that line your application gets started from the current working folder of Unity (or whatever), which usually is your home folder. That will break your application if it assumes it is started from /opt/NSTrain/ and hence tries to open a file like /opt/NSTrain/somefile.dat just as somefile.dat.

If that doesn't help please start your application in a Terminal from your home folder using /opt/NSTrain/nstrain.py and post any error messages you get.


When you arrive at grub, you will get some options like
Ubuntu
Advanced Options for Ubuntu
Memory Tests etc...
when you click on second option (Advanced options for Ubuntu), we'll get last 4 latest Linux kernels.And respective additional kernels that will load in recovery mode.


Unable to locate package libgstreamer0.10-dev on Ubuntu 18.04

libgstreamer0.10-dev is outdated in Ubuntu 18.04.

So, use newer version instead:

sudo apt install -y libgstreamer1.0-dev libgstreamer-plugins-base1.0-dev

This will surely work.


Dual boot Windows 8 and Ubuntu 14.04 - Lost ability to boot from USB

Normally you can get to the firmware's boot manager via a function key, as Raphael implies. If that list is missing the USB option, though, it could be that the USB drive you're using is missing the necessary boot files; or maybe the firmware has flaked out and permanently removed the USB boot option. If the latter, you might be able to get it back by fiddling with options in the firmware setup utility. (Sorry, I can't be more specific; unfortunately there's so little standardization in EFIs that it's impossible to point to a specific option without knowledge of the specific EFI in question.) In a worst-case scenario, restoring the firmware's defaults might do the trick -- but that might also render the system unable to boot Ubuntu.

Another option is to install my rEFInd. Once it's installed, it should detect EFI-bootable USB flash drives automatically -- although you may need to hit Esc to get it to scan them if they're slow to register. Ordinarily I recommend trying rEFInd from a USB flash drive or CD-R before installing it, but that's not exactly possible for you, so you'd have to jump straight to installing it via the Debian package or PPA.


Use multiple monitors as one big monitor

xrandr is the utility to produce the display layout that you want.
xrandr --output "DP-1-1" --mode "3840x2160" --output "DP-1-2" --right-of "DP-1-1" # launch a window manager
vim # vim spans both monitors if you only have a single window


How can I determine which font is broken?

Source: bug 616169 comment made by martin-autotelic

Quote:

  I've solved this problem for me.  Following information here: http://ubuntuforums.org/showthread.php?t=1487447 Basically I removed all Japanese fonts listed as installed in Synaptic, and then installed only these:

ttf-kochi-mincho-naga10
ttf-kochi-gothic-naga10
ttf-sazanami-gothic
ttf-sazanami-mincho

  Now I am getting the correct kanji consistently. Unfortunately, I do not know which of the fonts I uninstalled was corrupted, as I do not have the time to test and experiment. I will report if I work it out, though.

If you want to exactly know what font is messing up you will have remove all of them and have to start adding fonts one at a time and check if the problems starts to show up (lot of work but if you do please update the bug ;) ) To give you a headstart these fonts in the ubuntuforums link mentioned in the quote have been called not to be the culprits by user Frantic_Earthling:

ttf-umeplus
ttf-kochi-mincho-naga10
ttf-kochi-gothic-naga10
ttf-sazanami-gothic
ttf-sazanami-mincho
otf-ipafont-mincho
otf-ipafont-gothic
otf-ipaexfont-gothic
otf-ipaexfont-mincho
anthy
libanthy0
ttf-takao-pgothic
ibus-anthy
libtext-wrapi18n-perl
acroread-fonts
python-chardet
im-switch


hosts file and unclear behavior. How to make real alias?

You can definitely direct a host name to an IP address on your LAN with Ubuntu's hosts file, but it does not support the particular syntax you're using. From man hosts:

  This file is a simple text file that associates IP addresses with
  hostnames, one line per IP address. For each host a single line should
  be present with the following information:

IP_address canonical_hostname [aliases...]

The hosts file in Ubuntu does not direct hostnames with other hostnames, but only with IP addresses.

Therefore, instead of writing:

192.168.10.10/site.ru    site.ru

You should instead write:

192.168.10.10            site.ru

This will cause site.ru to be resolved to 192.168.10.10 instead of whatever it would otherwise be resolved to via DNS.

However, this may or may not effectively direct all traffic that is (conceptually) associated with the site.ru domain name. In particular, it will typically not be sufficient to cause a domain like www.site.ru to be mapped to 192.168.10.10 as well. To achieve that, add www.site.ru explicitly:

192.168.10.10            site.ru   www.site.ru

(You can alternatively make a separate line for it, if you prefer. This line must also start with an IP address.)

But hosts will not direct traffic to a specific folder on a website.

If by 192.168.10.10/site.ru you mean the site.ru directory on the web server at 192.168.10.10 (that is, if you are using / as a path separator), you cannot use the hosts file to do this. hosts files do not facilitate that behavior on any operating system; it is fundamentally unrelated to what hosts files do.

The reason this cannot work is that hosts files redirect host names to IP addresses. But 192.168.10.10/site.ru is not an IP address. It's an IP address followed by directory retrieval information sent to the IP address through an application-layer protocol. See this article on the meaning of different parts of a URL (and how only one part is resolved via IP).

The proper solution in this sort of situation is to configure the web server to serve different content depending on which host name is used to access the site. This can work because the HTTP protocol includes the ability of web browsers to tell the web server what host name it is using (and essentially all web browsers send this information whenever it's applicable).

If you have the ability to make changes to the web server and need help setting up "virtual hosts," and the web server is an Ubuntu system, please feel free to post a separate question about that here.

If you don't have the ability to make changes to the web server, you should talk to whoever does.

If even that is absolutely not an option, then you should edit your question (or post a new one, your choice) to clarify your situation in detail. A messier workaround that fits your needs might be possible. It would probably involve an HTTP proxy server running on each client machine and redirecting HTTP traffic by URL.


ubuntu 14.04 not coming out of lock, sometimes

If you can't get in to a terminal then you could use:

Ctrl+Alt+F2 - To access the core terminal;
Ctrl+Alt+F7 - to exit and return to the GUI;

If you're running nautilus you can restart a session by:

sudo killall -9 nautilus && nautilus &

You should first get the process ID of the failed session (gnome-shell/nautilus):

ps aux | grep gnome

Will return something like the following (perhaps lesser processes):

fs11# ~ $ ps aux | grep gnome
ash       2568  0.0  0.1 523420  4300 ?        SLl  Mar17   2:31 /usr/bin/gnome-keyring-daemon --daemonize --login
ash       2578  0.0  0.0 438164  2992 ?        Ssl  Mar17   6:11 gnome-session --session=gnome
ash       2625  0.0  0.0  12616    32 ?        Ss   Mar17   0:07 /usr/bin/ssh-agent /usr/bin/dbus-launch --exit-with-session /usr/bin/im-launch gnome-session --session=gnome
ash       2628  0.0  0.0  24468     0 ?        S    Mar17   0:00 /usr/bin/dbus-launch --exit-with-session /usr/bin/im-launch gnome-session --session=gnome
ash       2646  0.0  0.0 124856  1644 ?        Sl   Mar17   0:15 /usr/lib/at-spi2-core/at-spi2-registryd --use-gnome-session
ash       2666  0.0  0.3 966324 13728 ?        Sl   Mar17  15:26 /usr/lib/gnome-settings-daemon/gnome-settings-daemon
ash       2698  1.1 19.8 2952084 805572 ?      SLl  Mar17 836:10 /usr/bin/gnome-shell
ash       2754  0.0  0.3 528620 15652 ?        Sl   Mar17   7:09 gnome-screensaver
ash       2762  0.0  0.0 420240  2036 ?        Sl   Mar17   0:01 /usr/lib/gnome-shell/gnome-shell-calendar-server
ash       2994  0.0  1.2 775312 49648 ?        Sl   Mar17  52:52 gnome-terminal
ash       2998  0.0  0.0  14836   400 ?        S    Mar17   0:00 gnome-pty-helper
ash      13051  0.0  0.0   9448   944 pts/10   S+   10:57   0:00 grep --color=auto gnome

Now you need to find the failed process:

gnome-shell would usually be running /usr/bin/gnome-shell; OR
nautilus would usually be running /usr/bin/naultilus;

Example:

ash       2698  1.1 19.8 2952084 805572 ?      SLl  Mar17 836:10 /usr/bin/gnome-shell

With the example above the process ID is 2698 - Now we're going to "gracefully restart" this process by sending a hang-up signal known as a HUP with the following command:

kill -HUP 2698

Conclusion

When I say "gracefully restart" - A hangup signal simply send a signal to the parent process.  The phrase graceful(ly) essentially waits until the process has finished before sending the signal.  So you're not actually restarting the process.


Ubuntu 12.04 printing problem on Lexmark x340

After several months of having problems with printers, because we migrated from Windows to  Linux in our company which have more than 200 computers... now we found the driver which works on all our printers. The driver is ljet4 , just found some similar model of printer with ljet4 sufix on name and it will work. I wrote more on my blog : http://linuxibos.blogspot.com/2013/01/driver-that-works-on-allmost-all.html

We didn't try on your model but every similar model we have worked very well.


Enable Hibernate option on setting menu in Ubuntu 14.04

First, make sure that your SWAP area is larger than your RAM. You can give it a try by entering

  sudo pm-hibernate

If everything looks good then you can dig into it.

To enable the hibernation option.
See answer in the link


this is because the item you are trying to expand is inside a 'container'... the 'extended' partition...You have to extended the sda3 partition first so there is room for sda5 to expand.


live-media=/dev/sdb5 works as advertised.

I misinterpreted the reference to "187GB needed" as indicating that casper had latched onto the wrong (possibly unformatted) partition, since I expected it to need 1 GB if it copied the filesystem.squashfs file, and 3 GB if it copied the contents of the file system represented by that file.

I had managed to repeatedly read the description "copy the read-only media" and interpret it to mean "read-only file system".  Since it really did mean "media", and I was burying my casper directory in an NTFS file system with a whole lot of other crap, it really did want to copy 187 GB.


Cannot find appropriate Makefile processor on this system

You need to install make. Do:
sudo apt-get install build-essential


I now see that the following text in my i3 config file makes the media keys and the screen brightness work.

Pulse Audio controls

bindsym XF86AudioRaiseVolume exec pactl set-sink-volume @DEFAULT_SINK@ +2%; exec pactl set-sink-mute @DEFAULT_SINK@ 0
bindsym XF86AudioLowerVolume exec pactl set-sink-volume @DEFAULT_SINK@ -2%; exec pactl set-sink-mute @DEFAULT_SINK@ 0
bindsym XF86AudioMute exec pactl set-sink-mute @DEFAULT_SINK@ toggle

Media player controls

bindsym XF86AudioPlay exec playerctl play-pause
bindsym XF86AudioNext exec playerctl next
bindsym XF86AudioPrev exec playerctl previous

Sreen brightness controls

bindsym XF86MonBrightnessUp exec xbacklight -inc 20 # increase screen brightness
bindsym XF86MonBrightnessDown exec xbacklight -dec 20 # decrease screen brightness


I want to play DVD slide shows in Ubuntu. What program is the best?

If it is a slide show you should use Libre Office Impress.

If it is just a video resembling slide show use Totem video player.


makedepf90: program for automatic creation of Makefile-style dependency lists for Fortran source code

This is an easy solution that one friend probably mentioned here but is not anymore,
I write instead of him/her:
It is a ubuntu universe package apparently:
https://packages.ubuntu.com/focal/makedepf90
so in your terminal:
sudo apt install makedepf90

have fun.


How can I keep a package but discard its configuration?

To reinstall the package and overwrite the changed configurations in /etc with the configuration of the package run

sudo apt-get -o Dpkg::Options::="--force-confnew" install --reinstall package_name

But this command doesn't affect configurations in your home folder, because nothing in the home folder will be changed by the package manager.


WiFi password can be entered but won't connect with no error message

I was having similar problems. I was able to resolve it by going to the edit connection page for the connection in question and entering both the password and security type (WPA in my case) in the Wi-Fi Security tab.

You can access the edit connection page through the drop down on the Wi-Fi icon at the top of the desktop (after already having attempted to connect); or by clicking the orange arrow on the far right of that connection under the listing of wireless connections within the network manager.


Wired ethernet either not detected or unmanaged

Is the connection working? Some time back ubuntu switched to systemd and that change moved from naming wired connections with predictable names. Now the wired connections are named with something starting with en and wireless networks with wl. Your ethernet is named eno1.


What will happen if I remove this line from /etc/hosts

When you remove the line you can't resolve the Hostname slave1-machine to a IP Address anymore.
Linux looks into the /etc/hosts before triyng to resolve a hostname via a DNS Query.
So if you remove the Line. Linux try to resolve the Hostname slave1-machine via DNS and get a negative response.


Wireless connection fails every few minutes

Your wireless may be dropping because of power management; that is, the feature where the card partially powers down to save battery power during periods of inactivity and then, ideally, powers back up seamlessly when activity resumes. Let's disable power saving to see if it helps. From the terminal:
sudo sed -i 's/3/2/' /etc/NetworkManager/conf.d/*

Your wireless may be dropping because the channel to which it was connected has suddenly changed.
Please check the settings in the router. WPA2-AES is preferred; not any WPA and WPA2 mixed mode and certainly not TKIP. Second, if your router is capable of N speeds, you may have better connectivity with a channel width of 20 MHz in the 2.4 GHz band instead of automatic 20/40 MHz, although it is likely to affect N speeds. I recommend a fixed channel, either 1, 6 or 11, rather than automatic channel selection. Also, be certain the router is not set to use N speeds only; auto B, G and N is preferred.
Your wireless may be dropping because there are two wireless access points with the same name and password. This is typical when you have a 2.4 gHz segment and a 5 gHz segment of the same router. Your wireless may be roaming, looking for a better connection. If this is the case, I suggest that you rename the access points; something like myrouter2.4 and myrouter5.
After making these changes, reboot the router.
Next, I recommend that your regulatory domain be set explicitly. Check yours:
sudo iw reg get

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

Of course, substitute your country code if not Iceland. Set it permanently:
sudo nano /etc/default/crda

Change the last line to read:
REGDOMAIN=IS

Proofread carefully, save and close the text editor.
Is there any improvement?


How does one install a minimal gnome-shell?

I often use this parameter of apt for such things:

   --no-install-recommends
       Do not consider recommended packages as a dependency for installing.
       Configuration Item: APT::Install-Recommends.

Use it as follows:

sudo apt-get --no-install-recommends install gnome-shell


So I've done some fiddling and have been able to figure out the solution to this question. I place it here for posterity and just in case it might be useful for someone else.The ensuing answer assumes that java is installed in /usr/lib64/openjdk-11/bin/java. To be sure where java is installed, you can run which java in the terminal to see its path and substitute that below where you see /usr/lib64/openjdk-11/bin/java.

Begin by downloading both the java program and installing the jre/jdk from the software center.

Having installed jre/jdk, create a symlink from your java installation path to the /usr/bin/ directory. In my case, I ran the following command in a terminal because I installed openjdk-11:
sudo ln -s /usr/lib64/openjdk-11/bin/java /usr/bin/java

Create the following Desktop Entry in a text editor of your choice, replacing USERNAME with your correct username:
[Desktop Entry]
Categories=Application;Game;BoardGame
Encoding=UTF-8
Version=1.0
Type=Application
Terminal=
Exec=java -jar '/home/USERNAME/JavaFIBS2001/JavaFIBS-1.0.11_JDK16.jar'
Path=/home/USERNAME/JavaFIBS2001/
Name=JavaFIBS
Icon=/home/USERNAME/JavaFIBS2001/JavaFIBS.ico
Comment=Play backgammon online

(Of course, you will point it to the specific java program and its location on your system.)

Save the file you created in /home/USERNAME/.local/share/applications. (Do ensure the name of the file ends in .desktop).

Run the following command in the terminal
chmod a+x /home/USERNAME/.local/share/applications/FILENAME.desktop

You should now be able to select the program from your applications menu.
In case you are curious, JavaFIBS is client that allows you to play backgammon online against real people and robots at fibs.com and ti-ga.com (the latter site is presently down because of a server failure).


Unable to install updates apt-get install -f

The command should be
sudo apt-get install -f

Try this:

sudo apt-get autoclean  (This clears the cache)
sudo apt-get clean (Almost the same as above,  but doesn't hurt to run anyway)
sudo apt-get autoremove (Just in case there's something ib the way

Then try to reinstall katepart.


Which iwlwifi firmware for Intel WiFi Link 5100?

I have the same wireless card and downloaded the iwlwifi-5000-5.ucode
from here and added that to the lib/firmware director and its working well. I'm using an Intel Galileo board with Yachto Linux build on it.


Create a '.desktop' shortcut for 'Show Applications' on Ubuntu 18.04

First install xdotool by running the following command in Terminal

sudo apt install xdotool

The key combination Super+A shows the 'Show Applications' screen. The following command will simulate this specific combination

xdotool key super+a

So create a simple .desktop launcher and use the command above for the Exec= entry.


It looks like Mouse & Touchpad application can be replaced by Mouse and Touchpad at Ubuntu Software.
I haven't tried it out yet, but that looks promising.


Login freeze on Ubuntu 18.04 + can't bring up shell (Ctrl + F2)

From the comments...

I suspected a potential problem with the Nvidia video driver in Ubuntu. Windows worked fine.

I had the user edit the GRUB startup to include nomodeset, which effectively disables the Nvidia drivers, and will allow the user to update the Nvidia driver.

The user was able to download and install new/current Nvidia drivers, did some configuration, and enrolled MOK, and after a reboot, it all worked fine! Yeah!


Running Landscape server on CentOS/RHEL?

The server package can be downloaded free of charge -- but is distributed only as a binary .deb installable under Ubuntu and is under a proprietary license.  It's mostly all python, thus the source is visible and you can attempt to install it anywhere.  That said, I would recommend against trying to install directly on RHEL, sounds painful.

For a small installation, have you considered just a VM?  Landscape server should run fine in there and would give you a better idea of how things function.