I am having problem installing anything on ubuntu: Errors were encountered while processing: kexi

Start by reading the error message, it basically tells you what you need to do:

dpkg: error processing package kexi (--configure):
  package is in a very bad inconsistent state; you should
  reinstall it before attempting configuration

This means it needs to be reinstalled. So, reinstall kexi, and it should fix that issue:

sudo apt install --reinstall kexi


You use program called xflock4, I can really remember what is the shortcut to that bu i thing it is Ctrl+Alt+Delete. Anyway if it doesn't work make sure it is installed.


How to install the ubuntu server 12.04 gui in offline

No, if you want a GUI, then you should use the desktop install medium. There's no difference between Ubuntu Server and Ubuntu Desktop except the default packages. That is, you can install all services on Ubuntu Desktop as well.


How to configure a systemd service that uses D-Bus?

Too long for a comment ... I am using this in another script to change the wallpaper with cron:

#!/bin/bash -e
user=$(whoami)

fl=$(find /proc -maxdepth 2 -user "$user" -name environ -print -quit)
for i in {1..5}
do
  fl=$(find /proc -maxdepth 2 -user "$user" -name environ -newer "$fl" -print -quit)
done

export DBUS_SESSION_BUS_ADDRESS
DBUS_SESSION_BUS_ADDRESS=$(grep -z DBUS_SESSION_BUS_ADDRESS "$fl" | cut -d= -f2-)


Can I keep using Ubuntu 9.04 if it's outdated?

With all the other disclaimers re: no updates, no security ...

There are most old repositories available at http://old-releases.ubuntu.com

so edit /etc/apt/sources.list and change 'archive.ubuntu.com' to 'old-releases.ubuntu.com'

You can do this with sed

sudo sed -i -e 's/archive.ubuntu.com/old-releases.ubuntu.com/g' /etc/apt/sources.list

then update with

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

Alternately use a lighter weight distro such as lubuntu, slitaz or tinycore.

Attention: you should only use the old-release archive if you have no possibility to upgrade to a newer version, because you won't get any security updates using these old archives


Type the command "xinput" into terminal. Is your touchpad listed?
If not, most likely you won't be able to use it.

From what I can tell with the research I did, the L-50 has a Synaptics touchpad. These are normally universally supported by most linux distros- it may simply be a hardware problem.


How does Ubuntu determine the default route when multiple interfaces are defined?

Often there is some misunderstanding in what the 'default gateway' means. Usually there may be only one default gateway (there are exceptions, but not in your case). There is no need to have a gateway in network 192.168.57.0, as it is directly attached.

Defining two gateways (one for each interface) seems to end up only one, depending on the sequence of the definitions. The same holds true for the DNS servers - they are not bound to a specific interface, so maybe depending on the sequence of defining/starting the interfaces the last definition wil be used.

You may change the sequence of the interface definitions (eth1, then eth0), if needed, but define gateway 10.0.5.1 and dns-... with eth0 (or, if in doubt, the same with both interfaces).


Dual Booting With Windows 10 not working

What is your installation method?
If it was through an usb stick, what is your boot table system( depends on your bios version).
If it is an UEFI it's important to do the fallowing:
When u press F11 to boot from the flash drive (usb) make sure u select UEFL:USB.
Then proceed normally with your installation.
I highly recommend that u search more about the booting tables tybes.
Please make your research first before doing anything could damage your boot framware it's IMPORTANT!!!.


Booting sequence in dual boot environment - Windows 7 + Ubuntu 12.04

This sounds like you've managed to chain-load two grubs together. Or perhaps one grub and one lilo ro something crazy like that.

I'd give boot-repair a go.


What  kind of text formatting is valid on Launchpad?

Answered on Launchpad:

  Launchpad does not support markup in
  user entered content at this time. URL
  and bug numbers are linked by the
  formatter that preserves blank lines.

Please support this bug for a Launchpad wiki.


Your ISP is asking you to login to your SMTP server so that you can respond to a return receipt request.


Keyboard language configuration, Ubuntu 16.04

pehaps no one wrote the key mappings of your polish keyboard for german and deutsch use. Ubuntu used to have these problems, but latelly I've heard the keyboard support improved a lot.
try adding polish language. If it doesn't work just buy another keyboard or contribute to ubuntu with those mappings.


The colored circles on the outer ring are simply representative of how much activity you performed of the currently displayed metric, for the current and past days. If you double-tap the center of the large circle, it will switch to a different metric type (calls made, calls received, messages sent, messages received, etc…) and the outer circles will also change to match the new metric being displayed.


19.04 settings not showing up in Unity Control Center

Possibly you want to use Tweaks. If you haven't already, you should install Tweaks:

sudo apt install gnome-tweaks

Then open it, select Keyboard & Mouse, and find a Disable While Typing switch.


kvm, pci passthrough: unable to detach nvidia card for kernel 5.4 andabove

Don't know if you solved this, but I also had my VFIO configuration stop working after the update to Kubuntu 20.04 with kernel 5.4. The solution was something that I had not had to do before,here is the link to the solution that I used. In case the link is broken in the future, I am including the information below so that people can find it.

https://github.com/rmayobre/PopOs-VFIO-Tutorial/wiki/VFIO-Steps

  Step 1 - Install the required software

  You will need QEMU, Virt-Manager, as well as some packages. Run this
  line:

sudo apt install qemu-kvm libvirt-clients libvirt-daemon-system bridge-utils virt-manager ovmf

  Step 2 - Add required kernel parameters

 sudo kernelstub -a 'intel_iommu=on'
    sudo kernelstub -a 'iommu=pt'
    sudo kernelstub -a 'iommu=1'
    sudo kernelstub -a "pci=noaer" Add this if you have problems with your VM starting when a USB Controller is attached.

  Step 3 - Look up PCI devices by ID

  NOTE: make sure you write down the IDs (you will need them later). GPU
  and Audio output

  Run the command: lspci -vnn and search for the GPU you wish to
  pass-through to guest OS. The Audio output of your GPU should be
  underneath it. Your output should look something like this (of course
  if you're using Radeon it would say otherwise):

09:00.0 VGA compatible controller [0300]: NVIDIA Corporation GP104 [GeForce GTX 1070 Ti] [10de:1b82] (rev a1) (prog-if 00 [VGA

  controller])
      09:00.1 Audio device [0403]: NVIDIA Corporation GP104 High Definition Audio Controller [10de:10f0] (rev a1)

  Remember the numbers in front of your device (e.g. 09:00.0 and
  09:00.1). Step 4 - Attach VFIO drivers to PCI devices

  We need to bind the VFIO drivers to our GPU, as well as our GPU's
  audio controller. To do this, we will create a script to help us
  attach VFIO drivers to specified PCI devices. Create this file:

sudo nano /etc/initramfs-tools/scripts/init-top/bind_vfio.sh

  Then paste this script inside the newly created file:

#!/bin/sh
PREREQS=""
DEVS="0000:09:00.0 0000:09:00.1"
for DEV in $DEVS;
  do echo "vfio-pci" > /sys/bus/pci/devices/$DEV/driver_override
done

modprobe -i vfio-pci

  Replace 0000:09:00.0 and 0000:09:00.1 with your GPU numbers (NOTE: you
  must append 0000: to the beginning of your numbers). Add your script
  to the initial ram disk

  This can be done by making the script executable:

sudo chmod 755 /etc/initramfs-tools/scripts/init-top/bind_vfio.sh

  Now add the script:

sudo chown root:root /etc/initramfs-tools/scripts/init-top/bind_vfio.sh

  Finally, update the initial ram:

sudo update-initramfs -u

  You can then verify the initial ramdisk does indeed have the script
  ready by running this(replace /boot/initrd.img-5.0.0-55-generic with
  your file):

sudo lsinitramfs /boot/initrd.img-5.0.0-55-generic |grep vfio

  Now we have to append vfio-pci to this file and save:

sudo nano /etc/initramfs-tools/modules

  Run this again:

sudo update-initramfs -u

  Reboot your system. When it comes online, run this:

lspci -nnv

  Your GPU should have Kernel driver in us: vfio-pci (like this output):

09:00.0 VGA compatible controller [0300]: NVIDIA Corporation GP104 [GeForce GTX 1070 Ti] [10de:1b82] (rev a1) (prog-if 00 [VGA

  controller])
        Subsystem: Micro-Star International Co., Ltd. [MSI] GP104 [GeForce GTX 1070 Ti] [1462:330f]
        Flags: bus master, fast devsel, latency 0, IRQ 70, NUMA node 0
        Memory at b0000000 (32-bit, non-prefetchable) [size=16M]
        Memory at 90000000 (64-bit, prefetchable) [size=256M]
        Memory at a0000000 (64-bit, prefetchable) [size=32M]
        I/O ports at 3000 [size=128]
        Expansion ROM at b1000000 [disabled] [size=512K]
        Capabilities:
        Kernel driver in use: vfio-pci
        Kernel modules: nvidiafb, nouveau, nvidia_drm, nvidia

09:00.1 Audio device [0403]: NVIDIA Corporation GP104 High Definition Audio Controller [10de:10f0] (rev a1)
  Subsystem: Micro-Star International Co., Ltd. [MSI] GP104 High Definition Audio Controller [1462:330f]
  Flags: bus master, fast devsel, latency 0, IRQ 71, NUMA node 0
  Memory at b1080000 (32-bit, non-prefetchable) [size=16K]
  Capabilities: <access denied>
  Kernel driver in use: vfio-pci
  Kernel modules: snd_hda_intel

  Step 5 - Done

  If you have got this far, you are finished with setting up the VFIO
  drivers. You can now move onto the section about configuring virtual
  machines and Virt-Manager. Pages 5 VFIO and GPU Passthrough

Home
Hardware Configurations
VFIO Attachment
Virtual Machine Configurations
Windows 10 Install

  Clone this wiki locally


I've had this exact same issue before. What I ended up doing was unpairing the device, resetting it up, which solved the connection issue. After that, I saved it as a trusted device and so far haven't had issues since.


How do I get sleep and hibernate working on an Asus K53z?

Before enabling hibernation, please try to test whether it works
  correctly by running pm-hibernate in a terminal. The system will try
  to hibernate. If you are able to start the system again then you are
  more or less safe to add an override.

  To do so, start editing

sudo nano /etc/polkit-1/localauthority/50-local.d/com.ubuntu.enable-hibernate.pkla

  Fill it with this

[Re-enable hibernate by default]
Identity=unix-user:*
Action=org.freedesktop.upower.hibernate
ResultActive=yes

  Save by pressing Ctrl-O and exit nano by pressing Ctrl-X

  Restart and hibernation is back!

  Some users will then need to run sudo update-grub to get the hibernate
  option to be available in the power menu..

Take this how-to from Hibernation


How to store system("date +%s) output to variable?c++

The output of system("date +%s") can not be stored in a variable as you tried.

From man system

int system(const char *command);

  system executes  a  command  specified  in  command  by calling /bin/sh -c command, and returns after the command has been completed.

system does not return the output of the command executed. It returns 0 if command is successfully executed and shell is not available. Otherwise returns some integer exit status.

  How can I export the output of this command to a text file

Method-1: Redirection (already mentioned by @Jobin): call system as,

system("date +\%s >> text.txt");

Method-2: Use popen, It will return a FILE* which you can use to read the output of the command.

#include <stdlib.h>
#include <stdio.h>

int main()
{
  FILE *fp,*outputfile;
  char var[40];

  fp = popen("date +%s", "r");
  while (fgets(var, sizeof(var), fp) != NULL)
    {
      printf("%s", var);
    }
  pclose(fp);

  outputfile = fopen("text.txt", "a");
  fprintf(outputfile,"%s\n",var);
  fclose(outputfile);

  return 0;
}


problems trying to dual boot lubuntu with windows 7

Boot up the live usb and open a terminal. Type sudo update-grub and check if that helps you, don't forget to reply!


Unable to detect Intel's X540 network controller

Turns out the motherboard has a sneaky clause in its documentation stating "If only 1 CPU is installed, some PCIe, memory, network or I/O functions will not be available." which translates to the network controller will not work if you only have 1 CPU installed.


Using ncftp or other ftp command-line software to get directories

Well you don't say that there is strictly the need to use a command in the terminal in order to do the work so I guess what you wish is some terminal software which can handle ftp servers, such as a ftp client gui but for terminal purposes.

If I am right, I suggest you to give a chance to Midnight Commander. Inside of which you will be able to connect to a ftp server in order to put or get files the same as folders (with files recursively).

Certain ftp server commands are allowed, such as the chmod for changing the permissions of the files/folders and there is the help of a dual tree window in which you can handle the contents of both your local device and remote server.

Here is a screenshot to illustrate:

This screenshots are taken in a unity desktop (12.04) but the same screens you'll find in terminal mode. Here is a step by step process in order to connect to a ftp. (Mouse supported only in GUI)

First let's hit F9 in order to get in the PullDown Menu. Let's go to the "Left" menu and choose "FTP Link" as shown.

The machine name will be asked, let's write in this box using the next format:

user:password@ftpserver.com

This will send your username and password to the desired ftp server. If everything runs ok you'll be able to see the contents of your ftp server on the left side of the Midnight Commander windows.

If you succeeded, let's hit the TAB window in order to move the pointer to the right pane, in which you can choose which files/folders (with files) you wish to copy, move, delete, etc. You may wish to read the manual before using midnight commander but it is quite easy to use indeed.

Midnight commander is a powerful application that can be installed directly from the terminal using the next command:

sudo apt-get install mc

Good luck!


Well, looks like it's a bug of GNOME 3.6
https://bugs.launchpad.net/ubuntu/+source/gtk+3.0/+bug/1131919

I upgraded to GNOME 3.8 and it seems to work properly now.


This worked for me.
sudo apt-get install libnvidia-gl-440:i386

This worked because the issue was with the graphics and Ubuntu 20.04 combined.
This library has 32bit files for Nvidia's gpu. These 32bit files were removed while upgrading from 18.04 to 20.04.
Though they asked about it, on which most people just clicked on ok continue. I did the same.
Edit: as of 26, July 2020, nvidia's driver 450 is available but it's i386 is having issues. So until then stick with 440.
Edit: It works with nvidia's driver 450 i386 as well now.


(standard_in) 1: parse error with comparing decimals

You are using -lt and -gt in bc scripts, but these are not operators in bc. Replace all occurrences of -lt and -gt with < and >, respectively.

if (( $(echo "scale=4; $si > $six" | bc -l) )) && (( $(echo "scale=4; $il > $six" | bc -l) ))
    then
    echo "Value is a"
    elif (( $(echo "scale=4; $si < $six" | bc -l) ))
    then
    echo "Value is b"
    elif (( $(echo "scale=4; $il < $six" | bc -l) ))
then
    echo "Value is c"
else
    echo "Value is d"
fi

Also, the first condition can be combined using a single bc:

if (( $(echo "scale=4; $si > $six && $il > $six" | bc -l) ))


Can't install Wine on ubuntu studio 19.10

Edit /etc/apt/source.list and delete the line you should not have added.

 sudo apt-add-repository https://dl.winehq.org/wine-builds/ubuntu/


SAP GUI Error: ... cannot access class sun.awt.AppContext

Change the Java version.

In my case the default version was Oracle-Java-9 Java HotSpot(TM) 64-Bit Server VM (build 9-ea+140, mixed mode)

I changed it to OpenJDK 8 OpenJDK 64-Bit Server VM (build 25.111-b14, mixed mode)

By using the command sudo update-alternatives --config java


You need to zoom out.

Use Ctrl + Scroll to zoom in and out, like you would do on a webpage.

You might also prefer listview - at the top click the icon that looks like this: ≡. It will look like this instead:


Not able to install any bittorrent client

First of all, you can do export LANG=C beore running a command to get the output in english.

The reason you can't install the package rTorrent is that the name of the package is rtorrent.

You can search for a package using the command apt-cache search rtorrent, which would show you the following:

$ apt-cache search rtorrent
qbittorrent-nox - bittorrent client based on libtorrent-rasterbar (without X support)
rtgui - Web based front-end for rTorrent
rtorrent - ncurses BitTorrent client based on LibTorrent from rakshasa
rtpg-www - web based front end for rTorrent

You can install rtorrent by running sudo apt-get install rtorrent (note the lower case).

As per your update, you have already installed rtorrent, and can start it by running rtorrent in a terminal. It additionally seems that you have missing dependencies. Please try what the output suggests; sudo apt-get -f install. Usually this will install the needed package.


How to restart OpenStack services after restart/logout?

First, search for "rejoin-stack.sh" on your machine, copy and save its path on your machine.

Second, use the terminal by pressing CTRL+ALT+T on your keyboard.

Compute Nodes:

Third type:

sudo service openstack-nova-api restart
sudo service openstack-nova-cert restart
sudo service openstack-nova-consoleauth restart
sudo service openstack-nova-scheduler restart
sudo service openstack-nova-conductor restart
sudo service openstack-nova-novncproxy restart

Network Nodes:

Fourth type:

sudo service neutron-server restart
sudo service neutron-dhcp-agent restart
sudo service neutron-l3-agent restart
sudo service neutron-metadata-agent restart

[[Open Virtual Switch if installed]]

sudo service neutron-openvswitch-agent restart

Cinder Nodes:

Fifth type:

sudo service openstack-cinder-api restart
sudo service openstack-cinder-backup restart
sudo service openstack-cinder-scheduler restart
sudo service openstack-cinder-volume restart

If you want to get all the names of the services installed:

Sixth Type:

sudo service --status-all | grep nova
sudo service --status-all | grep neutron
sudo service --status-all | grep cinder

One last thing to do is to type:

cd /path/to/rejoin-stack.sh/folder
sudo ./rejoin-stack.sh

then wait for the confirmation to start using OpenStack again.


Install KDE DE without any effect on unity

Is there a way? No, not really. We can, however, lessen the pain.  Screenshots would also help with problems 1 and 4. If you're planning on using KDE regularly it is probably worth letting it do what it wants.

This can usually be fixed by removing any .gtkrc or .gtkrc-2.0 files in your home folder and logging out and logging back in.
Don't install the recommends and suggests. Run:

sudo apt-get install kubuntu-desktop

See all that stuff it wants to install? On my Trusty install it said:

0 upgraded, 408 newly installed, 0 to remove and 0 not upgraded.
Need to get 190 MB of archives.
After this operation, 662 MB of additional disk space will be used.

Ouch! That's a lot! Instead use:

sudo apt-get install --no-install-recommends --no-install-suggests kubuntu-desktop

That lowers things down to:

0 upgraded, 204 newly installed, 0 to remove and 0 not upgraded.
Need to get 110 MB of archives.
After this operation, 358 MB of additional disk space will be used.

Much more reasonable.  Granted, those recommended and suggested packages are there for a reason, you might find a few quirks, but everything in general should work in general.
That would be the plymouth-theme-kubuntu-logo and plymouth-theme-kubuntu-text packages.

Either remove them, (with apt, etc) or run:

sudo update-alternatives --config default.plymouth

and pick the one you want to use.
Again, screenshots would help. Probably depends some on the theme too. Making sure your Unity theme is set to Ambiance and doing step 1. should help some.


How can I make the goaccess package available in Lucid (10.04)?

Download the .deb file for 32-bit or 64-bit. Install it with dpkg -i path/to/download.deb It may (probably) complain that some dependencies are missing, if so, install them. If you need a higher version, look around here for the one in precise fitting your needs.


I have upgraded my diskless PXE booting systems in the past using do-release-upgrade.

Install update-manager-core to obtain do-release-upgrade. When you upgrade, don't forget to ensure that your initrd is built for netbooting in /etc/initramfs-tools/initramfs.conf, I have had this file overwritten on upgrade in the past, the option you need is:

 BOOT=nfs

You will also need to update your kernel and kernel configuration on your tftp server.

Edit the configuration file in your pxelinux.cfg directory to contain the new entry, on my server I have a host specific file:

johnf@carbon:~$ cat /srv/tftp/pxelinux.cfg/01-00-1f-d0-27-d2-17
LABEL linux
KERNEL /vmlinuz-2.6.38-10-generic
APPEND initrd=/initrd.img-2.6.38-10-generic root=/dev/nfs nfsroot=172.29.1.6:/home/export/argon ip=dhcp rw

You will also need to update the kernel images on the tftp server itself, here's the command I use:

sudo cp --preserve=timestamps /home/export/argon/boot/initrd.img*-generic /home/export/argon/boot/vmlinuz*-generic /srv/tftp


move all .formet file from specific location?

Read This How to move multiple files at once to a specific destination directory?

mv *IDENTIFIER* ~/YourPath/

* is a wildcard for zero or more characters, this means zero or more characters, followed by IDENTIFIER, followed by zero or more characters.

This will move all the files that contain the IDENTIFIER you specified.


Windows is an operating system, MS-DOS/PC-DOS are operating systems. Windows took over DOS as the main operating system for Microsoft around Windows '95-Windows 2000 era for personal computers. You would set up your boot options in the BIOS of the computer (by pressing a key like F2, F8, F10, DEL, or other key) then go into boot options and set the boot order of the USB drive to a higher priority slot (usually 1, or on top).

Just in case, make sure the USB is inserted (and it is bootable), if not check your Motherboard specs and see if it has the capabilities to boot from USB. (MOST do, but some are weird)


Can't update from 17.10 to 18.04 because a repository doesn't have a Release file

The PPA found under http://ppa.launchpad.net/jonathonf/backports/ubuntu is no full Ubuntu repository but a PPA. In this case it does not contain any bionic packages (yet).

You want to use an official repository or mirror which carries all of the packages you need for an upgrade.

Take a look into your /etc/apt/sources.list. Are there the regular repositories linked?

For Ubuntu 17.10 you should have something like

deb http://de.archive.ubuntu.com/ubuntu/ artful main restricted
deb http://de.archive.ubuntu.com/ubuntu/ artful-updates main restricted
deb http://de.archive.ubuntu.com/ubuntu/ artful multiverse
deb http://de.archive.ubuntu.com/ubuntu/ artful-updates multiverse
deb http://de.archive.ubuntu.com/ubuntu/ artful-backports main restricted universe multiverse
...

and the corresponding deb-src entries.

There might be more *.list files in /etc/apt/sources.list.d/ - there you might have to disable the PPA entry manually.

Ho do you try to do the upgrade? The do-release-upgrade would take care of disabling the PPA entries automatically. As the time of writing this, the official release hasn't happen yet. Therefore a do-release-upgrade would not find the currtly beta status release right now. Either wait some time until they released 18.04 or use do-release-upgrade -d and go with the current status of 18.04.


lenovo 330s Ryzen error installing ubuntu 18.04

For the same reasons you needed to add noapic and idle=nowait to the boot options of your installation media, you need to add the same boot options in the boot file that has been written on your hard drive during installation.

For this you can boot on your live isb and follow instructions that you will easilly find on internet


You have nice manual for server network configuration here.

Also you can add default gw with fallowing command

sudo route add default gw ip_address_of_gw

This command is only a temporary solution, until you restart server.


Nvidia driver installed successfully, but not activated

I was also facing the same problem. Now that you asked it, I wanted to fix in my computer as well. So here is how you do it.

EDIT: sudo apt-get install nvidia-current

sudo nvidia-xconfig. This will just create the file /etc/X11/xorg.conf. Next do

sudo software-properties-gtk

You should see something like this

Select Additional Drivers tab and select the latest NVIDIA driver as I have selected here.

Now reboot. This reboot might take a long time. No need to worry. If it takes more than 10 minutes with the black screen, even after rebooting, restart with Ctrl+Alt+Del or even hard reset (keep pressing the power button as long as needed). It should work properly now.


What is the default password for the MaaS Image?

Your SSH key should be used for access. The SSH keys that you've set in MAAS will all be put on the newly installed node, in the ubuntu user account. You should be able to get into the machine with:

ssh ubuntu@${address-of-node}

Then use sudo to do things as root, as usual, though I don't think it'll prompt you for a password.


How can I combine the find command with other commands so I don't have to navigate to the folder?

I think you're looking for:

python $(find -name myscript.py)


Caps lock now used to switch languages (I can't get rid of it)

go to control panel- language and region- change input methods- advanced settings- change language bar hot keys


Install Ubuntu 20.04 Server from a partiton on a RHEL 7 core programmatically

You won't able to install ubuntu from /tmp mount point. I would prefer mount Ubuntu iso as loopback partition. You can mount Ubuntu iso as separate loopback partition and make entry in grub boot loader to start Ubuntu installation. Here is official Ubuntu documentation about it.


How to use find when there are spaces in the directory names?

find doesn't care about special characters in file names, but the program that's parsing the output of find might. If you're using xargs, use the -print0 option to find, and the -0 option to xargs. This tells find and xargs to use null characters (which cannot appear in file names) as a separator between file names, and xargs not to do any other parsing which would mangle file names containing spaces.

find /media/media1/HDTV -name '*.nfo' -type f -print0 |
xargs -0 sed -i 's/pattern/replacement/'

Another way to invoke a command on many files is to use find only.

find /media/media1/HDTV -name '*.nfo' -type f -exec sed -i 's/pattern/replacement/' {} +


How to automatically change volume level when un-/plugging headphones?

To set volume level from console use the command amixer.
For example:

  amixer sset Master playback 0%

Will set your level to 0%

I don't know how to change this when you plug in your headphones... but maybe someone can help you with that


Can you provide more info. As mentioned, what was the other windows running on along side?? When you get black screen, how long does it stay.. meanwhile, does it shows any errors??


How can I make lightdm scale on a hidpi screen?

I've found a small fix that seems to work on login, but not on the lock screen. This solution also makes the top bar a little botched as the text is to big for the confinds - perhaps a costum theme would be the best solution? Also it's probably reliant upon the desktop already having set the Xft.dpi value highger.

Open a terminal and run xrdb -query | grep dpi
Open /usr/share/glib-2.0/schemas/com.canonical.unity-greeter.gschema.xml
Find by key-name="xft-dpi" type="d"
Replace the default value with the DPI from the xrdb output

This should go in effect instantly (logging out shows the larger text on my side).


Can I run a desktop OS in a virtual machine as if it ran on bare metal?

You are looking for Linux Containers:

  Containers are a lightweight virtualization technology. They are more akin to an enhanced chroot than to full virtualization like Qemu or VMware, both because they do not emulate hardware and because containers share the same operating system as the host. Therefore containers are better compared to Solaris zones or BSD jails.

LXC is very lightweight, so it's most common application is to have a container for each service. This means you can save up on a lot of space and other resources, since nothing is allocated unless needed. However, that doesn't mean it's the only way to use it.  For example, Docker is a service built on LXC, for packaging and deploying complete apps.

LXc can be used for running GUI apps, or even X itself. This Unix & Linux answer has a guide. Essentially:

Install any requisite drivers on both host and container systems.
Make the device nodes available to the container, creating them via mknod if necessary.
Configure them (the OP did it manually, since udev isn't available in the container).
Start X on an unused VT.

However, in your case, where you want things to Just Work and don't mind using the VM for everything X, you can use KVM with libvirt. Check the official Server Guide.


By default, if a username is not specified, ssh (and related tools) will try to user your current username. The DD-WRT router, however, has only the root user, and this is where the SSH key is stored.

You need to instead run ssh root@192.168.1.1 to log in into your router.


How do I create a self-signed SSL certificate?

Ubuntu, even the 'minimal' flavour, comes with the ssl-cert package pre-installed, which means you don't need to do anything.

The files you're looking for are already on your system:

/etc/ssl/certs/ssl-cert-snakeoil.pem
/etc/ssl/private/ssl-cert-snakeoil.key

Advanced:

If for some reason you need to create a fresh certificate, you can run

sudo make-ssl-cert generate-default-snakeoil --force-overwrite

If you want to change the expiration date of you certificate, you can manipulate the make-ssl-cert script at /usr/sbin/make-ssl-cert. Around like 124 there's a line similar to this:

openssl req -config $TMPFILE -new -x509 -nodes \

Where you can change the expiration date by adding the -days argument:

openssl req -config $TMPFILE -new -days 365 -x509 -nodes \

More options can be found in the manual page of req.


Grub2 package failed installed on dual boot with windows 10

As I found in this post  GRUB2 Installation failed Dual boot ubuntu with windows 8.

Follow these steps
*Make sure secure boot is off
Start your laptop and keep pressing F10.
*BIOS will open. Now go to System Confirguration and then select boot options.
NOW select Secure boot and choose disable.
*Press escape and save and exit . REMEMBER TO SAVE AND EXIT OTHERWISE IT WILL NOT SAVE YOUR SETTINGS(you can find save and exit in the exit tab)
*Turning Off fast boot
now open your windows , go to control panel(Those who dont know how to - press start+Q type control panel and open it[windows 8 + method]).
*Now go to power options or search for power options if you are not able to see by pressing ctrl+F and typing power options
*Now open power options and in the right side you'll see 'Choose what the power button do'. Click this .
Now you will see 'Change settings that are currently unavailable '. Click this and scroll down
*You will see an option of fast boot . make sure that it's not checked.

Now save changes and exit

Now install Ubuntu the usual way...


ubuntu 16.04 confuse wireless card with ethernet

I thin you have this bug appearing on your system. Please read the description. It's affecting many Ubuntu users:

https://bugs.launchpad.net/ubuntu/xenial/+source/network-manager/+bug/1574347

Cheers


why jamendo is off stores of music player banshee and rhythmbox and how can i add jamendo to the stores?

Jamendo was removed from the upstream code, for Rhythmbox. Banshee does not ship a Magnatune store, as far as I know. To get Jamendo in Banshee, it looks like you can install the banshee-extension-jamendo package. I have not tried it though.

http://git.gnome.org/browse/rhythmbox/commit/?id=5db81f7c22d7d558663e2f6db3bdcb871d3d482f is the commit where Jamendo was removed from Rhythmbox. It looks like it wasn't technically feasible to keep around for now. I suspect because of the way Jamendo works as a store, it had to be implemented in a certain way, and that it isn't good from a technical/performance perspective, as it required downloading the entire catalog all the time. Its removal from Rhythmbox has nothing to do with Ubuntu One though. It was a purely upstream decision.


different launchers for Firefox versions

You can't specify the WMClass for Firefox 29, but you can for newer versions using the --class=Something command line argument.

So I adjusted the firefox trunk launcher like so:

[Desktop Entry]
Encoding=UTF-8
Type=Application
Name=Firefox Trunk
Icon=firefox.png
Exec=/usr/local/firefox-trunk/firefox %u -P Trunk --no-remote --class=FirefoxTrunk
StartupNotify=false
StartupWMClass=FirefoxTrunk

... and added StartupWMClass=Firefox for the Firefox 29 launcher, and now when I run xprop WM_CLASS...

$ xprop WM_CLASS                         # then click on FF 29
WM_CLASS(STRING) = "Navigator", "Firefox"
$ xprop WM_CLASS                         # then click on FF trunk
WM_CLASS(STRING) = "Navigator", "FirefoxTrunk"

Yay!

So now the launchers each work as expected, with their windows attached to the correct launcher, and no new phantom launcher gets created.


How to open files with unknown extension

I couldn't find anything specific about how to launch these Microsoft 'ClickOnce' files with PlayOnLinux. However, there is a Wine FAQ on it which suggests:

wine start whatever.application

PlayOnLinux uses wine so you should already have it installed. You may also need to use winetricks to install the version of .NET required by the application.

Winetricks Installation

cd "${HOME}/Downloads"
wget https://raw.githubusercontent.com/Winetricks/winetricks/master/src/winetricks
chmod +x winetricks

Installing .NET (4.0) with winetricks example

bash winetricks dotnet40

Edit: Finding out about unknown extensions

If in future you have a file with an unknown extension (or no extension at all) the file command can tell you about the file:

file a-jpeg-file-with-wrong-ext.txt

Outputs:

a-jpeg-file-with-wrong-ext.txt: JPEG image data, JFIF standard 1.01 etc

Additionally, you can look up extensions online. A good database for this is fileinfo.com.


Trying to uninstall Bitwig from my computer with the .deb package missing

Make sure you type it in as

sudo apt-get remove bitwig-studio

It will uninstall after that. You're only giving it part of the name to look for. That's why it can't find it.


Is it possible to have Orca speak the laptop battery status?

Here is an option. It does not use Orca -- I'm sorry, but I don't know how to use it.

Install the acpitools package. From command line (opened terminal window or ALT-F2), run:
sudo apt-get install acpitools
Create a program that will read out the battery status. Edit a text file called "batstat.sh" and save it in your home directory. Here is the file contents:

#!/bin/sh

spd-say "`acpitool | grep Battery | sed 's/.*[^0-9]\([0-9]\+\)\.[0-9]\+%.*/Remaining battery \1 percent/'`"

(that's two lines, the empty line between them doesn't count)
Make this file an exectuable. Again, from command line

chmod a+x batstat.sh

Test that the tools is working by running

./batstat.sh

from your command line.
Move it to another location.

sudo mv batstat.sh /usr/local/bin/

With an editor, create a file called "Batstat.desktop". The contents should be as follows:

[Desktop Entry]
Name=Battery status
Comment=
Exec=/usr/local/bin/batstat.sh
Icon=icon name
Terminal=false
Type=Application
StartupNotify=true

Open the folder in which you have saved "Batstat.desktop" in nautilus, drag it to the Unity toolbar.
By clicking on the unity toolbar, you will hear what battery time remains.

If this kind of solution is fine for you, but you need something more complex, just respond, and I will update my answer.


Where are crontab -e settings saved in ubuntu 16.04? Working, but can't find

In /var/spool/cron/crontabs.

You can find this by looking up the manpage for crontab by:

man crontab


Screen dims when looking at Dark Screens

After a little bit of research, I found a way to disable this action.

I have an HP 3105m on xubuntu, with the fglrx driver.

In my situation, this only occurs when I go from being plugged in, to unplugging my power. Since it was triggered by a power change, I immediately thought acpi was the cause of action.

Now, I don't know how different it will be with other drivers, but I might as well put what I did out there.

What triggers this is an event file in /etc/acpi/events/, in my case there was a file named fglrx-ac-aticonfig pointing to a script in /etc/acpi/ named fglrx-powermode.sh

EDIT: You could aso just comment out everything in /etc/acpi/events/fglrx-ac-aticonfig, That may work better.

In this file I commented out the lines executing /usr/bin/aticonfig with su

In my case the line looks like this:

su $user -c "/usr/bin/aticonfig --set-powerstate=$powermode --effective=now" &>/dev/null

All I did was comment that out, and the problem disapeared.

I'm not sure what it looks like with intel drivers, but it may still apply on your end.

EDIT:

Turns out that doesn't work.

If you're using fglrx, open amdcccle, go under "PowerPlay" and uncheck "Enable VariBright"


Is there such thing as a heat / power management?

This Program doesn't run in the background, but Jupiter Power management can scale your CPU, which should cool it down when it's too hot, hope this helps, it runs as a panel applet.

sudo add-apt-repository ppa:webupd8team/jupiter
sudo apt-get update
sudo apt-get install jupiter

if by chance you have an EEEPC (i doubt that) sudo apt-get install jupiter-support-eee


how to start VNC service remotely without first logging into Ubuntu 12.04 locally

I also had this issue. I tried user1689961's answer but got a connection refused. When I added the -allow <ip address of client> option, it worked.

The full command:

sudo x11vnc -safer -localhost -once -nopw -auth /var/run/lightdm/root/:0 -display :0 -allow <ip address>


You have conflict between this two libpython3.6-stdlib versions: 3.6.6-1~18.04, 3.6.6-1+xenial1. Try to install libpython3.6-stdlib. It's possible that apt will offer you to remove this version: 3.6.6-1+xenial1


Easy method of switching from Openvpn-Acess Server to Community Edition?

This is an old question, but I would like to answer it in case someone else is trying to do the same thing. To switch from OpenVPN-AS to the community edition and keep the same configuration, the server.crt, server.key, dh.pem, and ca.crt used on the Access Server need to be referenced in the new community edition server.conf file. Since by default, A.S. uses pam authentication for dual authentication, the new C.E. server must be configured this way as well. These lines need to be added to the server.conf:

plugin /usr/share/openvpn/plugin/lib/openvpn-auth-pam.so openvpn

Then the file /etc/pam.d/openvpn needs to be created, with these lines:

auth       sufficient   /lib/security/pam_radius_auth.so debug
account    sufficient    /lib/security/pam_radius_auth.so

Any other options defined in the A.S. generated config need to be referenced in the server.conf file as well (such as port number, proto, com-lzo, cipher, etc). Since I could not figure out where or how those files are stored when using access server, I opted to simply uninstall openvpn-as, and start over.

In conclusion, I decided to rebuild the configuration from scratch because it was easier, and also made sense to learn how to properly deploy a community edition openvpn server myself. I opted to not use PAM authentication, and rather use easyrsa3 to set up the server and client certificates, using a separate machine as the certificate authority for enhanced security. I also used the tls auth option (incorporating a 'ta.key', as an HMAC firewall to help prevent denial of service attacks).

My advice to anyone wanting to switch from the Access Server to the Community Edition is to start from scratch, uninstall A.S. and install the openvpn package, generate new certificates and keys, and most importantly, use a separate machine to sign the certificate requests.


Do a default installation using the entire 128 GB SSD. You can then use that drive for your daily work, and use the large 1 TB HDD for storage (e.g. pictures, movies, archives, etc.)
After installation of Ubuntu, you can setup the large 1 TB HDD using the included utility "Disks". The large 1 TB HDD should be formatted in the ext4 file format. By default, it will only be mounted when you click on its icon in the File manager. You can also opt to have it automatically mounted during startup. That can be set up with the Disks utility.


Your approach is correct,${#arr[@]} will give you the number of elements in the array (in this case, 3):

$ var_names='test1 tutorial2 test3w'
$ arr=($var_names)
$ echo ${#arr[@]}
3

You can also return the string lengths of the individual array elements using ${#arr[0]}, ${#arr[1]} and so on:

$ echo "${#arr[0]}"
5
$ echo "${#arr[1]}"
9
$ echo "${#arr[2]}"
6

The reason that $arr returns only the first element test1 is that it is equivalent to ${arr[0]}; if you want to return the whole array, you can use either ${arr[@]} or ${arr[*]}:

echo "${arr[@]}"
test1 tutorial2 test3w

See the Arrays section of man bash


You just need to add some quotation marks:

xterm -e "sudo apt-get update && sudo apt-get upgrade && sudo apt autoremove"

I also like to add sudo apt clean to my update oneliner and I set an alias in my ~/.bash_aliases file to execute the line with just the command update:

alias update='sudo apt update && sudo apt upgrade && sudo apt autoremove && sudo apt clean'

Or if you want a separate xterm:

alias update='xterm -e "sudo apt update && sudo apt upgrade && sudo apt autoremove && sudo apt clean"'

If you want your xterm to stay open after executing the commands, add ;bash to the command chain's end or add the option -hold before -e.


How to change desktop font color in xfce when using nautilus to show desktop

I got this working. Xubuntu 12.04, transition from Thunar to Nautilus, including default desktop management.

Once you've transitioned to Nautilus to manage your desktop, the text of desktop icons will be grey or some other unreadable colour. To change this:

Go to settings manager -> Appearance.
Under the style tab, which opens by default, see which theme you are using.
In your terminal, type: gksu nautilus /usr/share/themes
Browse to the folder of the theme you are using.
I was using Greybird. In that theme's folder, I went to the gtk-3.0 folder, and pasted the code from the following post to the bottom of the gtk-widgets.css file (source: http://ubuntuforums.org):

/*######## MODIFY DESKTOP FONT #########*/

/* desktop mode */
.nautilus-desktop.nautilus-canvas-item {
    color: #ffffff;
 /*color: white;*/
    text-shadow: 1 1 alpha (#000000, 0.8);
}

.nautilus-desktop.nautilus-canvas-item:active {
    background-image: none;
    background-color: alpha (@bg_color, 0.84);
    border-radius: 4;

    color: #ffffff;
}

.nautilus-desktop.nautilus-canvas-item:selected {
    background-image: none;
    background-color: alpha (@selected_bg_color, 0.84);
    border-radius: 4;

    color: @selected_fg_color;
}

.nautilus-desktop.nautilus-canvas-item:active,
.nautilus-desktop.nautilus-canvas-item:prelight,
.nautilus-desktop.nautilus-canvas-item:selected {
    text-shadow: none;
}

Close your text editor.
Close your root nautilus folder
Terminal (Ctrl+Alt+T): killall nautilus
Alt+F2: nautilus

That should do it!

Side note: change the new nautilus desktop background with dconf editor, at the following location in the tree: org -> gnome -> desktop -> background


Ubuntu 18.04.4 Wireless is gone completely. Currently on a wired connection

Updated as requested. That command returns nothing.

For reasons that I don't understand, the package that you installed to update your wireless drivers doesn't actually cover your exact and relatively common device. I suspect it is a bug.

Please revert the change you made. If you installed the driver from the Additional Drivers utility, then do:

sudo apt purge backport-iwlwifi-dkms

Reboot and your wireless should be working.

If you installed some other way, from git or compiling from source, please telll us how and we'll further assist.

EDIT: Please do:

cd backport-iwlwifi/
sudo make uninstall

Reboot.

If you installed this driver to overcome another issue, tell us about it and we'll assist.


Restore individual folders from full backup using duplicity/deja

The old method of restoring via right-click in Nautilus should work. The only time that option is not available in the context menu is when you are in a folder that is not included in the current backup settings. On your fresh install, make sure you have configured the backup exactly like on the old install.

A little technical background: Nautilus doesn't check what backups currently exist on the system. In fact, doing so would take a long time and cannot be done everytime you right-click on a folder. It only checks which folders are scheduled for backup and shows the option whenever you are in such a folder.

(Also, it seems like it doesn't check for exclusion filters – even in excluded folders, the restore option is available if the parent folder is included. Deja-dup won't restore anything though if you actually click it.)

If you still don't succeed on your machine for whatever reason, you can use this method instead:

deja-dup --restore [File1 File2 ...]

will restore individual files if you know their names.

deja-dup --restore-missing [Directory]

will restore the files that have been deleted from the given directory.

Note that both of these commands will bring up the Deja-Dup Restore GUI, which will also allow you to specify the backup source. You don't need to do the whole task on the command line.


MythTV gives an error when selecting "Watch TV"

You will need to post some backend logs (/var/log/mythtv/mythbackend.log). Likely this is due to you not going through steps 2,3, and 4 in mythtv-setup.


Problem with LVM over mdadm with NTFS. Is it possible?

You probably have not created a filesystem on the partitions; see man mkfs.ntfs. Just setting the partition type is not enough.


Run in terminal:

gsettings set org.gnome.nautilus.preferences executable-text-activation 'display'

Or you can launch dconf-editor and navigate to /org/gnome/nautilus/preferences, then select the executable-text-activation key. Here is its description:

  What to do with executable text files when they are activated (single
  or double clicked). Possible values are "launch" to launch them as
  programs, "ask" to ask what to do via a dialog, and "display" to
  display them as text files.


Ubuntu 14.04.3 has frozen. What logs to check after reboot?

You should check /var/log/syslog . It logs everything with respect to time. You can check the logs for the time when your system froze .

For details you might want to see this
.


Open an Application without an icon showing up in Unity (Ubuntu 12.4)

Launcher is a bit of a misnomer for the bar on the left in Unity. Any running application with an open window, will show on the launcher, regardless of what the .desktop file says.


yea ,use gnome-disks,format disk in gpt,create main part leavin 2mb free space.run fdisk (usb) ,type n and then enters,then w.run parted (usb), set 2 bios_grub on (if it's 2.It's about 2mb partition  ).then deploy linux.then run this stuff `

mount (usbpart1) (mount dir)
grub-mkconfig -o (...)/boot/grub/grub.cfg
grub-install --boot-directory=(...)/boot/ (usb)


"Call from" qc 35 Bose ubuntu 18.04 even though no call

This was solved by changing the profile in the settings for bluetooth. The problems occur when the profile is HSP/HFP. You should use A2DP Sink


The system is running in low-graphics mode when Installing

At the grub boot selection screen tap e and place the kernel parameter nomodeset on the line that begins with linux the order of these parameters doesn't really matter, but to avoid confusion I would place it between the quiet and splash parameters preserving the spaces between the parameters.

Having edited the boot command line you can now hit F10 to boot with the modified parameters, then follow the directions to install Ubuntu, and remove the installation media when prompted. You should now be able to boot into your newly installed system normally.

If anything about this answer is unclear, drop me a comment and I'll do my best to clarify.


In the Grub menu, select Previous Linux Versions to go to your list of previous kernels. The selection is just below the latest kernel in recovery mode.

To remove the kernel, execute in the Terminal

sudo apt-get remove 2.6.38.11.26

then

sudo update-grub

I hope this helps.


Ubuntu 18.04 not detecting full RAM size

This line:

[    0.000000] Memory: 6929972K/7238032K available (12300K kernel code, 2472K rwdata, 4248K rodata, 2408K init, 2416K bss, 308060K reserved, 0K cma-reserved)

indicates that BIOS is giving the kernel 7238032K of memory. The rest of the memory is being used by the BIOS:

8,388,608 K Total - 7,238,032 K Kernel = 1,150,576 K reserved by BIOS.

That is an unusually large amount for BIOS to reserve. You would have to look at your BIOS settings to perhaps try to figure out why.


How to run a web url script in a terminal

It seems you have & somewhere in your url, hence the shell is sending the process to background.

To solve this, quote the url.

For example, if you use :

curl https://www.example.com/myscript/foo&bar

the shell will treat the url as https://www.example.com/myscript/foo and & after that will cause the curl https://www.example.com/myscript/foo process to go background. Note that bar after & is missing too.

So you need to quote the url :

curl 'https://www.example.com/myscript/foo&bar'
curl "https://www.example.com/myscript/foo&bar"

Also note that ? has a special meaning to shell (means any single character), so when you have shell meta-characters anywhere in your argument you should quote the argument (unless intentional).


How do shell scripts in /etc/profiled.d/ affect /etc/profile

Looking at /etc/profile, we see:

if [ -d /etc/profile.d ]; then
  for i in /etc/profile.d/*.sh; do
    if [ -r $i ]; then
      . $i
    fi
  done
  unset i
fi

That is, scripts called *.sh in /etc/profile.d will be executed whenever /etc/profile is executed.

When is /etc/profile executed? man bash (or Online man page shows:

When  bash  is  invoked  as  an  interactive  login shell, or as a non-
interactive shell with the --login option, it first reads and  executes
commands  from  the  file  /etc/profile,  if  that  file exists.  After
reading that file, it looks  for  ~/.bash_profile,  ~/.bash_login,  and
~/.profile,  in  that  order,  and reads and executes commands from the
first one that exists and is readable.  The --noprofile option  may  be
used when the shell is started to inhibit this behavior.

and:

 If  bash  is  invoked  with  the name sh, it tries to mimic the startup
 behavior of historical versions of sh as  closely  as  possible,  while
 conforming  to  the  POSIX  standard  as  well.   When  invoked  as  an
 interactive login shell, or a non-interactive shell  with  the  --login
 option,   it   first   attempts  to  read  and  execute  commands  from
 /etc/profile and ~/.profile, in that order.  The --noprofile option may
 be used to inhibit this behavior.

All this means that every time you invoke /etc/profile (The above shows when bash does it, does your ~/.bashrc?) the scripts will be run.

On your second (and subsequent) invocations of /etc/profile, shutdown sees that another shutdown is active, and complains.

You could put shutdown -c before shutdown -P 23:00 in your script to replace the old shutdown with the new shutdown.


network manager icon on 16.04 is not showing

Below commands help me (this command disable/enable network-manager applet) :

$ nm-applet --disable
$ nm-applet --enable


Is it possible to use bluetooth speakers with Ubuntu 16.04?

Works great here in 16.04.3 It auto pairs & auto connects to my bluetooth speaker when I turn it on. The only caveat is that if I set up & connect in another ubuntu install when returning to previous install I have to set up in bluetooth settings again.

If only using speaker in 1 ubuntu install then no problems..

Basically.

Make sure pulseaudio is fully updated, current is 1:8.0-0ubuntu3.7
Don't have blueman installed, just using gnome-bluetooth

Set up speaker

Open Bluetooth settings, add the speaker (pair).If speaker was already in Bluetooth settings then remove & add fresh.

After pairing close settings, then open indicator, click on your speaker > connect. (On is exposed, not covered) To check then open sound settings, make sure bluetooth speaker is selected as output device. Test for sound.

To get autoconnect in 16.04

Open /etc/pulse/default.pa in root text editor, ex. sudo -H gedit /etc/pulse/default.pa

Under the .ifexists module-bluetooth-discover.so section add this new section, save.

.ifexists module-switch-on-connect.so
load-module module-switch-on-connect
.endif

reboot

If still having issues with auto connecting or connection breaks right after connecting read my post here. Note I no longer need the startup script anymore with the updated pulse & it only worked if speaker was on before logging in. https://ubuntuforums.org/showthread.php?t=2365083&p=13661744&viewfull=1#post13661744


I upgraded my card by powering down, swapping cards and then booting up and installing the new drivers from the command line. It looks like the GTX 950 was added in the 352.41 version of the drivers, so you will need at minimum that version. (nvidia-352 should work but I haven't tested.)

Install the new drivers by adding the official PPA and following these instructions:

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

The install process was straightforward and I have not had any problems with the driver/card.


Can't enable nvidia profile on nvidia-prime, ubuntu 15.04

Yes, this affects me as well. I have tried drivers 340 and 346, I have installed bumblebee, primus and bumblebee-nvidia, I edited the bumblebee config file (etc/bumblebee/bumblebee.conf) replacing nvidia-current with nvidia-346 or nvidia-340 and editing Driver to Driver=nvidia and no positive results. But someone said that this worked for him, maybe it wasn’t an hybrid card.

I found out it is possible to run it if after doing the above procedure, run application with: vblank_mode=0 optirun -b primus, maybe just optirun in some cases.


Need help for installing vulkan on Ubuntu 18.04

Undo whatever you just did, and just follow the manual:
https://help.ubuntu.com/community/BinaryDriverHowto/Nvidia#Installation
So, only install nvidia-somenumber, and that should be it.

You do not need SDK, unless you are a developer
mesa-vulkan-drivers is for AMD and Intel GPUs, so do not install that unless you have those
do not screw your env unless you are pretty sure what you are doing
if for some reason driver does not pull it in itself, you can install vulkan-tools, which will give you vulkaninfo and vkcube test apps


Nautilus Raw thumbnail (ufraw) - Bug found in archives

I had the same problem and kept trying until I found a solution.

1) Install from debian repo (older version of liblensfun):

liblensfun-data_0.2.8-2_all.deb
liblensfun0 (0.2.8-2)

2) Delete symbolic link /usr/lib/x86_64-linux-gnu/liblensfun.so.1 -> /usr/lib/x86_64-linux-gnu/liblensfun.so.0.3.2

sudo rm /usr/lib/x86_64-linux-gnu/liblensfun.so.1

3) Create new symbolic link to older version

sudo ln -s /usr/lib/liblensfun.so.0.2.8 /usr/lib/x86_64-linux-gnu/liblensfun.so.1

** UPDATE **
This solution broke Rawtherapee (which I use to edit the raw files).

New solution: liblensfun1_0.3.2-3 (1 minor version back) does the trick


VLC doesn't fill the screen in full-screen mode

It can be related to VLC aspect ratio.

When you play your video press f key then a key. The first one will make it full screen and the second one will change aspect ratio to 16:9.

If that is not the correct answer then please add more details of your problem.


How can I change the size of the Dash font?

Unfortunately, the current answer is: you cannot (unless you figure out and modify the source code).

In this answer, I list the ways which do not work, to save future reader-modders the time and trouble of trying and failing.

A. Existing bug report

Bug #756845 ("Unity dash search unable to change font/icon size") refers to this exact problem, as shown by part of the screenshot for the bug report:

The bug has been confirmed and labeled "low importance", with no comments by developers or anyone else on a workaround or when it will be resolved.

B. Changing fonts or the scaling factor in gnome-tweak-tool

This does not work either:

Changing the scaling factor appears to change everything BUT the dash/hud font size (that's a 1920x1080 screenshot below -- compare the terminal font size!):

C. Editing dash-widgets.json in the Unity Theme folder

You can find a file called dash-widgets.json in /usr/share/unity/5/ and /usr/share/unity/themes. This contains a bunch of CSS-like settings that may give you hope, such as:

  "preview-heading-small"  : {
"main-title-size"    : 23.0,

but changing them does not work. (the Dash font is approximately size 22)

D. Changing the Launcher Icon size Doesn't Affect It

Since the dash text field is almost exactly the height of the Ubuntu launcher icon, you might think decreasing the icon size would change the height of the text field and make its font smaller.

Changing the icon size is easy from the Unity Plugin in CompizConfig Settings Manager (ccsm), or from its MyUnity frontend:

But decreasing to the minimum, 32, doesn't change the dash font size!


Ubuntu 15.04 has very poor PPTP connectivity

Seems it could be mitigated by updating the pptp client to version 1.8.0. Instructions is listed as follows.

Download the latest client from PPTP client repository on Sourceforge
Extract that archive file and read a file called INSTALL. (For convenience I have listed its contents here)

  Installation Instructions - Detailed

  install PPP, and make sure it is working.

  On most distributions, use the package called ppp or pppd.

  If your PPTP server requires MPPE, make sure the pppd program
     has been built with MPPE and MS-CHAP support.  PPP from
     version 2.4.2 onwards has this support.  PPP may require
     kernel support for MPPE, which may require patching your
     kernel.
  verify that the pppd program is in the /usr/sbin/ directory.

On some distributions, it is in /usr/bin, or somewhere else.
If it isn't in the default directory, edit the Makefile, and
change the PPPD variable to point at the pppd program.

You may even want to run a separate pppd program with MPPE
support.

  compile

Type 'make'.  This should generate the 'pptp' executable.

  install binaries

  Type 'make install' to have the program and the manual page
  installed.


How to install Deepin Desktop Environment in Ubuntu 16.04?

https://launchpad.net/~leaeasy/+archive/ubuntu/dde

Says, in part:

Important Issue:
Q: Can dde on Ubuntu 16.04?
A: Sorry, the dde depends on qt version above than 5.6.
     If you want to install dde, please upgrade to 17.04 or above.


authentication error ubuntu software center 16.04 LTS

I got the same thing, just go into the terminal and run sudo su. Then, enter the software center with software-center. This worked for me on 14.04, and it should work for you, good luck, fellow Chromebook Linux user!


*/150 * * * 0,6 gnome-session-quit

Works fine.


This is a known bug with gnome-shell, but has been fixed in 15.04. You can use tracker-search or tracker-needle instead in the mean time.


You'll need to give more information to get a better answer.

You need to identify what you're trying to do. Are you installing Ubuntu alongside of Windows or other operating systems? If so, your objective is slightly more difficult. If you're just trying to replace your whole hard drive with Ubuntu, then you're on the easy track.

/dev/sda is usually the device file of the main hard drive on your computer.

Your disk can have one or more partitions. /dev/sda1 is the first partition on your hard drive. You're most likely going to want to install the root of your Ubuntu installation on /dev/sda1 if you're using the whole hard drive for Ubuntu. Otherwise you'll want to partition your drive up and install Ubuntu on a different partition.

ntfs is a type of filesystem often used by Windows.

Please give more information regarding your question or it will be marked as too vague.


How does one 'vote' for a release codename?

There is a survey on OMG Ubuntu (http://www.omgubuntu.co.uk/2014/10/ten-years-ubuntu-user-survey) but it is unofficial.  Mark Shuttleworth actually picks the code name himself, based on which attributes he thinks the release should embody.  Although he may consider input, there is actually no "voting" for the release name.


extending win partition in win7 or shrinking ubuntu while in ubuntu?

Boot Ubuntu live-disk and click on try Ubuntu option on startup.
Open gparted from dash.Make sure that all the partitions are unmounted.
Shrink dev/sda7 partition to get 10 Gb unallocated space.
Now the unallocated space will comes under /dev/sda7 partition.Now you have to getout of the unallocated space from the extended partition.To do this,
Right-click on the dev/sda3 and select Move/Resize.Now you can be able to reduce it's space.
Now the free space will comes out of the extended partition.
Right-click on the dev/sda3 and select Resize/Move option.Click and move the bar to extreme right, so that the unallocated space will comes just above to the dev/sda3 partition.
Now you can be able to resize /dev/sda2 partition.

See here for more details.


Getting 10.04 LTS interface on Ubuntu 11.04

To revert to the classic interface used in Ubuntu 10.04 LTS, you can choose the "Ubuntu Classic" session when you log in.  At the login screen, double-click on your name.  At that point, the bottom of the screen will have several options you can set before you log in.  Where it says "Ubuntu", click there and choose "Ubuntu Classic" instead.  It should remember this setting each time you log in until you change it again in the future.


Can't reinstall Ubuntu from LiveCD (16.04) after deleting it

I solved it with f1 during the boot and reinstalled Ubuntu while rebuilding the partition table.


Create a new file on your desktop and name it whatever you want.

In Ubuntu 18.10 and earlier drag the new file into the terminal to show its full path. Here is an example of the result of dragging a file named myFile from the desktop into the terminal.

 $ '/home/username/Desktop/myFile'
myFile is located in /home/username/Desktop/ where username is replaced by your username. If the above example was the result you got on your computer, then cd Desktop would have worked, otherwise the result dragging myFile into the terminal will show the location of the Desktop directory.


PATH is not getting exported by default in Ubuntu 12.04

It works for me:

reut@HP-EliteBook-8470p:~$ which lesspipe
/usr/bin/lesspipe

How to fix anyway?

Short answer - make sure the following line is in /etc/environment:

PATH="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/your/specific/folder"

Notice the last folder is a specific folder you want to add. The folders you mentioned are in fact part of the PATH by default (unless you changed it).

If you want to extend your PATH:

# extend perserving old path (locations are prioritized by order)
PATH=$PATH:/some/folder
export PATH

You can add this code in  ~/.bashrc to have it available to you specifically.

you can also add /some/folder to the line I mentioned in /etc/environment to have it available to everyone, so you'd end up with:

PATH="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/some/folder"


Deploying a Spring Boot web application as a service to Ubuntu

Ubuntu uses systemd. You can find a post of someone asking a similar question in this post

Another approach would be to use some orchestration tool like kubernetes or docker swarm to create services that can rerun the service even if it fails at some point of time.

An example with docker:

In your Dockerfile

FROM java:8-jre-alpine
COPY /location/of/your/jar/xyz.jar /where/you/want/it/stored/xyz.jar
CMD ["/bin/sh", "-c", "java -jar /where/you/want/it/stored/xyz.jar"]

Build your docker image

docker build \
   -t my-app:0.0.1-snapshot \ #specify a name for your image
   /dockerfile/location/      # the location of your dockerfile

To test

docker run -it \           # -it represents interactive tty
   -p 80:8080 \            # -p binds 8080 (the container port) to 80 (host port)
   --restart=always \      # --restart=always run the service unless stopped by user
   --name my-app \         # --name the name of your container
   my-app:0.0.1-snapshot   # the image you built with the build command

Test with postman or browser to your localhost.
You can try restarting your computer and the application should still run.
In production, you'd use swarm or kubernetes.

To use swarm, you create a docker-compose.yml file and you should store your images on a registry - a built image must exist on the managing node if it's not pushed to a registry.

In your docker-compose.yml

version: '3.5'
services:
  my-app:
    image: my-app:0.0.1-snapshot
    ports:
      - "80:8080"
    restart: always

In terminal:

docker swarm init
docker stack deploy my-app --compose-file ./docker-compose.yml

You should check out their documentation for other matters like persistence and security.


Controlling where an opened window appears

Install compizconfig-settings-manager.

From ccsm go to the place windows plugin.

You can either choose to have windows open in the centre of the screen (use placement mode in the general tab),

or you can have them open in specific positions by using the fixed placement tab:


How to set shortcuts in Ubuntu (Gnome) for functionalities which are not available in Settings Keyboard Shortcuts?

Install dconf-editor, navigate to /org/gnome/desktop/wm/keybindings/, and enjoy a wealth of possible actions to which you can assign your custom keyboard shortcuts. You can change the settings using dconf-editor or change the setting with a gsettings command. For example,
gsettings set org.gnome.desktop.wm.keybindings move-to-workspace-5 "['<Super>F5']"

will setup Super+F5 for moving to the fifth workspace. Use reset and leave out the argument ("['<Super>F5']") to reset the setting to factory default. Only a limited number of shortcut bindings are exposed in "Settings" - "Keyboard Shortcuts".


What's the meaning of bash script lines beginning with #$?

The lines beginning with #$ are options for qsub, a command used to submit a job to the SGE cluster, a scheduling system explained in this readme:

Using the BIMSB (soon to be called MAX) cluster environment is similar to using unix/linux environments for your job submission (e.g running your scripts or other software). The difference is that you need to specify needed resources beforehand. The cluster is controlled by a SGE (Sun Grid Engine Software) that organizes the queues and resources. This sort of scheduling system is necessary when limited computational resources are shared by many. And, it would be useful if you are running alignments for multiple samples and want to distribute those tasks (jobs) across multiple machines or CPUs, or when running statistical simulations that needs to run on multiple CPUs for a long time. For these cases and many more alike, you just need to submit your job script (which is a shell script) and Sun Grid Engine will take care of the rest (as long as there is no error in your script).
SGE will do the "job scheduling". That means you can submit all your jobs and SGE will queue them and run them when resources you requested becomes available. SGE will also achieve "load balancing" where the jobs will be distributed so that specific nodes do not get overloaded. In addition, SGE will allow you to do "job monitoring and accounting" which will be useful when you want to check if your job is running ,and if it failed it will help you understand what went wrong.

The syntax of the qsub command is explained on its manpage, your script uses the following options:

-l h_rt=<hh:mm:ss> – specify the maximum run time (hours, minutes and seconds)
-V – pass all environment variables to the job
-N <jobname> – specify the name of the job. This you will see when you use qstat, to check status of your jobs.
-j y[es]|n[o] – specifies whether or not the standard error stream  of the job is merged into the standard output stream

As How to submit a job using qsub explains one can set the qsub options directly in the script in lines that begin with #$. This an alternative to passing them with the qsub command on the command-line.


Replace the pattern a certain number of times per line, using sed

GNU sed, Yes, has that option to replace all g occuraces of a patten or from Xth occurrence to all after that gX,  but you can use these two extensions to achieve what you want to replace only first Y occuraces like below to replace first 3 occuraces of PATTERN.

sed -E 's/PATTERN/TEMP-REPLACE/g4; s/PATTERN/REPLACE/g; s/TEMP-REPLACE/PATYERN/g' infile.txt

Also as non-GNU solution, you can have Y sed parts to replace Y times of a PATTERN like below,

sed -E -e 's/PATTERN/REPLACE/' -e 's/PATTERN/REPLACE/' -e 's/PATTERN/REPLACE/'

Updated answer as question revised

You could use awk for it with defining two control flag for START and END and do like below:

awk -v START=1 -v END=5 '{for (i=START;i<=END;i++) gsub(/PATTERN/,"****",$i)}1' infile.txt

please note that by default awk considering to read file delimited by  tab or space, if yours is different or you want to tell awk it's for example is ,, you can set with its -F',' option.


You can not pipe the text you want to display into zenity --notification this way.

From man zenity:

   Notification options

   --text=STRING
          Set the notification text

   --listen
          Listen  for  commands  on  stdin.  Commands  include  'message',
          'tooltip', 'icon', and 'visible' separated by a colon. For exam‐
          ple,  'message:  Hello  world',  'visible:  false',  or   'icon:
          /path/to/icon'.  The  icon  command  also accepts the four stock
          icon: 'error', 'info', 'question', and 'warning'

So you could either somehow convert the data you pipe into the format message: COMMAND-OUTPUT and use the --listen option, or simpler, directly pass the message in the command as argument option behind --text=:

zenity --notification --text="$(shutdown -P +60 2>&1)"

The command of which you want to capture the output is enclosed in $( ), which is called Bash "command substitution". It runs the inner command and behaves as if that one's output (standard output stream only) would have been entered in place of it.

Also note the 2>&1 which redirects the standard error stream of the inner command to the standard output stream. This is needed because shutdown prints its info message to the standard error stream which is not captured by the Bash command substitution.


Why does Gwibber keep asking to authorize my Facebook account, but doesn't add the account after authorizing?

This is a known bug. There's a workaround, though. Be careful replacing code and good luck!


Install Alfa AWUS036NHA driver on Ubuntu 18.04 LTS

You need to install the RTL8188FU driver, the steps are:

git clone https://github.com/kelebek333/rtl8188fu.git
cd rtl8188fu
make
sudo make install

In case you encounter the following error:

$ sudo make install
install -p -m 644 .ko  /lib/modules/4.15.0-20-generic/kernel/drivers/net/wireless/
install: cannot stat '.ko': No such file or directory
Makefile:481: recipe for target 'install' failed
make: *** [install] Error 1

Do:

sudo apt install libelf-dev

Then:

cd rtl8188fu
make clean
cd
sudo dkms add ./rtl8188fu
sudo dkms install rtl8188fu/1.0

Then reboot and test the adapter.


They updated the snap packages and it seems Wickr Me does not run on Ubuntu 20.04 anymore. Last time switching back to beta channel did work, because the actual version on beta channel was 5.47.25. It seems that was the last version  which worked with Ubuntu 20.04. But now the beta channel got updated to version 5.76.13 which does not run on Ubuntu 20.04. So changing the release channel does not help anymore and currently all version which are installable via snap do not run on this distribution.
If you try to run wickrme from terminal it gives error message: Illegal instruction (core dumped)


Ubuntu 13.10 and 12.04 ask for password when unlocking

The lock/Unlock screen was designed to prevent someone else in the room, your friend, or family member, to get into your computer when you go and get a cup of coffee. This does not do anything about someone hacking into your computer using the Internet.

See the picture below:

If you want to turn the screen off when you are not around, change Never to something else. This will save energy, but will not add any security.

If you don't want your spouse to read your emails, you lock screen. To unlock screen you will need password. (Don't tell the password to your spouse.) If you don't have a spouse then set Lock to OFF as shown in the image above.

Hope this helps


If you're using a Radeon HD5xxx or newer, then I would suggest you use the open driver. AMD has people working full time on it and in my experience, it's already much faster and more stable than the proprietary one. So without knowing why you installed the proprietary driver in the first place, I would say the answer is to uninstall Catalyst.

Only AMD can fix problems with the proprietary drivers. Noone else.


Will watch for any additions, but for the time being the only method i found of doing this was installing 10.04 LTS (maverick).


Unable to unblock Ideapad z570 broadcom wireless adapter

The module bcma is a dependency of brcmsmac; I suggest you undo its blacklist. Also, I'd try blacklisting ideapad-laptop and not acer-wmi.


How to repair:

Enter recovery mode:
Press & hold shift key while bios starts (See more)

Select Menu network
Will enable the network

Select Menu root
Will open a root shell

Type some commands:

dpkg-reconfigure sudo
apt install sudo
reboot

This should repair sudo


Unity needs gdm to be able to start, so you need to start it:

service start gdm

or the good old:

/etc/init.d/gdm start

If you don't want to have to enter your credentials again you can either activate autologin in Gdm  or switch the default session to classic in gdm. After login off and stopping gdm, startx should work again.


How can I highlight C syntax in CUDA (.cu) files in nano?

Change this line (or similar, probably first non-comment line) in /usr/share/nano/c.nanorc

syntax "c" "\.(c(c|pp|xx)?|C)$" "\.(h(h|pp|xx)?|H)$" "\.ii?$"

to:

syntax "c" "\.(c(c|pp|u|xx)?|C)$" "\.(h(h|pp|xx)?|H)$" "\.ii?$"

If you don't have permission to change /usr/share/nano/c.nanorc:

copy it to your home, for example to ~/.c.nanorc
change syntax as shown above
change include in ~/.nanorc:

from:

include "usr/share/nano/c.nanorc"

to:

include "~/.c.nanorc"


What media servers support DLNA sharing?

I would recommend XBMC for your need.

For further details on how to install and use it. Please refer the previous askubuntu question.

This link will help you on how to install XMBC

Hope this helps


How to run a .bin file without using terminal

step1: copy the file to the Desktop or home folder(for convenience )
step2: right click on the file and chose properties ,and check the allow the file to execute button
step3:rename the file to filename.bin to filename
step4:Double click on the program
The above method wont work if the program needs root permission


Date and time for log files different to `date`, `timezone` etc

I suffered from the same problem and issued the commands dpkg-reconfigure tzdata and service rsyslog restart in succession on a 14.04 server. I then initiated an ssh connection whilst viewing auth.log with

tail -f /var/log/auth.log

Log messages from then on were correct, as may be seen in this snippet

Aug 16 09:02:40 myhost sshd[11913]: Accepted publickey ...
Aug 16 09:02:40 myhost sshd[11913]: pam_unix(sshd:session): opened ...
Aug 16 09:02:43 myhost sshd[11913]: pam_unix(sshd:session): closed ...
Aug 16 15:04:45 myhost sshd[12019]: Accepted publickey ....
Aug 16 15:04:45 myhost sshd[12019]: pam_unix(sshd:session): opened ...
Aug 16 15:05:11 myhost sshd[12019]: pam_unix(sshd:session): closed ...

I see you did a tail of auth.log.1 (an older log file). Making the timezone changes does not modify an existing log file retroactively. Was that the problem perhaps?


Ubuntu 16.04 - Having both KDE and Gnome

You can install both KDE and Gnome on the same system and keep lightdm. However from personal experience I found that installing the kubuntu-desktop package with gnome did not work as there were package conflicts and when I installed the plasma-desktop it installed and ran but it was not seamless and a few of the KDE features did not work. Hope this helps


How to recover the corrupted flash drive ?

The problem was done with merely few steps after trying a lot. Just open DISK and the usb drive was shown in it. I tried to format from here and my drive was mounted after few seconds :) Thanks all for your help.


ubuntu bootloader doesn't detect window 8

Try using super-grub

http://www.supergrubdisk.org/

Just install it on a usb and boot it (you can use YUMI or Universal Usb Installer), it will automatically find the O.S. installed.

Once it boots do:

Detect Any OS

and that's all
Hope it helped


What causes a directory to have permissions of d?????????, an owner of ?, a group of ?, and a time of ?, but a name?

what you describe is the result of a corrupted file.  The most likely cause is a crash during file writing.  In a typical linux installation, you need to dismount the file system and run fsck.  For example:

umount /dev/sda5
fsck.ext4 /dev/sda5

If it's an xfs file system,

xfs_repair /dev/sda5

Since you are running ubuntu/bash on windows, you might need to run chkdsk in windows to clear up the error.  if the error disappeared without intervention, maybe windows detected the issue and repaired it during a boot.


Touchpad left-click and single tap not working

Hmm, I would try shutting down and pulling the battery out for a few seconds and put it back in and start it up.
EDIT:

It looks like its a bug that is ASUS specific :( > Elantech Touchpad


There's no reason for the file to exist just because you installed emacs. The file contains user customization, so it didn't exist until you started the program and did some customization. Creating the file in an editor is perfectly fine.


Dual graphic (between graphic card and mainboard graphic)

At least in my case, no you can't.

First, using multiple different vendor graphics cards, while theoretically possible, is riddled with problems.
This part has been asked before, but I can't seem to put my hands on the question

Second, most of the time on-board graphics is disabled when the motherboard detects a secondary video card inserted.

Third, even if it were possible you would run in to similar issues to what vga_switcheroo, bumblebee, and ironhide all try to address.

While they are a little different since they address hybrid graphics cards, I would imagine there would be similar problems.


Unable to execute python script directly

I advise against changing the PATH variable for just a single script. If you're not going to use it in any other environment, you can simply change your script's shebang to point to python2.7 directly:

#!/usr/bin/python2.7

This way you can execute it with the full path, e.g.:

/usr/local/bin/peepdf_0.3/peepdf.py -i test.pdf

If you however want to execute it conveniently with just a single keyword, I'd define an alias in the ~/.bash_aliases file, let's take “peepdf”:

alias peepdf='/usr/bin/python2.7 /usr/local/bin/peepdf_0.3/peepdf.py'

With that you're able to run your script simply with e.g.:

peepdf -i test.pdf


I know the link I provide isn't for ubuntu but it works the same way.
You need edit the gnome-shell-theme.gresource.xml file and set the background there, then recompile it with glib-compile-resources.


It's ages that I don't use Windows, but someone in the Italian community asked the same exact question some time ago and in the end he was very happy with Format Junkie.

Unfortunately, it needs an external PPA. To add it and install the program you can use the following terminal commands

sudo add-apt-repository ppa:noobslab/apps
sudo apt-get update
sudo apt-get install formatjunkie


How can I snap a window in a corner with 18.04?

Tested and works in Ubuntu 18.04 and Ubuntu 20.04:
As you've found out, Ubuntu 18 has moved away from the Unity desktop manager which I had finally gotten used to, to Gnome desktop, which is much different. Compared to Unity, Gnome Desktop's configuration settings are all wacky. You'll need to install Gnome shell extensions.
I recommend using the Put Windows GNOME extension, like @heynnema says.
However, hknust likes the  ShellTile one, so you can try it out too.
Note that Gnome Shell extensions change how your desktop works, but you configure them through your browser, which seems kind of weird at first. Your browser, in this particular case and for this particular application, acts as a front-end messaging service to communicate with the back-end configuration settings which apparently are running as a background program on your PC.
How to install the "Put Windows" GNOME shell extension to enable window tiling in Ubuntu 18:
Steps (in part borrowed from hknust's answer):

Enable shell extensions (the back-end service) on your PC, and the Gnome shell extension in Chrome (the front-end configuration panel):
sudo apt install gnome-shell-extensions chrome-gnome-shell

In your Chrome browser, open https://extensions.gnome.org/.

Search for "put windows", as shown below, and click on it.

Install it by clicking the button to the far right of it. You may see a message saying you need to install "GNOME Shell integration" from the Chrome Web store. If you do, go here and install that into Chrome: https://chrome.google.com/webstore/detail/gnome-shell-integration/gphhapmejobijbbhgpjhcjognlahblep.

Now you'll get that little foot-icon extension in the top-right of your Chrome: . Click it, then click the "Installed extensions" tab at the top of the page that loads. You'll now see the "Put Windows" extension installed as shown here. Note that you may need to refresh the page to get it to show the screwdriver and wrench icon once you've installed it: .

Configure it by clicking the little screwdriver and wrench icon under the yellow arrow I made in the image above. Notice the default keyboard shortcuts are set like so:  Super (ie: Windows key) + Keypad 7, for instance, will tile the selected window to the top-left corner of your screen.

If you have an ultrabook or smaller laptop that does not have a Numpad/Keypad, then I recommend using the following settings instead (where the "Super" key is your "Windows" key):
If you use the laptop/ultrabook settings that I recommend just above, note that the Alt + Super + S keyboard shortcut will interfere with Ubuntu's default Screen Reader keyboard shortcut, which is the same. So, go to Ubuntu's Settings --> Devices --> Keyboard --> click the search icon (magnifying glass) at the top-right side of the window, search for "Alt+Super+S", you'll see the option for "Turn screen reader on or off", which is assigned to this shortcut sequence. Click it, then press the Backspace key to delete this shortcut, then click the green "Set" button that appears. Done! The shortcut for this option now shows "Disabled" in bold instead of "Alt+Super+S" like it used to show. Here's what that looks like:
Once you've done this, the Put Windows Alt + Super + S keyboard shortcut to center or maximize the window may be temporarily broken, so you need to toggle this extension off and then back on again to refresh and fix it. Go back to Chrome (or whatever internet browser you used to configure this) --> click the black footprint ("Open GNOME Shell extensions website" button: ) in the top-right of your browser --> Find your "Put Windows" entry as shown here: , and click the "ON" slider to toggle this extension off, then click it again to toggle it back on. Now try your Put Windows window snap shortcuts and it should all be working! Alt + Super + S and the other shortcuts should all work fine now.
You will now no longer have a conflict between this keyboard shortcut and the Put Windows shortcut to "Move to center/maximize".

Remember, even though it seems odd at first, the browser plugins and tools are simply the front-end GUI interface to configure your computer's GNOME desktop settings. This fact alone can seem confusing at first.

BUG NOTE/WEIRD BEHAVIOR: If you are trying to snap a window to a corner but its size is off, first snap it to the center (Alt + Super + S), then snap it to the corner (ex: Alt + Super + Q to move to upper-left corner), and it will now be the right size to allow 4 windows to be seen at once--one in each corner, as snapping it to the center first also gets it to be the right size--ie: exactly 1/4 of the screen area.
Done!
Related:

Bug fix you might need to restart Gnome in the future in case Put Windows ever quits working: GNOME Shell Extension Put Windows stopped working


Screen goes blank when setting up Google account in GNOME control center. (Ubuntu 17.04)

This bug is listed here: https://bugs.launchpad.net/ubuntu/+source/webkit2gtk/+bug/1687019?comments=all

See the various comments there on how to fix the problem. In summary:

start terminal
sudo apt update
sudo apt upgrade

It should be fixed right away. No reboot required.


The trickier part of a backup: The restoration

It is an excellent idea to use rsync to backup your personal data. These are data that are unique and cannot be replaced. Once lost, these are lost forever.
I would not bother trying to backup system files along. Once an operating system is lost, a better version of it is easily downloaded and installed in less than an hour.
If you insist on having a backup of system configuration, by which you can easily restore older configurations, then I recommend you install and use Timeshift. Timeshift is a utility specifically designed to create system snapshots. Under the hood, it can work in rsync mode, where it used rsync, or can work in btrfs mode if you use that file system. It is very good quality software designed for system snapshots (not for personal data), and a testimony of that can be that it is installed in the Linux Mint distribution by default.
So in the end, use rsync as normal user to backup your user data on external media like a USB drive. A good backup of your user data is mandatory and indispensable. Optionally, use a tool like Timeshift to backup system configuration. In rsync mode, these backups can also be on an external volume.


Can ubuntu 20.4 run on single core 2.2 GHz 64bit processor?

Yeah, im sure it works, i have a Intel Celeron with 1.1Ghz (Dual core). It freezes, on swapping due to bad configuration, but im sure that's my fault.


I installed EdrawMax and can't uninstall it from the terminal

After the installation, the program is installed on
/otp/EdrawMax-9-64 (depends of program version - in this case v9 64bit)
The "Official program uninstallation" is actualy deleting of the folders:

Deleting the Main Program:

rm -rf /opt/EdrawMax-9-64/

Deleting the rest of the program (icons, Launcher, etc.)

rm -f /usr/share/icons/edrawmax.png
rm -f /usr/share/applications/edrawmax.desktop
rm -f /usr/share/mime/packages/edrawmax.xml
rm -f /usr/share/icons/gnome/scalable/mimetypes/eddx.svg
rm -f /usr/local/bin/edrawmax

Edit:
Deleting files from home dir

sudo rm -r $HOME/Edraw


How to use inotify to auto refresh a png file when the png file changed

I have the same problem while experimenting with imagemagick. So I have written a simple image viewer which updates itself (using inotify): https://gitlab.com/dknof/siv For compiling you need the gtkmm dev libraries, version 3. Just call siv with the image(s). You can scale them with the keys 1 - 0 and the mouse wheel.


When you use squid as a http(s) proxy, you are doing MTM.
Sites with HSTS will not accept traffic between the proxy and the browsers to run over http.
If you want to use a https proxy, you need to create your own certificate and import it in the browser.
You can try this: https://elatov.github.io/2019/01/using-squid-to-proxy-ssl-sites/


Using npm to install file to /usr/local/bin

To see npm current prefix value in effect, run:

npm get prefix

As described in install-and-configure-nodejs-and-npm-properly-on-ubuntu

You can set npm prefix e.g.:

$  npm config set prefix /usr/local

Note: Official NPM docs specify that:

  When in global mode, executables are linked into {prefix}/bin on Unix

Hence, your npm prefix shouldn't include the /bin suffix

In order to install in a system folder (e.g. /usr/local/bin) you should execute npm as root using sudo, e.g.:

sudo npm install -g price-feeder


How to find and up-to-date software on my machine?

Download from: here the latest version of VirtualBox

Open Terminal in the downloaded file location and type:

To Install deb package:

sudo dpkg -i DEB_PACKAGE

where DEB_PACKAGE is the downloaded file

To remove deb package:

sudo dpkg -r PACKAGE_NAME

where PACKAGE_NAME is the correct package you want to remove.
Recommended to press TAB for autocomplete the full package name.

Sometimes you'll need to install missing to complete the installation, it can be done by:

sudo apt-get install -f

To see where is app you can use:

whereis appname

About whereis:

whereis locates source/binary and manuals sections for specified files.

or

which appname

About which:

which returns the pathnames of the files which would be executed in the current environment


Display image in fullscreen from command line in Ubuntu

Ubuntu by default comes with Eye of Gnome , with has -f or --fullscreen flag

Run the command as such eog --fullscreen myImage.png or eog -f myImage.png


How do I selectively upgrade Ubuntu to a specific point-release version?

You need to boot that version manually after downloading the necessary files from website. The update feature only supports getting to the latest version (which is also accepted as the best)


Screen turns black during dual boot Ubuntu installation

Initially, you will have to edit 'Install Ubuntu' for installing Ubuntu and then after the installation, you will edit grub (this will make changes permanent) as follows:
For Installation

Highlight 'Install Ubuntu' and press e.

Add the following text after quite splash and before ---:
ivrs_ioapic[32]=00:14.0 spec_store_bypass_disable=prctl

Delete ---

Press F12 to boot.

After Installation
To make the changes permanent, do the following. (Else you will have to perform the above steps each time you log in.)

In the Terminal, enter sudo nano /etc/default/grub

Append "quiet splash" to look like
"quiet splash ivrs_ioapic[32]=00:14.0 spec_store_bypass_disable=prctl"

Press ctrl+x to exit and Y to save the edits.

Execute sudo update-grub in the terminal.

When you restart next time, you shouldn't get the blank screens anymore.
Sources: https://www.reddit.com/r/Ubuntu/comments/9tdut2/im_trying_to_install_ubuntu_1804_on_my_lenovo/
https://medium.com/@jthegedus/ubuntu-18-04-lts-on-lenovo-thinkpad-e485-15e1d601473f


Is there any way to have several open terminal windows with different themes?

To open a new terminal with a different profile, use File->Open Terminal->Profile name.

You can edit the different profiles under Edit->Profiles..., or just edit the current profile with Edit->Profile Preferences.


How to make a persistent USB/SD from Mac

UNetbootin
Has a MacOS version, it can be downloaded here:
https://unetbootin.github.io/
Off the shelf persistence is limited to 4GB but it is easy to create a persistent partition of any size, see: Can I convert a live Ubuntu USB to one with persistent memory?


I just downloaded Libreoffice's DEBS from their official website, reinstall it, and somehow my problem solved. I still don't know though, why the installation from their official PPA behave that way.


Bluetooth bluez and blueman-applet Xubuntu 18.04

I ran into this problem and fixed it by reinstalling all my bluetooth applications.

sudo apt install --reinstall blueman*
sudo apt install --reinstall bluez*
sudo /etc/init.d/bluetooth restart

It seems the audio and bluetooth systems on ubuntu/linux break every week or two for me, and very often the only solution involves reinstalling everything from scratch and restarting.


No sound from front headphone jack on MSI TRX40 Pro WiFi

I managed to fix this with the following combination of ALSA, PulseAudio, and kernel patches:

ALSA: https://github.com/alsa-project/alsa-ucm-conf/pull/25 . I didn't rebuild the package, I just dropped the two new files in /usr/share/alsa/ucm2/USB-Audio/.
PulseAudio: https://gitlab.freedesktop.org/pulseaudio/pulseaudio/-/merge_requests/292 . I used apt-get source pulseaudio to get the source, applied the patch, and then used dpkg-source --commit to tell dpkg about the patch info. Then I rebuilt the pulseaudio packages with dpkg-buildpackage -rfakeroot and installed them.
The topic/usb-trx40 branch of this kernel tree: https://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound.git/log/?h=topic/usb-trx40 . This is slightly tricky because I'm using ZFS, so I had to apply the ZFS patches as well as documented here: https://forum.level1techs.com/t/building-custom-kernel-with-zfs-built-in/117464

I'm not completely certain that all three are necessary, but they are sufficient. Sound works now!


You need to quote the arguments to test to stop them 'breaking' on whitespace, i.e. if

$ var1="sudo apt-get install postfix"

then

$ if test $var1 = sudo apt-get install postfix; then echo "Match"; fi
bash: test: too many arguments

but

$ if test "$var1" = "sudo apt-get install postfix"; then echo "Match"; fi
Match

The same applies if you use the [ ... ] test construct

if [ "$var1" = "sudo apt-get install postfix" ]; then echo "Match"; fi

As an aside, it's recommended not to use all-caps for your variable names - all-caps are generally reserved for system variables.


Booting problem? Need to fsck every time in order to make everything work!

If runing fsck solve your problem , you can change the frequency of the automatic check , you can perform the automatic file system check through fsck on every boot:

 sudo tune2fs -c 1 /dev/sdXY

Change sdXY with your root partition


Using an external monitor on a lubuntu laptop?

Question 1 : Your Nvidia GPU driver should work by default but it will be using the open source driver by Nouveau. Typically on the Nvidia cards the open source drivers are not as fast as the proprietary drivers provided by Nvidia. However, the drivers by Nouveau tend to be more stable.

Try the open source ones first if you don't get the performance you like then try the Nvidia proprietary ones. To change GPU drivers go into the additional drivers settings.

Question 2 : This just takes some tweaking in the settings. There is usually power settings in every distro that will let you set things like this. For instance set the close lid setting to “do nothing” when you close it. The external should work just fine.


Ubuntu 14.04 boot up, login, but once in desktop I can't do anything

I booted up in recovery mode (root terminal) and removed the packages I'd installed:

apt remove cmake kdelibs5-dev libqt4-dev libpoppler-qt4-dev

Did the trick.


Just saw this... might be up your alley:

https://github.com/vitaut/captain-nemo

Looks like there is the Shift Delete already configured in this example (referring to this image: https://raw.github.com/vitaut/captain-nemo/master/img/keyboard-shortcuts-dialog.png).

Good luck.


Upgraded to Ubuntu 15.10 Wily and get QNativeImage: Unable to attach shared memory segment

Have you tried the workaround described here?
https://bbs.archlinux.org/viewtopic.php?id=200167

I had the similar problems with Skype, VLC and Double Commander on my laptop with Ubuntu 15.04 and the hack cured them all.

Just add the following line

QT_GRAPHICSSYSTEM=native

to the file

/etc/environment


First Install package Control via these instructions take note that the instructions need to happen inside sublime and not in the console.

Then menu system-> Install Package -> Color Pick and see what's there.


Ubuntu stores variables in the wrong order

I don't think I understand why there's a problem but I think GCC might have something to do with it... Here's a comparison between GCC and Clang.

$ gcc -o test.gcc test.c
$ ./test.gcc
Size a: 4
size b: 4
Address a: 0x7fffeef71488
Address b: 0x7fffeef7148c

$ clang++ -o test.clang test.c
$ ./test.clang
Size a: 4
size b: 4
Address a: 0x7fff664573f8
Address b: 0x7fff664573f4

The compiler and its version you're using at uni may be the variable element here.


Command to show turtlebot3 packages have been installed

try

dpkg -l | grep ros-kinetic

then you may want to show details for specific package like this

dpkg -L <packagename>


How To Create A Live BackUp and Do An In Place Restore

If you create backup using tar, it will be enough to copy all your files, however the problem will arise when you try to extract that archive into a live system. Some binaries or libraries may not update because they will be in use by the system, and you will end up in a mess.
You should get some support from your hosting provider (for the new VPS). Usually they have some features for that case, for instance my hosting provider allows me to switch my VPS to "repair mode", in that mode new VPS is created with basic Linux software, and my VPS's disk is mounted there, allowing me to change it however I want and then leave repair mode. Or maybe you can just send your tar archive to the support team, asking them to extract it to your VPS when it's offline.