Errors in dmesg - Test WP failed, assume Write Enabled

I'm having the same issue on the official 12.04 LTS relase i also believe it is causing the system to be less responsive. According to some sources it's harmless. (i can apparently only post 2 links)

The following thinks this is error output from an onboard card reader:

https://bbs.archlinux.org/viewtopic.php?pid=1059099

It's confirmed to be an upstream issue in

https://bugs.launchpad.net/ubuntu/+source/linux/+bug/987993

Run lsusb and find the offending device

nathan@Ham-Bone:~$ lsusb

Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 003 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 004 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 005 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 006 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 007 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 008 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 001 Device 002: ID 0bda:0158 Realtek Semiconductor Corp. USB 2.0 multicard reader

In my case it's the Realtek multicard reader which a quick check of

$ dmesg | grep realtek
[    4.716068] usbcore: registered new interface driver ums-realtek
$ lsmod | grep realtek
ums_realtek            17920  0

reveals a module ums-realtek

$sudo rmmod ums_realtek

Fixes the problem in a reversible way for me. That is

$sudo modprobe ums_realtek

enables the card reader again. I haven't tested if it works since I never use it.

If this doesn't work there are some other ways to disable usb devices by unbinding them in the /sys/ directory.


Horrible battery life with Ubuntu 14.04 on ThinkPad

Try using the tool powertop. Helped me doubling the battery life on my E530.


Well, this has something to do with the user. I say this because if you log in Guest or create a new account, you'll find that the icons appear. I do not why this happens, but I suggest you move all your stuff to a new user and delete your old account. That's what I did, seems like it's one of the most practical solutions.


Installing Dual Boot Ubuntu 64 bit 13.10 along side Windows 8.1 Enterprise

Exit the ubuntu installer and install gparted partition editor by running the below commands on the terminal,

sudo apt-get update
sudo apt-get install gparted && sudo gparted

Then resize the windows partition and then create an ext4 partition for installing Ubuntu.
After that,run the ubuntu installer,and choose something else option.Then install ubuntu on the created ext4 partition.If it asks to create a swap partition,then create a swap partition of size equal to double the size of RAM(applicable for only low sized RAM's).


Is there anyway to move (swap) an icon pinned to the taskbar by keyboard?

There is no built-in possibility to move the pinned icons through keystrokes. The pinned icons (and their order) are defined in a dconf setting, e.g.

org.gnome.shell favorite-apps ['firefox.desktop', 'org.gnome.Nautilus.desktop', 'zim.desktop', 'org.gnome.Terminal.desktop', 'libreoffice-writer.desktop', 'libreoffice-calc.desktop', 'libreoffice-impress.desktop', 'org.gnome.gedit.desktop']

Thus, at least, the pinned icons and/or their order could be changed in a script by changing the setting:

gsetting set org.gnome.shell favorite-apps ['...']

It would probably not be that easy to implement a keyboard interface that would allow to select an icon and move it with keystrokes. There is no way that I know to select the Ubuntu dash with the keyboard. In Standard Gnome Shell, however, without Ubuntu Dock active, one can reach the Dash in the overview with: Super Ctrl+Alt+Tab.


How and why should I specify mtrr_gran_size/mtrr_chunk_size?

MTRR stands for Memory Type range registers which is a new way of
partitioning and managing memory resources in your system. This
feature had been placed in processors due to memory sizes becoming
bigger and bigger. There had to be a way that the memory could be
allocated addressed and used more effectively.
A main feature of the MTRR is to map locations of PCI or AGP
components in your system so that software, drivers could access them
quickly and efficiently.

(from Gentoo Wiki)
After reading Solving linux MTRR problems it appears that the error you see is reported when mtrr sanitizer is unable to choose from several options of memory layout. It should print a list of possible options next to the error message. To make the message to go away, you need to specify something like
enable_mtrr_cleanup mtrr_spare_reg_nr=1 mtrr_gran_size=32M mtrr_chunk_size=128M

in the kernal boot parameters (where the actual values come from one of the options proposed by the sanitizer).
The author of the article claims that

Now 24MiB of ram are gone, but my 3d workloads, which are basically
webgl content and the hidden flight simulator inside google earth, run
both at significant better framerates.

which makes me very interested... need to check dmesg on all my machines.


How do I disable the default window restore animation?

It can be disabled using the CompizConfig Settings Manager, but that also disables the minimization effect.

Go to the Animations plugin,
Open the Minimize Animation tab,
Double-click the Zoom entry in the Animation Selection list, and
Select None.

That's it, restore effect should be disabled.


How to upload a qmake-based package to my PPA?

After a bit of searching: (okay, a lot of searching)

This page seems to contain some information on setting up a Debian package that uses qmake.


ubuntu android sdk location can not be at the filesystem root

Click on Edit just beside the Android SDK Location box

You'd be redirected to a window with a couple of components to install, and a new location automatically selected for where to install them. Go ahead and install, and take note of your new SDK location


Ubuntu 12.04.3 Graphics Issues: Broken Pipes, Reinstalled Xorg and Bumblebee

I answered this before but apparently it was to wordy and got "deleted" for not answering so here is my next try at this without the explainations for why.

I have the exact same Haswell and 750M nvidia so I know exactly what you mean. For me, I was able to get the system working again by uninstalling the nvidia-prime dependency.

sudo apt-get purge nvidia-prime

That got most of the things working again just restarting lightdm after uninstalling that. Not explaining why this time since that is apparently off topic. What did not still work after that was the "optimus" system but I expect it to get worked out soonish by others.

If you cannot wait and want the optimus system working ASAP, then uninstall everything "raring" related and install "quantas" related equivalents instead. Then install the bumblebee/primus systems like normal and you are good. Remember both the xserver and the kernel must be of the quantas variety not raring in order to get optimus working again right now. If you still have a raring kernel installed, it will default to that kernel on bootup so manually switch to the quantas kernel or remove the raring kernel completely.


I set "PubkeyAuthentication" to no and I am locked out

I think the best option here is to reboot the system into single user mode and make configuration changes from there.  (i.e. update the ssh configuration or set a password)  Check here for details on getting into single user mode: How do I boot into single-user mode from GRUB?


How to disable next key (keycode 117) which is constantly being triggered?

keycode 117 is pagedown key. Check if it's pressed. or try

xmodmap -e "keycode 117=NoSymbol"


Getting window maximization to work properly with Tint2

Open tint2 conf file:

gedit ~/.config/tint2/tint2rc

Find the #Panel section and ensure to set these variables as follow:

panel_dock = 0
panel_layer = bottom

Find the # Panel Authoide section and set:

strut_policy = follow_size

Find more useful hints here


Ubuntu 18.04 cursor larger after suspend resume

Try Alt + F2 then type r and Enter to reload GNOME Shell.


Ubuntu 18.04 with Apogee ONE audio interface, Sound and PulseAudio show the ONEv2 Analog Stereo flashing each second but cannot select it

The ApogeeONE driver is included in the company's softwre which is only written for W10 and Mac. It is NOT USB 2.0 compliant, so it does not work with Linux (unless someone writes a driver). So the post by someone in 2009 saying that it worked does not apply at this time.
Audio interfaces that are USB 2.0 compliant, such as Scarlett, Komplete6 and others, are USB 2.0 compliant and work when plugged in since the drivers are included in the Linux kernels. This site lists some audio devices that definitely work with Linux. (It could use updating.) https://wiki.linuxaudio.org/wiki/hardware_support


Why can MySQL not use /run/shm as tmpdir?

There is a dependency from apparmor security settings

You have to change configs to get tmpdir into RAM

File: /etc/mysql/my.cnf

tmpdir = /run/shm/mysql

File: /etc/apparmor.d/usr.sbin.mysqld
add a line alongside with other filesystem rules

/run/shm/mysql/* rw,

And shell steps to GTD

service apparmor restart
mkdir /run/shm/mysql
chown mysql:mysql /run/shm/mysql
chmod -R 777 /run/shm/mysql
service mysql restart

Mysql daemon should be up and running after all.

PS. Don't forget to add a line to /etc/rc.local for getting system working after reboot

mkdir /run/shm/mysql && chown mysql:mysql /run/shm/mysql && chmod -R 777 /run/shm/mysql


How can I prevent a third party software to gather data from my device?

What you are trying to do is to "sandbox" your application. You can do your researchs again with this keyword

You may want to check that question

Several options are presented, the easiest probably is Firejail and the second one docker


Need help to salvage data from Ubuntu server

If you're uncomfortable at the command line and wish to use GUI tools you could make a bootable thumb drive using just about any of the available live linux distros. Once booted you can use the file manager of the distro you chose to mount the internal and external drives then move the data between them.


export SWT_GTK3=0 on terminal, does it effect your system?

If the only thing you did was running export SWT_GTK3=0 then you did nothing permanent. What the command does is to set an environment variable SWT_GTK3 and set its value to 0 for that terminal session only. If you close the terminal window and open a new one it will be gone or reset.

If you want to unset it in the current terminal window you can also do: unset env SWT_GTK3.

If you want to see the current value of an env. variable: echo $SWT_GTK3 or for example to see your current PATH variable echo $PATH.


How to set up a network for home network

Test this:

sudo su
apt-get update
apt-get dist-upgrade
apt-get install samba samba-common samba-common-bin smbclient system-config-samba
apt-get clean
system-config-samba

Click on Preferences on the menu bar to open Server Setting window.
In the Server settings window, on  the basic tab, you can setup or rename the samba Workgroup and short Description for the workgroup.
Make sure that the name of samba Workgroup did not match any Workgroups or any Domains on your network.
Then on the Security tab you can setup the configuration for:
Authentication Mode:
Authentication Server:
Kerberos Realm:
Encrypt Passwords:
Guest Account:

For the Authentication Mode, you can setup your samba server to:
ADS - Samba server act as a domain member in Active Directory domain.
Domain - Samba server relies for primary or backup domain controller to passes the username and password.
Server - Samba server verify the username and password on another samba sever, if fail then the samba server use the User authentication mode.
Share - Samba sever only prompt for username and password when only user connect to specific share directory.
User - User authentication mode (default setting), the samba user must provide username and password on a per samba server basis
To enable user to access the files and printer share on the Samba Server you need to create user for Samba Server.  The step by step procedure below show how to add user to Samba Server using the graphical Samba Server Configuration tool,
To create samba user go to Preferences tab, then click on Samba Users to open the Samba Users window.
On the Samba Users window, click Add User button to open the Create New Samba User window.
Provide the necessary information for samba user on Create New Samba User window.
Unix Username: Click and choose the username from local Fedora Core system user, you can add user to the list by using 'adduser' command.
Windows Username:  Provide the windows username for the samba user; make note that the Windows Username will be map with the Unix Username when user log in to the samba server.  Note: You can use same username for both Unix Username: and Windows Username:.
Samba Password:  Provide the password for samba user in order enable them to login to samba server.  Note: The password don't have to match the local Fedora Core user password neither the password from local user on Windows system.
Confirm Samba Password:  Retype the password.
Then click OK button to proceed.
The screenshot of list of Samba Users available on the system. Click OK button after done with the samba user creation.


Extend home partition /home with additional HDD

Boot up from a live gParted and resize /home as described in the manual. From the manual:

Select a partition. See the section called “Selecting a Partition”.
Choose: Partition → Resize/Move. The application displays the Resize/Move /path-to-partition dialog.
Adjust the size of the partition. See the section called “Specifying Partition Size and Location”.
-Specify the alignment of the partition. See the section called “Specifying Partition Alignment”.
Click Resize/Move. The application displays the resize/move partition operation in the Pending Operations pane.
Examine the operation that was added to the Pending Operations pane.
 If the operation involves a move step, then consider the following:

A move step might take a long time to complete.
If the partition is an operating system boot partition, then a move step might cause the operating system to fail to boot.

If you are not prepared to wait or to fix potential operating system boot problems, then you might want to undo the operation. See the section called “Undoing Last Operation”.


How can you make the system print dialogue default in chrome?

You could use Control+Shift+P.

Chrome also supports a --disable-print-preview mode where the dialogue is completely removed.

google-chrome --disable-print-preview

To persist this, you'll need to hack around the existing launcher. The easiest way is with alacarte (the menu editor). Just add the flag before the %U so you're left with something like this as the command:

/usr/bin/google-chrome --disable-print-preview %U


Could not open lock file /var/lib/dpkg/lock-frontend - open (2: No such file or directory)

You most likely have another process that is using the package manager.

Close any other terminal instances and any GUI package managers. If you are not sure which process/program currently has those privileges, a reboot should fix the problem.


Recovering broken or deleted NTFS partitions

Disclaimer: I provided an answer to similar questions here and here. This is a summary of those two answers. Moreover, I am the developer of RecuperaBit.

Your NTFS partition is broken. In order to restore the data, you need to make a copy of it (ideally) and then use a NTFS reconstruction software to restore its contents.

Clone the drive

You really should clone the drive in a file on an external disk, unless it is so big you can't find another drive than can contain it.

If you are really sure the NTFS partition coincides with /dev/sdb2, then use ddrescue to copy only that one:

sudo ddrescue /dev/sdb2 /media/user/External/copy.img /media/user/External/status.log

If you are not sure, it is much better to clone the entire /dev/sdb drive. This will take more space, of course:

sudo ddrescue /dev/sdb /media/user/External/copy.img /media/user/External/status.log

The status.log file is not mandatory, but it is needed if you want to pause the process and resume later on.

Analyze and reconstruct the file system

If the file system is only slightly broken, you may have luck with testdisk:

testdisk /media/External/copy.img

Follow the step-by-step procedure in the CLI and you will be able to list the contents of the partition with the P key, assuming it is almost intact.

If the damage is more serious, you need something else. You can recover (possibly severely) damaged NTFS partitions using RecuperaBit. RecuperaBit attempts to reconstruct file system structures and recover
files. RecuperaBit attempts reconstruction of the directory structure regardless of:

missing partition table
unknown partition boundaries
partially-overwritten metadata
quick format

Currently, it does not require installation, you need to download the archive from GitHub and extract it in a directory of your choice.

After that, create a directory for the output and start the program with:

mkdir /media/user/External/recovered_files
cd [full path of recuperabit]
pypy main.py /media/user/External/copy.img -o /media/user/External/recovered_files -s /media/user/External/savefile.save

You might also use python, however pypy is faster. The scanning process will take quite some time. When it's done, type recoverable and find the id of your partition. If it is e.g. 2, type:

restore 2 5
restore 2 -1

5 means the Root directory and -1 means the Lost Files directory.

For additional details, explanations and caveats, see the two links at the top of this post.


The Chatzilla URL is chrome://chatzilla/content/chatzilla.xul. To open just that window and not the browser itself, use the -chrome option. -no-remote is added to prevent an existing session being used.

The command for just starting Chatzilla becomes:

firefox -no-remote -chrome chrome://chatzilla/content/chatzilla.xul

If you've multiple profiles, specify the profile name too or the path to the profile:

firefox -no-remote -P default -chrome chrome://chatzilla/content/chatzilla.xul
firefox -no-remote -profile /path/to/profile -chrome chrome://chatzilla/content/chatzilla.xul

This may work for other add-ons as well, just look in the [profilefolder]/extensions/*/chrome.manifest file for possible URLs.

Mozilla knowledgebase - Command line arguments


You need to install the Qt 4 development packages. Particularly, that program is in the libqt4-dev package.


The addons doesn't seem to work. Why dont you try using Skype instead, if you are looking for an alternative solution.

https://www.skype.com/en/get-skype/skype-for-linux/

It runs quite well for me.


How to unlock screen in Ubuntu 14.04 LTS using command line

A workaround would be to use an alternative screensaver, for example the classic linux xscreensaver.
this can be deactivated from command line with

xscreensaver-command -deactivate


I installed the Oracle JDK manually but cannot use it

First, you should move the Sun JDK from /usr/lib/jvm to /usr/local/lib/jvm. Let the package manager manage all files in /usr, except under /usr/local, which is for files not managed by the package manager.

java and other executables need to be in your path. This happens automatically when you install a Java environment from Ubuntu, but Ubuntu does not ship the Oracle JRE (for legal reasons). So you need to one of two things:

Add the /usr/local/lib/jvm/bin directory to your path.
Create symbolic links from /usr/local/lib/jvm/bin to /usr/local/bin, by typing the following commands in a terminal:

cd /usr/local/bin
ln -s ../lib/jvm/bin/* .

I recommend the second method, that's what /usr/local/bin is for.


How can I duplicate my desktop and show it side-by-side on a single screen?

Most of what I am writing will be coming from this SU question, or more specifically this answer.

Since you are using raspbian, you're going to have to use FakeXRandr, which has FakeXinerama built-in:

Download FakeXRandr from this link. Unzip the archive,cd ~/Downloads/fakexrandr-master and run

sudo make
sudo make install
sudo apt-get install xorg-dev libglu1-mesa-dev build-essential python3-gi python-gi-dev python-gi-cairo

You will now have the tool fakexrandr-manage available to use. Launch that from terminal, and you will see the following GUI to configure your monitor setup:


Automatically reduce brightness on battery in Ubuntu 15.10?

Intro

The script bellow uses dbus and on_ac_power shell script (which comes by default with Ubuntu) to poll for presence of an ac adapter and sets brightness according to values set in $HOME/.auto-backlightrc file.

Installation

Installation using git through terminal:

Run sudo apt-get install git to install git
Run mkdir $HOME/bin. Skip this step if $HOME/bin exists already
cd $HOME/bin
Run git clone https://github.com/SergKolo/sergrep.git
The script will be in $HOME/bin/sergrep/auto-backlight.sh. Make sure the script is executable with chmod +x $HOME/bin/sergrep/auto-backlight.sh
Add the script as a startup application. Look for Startup Applications menu in Unity Dash or Gnome search. Alternatively, run gnome-session-properties command in terminal to launch the menu. Add the full path to script as startup application so that it launches every time you log into GUI.

Alternatively, you can copy and save script source by oneself, chmod +x file, and go through the step #6 described above.

To make the script automatically start every time you log in to Gnome or Unity, use Startup Applications utility.

NOTE: if you want the script to always set AC brightness as well uncomment the else statement on lines 60 and 61 , specifically this part

 # The two lines bellow are optional for
 # setting brightness if on AC. remove #
 # if you want to use these two

 # else
       # change_brightness $INCREASE

Script source

#!/usr/bin/env bash
#
###########################################################
# Author: Serg Kolo , contact: 1047481448@qq.com
# Date: February 26 2016
# Purpose: Brightness control that polls for
#          ac adapter presence. Uses
# Dependencies: on_ac_power script, dbus, Unity/Gnome
# Written for: https://askubuntu.com/q/739617/295286
# Tested on: Ubuntu 14.04 LTS
###########################################################
# Copyright: Serg Kolo , 2016
#
#     Permission to use, copy, modify, and distribute this software is hereby granted
#     without fee, provided that  the copyright notice above and this permission statement
#     appear in all copies.
#
#     THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
#     IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
#     FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.  IN NO EVENT SHALL
#     THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
#     LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
#     FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
#     DEALINGS IN THE SOFTWARE.

# uncomment the line bellow for debugging
#set -x

ARGV0="$0"
ARGC=$#

main()
{

  # defaults
  local DISPLAY=:0
  local DECREASE=30
  local INCREASE=75
  local RCFILE="$HOME/.auto-backlightrc"
  #---

  # Check the settings
  if [ -f $RCFILE ]
  then
       source $RCFILE
  else
       create_rcfile $DECREASE $INCREASE
  fi
  #---

  # now actually test if we're using ac adapter
  if ! on_ac_power
  then
        change_brightness $DECREASE
  # The two lines bellow are optional for
  # setting brightness if on AC. remove #
  # if you want to use these two

  # else
       # change_brightness $INCREASE
  fi

}

change_brightness()
{
  dbus-send --session --print-reply\
    --dest=org.gnome.SettingsDaemon.Power\
    /org/gnome/SettingsDaemon/Power \
    org.gnome.SettingsDaemon.Power.Screen.SetPercentage uint32:"$1"
}

create_rcfile()
{
  echo "DECREASE="$1 >  "$RCFILE"
  echo "INCREASE="$2 >> "$RCFILE"
}

while true
do
   main
   sleep 0.25
done


I notice you are missing (hd0,msdos4) and (hd0,msdos6). Were these your Ubuntu partitions?
There has been issue with win10 doing a major update and deleting linux partitions.

Boot from a LiveCD and select try ubuntu. If testdisk isn't installed, open a terminal and type
sudo apt-get install testdisk then sudo testdisk

scan for deleted partitions and add the ones that fit the holes between your partitions.

In most cases that is enough to get it to boot.


How to recover data from a deleted pen-drive?

If you want to recover the data from the drive then

sudo apt-get install gparted
sudo apt-get install gpart
sudo gparted
In the upper right hand corner of gparted choose your pen drive device
Under Device choose Attempt Rescue

The software will scan for the super blocks of the OS and rebuild your partition sector using that data. Just follow the instructions. Once rebuilt and written you will then have access to the pen drive after reinserting into your system.

Good luck


LibreOffice ignores Ubuntu regional settings

LibreOffice has its own locale settings under Options → Language Settings → Languages:

Make sure the correct locale setting is configured here and that your input data matches one of the date acceptance patterns, otherwise it won't be recognized as date by LibreOffice.


You can install KVPM, but you have to install some KDE dependencies it has; they're not many as they said in their page. If you use some QT software it is very probable you already have the dependencies already on the system.

sudo apt-get install kvpm

system-config-lvm is outdated and can't manage some new features of LVM (as reported by itself) so don't bother trying to install it.


Your script isn't set as executable; just like a script not installed by packaging, you need to make sure it has the executable bit set.
You have two options:

When creating the package, make sure that your script has the executable bit set before creating the package, by running this in your work directory Before building the package:
chmod +x /path/to/script.sh

OR...

Use the postinst script for your package to set the executable bit after installation.  Add a command to the .postinst script similar to the following:
chmod +x /usr/bin/myscript.sh

For some of my things, I use both methods just to make sure it sets things as executable.  That introduces headaches sometimes, but it's better to make sure than not make sure.  At least, in my opinion.

As for the script not being able to be executed as myscript, that's because myscript and myscript.sh are different objects.
If you want that, do the following in your .postinst script for your package:
ln -s /usr/bin/myscript.sh /usr/bin/myscript

... and then assuming you fix the executable bit problem, it should then 'just work' for both of the versions you were trying, both myscript.sh and myscript.
HOWEVER the proper way to do this is, instead, to just package the script as myscript and not include the shell extension.  You should then include a shebang line at the beginning (#!) indicating the interpreter to use.  Since .sh could be anything.  Then, set up the package to just install myscript.  As muru stated, you should avoid making links in your postinst, but it's up to you what you want to do.  There's many different ways to achieve your goal, but not really much strict guidance in the documentation for packaging.


how to change cursor position in gnome shell, at login?

Intro

What you might want to do to solve your issue is split into three steps:

Install xdotool.
Create a shell script which uses xdotool to position the cursor center-screen when run
Run this script on gnome startup

I can assist with part 1 and part 2. Part 3 I will drop some advice on, but I cannot test that advice personally as I do not use the gnome de.

Part 1

To install xdotool, you need to enable Ubuntu's universe repository in the apt package manager.

If you have Ubuntu 14.04, this should have been enabled by default when you installed your system.

If you feel this may not be the case, or if you have manually disabled the repo yourself, please enter the following commands into a terminal window (accessed by pressing ctrl + alt + t) to enable it:

sudo add-apt-repository universe
sudo apt-get update

Following this, to install xdotool, simple enter the following command into a terminal window

sudo apt-get install xdotool

Part 2

You can create this script wherever you like, but I will be using the Documents directory of your home folder for this example.
Additionally, you will have to source your own screen coordinates for the script. I will be using 960x540 because this is the center of my 1920x1080 resolution screen.
To get the center of your screen, find the resolution e.g. 1280x800, and half the width and height.

e.g.:
1280/2 = 640
800/2 = 400
So for a 1280x800 screen you would use 640x800.

To create a script that will position your cursor in the center of the screen when run, do the following:

Enter the command nano ~/Documents/cursorcenter.sh

Copy/paste the following into the terminal window (which has prepared to create the file cursorcenter.sh in your Documents folder upon saving):

#!/bin/bash
xdotool mousemove --sync 960 540

Press ctrl + x then press y then press enter to save the script.

Finally, to make the script 'executable', enter the following into a terminal window:

sudo chmod +x ~/Documents/cursorcenter.sh

You can test that your script works by running sh ~/Documents/cursorcenter.sh in a terminal window. If all goes according to plan, your cursor should jump to the center of the screen!

Part 3

To run your script on startup, you simply have to stick the command sh ~/Documents/cursorcenter.sh into whatever script gnome runs as it starts up.

If you are using Gnome3, you should be able to make this script run on start up by sticking it in the ~/.config/autostart/ folder.
To do this, run mkdir ~/.config/autostart && mv ~/Documents/cursorcenter.sh ~/.config/autostart/cursorcenter.sh in a terminal window.

EDIT

If you want to delay the running of xdotool, so that it waits until after whatever time gnome moves the mouse by, put a sleep [time in seconds] line in the script to be run.

For example, the entire script might look like:

#!/bin/bash
sleep 10
xdotool mousemove --sync 960 540

This would wait 10 seconds before positioning your cursor center-screen.


How do I modify these VPN connection settings for Xfce?

You can start the connection editing UI with the nm-connection-editor command.

That would likely require X forwarding, so ssh with ssh -X user@server.


Print Envelope using Only Office and HP Printer

The solution (work-around) is to save the document as a PDF and print it from a different application.
Only Office seems to always use A4 size for all print jobs, ignoring the selected paper size. Even selecting "Print to File (PDF)" from Only Office's print dialog will generate a PDF document that has A4 size.
However, the "Save as" feature produces PDFs of the desired paper size.
HP OfficeJet Pro 8740 (or other printer):

Remove original (Letter) size paper from Tray #1
Insert a #10 envelope in Tray #1 (face down with the flap to the left for HP 8740)
Adjust the paper guides to fit the envelope
Change the paper size to "#10 Envelope" in the printer's menu

Only Office:

Set page size: "Envelope #10 (10.48 cm x 24.13 cm)"
Set orientation: "Landscape"
Set Margins: "Narrow"
Type the address information in the document
Do not select the "Print" option.
Select "File" from the menu bar
Select "Save As"
Enter a file name
From the drop down at the bottom of the Save dialog, select "PDF File"
Click the "Save" button

Open the new PDF file in Document Viewer:

Click the menu (hamburger) in the header bar
Click the printer icon
On the "General" tab, select your printer
On the "Page Setup" tab, set Paper size: "#10 Envelope"
Keep Orientation: "Portrait" (9.50 inch x 4.13 inch)
Click the "Print" button in the header bar

Note: I have created the following bug report: Print feature ignores paper size, always produces A4 size printouts. Please go to the bug report and mark yourself as impacted, if you experience this issue.


What is the solution for this error ' the instraller can't partion on the disk while installing lubuntu?

If you read the Lubuntu 20.04 (focal) release notes you'll find

Installs replacing a partition may fail with this bug. As a
workaround; reboot, use KDE Partition Manager to delete the ‘unknown’
partition that exists, create the partition using the format you want
(ext4, btrfs were tested & worked), deactivate swap partitions & exit
KDE Partition Manager. Calamares can then use the prepared partition.

That condition deals with

sfdisk --force --append /dev/sda


How to Install TWRP with 16.04 for Phone?

The reason you do not get anything from adb devices is that your phone is not in the fastboot mode. So put your phone there and try again.

Shortly, here the work flow without rooting your phone. Do where recovery.img is the renamed TWRP image but has to be renamed like that

Enable Developer mode in your phone; enable smart bootloader and the other setting in Developer settings
Start your phone in fastboot; power + volume up; press so long as your phone vibrates
fastboot devices should return the device id; fastboot oem unlock and phone phone reboots
Again to fastboot and run fastboot flash recovery recovery.img
Go now to the recovery mode by Power + volume down
Wipe everything else except internal data
Install and flash with Switch_to_OOS3_H2OSMM.zip such that you can flash your OO Rom
Flash now with Cyanogenmod Rom and Pico Gapps (Arm64) - only for Google Play Store
Wipe Cache/dalvik

Sources

https://forums.oneplus.net/threads/24-06-2016-oneplus-2-how-to-unlock-bootloader-flash-twrp-root-nandroid-efs-backup-and-more.345478/
http://forum.xda-developers.com/oneplus-2/development/6-0-x-cyanogenmod-13-oneplus-2-t3292436/page769

Systems: Ubuntu 16.04, Windows 10


Remote desktop access between 2 Ubuntu 20.04 devices over the internet

Two uses of VPN
1. Enterprise VPN
VPN is used by enterprises (corporations) to allow remote users access to the office network and computer resources. For example a remote employee of a corporation can access the office's internal network drives using VPN. In this context when a remote users logs in to the corporate VPN server, their remote computer becomes a part of the office local network. Then the remote employee can use VNC to access an office desktop computer.
I think this is the kind of VPN use you envisioned. However, your remote computer is at home while you travel and you don't have an IT department to setup a personal VPN server for you. You can set it up yourself, but I think it is too much trouble for securely connecting one remote computer in the home network context.
2. Consumer VPN
Consumer VPN service providers such as VyperVPN provides slightly different kind of service to home users using the same technology. These service providers setup VPN servers in different locations and countries and allow home users to login to these servers.
This allows home users to hide their internet activities from their own Internet Service Providers, government, etc. This also allows the home users to "pretend" to be in another country and "fool" video streaming services.
Consumer grade VPN service providers do not setup a VPN server in your home network. In fact, if you use a VPN client, say from VyperVPN in your home desktop, then you may not be able to remotely connect to that desktop when you travel. This is because the VPN service makes your desktop "pretend" to be somewhere else! Therefore, you will have to turn the VPN service off in the desktop at home when you travel before you can remotely connect using VNC.
Why not just use VNC?
It is not safe. VNC is rather old protocol and its security is not up to the modern standards. Setting up the VNC server in your home desktop to accept connections from outside your own home network is possible. However, doing this is not recommended, as anyone from the Internet can easily break into your home desktop.
VNC over SSH
You will need to setup ssh server in your home desktop computer first. See Connect two computers with SSH in a home LAN for how to do this.
Once you have ssh working within your home network and you can ssh from your laptop to the home desktop while both are connected to the home network, you will need to setup Remmina to use VNC over SSH.
Open the Remmina desktop preference window you have already created in your laptop to VNC into the desktop from within your home network:

Note, the Server field is filled with an LAN IP address above. Yours will be different. Go to the SSH Tunnel tab:

Check all the boxes as in the picture above. Port 22 is the default port for ssh. For simplicity we will use this port. You can read about how to change the default to some other port and set it up differently later.
Note, I have setup a Public key during my ssh setup. If you have done so, choose Public key as the method of authentication.
Otherwise choose Password.
Try it out and make sure you can VNC from your laptop to your desktop using the SSH tunnel when both the computers are connected to your home network.
When Traveling
There are two things you will need to figure out if you want to VNC over SSH when you are outside your home.

Port Forwarding
Dynamic Domain Name System (DDNS)

1. Port Forwarding
This is part of your router setup. You need to tell your router which device the remote connection requests should go to when the request comes through port 22.
In the picture above, my home desktop has the IP address 192.168.0.101. This is a local IP address within my home network. It has no meaning outside my home network. The router assigns this IP address to my home desktop.
You should setup your router to forward all packages sent via port 22 to the port 22 of your home desktop's local IP address.
The exact process varies from router to router, and how to do this exactly is beyond the scope of this site, as it has nothing to do with Ubuntu.
2. Dynamic Domain Name System (DDNS)
Most home Internet service do not get a static IP address from their Internet Service Provider (ISP). If you have a static IP address assigned by your ISP then ignore this section.
You can copy the Remote desktop Preference in Remmina to a new one, and change the Server IP address to your ISP provided static IP address.
If your ISP dynamically assigns your home an IP address, then your home (external) IP address can change from time to time. You can find your external IP address by Googling what is my ip address when you are connected to your home network.
The problem is when you are traveling and your ISP changes your external IP address, you have no way of knowing what it is. Thus, you won't be able to connect to your home desktop.
You need to use a DDNS service provider. There are some free ones, like duckdns.org You will need to create an account in one of them. Once you have an account, you will need to setup your home desktop to periodically communicate with the DDNS service provider of your choice and update the any changes to your home IP address. The DDNS service provider will create an internet address for your home, such as ivapshome.duckdns.org, where ivanpshome is something you will choose.
The exact method setting up the DDNS client in your home desktop depends on the DDNS service provider. Please search this site, and ask another question (if needed) if you have trouble setting up the DDNS.
Note: Some routers can update some specific DDNS services. You have to check your router and the specific DDNS service you use. The exact methods vary and is beyond the scope of this site.
In Remmina, under the Server field, enter the DDNS provided Internet address such as ivapshome.duckdns.org.
Now you should be able to connect to your home desktop computer from your laptop while traveling.
Hope this helps


Using swap area when extracting a file or copying something into a external storage since Ubuntu 19.04

Swap is used to page out recently unused, but active pages of memory. This normally occurs under heavy usage.

If you look at your free -h command output, after the file copy operation, buff/cache went from 1233 to 6265, used as a file buffer/cache... and with only 8G RAM, something had to get paged out to swap, as you can see, RAM usage went from 900 to 1448, and swap went from 0 used to 38 used.

Absolutely normal.

Modern SSDs use wear leveling to prevent premature "aging". Swap is only used under heavy RAM usage.


It seems that what you want is

find /var/www -type f | xargs grep -l "peter\.dickson@"

The effect of xargs is that The outputs of find (all normal files under the path you provide) are passed as final arguments to the grep command (after the initial arguments provided).

Edit: the period is a special character for grep, so it should be escaped by preceding it with a backslash, as shown.


how do you remove the "Search Your Computer" icon from launcher in Ubuntu 16.04

You cannot remove the main Ubuntu logo icon from the launcher.


cannot enable wifi of Alienware R2 on Ubuntu 16.04 LTS

You are missing a board-2.bin file
cd /lib/firmware/ath10k/QCA6174/hw3.0
sudo wget https://github.com/kvalo/ath10k-firmware/raw/master/QCA6174/hw3.0/board-2.bin

Reboot


How to get Elantech trackpad to be identified properly, curently has no extended functionality

The method found here works for me:

sudo apt-get install dkms
cd /usr/src/
sudo wget http://planet76.com/drivers/elantech/psmouse-elantech-v6.tar.bz2
sudo tar jxvf psmouse-elantech-v6.tar.bz2
sudo dkms add -m psmouse -v elantech-v6
sudo dkms build -m psmouse -v elantech-v6
sudo dkms install -m psmouse -v elantech-v6


To use the AMD Graphics card, execute this command:

  DRI_PRIME=1 ./executable

If you want to run a Steam game with AMD Graphics Card, you should set the Game Launch Options on Steam with this command:

  DRI_PRIME=1 %command%

To test manually if this is working, you can execute this:

  glxinfo | grep "OpenGL renderer"

This command will show your Intel Graphics Card.
Execute this command to see your AMD Graphics Card:

  DRI_PRIME=1 glxinfo | grep "OpenGL renderer"

For example, in my case, when I execute glxinfo | grep "OpenGL renderer", my output is this:
OpenGL renderer string: Mesa DRI Intel(R) Haswell Mobile

But, when I execute DRI_PRIME=1 glxinfo | grep "OpenGL renderer", my output is like this:
OpenGL renderer string: Gallium 0.4 on AMD CAPE VERDE

There are other commands to test, If you want more tests:

  glmark2 (use intel) and DRI_PRIME=1 glmark2 (use AMD)


Not yet, but you can be the first to create such a snap (there is not Ubuntu Core 14.04 btw). You can join the snappy playpen and help us creating one there: https://github.com/ubuntu/snappy-playpen


How to escape grub rescue after formatting drive with Ubuntu partition?

There is no need of reinstalling Ubuntu, when you see this message. This message comes when you break the existing GRUB in the MBR. No need to panic. Just repair the GRUB. Use Boot Repair. Follow my steps and let me know if problem is not solved.

Live boot (try Ubuntu) to Ubuntu from a bootable media (note that the bootable media you insert must be of the same architecture as the installed Ubuntu i.e., if you have installed Ubuntu 64 bit on your hard drive, insert a 64 bit bootable device)
Open terminal when you reach the live Ubuntu and run sudo apt-get update
Then run sudo apt-add-repository ppa:yannubuntu/boot-repair
Then again sudo apt-get update
Then sudo apt-get -y install boot-repair
After installing Boot Repair, sudo boot-repair
You will see the Boot Repair screen, click on Recommended repair and follow instructions. When everything is completed, restart your computer and you can see the GRUB, hence you can see the OS installed.


This was happened due to the issues with proxy update.

Even though I change proxy to NONE as shown below

The proxy did not update properly on shell. If I type echo "$http_proxy" or echo "$https_proxy", it was showing old proxy(which was down). So, it was the issue.

I restarted the system  after this

Now, rosdep updated properly.


puppet rspec no such file to load -- rspec-puppet (LoadError)

I had this same problem and the fix was to put the following in my spec_helper.rb file:

require 'rubygems'

at the top of the file. I was then able to run $ rake rspec successfully.


Screen brightness very dim on a Dell XPS 13 (2013)

here are a couple kernel boot parameters you can try

acpi_osi=Linux
acpi_backlight=vendor
acpi_osi='!Windows 2012'

This is there you add that code, I had to use the 3ed one to get mine working right, it may be necessary to use 1 or 3 combined with the second oneThe file to edit is :/etc/default/grubonce you edit it run sudo update-grub then reboot


nvidia-prime switching to intel stopped working

I had the same portable. This is what I did:

Steps

Install Nouveau driver through "Software & updates"

Remove bumblebee or other installed nvidia drivers:

sudo apt-get purge bumblebee*
sudo apt-get purge nvidia-*

An then reboot

Install nvidia 331-updates driver through "Software & updates" (should also install nvidia-settings and nvidia-prime)

Then reboot


Brand new battery is 100% charged but at 0% capacity

You can see from the voltage and current readings that the battery is not being charged.  My Dell laptop has a blue battery icon on the F2 key and if I press Fn+F2, it will enable/disable charging.  If you have a key like that try pressing it and see if it starts charging.


Wi-fi internet speed for terminal is slow, internet speed on web browser is fast

Probably the download mirror you're using is slow. Try this:

Open Software Center > Edit > Software Sources
Under "Ubuntu Software" tab click on others in "Download from" menu

In next dialog box click on "Select Best Server".

It will search for best server for you, Once done click on "Choose Server" That's it!

Additional Sources:

Official Archive Mirrors for Ubuntu


The only way I've found is to install Cups' Gutenprint drivers and add a new (default) printer using those drivers. But Ubuntu keeps adding another printer using "driverless" drives.


Ubuntu 15.04 - No sound in speakers but working on earphones

You can follow these steps to debug your audio.

If you want to know more for ALSA and PulseAudio, you can check this answer.

Also you could use GUI to change your device preferences like:

(For Gnome) Sound Settings (which is a part of gnome-control-center)
(For KDE) Audio and video settings - KDE control module
pavucontrol

If your earphones use USB, then they are "seen" as a different device.


No.
The Livepatch Datasheet is conspicuous and clear on this topic:

Architecture: 64-bit (x86_64 or amd64)

ARM64 is not supported by Livepatch.


How come Power Manager Settings does not work when computer is under virtual console?

You'll find the answer in /etc/acpi/lid.sh. You are correct that there is an ACPI daemon that responds to things like closing the lid. However, if you look at the line near the top of the script:

if [ `CheckPolicy` = 0 ]; then exit; fi

you'll see a line that cancels the whole thing. The CheckPolicy thing checks whether something like Gnome Power Manager is running on the current console. If so, it aborts, and lets the power manager handle it.

So, when GNOME is the active session, Gnome Power Manager handles the lid. When the console is the active session, the ACPI daemon handles the lid. If you read the rest of the lid.sh script, you'll see that all it does is blank the screen.


How can I have xfce automatically adjust to changing available outputs?

$ xrandr --auto

From xrandr man page:

--auto: For connected but disabled outputs, this  will  enable  them  using their  preferred mode (or, something close to 96dpi if they have no preferred mode). For disconnected but enabled  outputs,  this  will disable them.


two finger scroll issues: erratic selecting and app switching -Macbook pro 8,1

This is three finger tap followed by hold to switch between app windows. The explanation here. https://wiki.ubuntu.com/Multitouch

You can disable it by following instruction in this link, https://wiki.ubuntu.com/Multitouch/TouchpadSupport , but I think it will be better to keep the setting as default, just change in the system setting >> touchpad.


ssh within a local network from a large number of systems without password

If your 50 systems are sharing the home directory, then you are using one and the same SSH keypair on all of them. Hence, there's only one public key to add to the lab computer's authorized_keys.

For more information on SSH keys and how to set them up, see: http://pkeck.myweb.uga.edu/ssh/


Why can't I block an IP range with gufw?

The short answer:
Don't Bother.

The long answer:
Nobody in the linux security space focuses on making a sensible UI for less-informed users that functions appropriately for local management.
Remove ufw and gufw, and rely strictly on iptables.

If you want something easy that works like you'd expect it to, focus on a rules file for iptables:

(please don't use your home directory like my example shows, use a higher privileged directory like /etc/)

This is no more tedious (and is the recommended method) than modifying hosts, other than of course having to execute the command $ sudo iptables-restore < /home/tcll/rules every time a change is made.
(note that I used the directory relative to the image, you'll want to change this to something like /etc/rules)

If you already have a ton of rules saved and want to export them, use $ sudo iptables-save > /home/tcll/rules with your directory of course.
(you'll want to prune these if you previously used gufw because ufw destroys it with tons of params)

This solution was the only thing that worked for me before, and continues to prove itself after 6 years.


Is it possible to have both libav and ffmpeg installed and running on ubuntu 14.04?

On 14.04, clementine is still using the gstreamer0.10 plugins and since ape support is provided by the ffmpeg plugin you need to set up the following PPA to play ape files:

sudo apt-add-repository ppa:mc3man/trusty-media
sudo apt-get update
sudo apt-get install gstreamer0.10-ffmpeg

I tested both vlc and clementine at the same time using this sample file (sh3.ape) and it works flawlessly:


Option 1. Install via APT

According to https://packages.ubuntu.com/search?suite=trusty&searchon=names&keywords=mumudvb the MuMuDVB package is available for 14.04 via APT.

So simply open up a terminal and run the following commands:

sudo apt update
sudo apt install mumudvb

This should result in version 1.7.1 at the moment.

Regaring different ubuntu-versions:

14.04
16.04
18.04

all featuring mumudvb 1.7.1 right now.

Option 2: Installing .deb manually:

In case you are willing to install a local .deb file manually, follow this steps

On Terminal
Navigate to the location where your .deb is located
Enter sudo dpkg -i NameOfLocalDebFile.deb

Option 3: Compile

If you need a particular newer version consider checking the project website and compile the source yourself.


This isn't really a bug and is a known issue.  The short story is that the Vulkan loader tries to load every driver installed on the system so that it can report information about each driver back to the application.  In this case, vulkaninfo is a 64-bit process, and attempting to load 32-bit drivers generates these messages.


I think what you want to do with konsole is the following:

$ konsole -e "sudo sysctl net.ipv4.ip_forward=1; sudo nethogs" --noclose --hold

This will invoke konsole and then run commands within it, -e. In this case we're running the 2 sudo commands and we're using the --noclose & --hold to tell konsole to keep the window open while these run.


The BIOS had a IDE emulator setting for the sata drives. This caused confusion in grub because It was trying to communicate with the sata directly rather than the emulated IDE.


How to get pretty fonts in Google docs on Linux?

The is that the fonts are not installed on your system. You need to have the font .ttf files to have the fonts. I solved this my navigating to my Windows  partition, finding the fonts directory, and copying over the required fonts - Try looking in C:/Windows/Fonts

You might also need to install Ubuntu restricted Extra .

Also, I previously found this if you want any Calibri fonts

This is intended to be helpful, but I don't intend to muck around with Windows copyright in anyway....


Openstack will only support LTS and only current versions. So, at this time that is 14.04, 16.04 and 18.04. Nothing else (12.04 has an extended support cycle but has gone end of life for us normal mortals; I would assume if you are a paying customer 12.04 is also still supported).

Including the not released 20.04 LTS, the following graphic from ubuntu.com shows the support for all the LTS releases (orange):


Ubuntu 11.10 64 bit won't start after I upgrade it, possible procesor problems?

So I will close this, a stop gap solution seems to be adding adding maxcpus=1 but I think I will have to wait for the dev team to trully fix it.


used python -v instead of python -version command, to find the version of python in my pc. does it change anything?

No, python -v has not changed anything or done any harm.

Upon initialization, It will show you the modules that are being initialized and the respective files from which they are being loaded. Upon exit, it will show you the unloading information of the loaded modules. So, for understanding, you can take -v as verbose.

On the other hand, to get the version, use python -V or python --version.

Also, in these kind of situations always start with reading the man page i.e. do man python.


How to get md5sum for online video without download

Note: If just a symbol is changed in the file's content, md5sum will provide another result.

It is impossible to do it on the fly, because md5sum is calculated by reading the file from the beginning till the end and to calculate it md5sum needs to have the file locally.

There are programs that calculates md5sum using its URL. But they will first download it and then calculate its md5sum.


Thats is very simple & easy task

          1. create a tar /var/cache/apt/archives

 tar cvf archives.tar /var/cache/apt/archives

          2. now backup archives.tar

          3. Now Install Ubuntu

          4. After Installing Ubuntu check for updates & close it

          5. now extract archives.tar at  /var/cache/apt/

sudo tar xvf archives.tar /var/cache/apt/

          6. i did a reboot ( Dont know may be Optional )

          7. Now check for Updates they will 0 MB to Download OR may be some kb's

                                          Verified & Checked on 1 host OS & 5 VM's

                                                            A GUI based solution

sudo nautilus

          make a tar & then backup

          Install Ubuntu & Check for Update & Close it

          after that again open terminal &  sudo nautilus

          open archieve.tar & Drag Drop it As shown in pic

          & then again Check for Update , it will be 0 MB


Unable to locate package mozilla-acroread

You need to check if you have the Canonical Partner repositories enabled. This can be done in the Software Center:

Go to Edit menu → Software Sources

Enter password

Click on 'Other Software' tab

Make sure 'Canonical Partners' box is checked.


Difference between gparted and df hard drive sizes

ext4 reserves a portion of space, typically 5%, to avoid fragmentation and for system services. This is specific to ext4
See How To Free Reserved Space On EXT4 Partitions. But use it at your own risk.
This should explain why the total partition size you see by both apps don't match. gparted reports the total partition size, while dh ignores the reserved space.
Regarding that 1% of usage, all filesystems need some space to track files (aka overhead and metadata), even when there's no files yet. FAT32 has very low overhead but still has some, while complex journal-based filesystems like ext4 and ntfs need more space.
It's not that you can't wipe that used space, it's that after the disk gets wiped, it gets filled again.


Append text to file names which do not contain a dot

Try this find command,

find . -type f ! -name "*.*" -exec mv {} {}.html \;

It renames the files which doesn't contain dots in their filenames present in the current directory to this filename.htmlformat(added .html at the last).

.              --> Represents current directory

-type f        --> To do this operation only on files.

! -name "*.*" --> print the name of the files which doesn't have dots in their name.

-exec mv {} {}.html  --> find command perform this move(or)rename operation on the extracted filenames.

\;   -->  Represents the end of find command.


Is it possible to create more than one extended partitions?

No. You can have per harddisk ...

4 primary partitions or
3 primary partitions and 1 extented partition.

The extended partition though can have a 'limitless' amount of logical partitions on Ubuntu. Nowadays the kernel can allocate device numbers dynamically (through udev) and the system will happily use 2 or more letters after reaching sdz. Though there will be a limit someone has tested this up to sdzzz and the idea is that it is safe up to 29 z's (though untested and there are people doubting it all their proof seems to have been deleted).

You can creat partitions from gParted but the partitions need to be unmounted (so you can not change the root partition from a running system). Boot from either an Ubuntu Live DVD or a Gparted Live DVD, start up gParted and shrink your partitions so you get unallocated space. Unallocated space needs to be adjacent to each other to create a big unallocated space. If you shrink sda1 and want that free space as part of sda3 you need to add it to sda2 and shrink sda2. That unallocated space can then be divided into partitions. You can have 1 more primary partition (I expect you'd use sda3 for that; but the 4th one will be impossible and needs to be added to the extended partition to create a logical partition).

Ubuntu (Unix/Linux in general) does not have any restrictions on where you can put the OS part of the installation. So any of these can be used to install Ubuntu (or any Linux based system).

Always create a backup when altering partitions. Making a fatal mistake is easily done but a power failure is always a possibility.

If we are talking modern systems there is also GUID Partition Table (or GPT). The default maximum number of partitions is 128, and if your operating system supports it you can have more
No more hacks to force yourself to a primary/extended/logical partitioning scheme.  When you are GParted and want to use GPT, just select the gpt option when formatting.

The differences between MBR and GPT are summed up nicely on the IBM site.


How to delete specific files from terminal

If you go one level up, you can do:

~music/artist_a/album1$ cd ..
~music/artist_a$ rm */*.mp3

to delete mp3s from every directory inside the current. If you want to delete only from specific subdirectories:

~music/artist_a$ rm {album1,album2,album4}/*.mp3

You can also use find to delete all mp3 in subfolders of every level

~music/artist_a$ find . -iname '*.mp3' -delete

Use these command with caution.


diffrence between two files of different row numbers

Here's one way:

$ awk -F, 'NR==FNR{a[$1$2$3$4]++; next}!a[$1$2$3$4]' csv2 csv1
110,12,31,345
1,12,14,55
12,53,22,10
1,12,32,44

Explanation

-F, : set the field separator to ,. Now, the first comma-separated field of each line will be $1, the second $2 and so on.
NR==FNR : these are two awk special variables. NR is the current input line and FNR is the line number of the current file. The two will be equal only while the 1st file is being read.
NR==FNR{a[$1$2$3$4]++; next} : while reading the 1st file, save the 1st 4 fields as a key in the array a and set their value to 1. This basically saves all 1st 4 fields of csv1. The next ensures that we immediately skip to the next line and don't process the rest of the script.
!a[$1$2$3$4] : the default action of awk is to print the current line. So, if you use something that evaluates to true, awk understands that it should print this line. !a[ $1$2$3$4] is true when a[$1$2$3$4] is not define which will happen for lines in csv1 whose 1st 4 fields were not present in any lines of csv2. Therefore, this directive will cause all lines whose 1st 4 fields have never been seen (so their value in the a array is not 1) to be printed.


Can you make `su` require a password, even if called with sudo?

Add

Defaults rootpw

to your sudoers file. This will have "sudo" ask for a "root" password and not the "current user" password. You can use a "group" to restrict this to that group.

Manual. The Arch wiki is very solid.

Always use visudo to edit your sudoers file (it will validate changes).


WSL: Am I running version 1 or version 2?

At a Windows 10 command prompt, run ver. Is the next-to-last numeric group version 18917 or higher? If so, it is possible you have WSL 2 but not yet verified. Go on to step A or B.
If you do not see Windows version 18917 or higher, you have version 1.
This illustrates the result when the OS is Build 16299:

A. Open Windows PowerShell and enter the command wsl -l -v.  If version 2 is installed properly, you will see the version number. If you don't see a version number, or if you see an error message (Thank you, Cornea Valentin) you have version 1. Uninstall it then reinstall it as per https://scotch.io/bar-talk/trying-the-new-wsl-2-its-fast-windows-subsystem-for-linux

B.  From the WSL shell prompt, run uname. If the kernel version => 4.19, it's WSL Version 2.

Why is this relevant?

WSL 1 was based on Microsoft's Linux-compatible kernel interface, a  compatibility translation layer with no Linux kernel code.

WSL 2 was redesigned with a Linux kernel running in a lightweight VM environment, and innovators have found many more things they can do with WSL 2.

Windows 10 Version 2004 (build 19041.153 & later) enhances WSL2 further; see https://devblogs.microsoft.com/commandline/wsl2-will-be-generally-available-in-windows-10-version-2004/ and https://winaero.com/blog/wsl2-will-ship-with-windows-10-version-2004-with-kernel-updates-via-windows-update/ .


Selecting the JDK for starting Intellij when openjdk-8 is installed

Problem got solved, just 'javac' was missing.
Just type  javac in your terminal and it will suggest commands for you.

sudo apt install openjdk-8-jdk-headless

solved my problem


Upgrading to Ubuntu 16.04 do-release-upgrade fails

had a similar problem (same error but different character). fix was to edit /var/lib/dpkg/status and remove the offending character. In my case it was the davmail package.

Also found its been around for a while and caused other issues:
https://lists.ubuntu.com/archives/foundations-bugs/2012-November/125607.html

"Maintainer: Mickaël Guessant"
That (ë) isn't encoded in UTF-8 :(

You may have a similar issue. If you know some Python you can write a script to detect where the problem is in your case.


phpmyadmin is not working on Ubuntu 16.04

You should install libapache2-mod-php7.0

sudo apt install libapache2-mod-php7.0


You can:

First try to enable hardware acceleration for video on VMware Player if not already enabled.
You can also try installing VMware Tools inside Ubuntu.

This happens because, VMware Player Guest OS can't directly access the video capability outside on Host OS. So Ubuntu checked for video capability and switched to 2D interface.


Choosing that option will enable file-based encryption of files within your home folder.  For this Ubuntu uses eCryptFS, a filesystem driver that it mounts into your home directory while you are logged in, performing encryption and decryption transparently.

This setting makes it very easy and transparent to do so - it's just a simple check box and you don't need to worry about mounting and unmounting, where you store the backing (encrypted) data, managing keys and settings, etc.  Ubuntu does it all for you.  But, it is limited to just the circumstances laid out here: your home directory, using your account password.

This is file-based on the fly encryption, so on disk the files are stored with each other encrypted individually under a directory usually called .Private.

You can use the ecryptfs-setup-private tool to automate some of the work of setting up other encrypted directories on your system.

If you want to encrypt a whole block device such as /dev/sda then you need block-based encryption, not file-based encryption.  The tool you want is cryptsetup.  Cryptsetup sets up and manages LUKS based encryption - a common format of block based encryption.  Note that encrypting an entire system (including the root) carries added complexity due to the need to boot from the system.


Having issues trying to hide side bar while surfing

For Unity Desktop Environment

You have to open Settings, choose Dock tab and do:

disable Auto-hide the Dock, so when you will move your cursor to the left side it will not appear hiding content. But your browser window will not take the whole width.
change icons size so it the left panel will be narrower
change the Position on screen to the Bottom


Proprietary Nvidia drivers 367.35 cannot be found in Additional Drivers

I had similar issues. Try to use command line or synaptic.

For command line search for drivers with

apt-cache search nvidia

And install nvidia driver

sudo apt install nvidia-VERSION

nvidia-VERSION is meant nvidia package with version, for example nvidia-367, nvidia-352 etc. This will not show you nvidia drivers in Additional drivers, it is only an alternate method for installing nvidia drivers.

Found this here


Right-click the Search and Launch. Click "Configure Search and Launch". Under the "View" option, click "Layout" and select "Default Desktop". No more Search and Launch!


Kernel panic when trying to fix broken packages (Nvidia)

You can try update-initramfs on your favorite kernel by logging into console and typing:

sudo rm /var/lib/initramfs-tools/4.19.59-041959-generic
sudo update-initramfs -c -k 4.19.59-041959-generic

As far as logging into the GUI you can try selecting Recover mode in the Advanced Options for Ubuntu submenu reached from the grub main menu.

Recovery mode runs in low resolution and isn't a permanent solution. It allows you to reinstall new drivers and then boot normally.

rm is needed as described here: update-initramfs missing /lib/modules/4.4.0-13-generic


This you can do by using the -std=c++11 flag. Here's an example:

g++ -std=c++11 -Wall -Wextra -Werror main.cpp -o main

This mode can be selected with the -std=c++11 command-line flag, or -std=gnu++11 to enable GNU extensions as well.(source)

See the explanation of the other flags below. I deeply believe that using at least those error flags will make your life easier in the long run. Once you have better knowledge of what your script does, you can omit warnings if needed to achieve a result but it should not be the standard.
Hope this helps you. Here's a good place to start reading.

-Wall — enables all major warnings.
-Wextra — enables other important warnings.
-Werror — make all warnings into errors, causing compilations to fail if any warnings are reported.

Sources:

GCC: Option Summary
GCC: Options to Request or Suppress Warnings


Try to save the file with a ".f" or ".f90" extension in the filename.

Or, in Geany, go to:

Document > Set Filetype > Programming Languages > Fortran (the version you want)


Editor with caching like Notepad++ in windows

Ubuntu have plenty of editor. Here are two options:

You can use Gedit with plugin (gedit-restore-tabs).
Atom is a very powerful editor with a tons of plugins, save-session or remember-session will does the trick.


The LXDE page in the Ubuntu Software Center contains 5 useful add-ons for LXDE including GUI login manager for LXDE (lxdm) and Easy-Mode launcher for netbook (lxlauncher). The LXDE add-ons can be installed by putting a check mark in the checkbox to the left of each add-on and then clicking on the Install button.

There are many possibilities for customization in the LXDE desktop including the package used to manage the internet connection, the LXDE Panel, the Desktop wallpaper and icon fonts. Take a look at this illustrated tutorial: How to Customize the LXDE Desktop.


Generally once an improvemnt is made to the kernel it is kept in and not deleted, somtimes however it can cause issues on some hardware after release so may be disabled in subsequent releases.

Until Precise is released with the 3.2 kernel (which should help) you can try some of the power saving tips from the Wiki page


Install nvidia geforce gt 845m driver on ubuntu 14.04.02 lts

According to.. here

1. Run these in Terminal (Ctrl + Alt + T):

sudo apt-get purge nvidia*

sudo apt-get update

sudo apt-get install nvidia-331-updates-dev

  THEN RESTART YOUR COMPUTER

2. Get the driver, run these intro Terminal too:

For 32-bit driver:

wget http://us.download.nvidia.com/XFree86/Linux-x86/337.25/NVIDIA-Linux-x86-337.25.run

For 64-bit driver:

wget http://us.download.nvidia.com/XFree86/Linux-x86_64/337.25/NVIDIA-Linux-x86_64-337.25.run

3. Switch command console (Ctrl + Alt + F1)

4. Run in Terminal:

By default:

sudo service lightdm stop

For Gnome GDM:

sudo service gdm stop

For Mint MDM:

sudo service mdm stop

5. Finally, permit and run the installer, run:

chmod +x ~/Downloads/NVIDIA-Linux-*-337.25.run && sudo sh ~/Downloads/NVIDIA-Linux-*-337.25.run


Had exactly the same problem (with the same font), it seems your bottom screenshot uses "hintsfull" whilst the top one uses "hintslight" (which I prefer)

I corrected the problem by using the following ~/.Xresources

Xft.dpi: 96
Xft.lcdfilter: lcddefault
Xft.antialias: true
Xft.autohint: true
Xft.hinting: true
Xft.hintstyle: hintslight
Xft.rgba: rgb

For reference, I also use the following ~/.gtkrc-2.0

gtk-theme-name="Ambiance"
gtk-icon-theme-name="ubuntu-mono-dark"
gtk-font-name="Ubuntu 11"
gtk-cursor-theme-name="DMZ-White"
gtk-cursor-theme-size=24
gtk-toolbar-style=GTK_TOOLBAR_BOTH_HORIZ
gtk-toolbar-icon-size=GTK_ICON_SIZE_LARGE_TOOLBAR
gtk-button-images=0
gtk-menu-images=0
gtk-enable-event-sounds=1
gtk-enable-input-feedback-sounds=0
gtk-xft-antialias=1
gtk-xft-hinting=1
gtk-xft-hintstyle="hintslight"
gtk-xft-rgba="rgb"

Alternatively, you can also run Xmonad under Gnome (I this case, Gnome controls the AA and you don't need to mess with config files) as it is quite widely documented, but to me, it defeats a bit the purpose of having an ultra-light WM.


Recently freed hard drive space is not being recognized

To figure this out, I ran sudo lsof | grep auth.log. This gave me a list of services that were using the auth.log file.

Rsyslog was one that I had already figured would have auth.log open, so I had already restarted it. What I forgot to take into account was the fact that we use OSSEC, and it had auth.log open as well. Restarting OSSEC solved the problem; the free space was then recognized by the server.


Virtual Machine Manager missing "Allocate Entire Drive Now" check-box when creating new VM

Actually qcow2 image that Virtual Machine Manager creates is sparse file.
It looks like for example 20GB file to ls -l but du on freshly created file will show it to be less than 3MB.


Answer is here.

but if you repeatedly experiencing this problem reinstalling Unity will Solve your problem.
also give a  Try to boot Ubuntu in Safe mode.for that choose advanced option from Grub Options.


Firefox Java plugin (icedtea) is installed, what prevents it from being loaded?

Why rename your .mozilla folder?

On Debian (Ubuntu and derivatives are based Debian), you will need to open a shell or terminal as root (elevate with sudo -s or use su). From there, do apt-get update to ensure you have a complete, current package list.

On Debian 8, I simply did: apt-get install default-jre icedtea-plugin. If Ubuntu has differing names for its packages, simply do aptitude search icedtea, etc. and request the packages that match your criteria instead.

Once the packages are installed, open Firefox. Open the Add-ons Manager. Go to Plugins, and change IcedTea (or Java) to "Ask to activate" or "Activate" to make the plugin active. The next time a site requests this plugin, you should see a plugin/lego badge and/or a popup asking to confirm it, depending on your plugin preferences.

If doing that still doesn't solve things, then first make sure you've synced your Firefox data, and reset Firefox. Then, remove and reinstall the above packages, and clear out your .mozilla, .firefox, and other related folders in your home folder (use Ctrl-H in Gtk filers or just to rm -rf .mozilla, etc. in a shell. Try again.

And if that doesn't work, then you will have to do whereis firefox, (the folder should be in /usr/lib, /usr/share, or /lib), and manually install the Java plugins yourself (guides are available elsewhere on the web for this). While it isn't recommended, if your system (browser) isn't seeing the plugins any other way, you'll have to do this.

Good luck; this should work, if not come close to solving your problem.


How do I get rid of this stupid system tray utility?

Sounds like Indicator Systemtray Unity. Try to remove the package indicator-systemtray-unity


Slow RDP with Remmina to Windows Server 2012 R2

I had this same issue on one out of two Ubuntu PCs, which are trying to RDP into a 3rd Linux PC with Lubuntu running. In fact even the UI for Remmina was quite slow when trying to click on the toolbar in RDP.
Due to the fact that only one of my Ubuntu PCs Remmina client was always slow when connecting I figured its nothing wrong with the Lubuntu PC I'm trying to connect to.
In the end I EXACTLY duplicated the connection settings from the smoothly working Remmina client into the one that was super-slow and suddenly its working smoothly!
Turns out the only difference in settings between the two clients was the SLOW client had the Resolution setting set to Custom 1024x768 and the smoothly working one had Use initial window size.  It is very strange that this was the issue but it worked for me.
Try setting Resolution to Use initial window size for the connection in the Remmina GUI connection settings
OR in your .remmina settings file: resolution_mode=2


How to configure mail server to report a hostname distinct from server name

Make sure the content of /etc/mailname is example.com. If not, change it and reboot:

sudo nano /etc/mailname
sudo reboot


Is there a way to use ubuntu one for synchronizing Thunderbird on 2 computers?

You could store your whole profile folder in a shared folder that is synched with ubuntu one and place a symlink in the old location so thunderbird picks it up.

Your profiles are stored in ~/.mozilla-thunderbird/<Profile name>, so

open a shell and move it to the shared folder with mv ~/.mozilla-thunderbird/<Profile name> <sharedfolder>/
create a symlink using ln -s '<sharedfolder>/<Profile name>' ~/.mozilla-thunderbird/<Profile name>
repeat step 2 for the synchronized computer.

If you're only interested in synching the emails, not the addons and settings of your mailclient, you should just switch your account type to IMAP.


Are two instances of pip & youtube-dl installed after using sudo to update?

My understanding is that you are concerned you might have several versions of the same software installed and that it differs between the user account and the root account.  Please correct me if I misunderstood you.

You can analyse this from the command line in the following way.

which youtube-dl pip pip3
sudo which youtube-dl pip pip3
youtube-dl --version
sudo youtube-dl --version
pip --version
sudo pip --version
pip3 --version
sudo pip3 --version

Post the result here if you need help in understanding the output.


First, add-apt-repositories adds repositories to the list of sources, and never packages.
Second, there are no packages for 17.10 in ppa:slgobinath/safeeyes, which is why nothing gets installed.


"unknown audio device" dialogue box unresponsive

I'm none the wiser as to the precise cause - but the following mitigating steps prevent it from occurring.

Always plug in the headset, and select "headset" on the options pop up before plugging in any USB audio devices (in my case, port replicator/hub with a mysterious microphone)


How to decide and apply priorties in /etc/rc0.d

You should read man update-rc.d. There is a system to the names, and you will have a happier life if you learn it, rather than figuring out your own. Also read man run-parts.

From man update-rc.d:

DESCRIPTION

       update-rc.d  updates   the   System   V   style   init   script   links
       /etc/rcrunlevel.d/NNname  whose  target is the script /etc/init.d/name.
       These links are run  by  init  when  it  changes  runlevels;  they  are
       generally  used  to  start  and  stop  system services such as daemons.
       runlevel  is  one  of  the  runlevels  supported   by   init,   namely,
       0123456789S,  and  NN  is the two-digit sequence number that determines
       where in the sequence init will run the scripts.

       This manpage documents only the usage  and  behaviour  of  update-rc.d.
       For  a discussion of the System V style init script arrangements please
       see init(8) and the Debian Policy Manual.


What is the difference between ubuntu-18.04-server and ubuntu-18.04-live-server?

It always helps to read the Release Notes.

https://wiki.ubuntu.com/BionicBeaver/ReleaseNotes

  The next generation Subiquity server installer, brings the comfortable
  live session and speedy install of Ubuntu Desktop to server users at
  last.

  N.B., If you require LVM, RAID, multipath, vlans, bonds, or the
  ability to re-using existing partitions, you will want to continue to
  use the alternate installer

From Update to Release notes. But still some issues, see notes for full details.

  As of 18.04.1, the Subiquity server installer now supports LVM, RAID,
  vlans, and bonds.


What is the correct way to restart udev?

I don't know if this helps in reloading the network configuration, but when I modified /etc/udev/rules.d/70-persistent-cd.rules to correct the DVD device link from /dev/dvd1 to /dev/dvd, I had to run

sudo udevadm trigger

to get have the new links created.


What gstreamer packages to install for PiTiVi

The "aptitude" function in Ubuntu terminal installs any application you tell it to w/ all the needed dependencies along with it.

If you don't already have "aptitude" installed, use "sudo apt-get install aptitude".

And than use "sudo aptitude install pitivi".

At least for me, I need "gstreamer0.10-gnonlin" along w/ PiTiVi to get it to work (might be more for you because I could already have other dependencies satisfied).


Vodafone usb Modem(ZTE K3770-z) is not working

open Synaptic Package Manager Type "Smartlink" into the search field in the Synaptic Package Manager and install all of smarlink package. http://www.ehow.com/how_5435902_install-modem-drivers-ubuntu.html#ixzz2BcaT8Ean it works with me very well


Replace the line

hints.ai_flags = flags

with

hints.ai_flags = flags & ~AI_ADDRCONFIG;

in lib/util/util_net.c file of Samba. Compile and run the samba in only IPV6 environment.


How do I set a system wide proxy with a username and password?

Try escaping the backslash like this:

http://user%5Cname:password@proxy.thing.com:8080/

where '%5C' is the URL-encoded value for the backslash character. See this background.


Touchpad doesn't work after suspending the computer

The first thing your should do is upgrade your linux kernel to 4.4 stable.
Google the instructions.  It is easy.

The second thing you should do is take a peek at the new 16.04 and see if that fixes your problem.

The third thing you should do, which is not so fun, is upgrade your bios.
After that file a bug (quickly) typing "ubuntu-bug linux" in terminal.


How to format "if" statement (conditional) on multiple lines in bash?

Use backslashes.

if [ $(do_something "arg1") ] || \
   [ $(do_something "arg2") ] || \
   [ $(do_something "arg3") ]
then
  echo "OK"
else
  echo "NOT OK"
fi

EDIT

Also - I want to make sure that even if the first condition is true all other conditions will still be evaluated.

That's not possible in only one if statement. Instead you can use a for loop that iterates over the arguments and evaluates them separately. Something like:

do_something() {
  for x in "$@"
  do
    if [need to do something on $x]
    then
      do it
    else
      echo "no action required on $x"
    fi
  done
}


USB ports detected but not active on Ubuntu 18.04

After installing multiple tools such as Hardinfo and Usbview investigating to no avail, I resorted to opening up my chassis and check the motherboard. It seems the USB 3.0 ports are broken(since they won't even power up a USB fan) leaving only the eSATA USB active. A motherboard replacement seems to be most likely if I'm planning to keep this machine going.


When trying to check for any updates, why is it taking so long to update the sources?

This was due to problems with some of the Canonical servers (for the Main & US repo's) starting on 05/15. It has been fixed sometime over the last several hr.s & speeds should be back to normal


Is disabling AppArmor to solve permission issues when deploying MaaS advisable?

While it would be OK to disable the apparmor profile for maas-provision, I'd highly discourage it. The profile handles the operations that are needed for MAAS within cobbler, and while you might see denials, it continues to work the way MAAS needs cobbler to.

In other words, these apparmor permission errors are irrelevant to what you are doing.


Will my Intel video graphics work with compiz?

Looks like your graphics card doesn't support the level of OpenGL composting required by Unity.

In such a situation you can't use Compiz Unity (also known as Unity 3D) but you can get an experience nearly similar to that of Unity Compiz by installing unity-2d

sudo apt-get install unity-2d

I have been using Unity 2D for quite some time and its very very similar to Unity 3D.


Ubuntu 13.04 shutdown problem. Got no idea what to do next

Try following the instructions from Shutdown does not power off computer

Type in terminal:

sudo -i  (to get a root shell, sudo gedit is not recommended)
gedit /etc/default/grub
Find the line: GRUB_CMDLINE_LINUX_DEFAULT="quiet splash"
Change this to: GRUB_CMDLINE_LINUX_DEFAULT="quiet splash acpi=force"
Save the file and close the file.
Finally, in terminal: update-grub
exit  (to end the root shell)


Recursive list of files with names that don't contain a certain string

Depends on what you want in the output.

ls -R | grep -v test

Or

find foo -type f | grep -v test

You can format the output with tools such as perl or awk


corrupt usb flash drive, complains about /dev/sdc, but there is nothing there where do I find it?

Honestly, usually I have opposite situation, USB that is unusable on Windows and nothing helps.
In such situations it's easiest and most user friendly to us Gparted:
https://gparted.org/
It had been standard tool in Ubuntu and other Linux distros for years (should I say decades?), has GUI, is relatively user friendly, and most of all - extremely powerful.
Since you solved your issue all I can give you is this recommendation.
If you have empty USB play with it for 5 minutes, you should be good!


Should security updates always be installed?

Generally security updates are about fixing serious BUGS in the current Ubuntu OS regarding Network, Security and all. If you are maintaining a web server or any web related things, then you must have them to be safe.

For example see here some issues: Ubuntu security notices | Ubuntu


Help with permissions for a folder on another hard drive

If you want access to /data and /backup.

sudo chown [yourUser]:[yourGroup] /data /backup

That's all there is to it. Root has always access to everything. Since you just installed all root mounts are owned by root.

You can also solve it differently and add a folder in each of those mounts.
After that you adjust the rights of those folders to your user. Both solutions would work.

sudo mkdir /data/mydata /backup/mybackup
sudo chown [yourUser]:[yourGroup] /data/mydata /backup/mybackup


Is it possible to set a download limit in the Ubuntu Software Center?

Setting the bandwith limit on apt-get which is still what Ubuntu software Center and Synaptic use to get packages (I believe) is fairly simple.  If you go into the /etc/apt/apt.conf.d directory you can add Acquire::http::Dl-Limit "70"; ("70" being the kb/s) in whichever parts of apt you choose.


How to provide two-factor authentication in Kubuntu without a phone

Looks like Coinbase supports Yubikey.  From https://help.coinbase.com/en/coinbase/getting-started/authentication-and-verification/2-factor-authentication-2fa-faq :

Coinbase supports all WebAuthN / Fido2 standard security keys. An
option for a security key is Yubico's yubikey.

See Using security keys
The Yubikey plugs into a USB port, emulates a keyboard, and produces a security code when touched. Should work with Kubuntu 18.04.


You state that it 'feels' slow; have you done any real testing already? Try downloading a file and report the speed. Do a speedtest and report the ping etc. When is it slow, only the internet, or also on your own network when, for example, copying files between computers? We need more information before we can help you.


It should work fine. You can find a list of supported hardware from most vendors at http://www.ubuntu.com/certification/desktop/

Do not rule out Ubuntu not working just based on that list though -- if that was the case, I wouldn't be typing this message now (mine is not on the list).

You can always make a live USB stick or live DVD to try out Ubuntu on your hardware as well. To make a live DVD, just burn the .iso file you downloaded to a DVD ( If you have Windows 7 and below, you will need 3rd party software to do this correctly). If you want to make a live USB stick, just follow the directions here:
https://help.ubuntu.com/community/Installation/FromUSBStick


Can't install VirtualBox 5.2 on Ubuntu 16.04 because of dependency errors

While trying to achieve this I had added repositories for different Ubuntu versions and that was causing the package conflicts. I went into my sources.list.d and removed the repositories for VirtualBox that were not for my version of Ubuntu (16.04).

That fixed my problem and now it's installed for me just fine.


How can I use Devilspie2 to bring a window to the foreground when opened?

I don't think get_window_class() is the correct function for your problem, try it with get_window_name() or get_application_name():

if (get_window_name()=="Lollypop") then
  unmaximize();
  focus();
  focus_window();
end

Or run devilspie2 in the terminal and check with debug_print(get_window_class()) what that returns.


mysql commands are not working properly from terminal

Nothing wrong - everything works as supposed to do.

You typed an incomplete command and because this you see

mysql> SHOW DATABASES
    ->

The mysql CLI waits for the completion of the command SHOW DATABASES. type ; followed by a Return

The correct syntax is

show databases;

The commands are not case sensitive.


overheating thosiba m840 radeon 7500M/7600M ubuntu 14.04

Laptops overheating is not a problem specific tu Ubuntu. It can happens with Windows 7/8/8.1/10.

If your toshiba satelite m840 is not under warranty anymore, you can try to open it carefully and using a air spray bottle, try to remove dust as much as possible, specially on the CPU fan and cooler below. Samething with the GPU fan and cooler below.

This should help to gain an appreciable difference in degrees.

Please take note that a battery charging is heating also.


I am a newbie to Ubuntu myself. But I think grub-customizer should help to solve the problem. Add the ppa for it, install and run it to check if there are menu entries for both Windows and Ubuntu.

I hope this is what you need :)


The X Window System used to be distributed as one big tarball containing the server, drivers, client libraries and some applications.

This changed with the release of X11R7.0, where these components were split into separate tarballs.  The main benefits being:

If a component doesn't change between releases, the same tarball can be included in multiple releases.
More frequently changing components (such as graphics drivers) can release new packages that can be installed without having to rebuild everything else.
Different people can handle the release of different components.

It does have one downside in that the version numbers of all the different components are now more visible to users.

In the case of the X server itself, you can see what version was included in X11R7.6 at the download site:

http://www.x.org/releases/X11R7.6/src/xserver/

So the version included with Ubuntu 11.10 is somewhat newer.  The driver you downloaded from AMD may be compatible with the newer server, but AMD is unlikely to advertise this one way or the other until a full X11R7.7 release is out.  If you are concerned, I suggest sticking to the driver versions included with Ubuntu.


.bashrc not executed when opening new terminal

It isn't necessarily run; at the top of the standard .bashrc is this comment:

# ~/.bashrc: executed by bash(1) for non-login shells.
# see /usr/share/doc/bash/examples/startup-files (in the package bash-doc)
# for examples

I believe there is an option to run bash terminal as a login shell or not.  With Ubuntu, gnome-terminal does not normally run as a login shell, so .bashrc should be run directly.

For login shells (like the virtual terminals), normally the file ~/.profile is run, unless you have either ~/.bash_profile or ~/.bash_login, but they are not there by default.  By default, Ubuntu uses only .profile.

The standard ~/.profile has this in it:

if [ -n "$BASH_VERSION" ]; then
    # include .bashrc if it exists
    if [ -f "$HOME/.bashrc" ]; then
        . "$HOME/.bashrc"
    fi
fi

This runs .bashrc if it is available - assuming $BASH_VERSION is present in your environment.  You can check for this by entering the command echo $BASH_VERSION, and it should display some information on version number - it should not be blank.


Krusader sees doc, docx, xls, xlsx as zip archive

This should be perhaps a comment, but as mentioned here deinstalling WPS solves the problem. It worked for me also. Alternatively (untested):

Remove the 3 xml files wps-office-et.xml wps-office-wpp.xml wps-office-wps.xml from /usr/share/mime/packages/
sudo update-mime-database /usr/share/mime
Assign the .xlsx format to et, the .docx format to wps

Credit to users miku and unsocialwhoyou from mentioned forum.


This really worked for me.

On some recent Linux releases, you need to install ntfs-3g utilities. Try sudo apt-get install ntfs-3g or download from http://www.tuxera.com/community/ntfs-3g-download/. ntfs-3g includes ntfsprogs.

ntfsprogs is a suite of NTFS utilities based around a shared library. The tools are available for free and come with full source code.

mkntfs: Create an NTFS volume on a partition
ntfscat: Print a file on the standard output
ntfsclone: Efficiently backup/restore a volume at the sector level
ntfscluster: Given a cluster, or sector, find the file
ntfsfix: Forces Windows to check NTFS at boot time
ntfsinfo: Dump a file’s attributes, completely
ntfslabel: Display or set a volume’s label
ntfslib: Move all the common code into a shared library
ntfsls: List directory contents
ntfsresize: Resize an NTFS volume
ntfsundelete: Find files that have been deleted and recover them
ntfswipe: Write zeros over the unused parts of the disk
ntfsdefrag: Defragment files, directories and the MFT
ntfsck: Perform consistancy checks on a volume
nttools: Command-line tools to view/change an offline NTFS volume, e.g. ntfscp, ntfsgrep, ntfstouch, ntfsrm, ntfsrmdir, ntfsmkdir
ntfsdiskedit: Walk the tree of NTFS ondisk structures (and alter them)

Be careful with these utilities, they might damage the filesystem, or your hard disk !

(Source: http://gnuwin32.sourceforge.net/packages/ntfsprogs.htm)

With ntfs-3g installed (sudo apt-get install ntfs-3g) you should execute the following commands in a terminal:

sudo ntfsfix /dev/partitionName

After this command you should expect the following output:

~$ sudo ntfsfix /dev/sdb3
Mounting volume... FAILED
Attempting to correct errors...
Processing $MFT and $MFTMirr...
Reading $MFT... OK
Reading $MFTMirr... OK
Comparing $MFTMirr to $MFT... FAILED
Correcting differences in $MFTMirr record 0...OK
Processing of $MFT and $MFTMirr completed successfully.
Setting required flags on partition... OK
Going to empty the journal ($LogFile)... OK
NTFS volume version is 3.1.
NTFS partition /dev/sdb3 was processed successfully.

After this step you should be able to access your external drive partition as usual, mount or use nautilus to access your files.


Is there a way to dual boot Windows 7 and Ubuntu in a Lenovo Ultrabook (without loosing the SSD cache)?

You can use 'wubi' installer given in the ubuntu download image file.

Just extract the downloaded image file of ubuntu (whatever version, no matter) and copy the 'wine.exe' and place it in a folder again with the downloaded image file of ubuntu in the same directory.

Now just double click the 'wine.exe' file. Now it will ask you to allocate some space for ubuntu (Note: ~18GB space is by default selected). Give the password and let it do other for you.

It will ask to reboot. Just reboot and on the next start you will see installing ubuntu. Just follow the on screen steps and you are done.

Now on each start, it will ask you to choose OS to start. Just give your choice as ubuntu (if you want) and use ubuntu.
It will work as dual boot OS parallel to windows.

The great thing is that you can remove it whenever you wish just as you remove other installed programs from windows. Just boot into windows, and go to 'Remove/Uninstall Programs' and uninstall 'wubi' and 'ubuntu'. Now you are done..

Enjoy.


How do you remove Nvidia's proprietary drivers?

sudo apt-get purge nvidia-current

If you type that into the terminal, it will remove the propriatry drivers and go back to the stock drivers. I was having a similar issue and reformed the other day to figure out that the issues seem to be from the latest propriatary drivers. Once I uninstalled it and rebooted, everything was back to normal. Hope it helps!


${f%.wav} removes .wav from the end of the variable. Since f only ever contains filenames with .gsm at the end, ${f%.wav} outputs the filename unchanged.

You probably want "${f%.gsm}.wav" instead (assuming either (a) sox actually did convert the files and only the extension is incorrect or (b) sox uses the filenames to determine the conversion required, so fixing the filenames would fix the conversion).


GNOME Shell extension problem when trying to install themes

Just to make sure - Did the instructions you followed involve extracting the theme to /usr/share/themes? If not you can find a more detailed description of how to install a theme in 11.10 here.


How do I add (mail) programs to the messages indicator?

The Gmail Notifier program integrates with the mail indicator very nicely. You can install through this command :

sudo apt-get update && sudo apt-get install gm-notify

The open the gm-notify program to choose your settings. If you want to remove the evolution icon from the menu, please see this question.


How do I remove a video driver that breaks my system?

There are several ways you can try:

Login with Guest session, and see if you have the previleges to install/uninstall
If your system is dual-booted, you my see a grub menu when starting. Switch to recovery mode on grub menu and see if you can do somehting on the terminal
If you know a way to fix the problem by just editing some files manually, you can start another Ubuntu from your installation CD (or usb stick), and edit your original system files, which is mounted as a folder in the /media directory.


I cannot view file permissions after 14.04 upgrade

You simply mistyped the command. Correct is:
ls -ld ~/.*authority

With the lowercase letter "L" and not the number 1.
An example output on my machine (user "bytecommander") would be:
$ ls -ld ~/.*authority
-rw------- 1 bytecommander bytecommander 6286 Nov  4 17:27 /home/alphawolf/.ICEauthority
-rw------- 1 bytecommander bytecommander   54 Nov  4 17:26 /home/alphawolf/.Xauthority

You can see the permission strings of the form -rw-------.
What the symbols mean from left to right:
- it's a file. Directories would have a d.
r the owner user has read access. (no access would be -)
w the owner user has write access. (no access would be -)
- the owner user has no execute permission. (permission would be x)
- the owner group has no read access. (access would be r)
- the owner group has no write access. (access would be w)
- the owner group has no execute permission. (permission would be x)
- all others have no read access. (access would be r)
- all others have no write access. (access would be w)
- all others have no execute permission. (permission would be x)
There are some more complicated permissions like SUID, SGID or Sticky Bit, but you will very probably not encounter them there.
How ~/.Xauthority has to be configured:
It needs to be owned by your user and its primary group (same name). In the ls -ld output, the owner is displayed in the 3rd column (in my example "bytecommander") and the owning group in the 4th column ("bytecommander" as well in my example).
If you find e.g. root in both of these columns, you need to change that by running:
sudo chown $USER: ~/.Xauthority

The permissions should be set up so that only the owning user has read and write access, everything else is denied. If your permission string looks any different than -rw-------, you should run the following command to fix it:
chmod 600 ~/.Xauthority

Note that 600 is the octal representation of the permissions described above. Run man chmod if you want more info.


Which Ubuntu variant is recommended for an eee PC with a single-core Atom and 1GB RAM?

I have an Asus EEE PC 1000H (1.6 GHz Atom, 1GB RAM, 160GB HD), which is very similar to yours and can say that Xubuntu works very well. I'd recommend it for anything running one of the older single-core Atoms (N230, N270, etc.).

Firefox works great, although if you save and restore entire sessions, it takes a few seconds (10-15) to exit or open and restore the sessions.
Youtube works well, 480p and even some 720p videos play smoothly.
The usual office apps (I installed LibreOffice) work well.