KVM host can't ping guest on same subnet

I think this might be the answer you are looking for:

http://sshmenu.sourceforge.net/articles/transparent-mulithop.html

Transparent Multi-hop SSH

It is often necessary to SSH through one host to get to another host. This article will walk you through configuring SSH so that the intermediate step is transparent.
Example Network

For our example, we're going to use the network pictured below:

Example network diagram

From your computer at home you wish to log in to the host called 'tongariro' on the LAN at your office. All connections into the office LAN must pass through the firewall host 'aoraki'. The firewall host will only accept connections from the bastion host 'ruapehu'.
Doing It Manually

These are the steps we plan to automate:

To connect to 'tongariro' you must first ssh to 'ruapehu'. Because you're connecting over the internet, you'll need to specify the full domain name when you connect. You'll also want to use '-A' to enable 'agent forwarding' (discussed below):

ssh -A ruapehu.example.com

Now that you're logged in to a shell prompt on 'ruapehu', you'll need to connect to 'aoraki'. To allow password-less logins you'll have installed the public key from your home computer into the ~/.ssh/authorized_keys of each host along the way. When you execute the following command, the SSH server on 'aoraki' will request a key, this request will be forwarded back through 'ruapehu' to the agent running on your home computer and access will be granted:

ssh -A aoraki

Finally, you can connect to the target host 'tongariro':

ssh -A tongariro

Quick and Dirty Automation

The manual steps outlined above use three chained SSH connections to pass through two intermediate hosts. You can chain the three commands together into one monster command-line (perhaps in a shell script or a shell alias):

ssh -A -t ruapehu.example.com ssh -A -t aoraki ssh -A tongariro

In addition to the -A to enable agent forwarding, I've added -t to force a pseudo-tty to be allocated. Normally when your ssh command specifies a command to be run on the target host, no pseudo-tty will be allocated. That's fine if you want the command to run and then exit, but if you want an interactive shell session then you'll need a pseudo-tty.
Quick and Dirty Automation with SSHMenu

You could assign that same monster command-line to a host connection on your SSHMenu:

SSHMenu host dialog

A Better Way

Another way to automate the connections through the intermediate hosts is to add a 'ProxyCommand' setting to your SSH config file. For this to work, you must have the 'netcat' package installed on the intermediate hosts.

Start by editing your SSH config file (which might not exist yet):

gedit ~/.ssh/config

And add the following lines:

Host ruapehu
  HostName ruapehu.example.com

Host aoraki
  ProxyCommand ssh -q ruapehu nc -q0 aoraki 22

Host tongariro
  ProxyCommand ssh -q aoraki nc -q0 %h 22

The first entry defines a hostname alias so that you can ssh to 'ruapehu' instead of having to type 'ruapehu.example.com'.

The second entry sets up a proxy command that will be used to connect to the 'aoraki' host. Normally ssh establishes its own TCP connection to port 22 on the target host, but with this setting in place it will use the proxy command to establish the connection. The proxy command in the example will establish a normal SSH connection to the intermediate host ('ruapehu') and then use the 'nc' command to extend the connection to port 22 on 'aoraki'.

Now that the proxy command is set up, you can connect to the 'aoraki' host simply by typing:

ssh aoraki

The third entry builds on this by using the newly accessible 'aoraki' host in a proxy command which extends the connection to our ultimate target 'tongariro'. Note that in this command, '%h' was used for the hostname. This is simply a shorthand that tells SSH to insert the target hostname (from the line above) in place of the %h. If you want to connect to other hosts on the office LAN you can duplicate the last two lines and just change the hostname in one place.
So Why is this Better?

With the above configuration in place, you can now SSH directly to the 'tongariro' host with this command:

ssh tongariro

You can copy files directly to (or from) 'tongariro' without having to worry about intermediate steps:

scp path/to/local/file tongariro:path/to/remote/file

You can enable X-forwarding which means that any GUI program you start on 'tongariro' will display on your workstation:

ssh -X tongariro xclock

GUI application performance will be sluggish over slow network connections but some GUI apps on your local machine will now be able to use SSH to talk to the remote host. For example if you're running GNOME, you can use an 'ssh' URL in Nautilus to browse files on the remote host. (KDE provides equivalent functionality):

SSHMenu host dialog

If you right click a file and select "Open with Text Editor", the GNOME Text Editor program will run on your local machine but will use SSH to read/write the file to the remote host.

For an even more powerful approach to editing files over an SSH connection, you might like to look into bcvi.

Many other familiar tools will also be able to use the transparent SSH connections. For example you can access version control repositories (CVS, Subversion, Git etc) over SSH. You can also use port-forwarding on the SSH conection to access intranet servers or HTTP proxies on the office LAN from your workstation.
Reusing Connections

The transparent multi-hop connections can be very useful but you may find that it takes a second or two to establish each connection. This delay can become annoying if it happens a lot (e.g.: every time you save a file from the text editor).

The good news is that if you can configure SSH to reuse an existing connection. This means that for example if you have an SSH shell session running then a new connection for SCP can skip the connection setup phase. Two steps are required:

First, you must create a directory (or 'folder') which SSH will use to keep track of established connections:

mkdir ~/.ssh/tmp

Next, add these two lines at the start of your ~/.ssh/config (make sure to use your username in place of 'YOUR-NAME'):

ControlMaster auto
ControlPath   /home/YOUR-NAME/.ssh/tmp/%h_%p_%r

As you can see, a small investment in time setting up your SSH configuration can pay back dividends in convenience.


TRUSTY: ssh connexion [root@127.0.0.1 Permission denied]

In your case "Server" and "Client" are that same computer.

Client side settings

Generate SSH keys pair.

mkdir ~/.ssh

cd ~/.ssh && ssh-keygen -b 2048 -t rsa -C "My Comment for key" -t "access_key"

Detailed information about ssh-keygen options you can read in man page:

man ssh-keygen

After that you can find two files access_key and access_key.pub in ~/.ssh/

Create file with name "config" in your ~/.ssh directory.
This file allow you to set up different settings for each host you need to connect.

Here is simple content of this file

Host my.remote-host.com
   User remoteusername
   Identityfile ~/.ssh/access_key

my.remote-host.com - target host to connect to (localhost)

remoteusername - login name of user on remote machine

Identityfile - path to you private key

Server side settings

How to enable "PublickKey" authentication:

sudo nano /etc/ssh/sshd_config

Uncomment next lines:

RSAAuthentication yes
PubkeyAuthentication yes
AuthorizedKeysFile     %h/.ssh/authorized_keys

RSAAuthentication - enable RSA keys support

PubkeyAuthentication - enable authentication by public keys

AuthorizedKeysFile - path to file that contain public keys

Restart your ssh server

sudo service sshd restart

Create directory and set correct permissions

mkdir ~/.ssh
sudo chmod 700 ~/.ssh

Create file for public keys and set correct permissions

touch ~/.ssh/authorized_keys
sudo chmod 600 ~/.ssh/authorized_keys

Put your public key (access_key.pub) into ~/.ssh/authorized_keys

You should use only one line per each key. Example:

ssh-dss AAAAB3NzaC1kc3MAAAbC2kVOJpcnfu7UqKV44uZ/khiP9K7F...aoSe MyComment

How to completely disable password authentication

sudo nano /etc/ssh/sshd_config

Change PasswordAuthentication from "yes" to "no"
Restart sshd server

sudo service sshd restart


Is possible. There is a great guide here.


/dev/nvme0n1p5 message; Ubuntu won't boot

Have you tried the solution outlinked here
"dev/sda1: clean, ..." This message appears after I startup my laptop, then it won't continue booting
Edit 1 :
If you are getting incorrect password when you try to purge nvidia drivers, and you are certain your password is correct, please make sure your keyboard layout hasn't changed. You can use this command to check the current layout : setxkbmap -query


Read/write speed may be lower unless using USB 3.0, but aside from that there shouldn't be too many notable differences.  Ultimately it comes down to what hardware you're using, and may require some tinkering around - This is kind of one of those things you have to try for yourself, because every computer and every setup will yield different results.  There shouldn't be any problem with the installation, and if its successful then you'll have a fully functional operating system in your pocket, bootable on any computer (Thumbs up for Ubuntu's amazing compatibility).  Just turn off the computer, plug in the USB drive, tell the BIOS to boot from USB, and you'll have your OS and all your files on any computer you want.  I definitely encourage you to try, because ultimately there's nothing to lose except for that which you don't have.  As for your question, you'll have to try it for yourself to know for sure, because all hardware is different.


How to increase the space in ubuntu installed under windows7?

First download the attached file wubi-resize-1.6.tar.gz to your Downloads directory, right-click and choose "Extract here". The rest of the resize is run from the Terminal (press Ctrl+Alt+T to open).

cd ~/Downloads/wubi-resize-1.6

bash wubi-resize.sh --help

sudo bash wubi-resize.sh <your desired space in GB>

This will resize wubi as per you want.


They are under the pool(s) created in my install I show here I created a pool named WD4.
root@zeus-H370M:~# zpool list
NAME   SIZE  ALLOC   FREE  CKPOINT  EXPANDSZ   FRAG    CAP  DEDUP    HEALTH  ALTROOT
WD4   3.62T  1.20T  2.42T        -         -     0%    33%  1.00x    ONLINE  -
root@zeus-H370M:~# df  -h | grep WD4
WD4             2.4T  128K  2.4T   1% /WD4
WD4/Files       3.0T  663G  2.4T  22% /Volumes/Files
WD4/Music       2.9T  570G  2.4T  20% /Volumes/Music

And can access any file for it via their mount points.
root@zeus-H370M:~# ls -l /Volumes/
total 1
drwxr-xr-x 4 zeus zeus 4 Jan 27 08:47 Files
drwxr-xr-x 3 zeus zeus 3 Jan 27 01:21 Music

You have not created any significant storage area under the rpool to have any files on. Whatever command you used to import that pool was not correct forget the way they tell you and export the both pools and only import the rpool as it is the only thing with a size that can contain many files on it then you should have chance of finding the data on it, if they were ever there. The temp_rpool is only 1.8G in size with 872M of files on it all contained in the path /mnt/datadisk/vm_guests/.
zpool export rpool
zpool export temp_rpool
zpool import rpool

Then create your storage area(s) on the rpool where you can set the mount point of them to what you wish it to be. Proceeding to copy whatever files you want into those mount points you create or using the default path the zfs creates for them. When the rpool is simply imported like this the data contained on that should be available at the mount point for it, there is no need for any extras to the command to import to get access.


If not installed, install GPartEd: open a terminal and type:

sudo apt-get install gparted

Now open GParted and look for the partition which you used as home folder. Right click on it and copy the UUID and note down the fylesystem type.
Now type in terminal:

sudo gedit /etc/fstab

and add a line in it:

UUID=<the_UUID_you_copied> /home <ext4_or_the_partition_tye> defaults 0 2

Save and reboot.


Black screen after kernel update to 3.13.0-103-generic on ubuntu 14.04

I got the solution...
First I noticed that Ubuntu was loading fine in recovery mode and it was giving black screen in normal boot mode.

So i edited grub file with command

gksudo gedit /etc/default/grub

For line

GRUB_CMDLINE_LINUX_DEFAULT="quiet splash"

changed it to
GRUB_CMDLINE_LINUX_DEFAULT="quiet splash nomodeset"

I saved it and run the command

sudo update-grub

And restarted, it works fine.

Ubuntu boots as expected but there's still a problem. I had saved some script than run on startup and set my screen brightness to some lower value, now I lost it. For now, I am ok with the solution I got.


Kingoffice availability for ubuntu 12.04

Kingoffice is free as in free beer but not free as in freedom. So you don't have to spend money to install it but cannot modify or even study its source code, even if you want to.


Encoding and decoding error in non-English name of compressed file

Perhaps the graphical archive program does not understand Chinese. Try extracting the archive using the command-line:

Open a terminal.
Navigate to the directory containing the file:

cd /path/to/directory/

You can use the Tab key to complete filenames and directory names. Double press Tab to get a list of possible completions in case there is more than one option.
Run the unrar program to unpack filename.rar:

unrar x filename.rar

Here, you can use tab-completion too for the filename.
The contents of the archive will be visible in the current directory.


If you don't have LibreOffice Base installed, you can obtain it by installing the libreoffice-base  package. This package is available for Ubuntu 12.04, as well as other releases.

You can install it in the Ubuntu Software Center or Synaptic Package Manager. Or you can install it from the command line (Ctrl+Alt+T) by running:

sudo apt-get update
sudo apt-get install libreoffice-base

If you are able to install it, or find it is already installed, but you are still unable to run it, please update your question with details.


How to determine whether a dvd is re-writable or not?

You can try Brasero or Xfburn to check all your CD/DVD discs for the rewritable feature. Use each application's menu to list your disc capabilities the same way you do in Windows with Ahead Nero.

There are plenty of other software packages that you can use for CD/DVD burning, and you can test them if unsatisfied with either Brasero or Xfburn. Use Software Center or Synaptic to look for all of them, and install whatever you think it meets your particular requirements.


Is it a good idea to install gedit in Lubuntu?

None of the packages on that list will load anything that can make your system slow down.

It will install the necessary libraries, the rest of the dependencies that are not satisfied, etc but will only call them when you run gedit and will go away when you close it. I dont think you will have any performance issues related to installing gedit on your Lunbuntu system.


Trying to export xinput information for remote display in 12.04

X isn't allowing it to make changes because it doesn't believe it has the authority to do so:

export XAUTHORITY=$(eval echo ~`who | grep tty7 | sed 's/\([a-z]*\).*/\1/'`)/.Xauthority


Does anyone know why thunderbird is suddently asking for my gmail password every day?

I would suggest using an application password. Most of the time the session is created when you login, to prevent you from keeping an open client session. Depends on the provider. But, try the app password.


The missing dependencie  guile-2.0-libs available from the main repository. mailutils and its dependency libmailutils5 are available from universe, edit your /etc/apt/sources.list as follows:
deb http://us.archive.ubuntu.com/ubuntu/ bionic main restricted universe multiverse
deb http://us.archive.ubuntu.com/ubuntu/ bionic-security main restricted universe multiverse
deb http://us.archive.ubuntu.com/ubuntu/ bionic-updates main restricted universe multiverse
deb http://us.archive.ubuntu.com/ubuntu/ bionic-proposed main restricted universe multiverse

Then run:
sudo apt update
sudo apt install mailutils


sudo apt-get update: CD-ROM does not have a release file

It looks like you are trying to use a CD as a repository. You can't do that in this way, because the CD doesn't have the necessary structure. If you want to make a CD accessible to  APT, you have to use apt-cdrom. You can find further information on apt-cdroms man page

man apt-cdrom

And, no offence meant, but the error messages you quoted in your question literally tell you just that:

  Please use apt-cdrom to make this CD-ROM recognized by APT. apt-get update cannot be used to add new CD-ROMs


Mount external ext4 with changed uid and gid

The simplest thing would be to ensure both default gids exist on both
machines, and your uid is in both groups.

The simplest thing is to have one group in both machine with the same gid and use
something like
chmod 2770 YOUR_DRIVE

Where 2 is a setgid, that way any file created will inherit group permissions and you will be able to create or modify files on both systems using the same user who doesn't match it's uid.
If you want to create the group use
sudo groupadd --gid UNUSUSED_GID_HERE YOUR_GROUP_NAME

Do that on both machines, then chgrp to group name your drive.
Hope that makes sense.


How to run Git projects on SDD (non Root)

Try accessing the Windows storage from Ubuntu itself. You can access your windows storage drives & its files from Files -> Other Locations -> Select the appropriate drive. Make sure you do this as a root user.


JODReports (open source) and Docmosis (commercial) work similarly with documents as templates.   Both allow you to use Word or Writer documents as templates and can work on Ubuntu.  Please note I work for Docmosis.

I hope that helps.


How to stop XAMPP/MySQL from defaulting to IPv6?

Completely disabling IPv6 is getting harder and harder these days. In many operating systems and for many applications it's a crucial component now. if you really want to remove all traces of IPv6 then your only option might be to recompile a lot of software with different options.

I think the best option In most cases is to leave it enabled and configure your firewall to block unwanted traffic. That way the software can continue to use I use IPv6 sockets (which on Linux and other operating systems also can handle incoming IPv4 connections) while your system is protected against unwanted traffic.

Of course what the best alternative is depends on why you want to disable IPv6. The answer above won't help if your goal is to lower memory usage or something like that.


Ubuntu unable to detect Huawei E392 USB modem with Airtel 4G connection

Run in terminal

sudo -H gedit /lib/udev/rules.d/40-usb_modeswitch.rules

and add a line to the file

ATTRS{idVendor}=="12d1", ATTRS{idProduct}=="1505", RUN+="usb_modeswitch '%b/%k'"

Then run

sudo -H gedit /etc/usb_modeswitch.d/12d1:1505

And paste this text to the editor

 TargetVendor= 0x12d1
 TargetProduct= 0x1505
 MessageContent="55534243123456780000000000000011062000000100000000000000000000"

Save the file.

Unplug the modem and plug it in again. In about 20 seconds try to create a connection.


How intelligent is OpenSSH when it comes to connecting to a domain that leads to your internal network?

SSH client resolves DNS of you domain and it connects to the IP it receives. It does what all the other Internet facing clients. There is nothing about being "smart enough".


get tags in docker registry response using shell script

That's a JSON string. It's better to use command line tools such as jq to manipulate JSON. To install jq, run
sudo apt install jq

In your the response, you have "tags" array and 2.9.6 is at index 0. To get that, you can parse the response to jq and use r flag. Example usage:
$ curl -X GET "192.168.50.117:5000/v2/internet-crawler/tags/list" | jq -r '.tags[0]'
2.9.6


English menus, but German keyboard setting

Access the Dash, search for an application named "Text Entry" and start it up. In it you will be presented with a selection box entitled "Input sources to use:"; it lists all the keyboard mappings presently available in your system. In your case it is probably listing English and German (Switzerland).

You can turn the German mapping the default in two ways:

using the "arrow up" button to move the German mapping to the top.
using the "minus" button to remove all mappings except German.

These buttons are signalled in the image below.


How long does it take to ubuntu 12.10 reboot after installation?

Sometimes,users face this problem.Normally, it takes a couple of seconds.I think, you can power-off manually then can start it.They wouldn't cause problems.There is nothing else you can.
I don't think,but If you face some problems after manual reboot(like critical errors),most probably you will have to install ubuntu again.


WxPython 2.8 Offline Installation on Ubuntu 9.10 with 2 version of Python

Just download the .tar.gz package of wxPython for python 2.6 here. Just follow the documentation here.

After it finishes its download, I am assuming it is downloaded into /downloads folder. Then just extract the files to a folder. let's assume it wxpython. Now I just recommend you to use easy_install to install modules for multiple version of python. Just download it to insatll it offline like this:

cd Downloads
cd setuptools
sudo python setup.py install

This will install the setuptools for python which will installl easy_install for you automatically. Now download virtual environment package tarball here. You can install it in similar fashion you installed the above easy_package. Remember, all thing is going offline except for the packages to be downloaded externally.
Now you have a virtual environment package, you can create virtual environment for each project you follow like this:

virtualenv -p python2.6 --no-site-packages ~/env/NEW_PYTHON_PROJECT

read full documentation here.

ELSE you can easily install modules for each python version specifically like:

sudo python2.5 easy_install package_name


Boot error > no such device: grub rescue

Re-install your GRUB.

Boot using a live cd of ubuntu.
Open a terminal and run the command
sudo fdisk -l
It lists the complete partition table of the hard disk. In there, identify which partition you have got your linux installed on. You can identify it using the drive size you had allocated for it and looking at the last column of the output which will be extended or Linux for all of your linux partitions. The partition will most probably be something like /dev/sda5 or something. Remember this partition.
Create a temporary folder in your home directory (Note: You can make the temporary folder anywhere you want. I’m using the home folder just for the sake of explanation). I’m calling it temp for now. So that temp folder’s path will be/home/ubuntu/temp`.
Mount your linux partition there. That is, assuming that you found your linux partition to be /dev/sda5, you mount that at the temp folder by doing the following command

sudo mount /dev/sda5 /home/ubuntu/temp
If you want to check whether you have mounted the correct partition, go to your home folder and open temp. You will be in the / directory. In there you will find home, in which your home folder’s name will be there. Once you’ve confirmed you have mounted the correct partition, do step 6.
You have to install grub by showing the system where to read the data from the hard disk at the beginning. Don’t worry, just run the following command

sudo grub-install --root-directory=/home/ubuntu/temp /dev/sda

The /dev/sda corresponds to your hard disk name. Replace it by whatever the command sudo fdisk -l command showed you.
You’re done. You may restart your system.


installing oracle java jdk 1.8.0_45 manually

mkdir if not present "/usr/lib/jvm"
download package and type this comand from the download directory

tar -zxf jdk-8u5-linux-x64.tar.gz -C /usr/lib/jvm/jdk1.8.0_45

install java

sudo update-alternatives --install /usr/bin/java java /usr/lib/jvm/jdk1.8.0_45/bin/java 100

to check if java is installed type

java -version

if you have multiple java you need to configure it by

sudo update-alternatives --config java

enter the number you want the default java to be from the list


Need help installing Micromax Modem MMX210G

How to Configure Micromax 3g Modem on Ubuntu 12.04, 12.10 And 13.04

Finding the Product ID of the USB Modem

Plugin the USB modem to the Computer
Open the Terminal (ctrl+alt+t)
Type the command lsusb (This lists the active USB devices connected to the computer along with the Product ID and the Vendor name)
Make a note of the Product ID and Vendor name

Editing the content of  Modules.

In the Terminal, type the following command to edit the “modules” file
sudo gedit /etc/modules (Type your administrator password if it asks for). Clear all the content and replace it with new content shown below:

             # /etc/modules: kernel modules to load at boot time.
             #
             # This file contains the names of kernel modules that should be loaded
             # at boot time, one per line. Lines beginning with “#” are ignored.
             loop
             lp
             rtc
             usbserial vendor=0x1c9e product=0x9605
             option

(Change the vendor and product value if it is different for your USB modem, You can get this values in 1step Terminal window)

Editing the content of usb_modeswitch.d
In Terminal, type the command

         gksudo gedit /etc/usb_modeswitch.d/1c9e:9605

The command opens the text file with the above mentioned name in the text editor.

Add the following lines to that file and save it.

             DefaultVendor = 0x1c9e
             DefaultProduct = 0x9605
             TargetVendor = 0x1c9e
             TargetProduct = 0x9605
             MessageContent=”55534243123456788000000080000606f50402527000000000000000000000″

Close the text editor

(These values are only for the Micromax MMX352G Model. Change the values as per your device if you are using the different one)

Execute these commands in the terminal as root user to configure the modem.

             modprobe usbserial vendor=0x1c9e product=0x9605

             usb_modeswitch -c /etc/usb_modeswitch.d/1c9e\:9605

4.Create a mobile Broadband connection

Open Network Connection Manager, Click the Add button on the Mobile Broadband tab, Create a new mobile broadband connection using the wizard appeared. Add the appropriate country, service provider, plan and just finish the wizard after selecting the appropriate name for the connection. (Be careful in selecting the plan)

After restarting process finish the login and wait for few minutes. It would take some time to configure so please be patient. The new mobile broadband connection is visible and available on the network connection list. Connect to the Internet by clicking on that.

Now your Internet is Connected with your USB Modem on Ubuntu 12.04.

For Ubuntu  12.10 and 13.04: Open the Terminal. Change to root user using the su command.

Ubuntu 12.10

             echo 1c9e 9605 > /sys/bus/usb-serial/drivers/option1/new_id

Ubuntu 13.04

             echo 1c9e 9605 > /sys/bus/usb-serial/drivers/generic/new_id

Wait for a while it will take some time . You will see your  your modem connection  visible on the default connection.

Note: If you want to run the command automatically whenever the system starts add the above code to the file rc.local before the line exit 0.

To edit the rc.local file use the command.

             sudo gedit /etc/rc.local


cd ~/Desktop
(In Terminal) sudo chown yourusername DaVinci\ Resolve.desktop
Right Click Icon and make sure "Allow executing file as a program" is ticked or enabled.
Double click the icon and it will change the actual program Icon and launch.


Your first link isn't the only one provided by AMD. This page has separate AMD GPU drivers for Ubuntu 16.04 and 18.04:

Radeon™ Software for Linux® 18.40 Highlights

On the same page you will find links to instructions tailored for Linux users:

Radeon™ Software for Linux® Installation

Within the instruction section you'll find a link for reporting bugs:

Generating a Bug Report

This could be your best friend because even operating on CPU's iGPU alone there shouldn't be any lagging with youtube videos.


How to view a web app hosted on ubuntu from another machine?

Generally, webapplications like Flask will bind to 127.0.0.1 for numerous reasons, like security, SSL, reverse proxies, etc.

The simplest solution would be to change the binding of the webapp. When you call flask run, simply do this:

flask run --host 0.0.0.0

This will instruct Flask to bind to the IP address 0.0.0.0, which is a catch-all, allowing you to access Flask from any IP. Note that you will need to allow port 8050 through your firewall for this to work.

Alternatively, you may use a reverse proxy like NGINX. This also allows you to change the server port, add SSL certificates, balance server load, and many other features necessary for a production webapp. See the official NGINX docs for an example of how to do this. You may also use Apache2's mod_proxy, but my personal recommendation would be NGINX.


Okay, current state of affairs:

lisea@ubuntu:~$ bin/rtcheck.sh
-----------------------------------------------
SUSPEND_MODULES="rt2800pci"
-----------------------------------------------
blacklist rt2800pci
-----------------------------------------------
parport_pc             32111  0
rt2860sta             494649  1
crc_ccitt              12595  1 rt2860sta
parport                36746  3 parport_pc,ppdev,lp
-----------------------------------------------
lisea@ubuntu:~$
lisea@ubuntu:~$ cat bin/rtcheck.sh
#/bin/sh

echo "-----------------------------------------------"
cat /etc/pm/config.d/config
echo "-----------------------------------------------"
tail -n 1 /etc/modprobe.d/blacklist.conf
echo "-----------------------------------------------"
lsmod | grep rt
echo "-----------------------------------------------"

In part this was achieved through these commands:

sudo modprobe -rf rt2800pci
sudo modprobe -rf rt2860sta
sudo modprobe rt2860sta

I blacklisted rt2800pci first (meaning it won't be loaded in the future), then removed it right now with the 3 commands above. The computer froze as a result of the last command, but after boot it finally did what it was supposed to do.

Success! My computer finally understands how a shutdown works!


How to make txt, csv and pem files read and writable only by root with sudo previliges?

Suppose your file is named example.txt. Then:
$ sudo chown root: example.txt
$ sudo chmod o-rwx example.txt

should do the job.
If you want an entire directory exampledir to be accessible only to root:
$ sudo chown -R root: exampledir
$ sudo chmod -R o-rwx exampledir


First, install xbindkeys and xautomation...

sudo apt-get update
sudo apt-get install xbindkeys
sudo apt-get install xbindkeys-config
sudo apt-get install xautomation

Understand that configuring these can be difficult, but there are plenty of examples for different .xbindkeysrc online. Here's mine, just to get you started... you'll note that I already have a mouse wheel setup, but it's commented out, as I don't use it...

###########################
# xbindkeys configuration #
###########################
#
# Version: 0.1.3
#
# If you edit this, do not forget to uncomment any lines that you change.
# The pound(#) symbol may be used anywhere for comments.
#
# A list of keys is in /usr/include/X11/keysym.h and in
# /usr/include/X11/keysymdef.h
# The XK_ is not needed.
#
# List of modifier (on my keyboard):
#   Control, Shift, Mod1 (Alt), Mod2 (NumLock),
#   Mod3 (CapsLock), Mod4, Mod5 (Scroll).
#
# Another way to specifie a key is to use 'xev' and set the
# keycode with c:nnn or the modifier with m:nnn where nnn is
# the keycode or the state returned by xev
#
# This file is created by xbindkey_config
# The structure is :
# # Remark
# "command"
# m:xxx + c:xxx
# Shift+...

#keystate_numlock = enable
#keystate_scrolllock = enable
#keystate_capslock = enable

"xbindkeys_show"
   control + shift + q

#Zoom In
"xte 'keydown Control_L' 'key KP_Add' 'keyup Control_L'"
b:13 + Release

#Zoom Out
"xte 'keydown Control_L' 'key KP_Subtract' 'keyup Control_L'"
b:10 + Release

#Tab Left
#"xte 'keydown Control_L' 'keydown Shift_L' 'key ISO_Left_Tab' 'keyup Control_L' 'keyup Shift_L'"
#b:6 + Release

#Tab Right
#"xte 'keydown Control_L' 'key ISO_Left_Tab' 'keyup Control_L'"
#b:7 + Release

#bind shift + vertical scroll to horizontal scroll events
#(xbindkey '(shift "b:4") "xte 'mouseclick 6'")
#(xbindkey '(shift "b:5") "xte 'mouseclick 7'")

#Horz scroll Left
"xte 'key KP_Right'"
b:6 + Release

#Horz scroll Right
"xte 'key KP_Left'"
b:7 + Release

#
# End of xbindkeys configuration


Try cleaning up your apt-cache and running any updates:

sudo apt-get clean
sudo apt-get update
sudo apt-get upgrade

If you still have issues, then change your repo mirror: Open “Update Manager”, then click Settings -> Ubuntu Software tab, then select Other... from the Download from and click the Select Best Server button. Now try updating/upgrading again.


How to fetch multiple logs from filebeat?

You are using different Syntax in the grok match line.
Change it to
{ "message" => "..." }
like in the second one.


Windows Invalidation after Installing Ubuntu Alongside Windows 7

I hardly think there really is any BIOS issues. I know sometimes Windows can get a little picky if it suddenly sees it's root partition is smaller than it once was. Usually it just does a simple disk check and that's it. But in some cases you might need to reactivate Windows. This usually happens when you make a hardware change, but I've seen some cases where a new dual boot config produces the same thing.


Recursive search and move of a filesystem

You can use the find command below to recursively (depth-first) move all folders into a folder named after the first letter of their file name, creating it if it does not exist yet, starting from your current working directory:

find . -depth -mindepth 1 -type d -execdir bash -c 'l=./$(basename "{}" | head -c1) ; test -d "${l^^}" || mkdir "${l^^}" ; mv "{}" "${l^^}/"' \;

Explanation:

find . -depth -mindepth 1 -type d -execdir <COMMAND> \;
recursively searches your current directory (.), depth-first (-depth), for all directories (-type d), excluding your current directory itself (-mindepth 1).
Then it cds into each found folder's parent directory and executes <COMMAND> from there, replacing every occurrence of {} with the relative found directory name (-execdir).
bash -c '<COMMAND>'
starts a Bash subshell and lets it interpret and execute the string <COMMAND>. We need this because we're going to use shell features like variables, pipes, command substitution, etc, which can't be done directly by find -execdir.
l=./$(basename "{}" | head -c1)
stores the first letter of the found directory name (remember that {} gets substituted with the search result) in the shell variable $l.
test -d "${l^^}" || mkdir "${l^^}"
checks whether a directory exists and creates it if not. The name of the directory ("${l^^}") is the content of the variable $l (the first letter of the found directory name) converted to upper case.
mv "{}" "${l^^}/"
moves the found directory (remember again that {} gets substituted) into the directory named after its first letter converted to upper case (`"${l^^}/", which we prepared earlier).

Example run:

$ tree -F
.
├── apple/
│   ├── hamster/
│   ├── horse/
│   ├── snake/
│   │   ├── blue
│   │   ├── green
│   │   ├── grey
│   │   └── red
│   └── spider/
├── apricot/
├── banana/
├── cherry/
│   ├── pink
│   ├── purple
│   └── yellow
└── coconut/

9 directories, 7 files
$ find . -depth -mindepth 1 -type d -execdir bash -c 'l=./$(basename "{}" | head -c1) ; test -d "${l^^}" || mkdir "${l^^}" ; mv "{}" "${l^^}/"' \;
$ tree -F
.
├── A/
│   ├── apple/
│   │   ├── H/
│   │   │   ├── hamster/
│   │   │   └── horse/
│   │   └── S/
│   │       ├── snake/
│   │       │   ├── blue
│   │       │   ├── green
│   │       │   ├── grey
│   │       │   └── red
│   │       └── spider/
│   └── apricot/
├── B/
│   └── banana/
└── C/
    ├── cherry/
    │   ├── pink
    │   ├── purple
    │   └── yellow
    └── coconut/

14 directories, 7 files

Edit:

If you want it non-recursively, i.e. operating only on the direct first-level subdirectories of your current working directory, simply add the -maxdepth 1 option to the find command. You can omit the -depth option then though:

find . -mindepth 1 -maxdepth 1 -type d -execdir bash -c 'l=./$(basename "{}" | head -c1) ; test -d "${l^^}" || mkdir "${l^^}" ; mv "{}" "${l^^}/"' \;

Edit 2:

It is possible to only perform the move if the directory to move contains files matching a specific criterion (here: contain a file with file name ending in .jpg anywhere, including subdirectories), but it adds another find command and an if clause:

find . -depth -mindepth 1 -maxdepth 1 -type d -execdir bash -c 'if find "{}" -type f -iname '*.jpg' | grep -q '.' ; then l=./$(basename "{}" | head -c1) ; test -d "${l^^}" || mkdir "${l^^}" ; mv "{}" "${l^^}/" ; fi' \;

Explanation (after edit 2):

if <CONDITION> ; then <COMMANDS> ; fi
Checks the exit code of the command <CONDITION> and only runs the <COMMANDS> between then and fi if the condition was fulfilled (exit code 0). <COMMANDS> is the same as in the previous version.
find "{}" -type f -iname '*.jpg' | grep -q '.'
Searches inside the directory found by the outer find command (remember once again that {} gets substituted) for files (-type f) with a name that ends with .jpg, case-insensitively (-iname '*.jpg').
The grep -q '.' simply checks whether the find produces any output on STDOUT (means that files were found) and returns an exit code of 0 then, 1 if no files were found.

Example run (after edit 2):

$ tree -F
.
├── apple/
│   ├── hamster/
│   ├── horse/
│   ├── snake/
│   │   ├── blue
│   │   ├── green
│   │   ├── grey
│   │   └── red
│   └── spider/
├── apricot/
├── banana/
│   └── black.jpg
├── cherry/
│   ├── pink
│   ├── purple
│   └── yellow
└── coconut/

9 directories, 8 files

$ find . -depth -mindepth 1 -maxdepth 1 -type d -execdir bash -c 'if find "{}" -type f -iname '*.jpg' | grep -q '.' ; then l=./$(basename "{}" | head -c1) ; test -d "${l^^}" || mkdir "${l^^}" ; mv "{}" "${l^^}/" ; fi' \;
$ tree -F
.
├── A/
│   └── apple/
│       ├── hamster/
│       ├── horse/
│       │   └── white.jpg
│       ├── snake/
│       │   ├── blue
│       │   ├── green
│       │   ├── grey
│       │   └── red
│       └── spider/
├── apricot/
├── B/
│   └── banana/
│       └── black.jpg
├── cherry/
│   ├── pink
│   ├── purple
│   └── yellow
└── coconut/

11 directories, 9 files


Thinkpad x220 not waking from suspend after upgrading to xUbuntu 14.04 from 13.10

There is an log file, perhaps there are some details:

  /var/log/pm-suspend.log

Perhaps this bug: https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1243647


Open your terminal( CTRL + ALT + T ) and type as

sudo /usr/lib/lightdm/lightdm-set-defaults -s ubuntu

this will make the Default DE as Ubuntu.

If you want to deal with choosing more desktops environment.

sudo gedit /etc/lightdm/lightdm.conf

Then you can find

there

user-session=xubuntu

So right now my Default is xubuntu. If you want change it then lubuntu,xfce,lxde,gnome,ubuntu are other DE's.

to list all installed DE's ,

august@august-OEM:~$ ls /usr/share/xsessions
awesome.desktop  cairo-dock.desktop  xfce.desktop  xubuntu.desktop


Instalation through PPAm just purge your previus install and reinstall again

Run:

sudo add-apt-repository ppa:nvidia-vdpau/ppa
sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys CEC06767
sudo apt-get update
sudo apt-get install nvidia

If that doesn't work you can try  the propietary drivers from Nvidia, you can try this:

Go to http://nvidia.com and download the driver to a known directory (~/Downloads, for example)
Press Ctrl+Alt+F6 to switch to another Virtual Terminal and login with your User/Password
Run sudo service lightdm stop (or Nvidia installer will not run, because there's an active X session)
Run cd ~/Downloads && sudo chmod +x ~/Downloads/NVIDIA-Linux-x86_64-295.33.run (if that's the version you have downloaded, to make the installer executable)
Run sudo ./NVIDIA-Linux-x86_64-295.33.run and press "OK" to all installer questions (default options)
As the installer finishes, run sudo reboot now to reboot the machine.
At lightdm, login to Unity 3D and verify if there was any change or improvement.

Also:

Make sure you are not running nouveau. You can check if nouveau is loaded by running lsmod | grep -i nouveau. It should display no results.
Make sure your currently loaded NVidia kernel module is the same version as the installed drivers.
You can check that Nvidia Kernel module is is loaded with lsmod | grep -i nv. If you installed Nvidia drivers from the proprietary/binary installer from NVidia website/FTP it should output "nvidia".
If you have NVidia installed from Ubuntu repos (pakage nvidia-current) it should output nvidiafb.
To check the Kernel module version, use modinfo nvidia or modinfo nvidiafb. It should output "version:  along with other module details.

This version should match the drivers you installed.

Source


There are no official snappy Ubuntu Core 16 images just yet. They'll be released soon (though I'm not sure how they get into Azure); until then you'll need to use snappy from the 16.04 server or desktop install.


As it is explained in this answer, you can't open a file from /proc in an editor because it is virtual.

Files in /proc/sys can be managed using the sysctl utility.

Temporary change

sudo sysctl -w kernel.yama.ptrace_scope=0

Permanent change

Edit the /etc/sysctl.conf and add this line:

kernel.yama.ptrace_scope=0

As you may already know, changing this setting may have security implications (see the documentation for yama).


How to configure Thunderbird to notify new mails only in certain folders?

In Thunderbird, when we Right Click on Inbox or any of the Folder Entries in the Left Panel, we get a Subscribe Option in the Context Menu.

Using this we can subscribe to a select group of folders among all the available folders in the Mail Account.

By doing so, Thunderbird checks for New Mail, only in those folders, and the indicator responds to new mail only in those folders.


No audio in laptop speakers or headphones, but sound plays in screen (HDMI connection)

Short answer
[Probably] Update the kernel to the latest version recommended for your system.
Mine resolved with 4.15.0-109-generic, installed with Software Updater.
(Resolved on its own in about 2 months since I first faced the issue)

Details -
I have suddenly got the audio back (speakers, microphone and headphones). Before this point, a month ago, in an attempt to resolve the issues, with no luck, I had

Updated firmware (Required booting into windows and took >6 hours) and
Consistently installed new updates as soon as I received a notification for them (Ubuntu).

I have not done anything since, to resolve the issue, except installing regular kernel updates.
I suspected the kernel update because of the sudden occurrence of the issues, and I suspect it even more because of sudden resolution. Both times, there was a kernel update in merely a day or two ago. My problem began around the time of 4.15.0-99-generic update and was resolved around the time of 4.15.0-109-generic.  It could be a bug that is resolved in this update (you'll have to check). I am only stating that this kernel version for my system specs, worked for me. Reiterating my system specs (from question) -

Ubuntu 18.04
Dual boot (for >2 years) - Windows 10 as the other OS.
Codec: Realtek ALC3253
Laptop - Dell Inspiron 13 5000 Series

The full log kernel update log, that I obtained using zgrep 'install linux-headers' /var/log/dpkg.log* | sort | cut -f1,2,4 -d' ', for reference is given below-
/var/log/dpkg.log.10.gz:2019-09-07 06:26:45 linux-headers-4.4.0-161:all
/var/log/dpkg.log.10.gz:2019-09-07 06:27:06 linux-headers-4.4.0-161-generic:amd64
/var/log/dpkg.log.10.gz:2019-09-07 06:28:13 linux-headers-4.15.0-60:all
/var/log/dpkg.log.10.gz:2019-09-07 06:28:35 linux-headers-4.15.0-60-generic:amd64
/var/log/dpkg.log.10.gz:2019-09-12 07:01:06 linux-headers-4.15.0-62:all
/var/log/dpkg.log.10.gz:2019-09-12 07:01:45 linux-headers-4.15.0-62-generic:amd64
/var/log/dpkg.log.10.gz:2019-09-18 06:49:18 linux-headers-4.4.0-164:all
/var/log/dpkg.log.10.gz:2019-09-18 06:49:41 linux-headers-4.4.0-164-generic:amd64
/var/log/dpkg.log.10.gz:2019-09-18 06:51:50 linux-headers-4.15.0-64:all
/var/log/dpkg.log.10.gz:2019-09-18 06:52:29 linux-headers-4.15.0-64-generic:amd64
/var/log/dpkg.log.11.gz:2019-08-15 06:14:17 linux-headers-4.15.0-58:all
/var/log/dpkg.log.11.gz:2019-08-15 06:14:38 linux-headers-4.15.0-58-generic:amd64
/var/log/dpkg.log.11.gz:2019-08-15 11:45:17 linux-headers-4.4.0-159:all
/var/log/dpkg.log.11.gz:2019-08-15 11:45:52 linux-headers-4.4.0-159-generic:amd64
/var/log/dpkg.log.11.gz:2019-08-15 11:46:19 linux-headers-generic:amd64
/var/log/dpkg.log.1:2020-06-10 06:56:50 linux-headers-4.15.0-106:all
/var/log/dpkg.log.1:2020-06-10 06:57:15 linux-headers-4.15.0-106-generic:amd64
/var/log/dpkg.log.12.gz:2019-07-25 06:33:10 linux-headers-4.15.0-55:all
/var/log/dpkg.log.12.gz:2019-07-25 06:33:36 linux-headers-4.15.0-55-generic:amd64
/var/log/dpkg.log:2020-07-01 06:25:25 linux-headers-4.15.0-108:all
/var/log/dpkg.log:2020-07-01 06:26:12 linux-headers-4.15.0-108-generic:amd64
/var/log/dpkg.log:2020-07-03 06:46:50 linux-headers-4.15.0-109:all
/var/log/dpkg.log:2020-07-03 06:47:14 linux-headers-4.15.0-109-generic:amd64
/var/log/dpkg.log.2.gz:2020-05-20 06:08:58 linux-headers-4.15.0-101:all
/var/log/dpkg.log.2.gz:2020-05-20 06:09:34 linux-headers-4.15.0-101-generic:amd64
/var/log/dpkg.log.2.gz:2020-05-28 18:10:06 linux-headers-4.15.0-91:all
/var/log/dpkg.log.2.gz:2020-05-28 18:10:31 linux-headers-4.15.0-91-generic:amd64
/var/log/dpkg.log.2.gz:2020-05-28 18:11:49 linux-headers-4.15.0-96:all
/var/log/dpkg.log.2.gz:2020-05-28 18:12:19 linux-headers-4.15.0-96-generic:amd64
/var/log/dpkg.log.3.gz:2020-04-07 06:13:59 linux-headers-4.15.0-96:all
/var/log/dpkg.log.3.gz:2020-04-07 06:14:37 linux-headers-4.15.0-96-generic:amd64
/var/log/dpkg.log.3.gz:2020-04-29 06:28:56 linux-headers-4.15.0-99:all
/var/log/dpkg.log.3.gz:2020-04-29 06:29:20 linux-headers-4.15.0-99-generic:amd64
/var/log/dpkg.log.4.gz:2020-03-19 07:10:22 linux-headers-4.15.0-91:all
/var/log/dpkg.log.4.gz:2020-03-19 07:22:12 linux-headers-4.15.0-91-generic:amd64
/var/log/dpkg.log.5.gz:2020-02-22 06:31:45 linux-headers-4.15.0-88:all
/var/log/dpkg.log.5.gz:2020-02-22 06:32:42 linux-headers-4.15.0-88-generic:amd64
/var/log/dpkg.log.6.gz:2020-01-08 10:27:33 linux-headers-4.4.0-171:all
/var/log/dpkg.log.6.gz:2020-01-08 10:46:25 linux-headers-4.4.0-171-generic:amd64
/var/log/dpkg.log.6.gz:2020-01-08 10:51:03 linux-headers-4.15.0-74:all
/var/log/dpkg.log.6.gz:2020-01-08 10:51:26 linux-headers-4.15.0-74-generic:amd64
/var/log/dpkg.log.6.gz:2020-01-31 06:16:52 linux-headers-4.15.0-76:all
/var/log/dpkg.log.6.gz:2020-01-31 06:17:30 linux-headers-4.15.0-76-generic:amd64
/var/log/dpkg.log.7.gz:2019-12-04 06:05:28 linux-headers-4.4.0-170:all
/var/log/dpkg.log.7.gz:2019-12-04 06:05:57 linux-headers-4.4.0-170-generic:amd64
/var/log/dpkg.log.7.gz:2019-12-04 06:07:16 linux-headers-4.15.0-72:all
/var/log/dpkg.log.7.gz:2019-12-04 06:07:42 linux-headers-4.15.0-72-generic:amd64
/var/log/dpkg.log.8.gz:2019-11-18 06:04:57 linux-headers-4.4.0-169:all
/var/log/dpkg.log.8.gz:2019-11-18 06:05:18 linux-headers-4.4.0-169-generic:amd64
/var/log/dpkg.log.8.gz:2019-11-18 06:07:09 linux-headers-4.15.0-70:all
/var/log/dpkg.log.8.gz:2019-11-18 06:07:49 linux-headers-4.15.0-70-generic:amd64
/var/log/dpkg.log.9.gz:2019-10-02 06:24:23 linux-headers-4.4.0-165:all
/var/log/dpkg.log.9.gz:2019-10-02 06:24:54 linux-headers-4.4.0-165-generic:amd64
/var/log/dpkg.log.9.gz:2019-10-02 06:26:11 linux-headers-4.15.0-65:all
/var/log/dpkg.log.9.gz:2019-10-02 06:26:45 linux-headers-4.15.0-65-generic:amd64
/var/log/dpkg.log.9.gz:2019-10-23 06:33:05 linux-headers-4.4.0-166:all
/var/log/dpkg.log.9.gz:2019-10-23 06:33:30 linux-headers-4.4.0-166-generic:amd64
/var/log/dpkg.log.9.gz:2019-10-23 06:34:49 linux-headers-4.15.0-66:all
/var/log/dpkg.log.9.gz:2019-10-23 06:35:14 linux-headers-4.15.0-66-generic:amd64

It seems that kernel update resolved it for me, on its own. I post this answer, in hopes it may provide someone else facing similar issue with either clues or the patience to wait out a few kernel updates and see if the issues are resolved.


Write tags from collection to files in amarok

If by "tag" you mean ID3, APE or vorbis comments, then those informations are written in the file itslef.
That means that if windows messed with your tags, then Linux (amarok included) can't do anything, unless you have a backup of those files.

My understanding of Amarok's database is that it stores only ratings, statistics, and that sort of information. Not the title, the artist, the album, the year, etc.

To write the tags (anew) for your files in an efficient way, you can try to

use Amarok system to guess the tags using MusicBrainZ (cf. this page)
use Amarok system to guess the tags using the file name (cf. this page)
use a good program to write new tags (cf. this page)

You can always have a peek at $HOME/.kde/share/apps/amarok/mysqle to see what your database looks like, but I doubt you're going to find anything useful in it.


How to clean up aftermath from rookie ubuntu command

To recover the permissions on the sudo executable, you'll need to boot to recovery mode and make the changes from there. Specifically:

reboot your computer
choose the "Ubuntu recovery" option - this will get you a root shell without needing sudo
run the commands:

chmod 755 /usr/bin/sudo

chmod +s /usr/bin/sudo
use ls to confirm that the permissions are okay now:

ls -l /usr/bin/sudo
the output should start with:

-rwsr-xr-x 2 root root

At this point you can test sudo to see if it works as the root user:

sudo echo "it works"

If that works, then you can reboot to an ordinary ubuntu session and use sudo to fix whatever else needs fixing.


How do I set nomodeset from GRUB2 shell?

When booting, at the grub screen press 'e' with the default entry selected to edit the grub config for that kernel. Go to the line starting with 'kernel' and usually 'quiet splash' towards the end of it. Go to the end of this line, and add 'nomodeset'. Press F10 to boot and see if it helps!


Looks like you are affected by the bug reported in Launchpad. A suggested fix is to open /var/lib/dpkg/info/slpd.postinst and edit it. So, open your terminal and type:

  sudo nano /var/lib/dpkg/info/slpd.postinst

and add -f to the line no:9 so that it becomes:

  update-rc.d -f slpd remove

Save and then try installing again.


To change your resolution open a terminal: Ctl + Alt +T

Find your resolution modes and ouput:
'xrandr -q'

Change your resolution to options litsed in terminal;

xrandr --output LVDS --mode 1280x800

You may  have to add a -d :0 parameter:

xrandr -d :0 -q
xrandr -d :0 --output LVDS --mode 1280x800


How to install mac keyboard and trackpad drivers

Did you enable "Install third-party software for graphics and WIFI hardware and additional media formats" during installation? Also, if you have a external mouse, can you try using that? Theres also "Additional Drivers" in the "Software & Updates app, see if the drivers for the trackpad/keyboard are there.


Is there a program to charge/discharge the battery automatically without the need to unplug the ac adapter everytime?

As far as I know, the choice of power source it is automatically controlled by the bios, may also be the case that this is done by the motherboard hardware itself. I seriously doubt that there is an option to change this.


I had a lot of problem when updated to 12.04.

What i've done was in a console ( ctr + alt + f1 ) to uninstall the packages xserver-xorg, ubuntu-desktop (and fglrx packages because i have an ati)

To uninstall:

sudo apt-get remove --purge xserver-xorg ubuntu-desktop

After doing this you may have uninstalled some usufull packages like gnome. Before uninstall check the packages that apt-get uninstalled to manually do that when you reinstall again the packages.

sudo apt-get install xserver-xorg ubuntu-desktop

--------- [init] DO YOU HAVE AN ATI?----------------

sudo apt-get remove --purge fglrx*

Then try to install your graphic card drivers property. If you have an ati:

http://support.amd.com/us/gpudownload/Pages/index.aspx
(download it before you uninstall these packages)

I also recommend do check this post: X doesn't start after Upgrade from 11.10 to 12.04

--------- [END] DO YOU HAVE AN ATI?----------------

Before you try this you can also try to run the command:

apt-get install --reinstall xserver-xorg ubuntu-desktop

Good luck.


The Arial font is get installed by ttf-mscorefonts-installer and the David font is available in culmus package.

Open a terminal and do this command to get them

sudo apt-get install ttf-mscorefonts-installer culmus

Or using Software center:

If you want to install only the David font (culmus package includes some other fonts too), you can download that font from the link below

Download link for David font only

Download it and copy the font file in the .fonts directory in your home. This directory is hidden by default. Use Ctrl + H to reveal the hidden files and folders.
If the directory does not exists already, create one with name .fonts and copy the file in that directory.

Note: You have to accept the EULA when installing the ttf-mscorefonts-installer package. Use Tab for navigation in the terminal.

[Reference]

Arial is installed by ttf-mscorefonts-installer as described in the package's description
David font is in the culmus package as described by the package's file list


What is the best way to synch One Drive business folder to Ubuntu 18.04?

I am looking for a way to sync my One Drive (business) onto my computer with the OS Ubuntu 18.04

I am the developer of the Linux OneDrive Client: https://github.com/abraunegg/onedrive
Fully supports:

OneDrive Business
OneDrive Business Shared Folders
SharePoint Drives


Install Losslesscut snap as follows:
sudo snap install losslesscut

See reference and further guidance on usage here and product details here.


glxinfo Error: couldn't find RGB GLX visual or fbconfig

My particular problem was caused by trying to start X directly as a service using SystemD without logging a user in. I refactored my setup to have SystemD automatically log in with the following getty override script:

[Service]
ExecStart=
ExecStart=-/sbin/agetty --noissue --autologin {{ username }} %I $TERM
Type=idle

saved in /etc/systemd/system/getty@tty1.service.d/override.conf. I then started X from the user's bash_profile by running /usr/bin/startx.


Ubuntu 14.04 installation for Surface Pro 3

The easiest way is to use the Ubuntu USB to boot into an Ubuntu Live Session, then use boot-repair to fix it:

sudo add-apt-repository ppa:yannubuntu/boot-repair
sudo sed 's/trusty/saucy/g' -i /etc/apt/sources.list.d/yannubuntu-boot-repair-trusty.list
sudo apt-get update
sudo apt-get install -y boot-repair && (boot-repair &)
sudo boot-repair


How do I update bash on a Quantal system?

The cleanest way is to compile from source.

The correct way is to upgrade.

The wrong way is to get the package from a release which has patched that (according to this question, fixes have been released for supported versions - 10.04, 12.04, 14.04) and install it.


SED command to replace certain string for the specific format

this should do

$ sed '/TableName/s/Name,$/"&"/' infile
Name,
TableName.Name AS "Name,"

$ is an anchor to point end of line, so Name,$ matches 'Name,' at the end of the line and replace it with "Name,"


Can't install mysql-server with 'sudo apt install mysql-server'

mysql repository is misconfigured because the used codename is xenial instead of focal. Use the following command to fix mysql repository (Ulyssa is based on Focal):
sudo sed -i 's/xenial/focal/g' /etc/apt/sources.list.d/mysql.list

Then run:
sudo apt update
sudo apt install mysql-server


Feedback still exists: if you click an icon of an unopened app on the launcher, you should see it pulsing until the app is open.  It will also wiggle if it wants your attention but does not have focus.


This location could not be displayed on Ubuntu 16.10

If you don't have permissions to see a drive, you can set permissions as root in the terminal:
(Change "user" with your Linux user)

# chown -R user:user /media
# chmod -R 775 /media

EDIT: Although I was happy to help you and solve the problem, I must also say that this could also be a security breach as long as everyone else in the computer can see and run every media file inside the /media tree path.

If you have more users, or simple want to keep your files away from other's eyes, check the meaning of the permissions and set them accordingly.

For example: chmod -R 750 to be allowed to do everything to your files; everyone else in your user group, can watch and run; and the rest, well, could not even watch if there is any folder, even less what stuff there is inside them (again, unless you give them permissions).


What version of Evolution will be in Maverick?

According to its Launchpad page the current version in Maverick is 2.30.3.

https://launchpad.net/ubuntu/+source/evolution

(Tip: You can use any package name in Ubuntu and replace it in that URL and find that information for any given package in the archive and any supported release.)


Cannot append to mbox file error while fetching mail in Evolution

If you are using lucid(10.04) you can use this ppa https://launchpad.net/~jacob/+archive/evo230 to fix this error.

Some  workarounds are also available to solve this error( eg: archivemail). There is bug report on launchpad regarding this. Just go through it:
https://bugs.launchpad.net/evolution/+bug/197290


How do I recover deleted entries from Xubuntu Settings Manager?

Your question is a good one, as there is no documentation on what to do when this happens. Deleting Display or Accessibility, for example, from the Accessories part of the Xfce4 menu will actually remove the helper application's link from settings manager.

What happens is that when you 'delete' something like accessibility from the Accessories part of the Xfce4 menu, a .desktop file appears in ~/.local/share/applications. That file will be labelled, for example, xfce4-accessibility-settings.desktop and will have in the file:

Exec=xfce4-accessibility-settings
Hidden=true

So therefore just delete the .desktop files in ~/.local/share/applications that refer to the Xfce items that you have deleted in the menu dialog: e.g. xfce-display-settings.desktop.

Now when you load up the settings manager again they will be available once more. The 'applications' in settings manager are just links to those applications: e.g. xfce4-accessibility-settings is the program behind the accessibility icon.

If you want to get a list of the settings programs for reference, run

dpkg -L xfce4-settings | grep bin

which returns:

/usr/bin/xfce4-settings-editor
/usr/bin/xfce4-mouse-settings
/usr/bin/xfsettingsd
/usr/bin/xfce4-keyboard-settings
/usr/bin/xfce4-settings-manager
/usr/bin/xfce4-display-settings
/usr/bin/xfce4-accessibility-settings
/usr/bin/xfce4-mime-settings
/usr/bin/xfce4-appearance-settings

I can say that the solution has been tested on Xfce 4.10 and 4.12 (development) and will work. However, reinstalling the Xfce components would not work, as the problem lies in your home folder, of which files and settings are not purged when reinstalling programs.


It's obsolete and has been removed

DCOP the protocol is now being handled by D-Bus, the former dcop command is an old KDE thing.

It's even in the Wikipedia: DCOP page you provided yourself!

  DCOP was replaced by D-Bus in KDE Software Compilation 4.

  [...]

  D-Bus, a message bus system standardized by freedesktop.org, was heavily influenced by the DCOP system and replaces DCOP in KDE Software Compilation 4.

So, have a look at the possibilities the dbus-* commands can do for you.

I think you were looking at a very old or mixed up sources, as Cinnamon is quite new thing while this has been obsoleted since the release of KDE 4 in 2008.

Move to D-Bus

In KDE, to toggle the window state of Yakuake Terminal emulator, do this (verified working):

qdbus org.kde.yakuake /yakuake/window toggleWindowState

How to get this working in Cinnamon? Not sure, as Yakuake is a KDE program and I'm not familiar with non-Qt D-Bus implementations.


Printer and software for label printing?

Libreoffice has label printing capabilities. Just open File - New - Labels.

Any good printer which is Linux compatible should do. You can check here and here if the printer you're considering is compatible.

As a side note, I recommend using good quality label paper, because if labels get stuck in the printer, they can cause havoc.


Intel Graphic Driver on Toshiba Satellite L755

This is what I meant with my comment in our discussion :

To achieve want you want - switching to intel graphics -
you have to install NVIDIA drivers and Optimus support.

Install the latest current stable NVIDIA driver
from the NVIDIA short-lived branch (355.11) :

sudo add-apt-repository ppa:graphics-drivers/ppa
sudo apt-get update
sudo apt-get install nvidia-355 nvidia-prime
sudo reboot

After rebooting open NVIDIA Xserver Settings -> PRIME Profiles and select Intel.
Logout and back in - check PRIME Profiles - now you are using the intel graphics !


If I am correct, you can change and customize your launcher simply by installing a new theme.

To install it, open a Terminal and enter the following commands (for installing numix theme)

sudo add-apt-repository ppa:numix/ppa

sudo apt-get update

sudo apt-get install numix-gtk-theme numix-icon-theme-circle

Then, install the Unity Tweak Tool

sudo apt-get install unity-tweak-tool

Open the Unity Tweak Tool and click on Theme

You can find more themes online just numix theme it's very popular.


Does TLP dynamically change according to power source?

Yes it does
You can check it yourself by running  sudo tlp stat once on battery & once on AC power.


How to open several Terminal Tabs in different folders (working directories)?

The following works for me on oneiric. You can use this in place of your version:

#!/bin/bash
gnome-terminal --tab  --working-directory="/var/www/" --tab --working-directory='/home/' --tab --working-directory='/home/'
exit 0


KDE5 -- bring up the "command prompt" like bar at the top of the screen

It's called KRunner, but you'll find the shortcut settings in

System Settings > Workspace > Shortcuts > Global Shortcuts > Run Command:

Alt+Space is the default binding. You can also open it by executing krunner, e.g. in a terminal.


How to securely mount LUKS partition at login?

If your home folder itself is encrypted by LUKS, there should be no way for the key to be read without the home folder being decrypted (which only happens when you're logged in).
As long as the keyfile is actually read from your user directory (/home/<whatever>) and not /root, you should be okay.
As for auto-mount on login, you can use a simple script in your Startup Applications list (run after login succeeds, so it will work as long as you're mounting this drive to userspace). For logout, you can set it up to unmount when you kill your X session.
In short, you would do the following:

Create a small script that will unmount the encrypted drive from wherever it's mounted
Add this to session-cleanup-script in /etc/lightdm/lightdm.conf. This will run whenever any session is killed, so this may not be the best option.

Caveats

As mentioned before, the auto-logout script runs when any X session is terminated, so it's likely that your drive may be accidentally unmounted when another user logs out of your concurrent session. However, this won't be an issue if you're an only user who keeps only a single X session running.
Similarly, you NEED to keep an X session open, even in a TTY, unless you want to manually mount/unmount the device.


Run AIDE at the selected time of the week

Do a which aide and copy the result (assuming /usr/bin/aide)

Add a line to crontab -e  with format

0 9 * * Sun /usr/bin/aide --check

OR to /etc/crontab:

0 9 * * Sun {user} /usr/bin/aide --check

(1st 5: minutes, hours, day of month, month, day)
replace {user} by your username
Sun can be replaced by either 0 or 7.


Can't install programs from terminal - error "403 forbidden"

I found the problem: it seems that permissions were misconfigured on my session, all I had to do was to open the terminal (Ctrl+Alt+F2) and change permissions with a chmod 0766 -R *.


How to add calculations to the gnome search bar?

I found this from Built-in calculator to GNOME search window

The pre-installed GNOME Calculator in Ubuntu 18.04 is a snap application which may lack some features provided by the traditional one due to restrictions of snap packages.

Remove the snap application by running

snap remove gnome-calculator

and install the traditional apt one by running

sudo apt install gnome-calculator

You may need to to restart GNOME shell by hitting Alt+F2, then typing r and pressing Enter for it to take effect.


I want to install skype but i have to authenticate first, the problem is that i do not know the password. Where can i find the required password?

This is how to reset password.

I suggest also creating a new user with administrative rights and remove that "Dell" user.


Don't run steam as root, there is no benefit.
You can search protondb for the game, there are some results. Some can run it, some not. Seems related to grafic driver, which you forgot to tell us.
The error message you posted above are register messages from the cpu i think, nothing about permission. Take a look to the crash log.


What directories on Ubuntu aren't actually on the Hard Drive?

To list all mounted file systems and their mount point directories that are virtual i.e. not backed by a physical disk storage, you can parse the output of the mount command.

For simplicity, I'm only filtering out all mounts corresponding to devices starting with /dev/sd or /dev/mmcblk, which should cover most hard disk partitions and removable media. This is not perfect, because you might possibly have devices that show up differently which would then not get filtered out, but as you later still see what was mounted in the output, I prefer false positive results here over false negatives. If you notice you need to add something, simply add it to the regular expression pattern of the first grep command, inside the (...) brackets and separated from the other filtered line beginnings with a | pipe.

mount | grep -vE '^(/dev/sd|/dev/mmcblk)' | grep -oE '\S+ on \S+' | sort -k3 | column -t

This will result in a list of mounts, like that one on my example machine:

$ mount | grep -vE '^(/dev/sd|/dev/mmcblk)' | grep -oE '\S+ on \S+' | sort -k3 | column -t
udev           on  /dev
hugetlbfs      on  /dev/hugepages
mqueue         on  /dev/mqueue
devpts         on  /dev/pts
tmpfs          on  /dev/shm
proc           on  /proc
binfmt_misc    on  /proc/sys/fs/binfmt_misc
systemd-1      on  /proc/sys/fs/binfmt_misc
tmpfs          on  /run
cgmfs          on  /run/cgmanager/fs
hugetlbfs-kvm  on  /run/hugepages/kvm
tmpfs          on  /run/lock
tmpfs          on  /run/user/1000
gvfsd-fuse     on  /run/user/1000/gvfs
sysfs          on  /sys
efivarfs       on  /sys/firmware/efi/efivars
tmpfs          on  /sys/fs/cgroup
cgroup         on  /sys/fs/cgroup/blkio
cgroup         on  /sys/fs/cgroup/cpu,cpuacct
cgroup         on  /sys/fs/cgroup/cpuset
cgroup         on  /sys/fs/cgroup/devices
cgroup         on  /sys/fs/cgroup/freezer
cgroup         on  /sys/fs/cgroup/hugetlb
cgroup         on  /sys/fs/cgroup/memory
cgroup         on  /sys/fs/cgroup/net_cls,net_prio
cgroup         on  /sys/fs/cgroup/perf_event
cgroup         on  /sys/fs/cgroup/pids
cgroup         on  /sys/fs/cgroup/systemd
fusectl        on  /sys/fs/fuse/connections
pstore         on  /sys/fs/pstore
debugfs        on  /sys/kernel/debug
securityfs     on  /sys/kernel/security
none           on  /tmp

This listing should show all paths on the right where you have a virtual file system mounted and the corresponding type of file system on the left. As mentioned above, due to filtering /dev/sd* only, there might be some false positive results in the list.

So from that list we can conclude that /dev, /proc, /run, /sys and /tmp are purely virtual. Note that while the first four directories are virtual on all Ubuntu installations, /tmp is normally stored on he hard disk unless you manually make it a tmpfs like I did. It should never be included into a backup anyway though.

If you want a way to reduce that list of paths and filter out all those which are only subdirectories of already mentioned paths (like e.g. /dev/pts can be omitted because /dev is already listed), look at Having a list of paths, how can I filter out subdirectories of previously mentioned paths?


Allow a LXC container user to write as an external user to a mounted directory

ACL can do it successfully because it makes files to be shared for multiple users based on username rather than userid number.

It's converted to userid number inside of file's attribute.

Can I map container-www-data to have host-oli privs on the filesystem? Would this grant them access to the host? oli is not an unprivaliged account. It can do real damage.

You can run following command on host to make lxc container's www-data user can write the /incoming folder.

$ sudo chown oli /media/steve/incoming
$ sudo setfacl -m u:www-data:rwx /media/steve/incoming

/media/steve/incoming is binded one for /incoming of the lxc container.

And /media/steve/incoming's owner is already owned by oli.

So host's oli can write it directly and the container's www-data user also can write it directly.

And if setfacl command is not exists at the host, you can install it with following command.

$ sudo apt-get install acl

Host's www-data and containter's www-data can use difference user id number, So you can share /media/steve/incoming for Container's www-data user id as following.

At first, get userid number of www-data on container.

$ cat /etc/passwd | grep "^www-data:" | awk -F ":" '{print $3}'

Then it'll show an number if container has a user named www-data, userid of www-data.
At second, set file attribute with acl as following on host.

$ sudo setfacl -m u:<got_number_above>:rwx /media/steve/incoming

Then it'll work for container.

You can get more help for ACL from FilePermissionsACLs


Libreoffice+Python: Importing additional packages

Thank you Javier!

In case anyone else needs it, the correct command for me was:

pip3 install selenium --user

which installed the bindings to this folder:

/home/ --UserName-- /.local/lib/python3.4/site-packages/


How to change applications icons of Kde-Plasma 5

I had previously had Gnome installed. So this strange behavior was in fact caused by applications picking up a GTK theme.

I was able to change GTK theme in Settings > Application Style > Gnome Application Style (GTK).

After that, I unset QT_QPA_PLATFORMTHEME from /etc/profile.d/appmenu-qt5.sh and was finally able to change icons from  Settings > Icons


What is the simplest way to check to see if webmin is installed?

It should be in /usr/share/webmin

so try ls /usr/share/  or try whereis webmin

Alternately try  sudo dpkg --get-selections , to list all packages.


Well, as a kernel engineer, I've found in general the best lessons I learned
were the hard ones. Where I was challenged to dig deep and find new and creative ways to debug an issue or solve a particular sticking point. The motivation for sticking with that really came from my invested interest in a particular sub-system. If you're not committed to seeing things through then just stop now, it's all hard, it's the intensity of the war stories that vary :).
You can best help out in an area you're motivated to sustain the effort. Ask yourself how close you want to get to the HW and continue from there. For example there's a lot less applied OS concepts in general device driver development vs greater resource management issues like memory management, IO writeback, process scheduling. Device drivers after all are about banging the firmware to get what you want and then adhering to the interface for that subsystem, there are so many comparable works that it makes it relatively easy to get started there. The drawback is, you're working with HW, which is always a net drag on development.
That's a userspace book, you won't need that anymore :-p. The kernel is a service driven framework, understanding the whole user/kernel interface to begin with isn't going to be very useful if you dive right into the driver development for example, as you'll be quite insulated from userspace. The Linux Device Drivers 3rd edition is freely available and is a great reference.
See link below. Though most importantly, just start somewhere and hang on. It's supposed to be hard, test your patience, and commitment. Since you don't really know what you're interested in, it's the lessons learned from these skirmishes that will shape your future engagements. If you can't even do that, then kernel hacking isn't for you.

I would advise that you find a mentor that will challenge you and be there for you while you come up to speed. I haven't tried this myself, but this project might be a good start for you: http://kernelnewbies.org/KernelMentors.

I also suggest you become familiar with the kernel trace frameworks out there like ftrace, perf, and systemtap.

Good Luck!


Can't open apt-url links from playdeb in Chromium on Lubuntu

You will need to install the playdeb package first:

1) Download it: cd ~/Downloads && wget -c http://archive.getdeb.net/install_deb/getdeb-repository_0.1-1~getdeb1_all.deb

2) Make it executable: chmod +x ~/Downloads/getdeb-repository_0.1-1~getdeb1_all.deb

3) Install: sudo dpkg -i ~/Downloads/getdeb-repository_0.1-1~getdeb1_all.deb

All in one: cd ~/Downloads && wget -c http://archive.getdeb.net/install_deb/getdeb-repository_0.1-1~getdeb1_all.deb && chmod +x ./getdeb-repository_0.1-1~getdeb1_all.deb && sudo dpkg -i ./getdeb-repository_0.1-1~getdeb1_all.deb


How can I convert a 1080p wmv video to a 720p video?

Since you used an ffmpeg tag I will use that for the answer.

ffmpeg -i input.wmv -s hd720 -c:v libx264 -crf 23 -c:a aac -strict -2 output.mp4

Change the video quality by specifying a different CRF parameter. See the x264 encoding guide for more info.


The default font for Ubuntu is called Ubuntu.

Quote from http://en.wikipedia.org/wiki/Ubuntu_(typeface):

"The Ubuntu Font Family is the default font for the current and development releases of the Ubuntu operating system and is used for the Ubuntu project branding"


Multiboot Win 7, Ubuntu + Linux on UEFI system

Your multi-boot will not work if you use distributions not compatible with UEFI and SecureBoot. (eg Debian)

Currently, very few Linux distribution have good support of UEFI+SecureBoot.(AFAIK, only Ubuntu12.04.2/12.10 and the last Fedora and derivatives)

Furthermore, I think that Ubuntu and Fedora have different ways to handle UEFI+SecureBoot, so it might not be possible to do a Ubuntu+Fedora multiboot on UEFI/SecureBoot. To workaround this, I recommend you first disable SecureBoot, then run Boot-Repair (this will convert Ubuntu into "Non SecureBoot" mode), then check that Windows+Ubuntu still work, then install Fedora, then run Boot-Repair again.


while speaking using headphones how to stop sending internal sound with my voice?

You are probably using skype to talk to them. Make sure you disable your sound in teamviewer. In ur settings, on your computer disable the sound from teamwiever.

If you are using TeamViewer to talk to another person, you shouldn't be able to hear them.


How do I batch delete a specific file inside multiple rar archives?

To delete files in a rar archive we may use the option d. This can easily be integrated in a recursive action like e.g.:

for f in *.rar; do rar d "$f" JPG-Crack.exe; done

The above command will find and delete JPG-Crack.exe files in all *.rar archives of the current directory.


Screen goes off when playing videos in kubuntu

Ideally, the video application should handle this itself, but not all do, for all platforms.

You can manage it yourself with Caffeine.

You'll need to get it from a ppa:

sudo add-apt-repository ppa:caffeine-developers/ppa
sudo apt update
sudo apt install caffeine


How to switch between GPU's  on HP Pavilion DV7 Laptop?

I myself had got a Laptop with two GPUs . They also supported auto-switching technology. Now when i installed ubuntu, I ran into a similar problem that when auto-switching is done, It could not switch completely which resulted into erroneous screen, ending up in unexpected system shutdown. What worked for me was to edit my kernel boot details first as:

grep -i switcheroo /boot/config-2.6.*

and setting the essential options for GPU switching(Which obviously I googled)

The condition is: The vga_switcheroo mechanism will only be active when the kernel is booted with either the "modeset=1" kernel option, and/or the "nomodeset" option being absent

Now after making the above mentioned configurations, test if vga switching works by:

ls -l /sys/kernel/debug/vgaswitcheroo/switch

and if that works, you can try out the advanced methods for vedio switching as mentioned in this article.


You need to edit your /etc/hosts file so that http://foo resolves to 127.0.0.1.

Edit the file /etc/hosts (with sudo/root) and add the following line:

127.0.0.1 foo


Redis is located in the Universe repository

From https://help.ubuntu.com/community/Repositories/Ubuntu

  Universe - Community maintained software, i.e. not officially
  supported software.

Looking at packages.ubuntu.com, the version of redis-server in the 13.04 repositories is 2.6.0, which is pretty current, although could use a small update to 2.6.7. Since Universe is community supported, you might want to file a bug against the package here

From http://packages.ubuntu.com/search?keywords=redis-server&searchon=names&suite=all&section=all

lucid (misc): Persistent key-value database with network interface [universe]
2:1.2.0-1: amd64 i386
oneiric (misc): Persistent key-value database with network interface [universe]
2:2.2.11-3: amd64 i386
precise (misc): Persistent key-value database with network interface [universe]
2:2.2.12-1build1: amd64 i386
quantal (misc): Persistent key-value database with network interface [universe]
2:2.4.15-1: amd64 i386
raring (misc): Persistent key-value database with network interface [universe]
2:2.6.0-1: amd64 i386

Why don't the Ubuntu repositories have the latest versions of software?


take a look at the Arch-Wiki there you will find what you need. Generating key-pairs in OS X is done the same way you would do on any other linux distro take see this article

$ ssh-keygen


Need driver for an Epson WF-3620 printer

Go to the Epson download page.
Enter WF-3620 as product name and choose Linux as operating system.

The search result page will give you three download links. Click on each of them. You will get new windows or tabs. Change to them. Scroll down until the end of the relevant driver download pages. Click the accept button and scroll down again.  There you click again on the download button of your matching *.deb file. Download and install them.

But beware, unfortunately not all features are supported by these generic drivers


Change

GRUB_HIDDEN_TIMEOUT_QUIET=true

and run

sudo update-grub


No files or folders are shown on Desktop Ubuntu 17.10

Gnome Tweaks, installed with Ubuntu Software, should work. I also have the two settings (changed in dconf interface) you list (same values). Additionally, the org.gnome.desktop.draw-background is set to true.

I remember having problems with this in Gnome Classic on 17.04 release. It worked for me eventually, might require session logout. Try using dconf instead of gsettings.

If you have gone through many consecutive upgrades between Ubuntu versions a hard reset might be necessary first. This command will reset all your desktop settings in 17.10 to default so use as a last resort (I had to do this myself for other reasosn): dconf reset -f /


Is it possible to have audio output source switch automatically with Xonar DG?

Headphone detection is not implemented in the current version of the Linux driver.


CLI command being overridden? visual-studio-code is installed alongside sublime text but the CLI command `code` only opens sublime

I was only able to find this due to the comments above for debugging commands. The source of this issue ended up being the following:

I had an alias that looked like this:

alias e="code"

Then later on I had a function that was mapping:

function e() {
     subl
}

Which was overriding the alias.  So a search for "code" found the alias that I expected, but since apparently functions get checked first, it was still calling for the function e instead of the alias.


Crunchbang! how to install on second HDD and have working grub

You can install crunchbang linux without affecting ubuntu , just insert live cd in the drive and follow the onscreen instructions . Keep in mind that crunchbang is highly unstable and it is not recommended for nomal users . If you just want to try crunchbang install it in virtualbox inside ubuntu

EDIIT

since crunchbang have no wubi like installer ,And you have no previous experiance with dualboot(wubi is not real dualboot) ,try it in virtualbox ,

If you have more doubts visit our neighbour unix.stackexchange.com


Random memory corruption going undetected by memtest86

There are other tools for RAM testing within Ubuntu. It is possible that they will detect errors that Memtest86+ doesn't, since the errors depend on the patterns written to memory.

MPrime is a popular RAM and CPU tester. If you use it to test RAM, make sure that you manually specify the amount of memory to use—otherwise it defaults to 1600 MB. E.g.,

Type of torture test to run (3): 13
Min FFT size (in K) (8):
Max FFT size (in K) (4096):
Memory to use (in MB, 0 = in-place FFTs) (1600): 15000

memtester is another RAM tester and is in the repository.


Change your system configuration for the installation to non hi-def and change it back afterwards.

system settings --> general --> desktop scaling

You only need to do this during the installation of new software (not for starting and configurating existing ones) and you can keep the settings windows open, so it's not as big a pain as it seems at first. I still suggest to open an issue on their official forum


Change default applications in Lubuntu using configuration file

To change the default application, the instruction here shows how. https://manual.lubuntu.me/stable/3/3.2/3.2.7/file_associations.html


If I understand correctly, you want to keep HTTP and HTTPS ports redirected to RPi, but you want to be able to somehow use webmail from the Ubuntu machine?
In that case you need to take advantage of the Apache web server proxying capability. You can set up a particular subdomain or URL on your Apache server to "forward" a connection to a completely different website. Here's the guide on setting this up: http://httpd.apache.org/docs/2.4/howto/reverse_proxy.html
Of course for the mail server itself, you need to forward ports 25/587/465 (for SMTP) and 143/993 (for IMAP) to the Ubuntu machine.


Just dd the section of the disk that goes from the start of the disk to the end of the last partition.

In your case the last partition is /dev/sdb3, so:

Find /dev/sdb3's end using sudo fdisk -l /dev/sdb (End column);
dd the section of the drive that goes from the start of the disk to the end of /dev/sdb3 (let's assume that the end of /dev/sdb3 is on byte 50000000000 and that the target drive is /dev/sdc for the sake of the example): sudo dd if=/dev/sdb | head -c 50000000000 | sudo tee /dev/sdc


Windows 7 Slow bootup after installing Ubuntu

I had a similar problem:

Windows 7 was already installed (and working well)
Installed Ubuntu 13.04 with option to install alongside existing OS

Then, Windows 7 took a long time (2-3 mins) to boot.  Plus, it was very slow, system sounds played distorted, and the touchpad was sluggish.

Unfortunately, I do not have a good solution; I booted with a live Ubuntu USB stick, and ran "OS Uninstaller" to remove the Ubuntu installation on the machine.  Afterwards, Windows 7 runs much better.

I suspect that it has something to do with booting Windows 7 from the GRUB menu instead of through it's own bootloader, but I did not have a chance to investigate.


apt update throws signature error in Ubuntu 20.04 container on arm

The root cause of the problem is in libseccomp. The newer version fixes the problem, but it is not yet available in Debian's stable repos. There are two way to fix this problem:
Method 1
Start the container with --privileged. This bypasses docker's security measures, so it is not recommended. Or with --security-opt seccomp:unconfined as a little more secure.
docker run -it --security-opt seccomp:unconfined ubuntu:latest
Method 2
Upgrade libseccomp manually on the host system. Dowload version from unstable repos (I tested with 2.4.3-1) here.
Install the new version:
sudo dpkg -i libseccomp2_2.4.3-1+b1_armhf.deb
Note: The above methods solved the problems for systems based on Raspbian. The error was also happening on a Ubuntu 20.04 aarch64 system, for which @NeonLines' answer was able to help.


Is it possible to have Separate X Screen with separate sound?

Sure you can. Simply choose the appropriate sound card on the application whose output it's on the TV screen. Or you can use a soundserver like PulseAudio (or Jack if supported by the applications) and setup a custom routing.


ubuntu 12.04.3 with gnome: some shortcuts e.g. [alt]+[f2] do not work

Here is your solution

You can give a try to this option. You'll get a lot of configuration to set your own Shortcut Key.

Follow these steps:

Open Keyboard from System Settings (or Search in dash)
Chose Shortcuts tab
Go to Custom Shortcuts to set a new key to run any application. For example you can set gnome-terminal to execute in press of Ctrl+Alt+T which I think is missing for you. You can set any thing you want.
I am attaching a screenshot which shows the shortcuts for Navigation.

I hope you would get your missing keys.. Reply if you need further assistance..


Why is the "repo" package unavailable in Ubuntu 20.04? How can I install it?

I encountered this issue as well and I solved it by manually installing repo
from the repo installation page:
Taken from the install instructions:
mkdir -p ~/.bin
PATH="${HOME}/.bin:${PATH}"
curl https://storage.googleapis.com/git-repo-downloads/repo > ~/.bin/repo
chmod a+rx ~/.bin/repo


how to restore top level menu on panel in ubuntu 13.04

Uninstalling Macbuntu will remove appmenu-gtk so you have to install it again: sudo apt-get install appmenu-gtk appmenu-gtk3 appmenu-qt indicator-appmenu


Kmail can't start Akonadi services on Kubuntu 20.04

Here follows a bit more information about akonadi  and kmail issues in Kubuntu 20.04 LTS
I have noticed that kmail starts fine after rebooting. But if I close the session and start a new one (no matter whether with the same user or with a different one), akonadi complains and is no longer able to start.
Here follows akonadi's complain after running  akonadictl start
org.kde.pim.akonadiserver: Starting up the Akonadi Server...
org.kde.pim.akonadiserver: Failed to connect to database!
org.kde.pim.akonadiserver: Database error: "Can't connect to local MySQL server through socket '/run/user/1002/akonadi/mysql.socket' (2) QMYSQL: Unable to connect"
org.kde.pim.akonadiserver: Shutting down AkonadiServer...
org.kde.pim.akonadicontrol: Application '/usr/bin/akonadiserver' exited normally...

Running mysqld --version I get:
mysqld  Ver 10.3.22-MariaDB-1ubuntu1 for debian-linux-gnu on x86_64 (Ubuntu 20.04)

Trying to start kmail, I get:
Connecting to deprecated signal
QDBusConnectionInterface::serviceOwnerChanged(QString,QString,QString)
org.kde.pim.akonadiserver: Starting up the Akonadi Server...
org.kde.pim.kidentitymanagement: IdentityManager: There was no default identity. Marking first one as default.
org.kde.pim.akonadiserver: Failed to connect to database!
org.kde.pim.akonadiserver: Database error: "Can't connect to local MySQL server through socket '/run/user/1002/akonadi/mysql.socket' (2) QMYSQL: Unable to connect"
org.kde.pim.akonadiserver: Failed to remove runtime connection config file
org.kde.pim.akonadiserver: Shutting down AkonadiServer...
org.kde.pim.akonadicontrol: Application '/usr/bin/akonadiserver' exited normally...
org.kde.pim.akonadicore: Job error:  "" for collection: QVector()
org.kde.pim.akonadicore: Job error:  "" for collection: QVector()
org.kde.pim.messagelist: Failed to load tags  ""

Certainly, /run/user/1002/akonadi/mysql.socket  never exists (even when kmail is able to start at a first attempt).
I have tried many solutions proposed in several forums (even reinstaling kontact) and the issues remained.


actually it was a bug in remmina that got fixed couple of days ago ,
you can get that bug fix by refreshing snap from edge channel :
sudo snap refresh remmina --channel=edge


Mono: Apache mod_mono installing issue on Ubuntu

Install mono-apache-server4 instead of mono-apache-server with libapache2-mod-mono

So, try:

apt-get install libapache2-mod-mono mono-apache-server4


Assign fixed path to printer (/dev/usb/lp0)

You can write udev-rules to assign different names to the printer, depending on their serial numbers.

See http://www.reactivated.net/writing_udev_rules.html#example-printer for an example of a udev printer rule.


How can I uninstall Ubuntu when dual-booted?

You can use OS-Uninstaller or you can do manually

How to using OS Uninstaller https://help.ubuntu.com/community/OS-Uninstaller

also see windows 7 or 8 in this link https://help.ubuntu.com/community/RestoreUbuntu/XP/Vista/7Bootloader


Try:

sudo gedit /etc/apt/sources.list.d/ondrej-php5-trusty.list

Than remove the hashes (#) re-enable that PPA which were probably disabled by system

sudo apt-get update

sudo apt-get install skype


Boot repair enable a repository containing grub2 packages

Boot Repair didn't work work me. After a lot of searching and trying I finally managed to regain access to my Ubuntu with following set of commands:

sudo mount /dev/sdb8 /mnt
sudo mount --bind /dev /mnt/dev/
sudo mount --bind /dev/pts /mnt/dev/pts
sudo mount --bind /proc /mnt/proc
sudo mount --bind /sys /mnt/sys
sudo chroot /mnt
grub-install /dev/sdb
grub-install --recheck /dev/sdb
update-grub
exit
sudo umount /mnt/sys
sudo umount /mnt/proc
sudo umount /mnt/dev/pts

(All commands were executed in LiveUSB)


It was not clear, you do not have root password?
If you install Skype, I advise to download directly from the site http://www.skype.com/pt-br/download-skype/skype-for-computer/
You will download the .deb file
By downloading run in the terminal: dpkg -i (downloaded package).
Then run: apt-get -f install
So resolve the pending package.


Well this drove me mad for five minutes. Change your statement to:

convert $(LC_COLLATE="C" ls -w 1000) +append sprite.png

For some reason Nautilus doesn't follow the system-wide locale settings so sorts are out of sync. By faking back to the standard, sorts unify.

My test harness:

$ mkdir test && cd test
$ touch cloudy_with_heavy_rain{,_night}.png

$ ls -l
total 0
-rw-rw-r-- 1 oli oli 0 Apr 13 00:32 cloudy_with_heavy_rain_night.png
-rw-rw-r-- 1 oli oli 0 Apr 13 00:32 cloudy_with_heavy_rain.png

$ LC_COLLATE="C" ls -l
total 0
-rw-rw-r-- 1 oli oli 0 Apr 13 00:32 cloudy_with_heavy_rain.png
-rw-rw-r-- 1 oli oli 0 Apr 13 00:32 cloudy_with_heavy_rain_night.png


If you have Detect Outputs checked, that overrides the manual outputs in the window below. Once I unchecked Detect Outputs, everything works well.


Ping6 routing between interfaces failing

If you are using static IPv6 addresses, you also need to set up IPv6 static routes. You can't get around that. You can run a routing protocol, but that would be overkill in this situation.

You instead want to use router-assigned addresses, namely SLAAC, so that the default route will be provided with the address.

Maybe start here to understand the basics: https://community.infoblox.com/t5/IPv6-CoE-Blog/SLAAC-to-Basics-Part-1-of-2/ba-p/11356

And then set up Machine B as a router, since that is what it is. http://www.tomicki.net/ipv6.router.php


Problem connecting to my Samba server on ubuntu from my windows computer

When i have problems with samba I'm always starting from switching to ethernet cable. If my share is connected via ethernet i cant connect to it via wifi (eventhough I can ssh with no problem). Then i make easiest share possible with no fancy masks end forcing options, only to test if it works. If not then I'm checking logs to see if it's stopped by any security mechanism (it could be firewall, iptables, selinux). For home usage I'm switching all security off and test it again. Then, if it works I form my share policy in smb.conf and reset smb and nmb. And them I'm checking if my share still works. And then I switch my security back on, one by one to find which one is blocking my smb. This is how you can learn using selinux. I forgot to mention most improtant thing. Alwayas check premissions, and host part of samba configuration. You must be shure that you have unix premissions on your share.


Shell script to search for a pattern in a file using if else

I'd strongly suggest not using csh (or its variants) for new scripts, for the reasons discussed here Why shouldn't I program in csh?

However the correct syntax appears to be:

if ( { grep -q 'Pattern' file } ) then
  echo "Pattern found"
else
  echo "Pattern not found"
endif

i.e. the inner brackets need to be braces, { ... }. You don't need to echo $? in order to test the exit status.

Alternatively, you can use the $status variable:

grep -q 'Pattern' file
if ( $status == 0 ) then
  echo "Pattern found"
else
  echo "Pattern not found"
endif

In tcsh, the variable $status may be replaced by $? - but not all csh implementations appear to support this.


Can I change the window-switching animation without CCSM?

The only alternatives I can think of involve switching compositor.

Before I go any further down that route you need to understand that Unity (the desktop environment that default Ubuntu ships with) depends completely on Compiz. If you use another compositor, you need another desktop environment.

Assuming you want me to continue, what we're actually looking for now is a replacement desktop environment. They're all substantially different to Unity so I can't tell you what you want. I use KDE, lots like Gnome and plenty use XFCE on lower-end hardware. There are many, many choices.

This question goes a distance to detail some of them:

What kinds of desktop environments and shells are available?


Well, let's try fixing your boot first, because that seems to be possible.

First off, grab a live disk and boot from it, into Try Ubuntu mode, and open a terminal.

From there, run fsck on the Ubuntu partition to see if there are any issues on it. Let fsck fix it if at all possible. Example with /dev/sdb1 being the Ubuntu installer:

sudo fsck /dev/sdb1

If everything's alright and the drive is fixed, you can try running a chroot and re-installing Grub to the OS. sudo -s into root, and run these commands:

cd /
mount /dev/sdb1 /mnt
chroot /mnt

You will now be in the "broken" Ubuntu install, and will be able to perform operations on your drive. Run the below command to re-install Grub:

grub-install /dev/sdb

This will re-install Grub to your disk, and hopefully allow everything to work.

Stop here. exit your chroot, reboot your system and see if it works. If not, then continue.

Now, let's also backup your installed packages list and your home folders. Get back into your live disk and chroot

While still in the chroot, run this command:

apt list --installed > /installed-packages.txt

Now, go ahead and exit the chroot and insert some backup media and mount it wherever. In this example, it will be at /mount/BACKUP.

Just run these commands to copy your installed package list and home folders to your backup drive. Also be sure to back up anything else that you need/want stored.

sudo cp /mnt/installed-packages.txt /media/BACKUP
sudo mkdir /media/backup/homes
sudo cp -R /mnt/home/ /media/backup/homes


error: Cannot autolaunch D-Bus without X11 $DISPLAY

export DISPLAY=:0.0

if you see

Xlib: connection to ":0.0" refused by server
Xlib: No protocol specified

Error: Can't open display: :0.0

then

xhost +


Ubuntu 18.04: Save and Restore Workspace Layout (w/ Multiple Workspaces)

The Gnome Extension "Auto Move Windows" will move applications to a specified workspace when they are opened. The location of the application windows within the workspace are also remembered. See, https://extensions.gnome.org/extension/16/auto-move-windows/

Note that there are solutions for prior versions of Ubuntu (w/ Unity) that use scripts. However, Ubuntu switched back to using Gnome in 18.04. (e.g., Saving and restoring window positions and How can I start up an application with a pre-defined window size and position?)


Can't ping router with Realtek [10ec:8168] (rev 06) Ethernet adapter

You can install another driver. Connect to internet an alternative way and run in terminal:

sudo apt-get install r8168-dkms

If you can't connect an alternative way, you will have to download this package and dkms separately.

Run

sudo modprobe -r r8169
sudo modprobe r8168

or reboot after the installation.


Create a single logical volume from 2 external hdd's

I think what you are looking for is BTRFS. Here is a guide to lead you in the right direction in terms of combining physical devices into a single logical one (on the fly even).