How do I use the latest GCC on Ubuntu? I want to compile my program with the latest version of gcc.

Ubuntu 14.04 comes with gcc 4.8.2, however there's 4.9.0 available, moreover, I see that it is available as a package: gcc-4.9. I tried to install it

sudo apt-get install gcc-4.9

but it says

Reading package lists... Done
Building dependency tree
Reading state information... Done
Note, selecting 'gcc-4.9-base' for regex 'gcc-4.9'
gcc-4.9-base is already the newest version.
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.

Looks like it is already installed, just not as the default one? How do I utilize it to build my program?

The best way to correctly install gcc-4.9 and set it as your default gcc version use:

sudo add-apt-repository ppa:ubuntu-toolchain-r/test
sudo apt-get update
sudo apt-get install gcc-4.9 g++-4.9
sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-4.9 60 --slave /usr/bin/g++ g++ /usr/bin/g++-4.9

The --slave, with g++, will cause g++ to be switched along with gcc, to the same version. But, at this point gcc-4.9 will be your only version configured in update-alternatives, so add 4.8 to update-alternatives, so there actually is an alternative, by using:

sudo apt-get install gcc-4.8 g++-4.8
sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-4.8 60 --slave /usr/bin/g++ g++ /usr/bin/g++-4.8

Then you can check which one that is set, and change back and forth using:

sudo update-alternatives --config gcc

NOTE: You could skip installing the PPA Repository and just use /usr/bin/gcc-4.9-base but I prefer using the fresh updated toolchains.

For GCC 5.X or 6, the packages (and correspondingly, the commands) are just called gcc-5, gcc-6, etc. This is due to the change in GCC's version scheme, where 5.1 is the first GCC 5 release, and future 5.X releases are for bug fixes.

To call gcc 4.9 specifically, use gcc-4.9 at the command prompt.

All the gcc versions you have installed can be called individually by adding a hyphen and the version number at the end of gcc.  In your case, gcc-4.8 and gcc-4.9 should be available. In a terminal, type gcc- (note the hyphen) and the push tab twice to see if there are any other versions installed.

Note that the default gcc is likely still 4.8.  (Use gcc -v to verify this.) Unfortunately changing the default is not trivial if you installed gcc-4.9 from the default repository as it did not add a update-alternatives entry. If you are interested in how to change the default, see answers to this this question.


HP QuickTouch media keys worked with LiveCD but not after install The "touch sensitive keys", that control volume and media worked great out of the box when I was running Ubuntu on a LiveCD, but they are totally unresponsive after installation.

HP Pavilion dv9740us with dual-boot Vista Ultimate and Ubuntu 10.10
Intel Core 2 Duo T5450 / 1.67 GHz
NVIDIA GeForce 8600M GS @ 512MB
3G DDR2 RAM,

I can offer a workaround for this problem. Boot Windows (from stick, from disk, whatever) and make sure this Windows has installed the appropriate HP Quicklaunch Button driver (find it here). After starting Windows, use the touch buttons. If the buttons work, you can restart you laptop and boot ubuntu. It should work then, it did for me.

Although it is just a workaround, I hope it helps.

Most likely it was because there was a certain driver in use due to Windows/Vista being installed. During your LiveCD usage it's using the currently loaded drives from the main installation I.E. Windows and it uses those. When you install well, that all goes away. Most likely you'll need some proprietary driver or driver(s) if they even exist which I'm sure they do.


Ubuntu 18.04 Laptop Lid Behaviour I've been having this problem with my acer laptop where ubuntu totally ignores the lid power options.
I want my laptop to lock (always) when I close the lid and also, to sleep (only when the adapter is not connected).

I've tried the power options in settings and it didn't work. I tried to edit org.gnome.settings-daemon.plugins.power.lid-close-ac-action and org.gnome.settings-daemon.plugins.power.lid-close-battery-action using dconf-editor but those seem to be completely ignored.

The only setting that does work is the Power > Suspend when laptop lid is closed in Gnome Tweaks but that causes the laptop to sleep even if it's connected to power.

How do I get ubuntu to behave according to the power settings?
Is there some other way to do this in Ubuntu 18.04?

I came up with my own solution for this. Basically, I wrote a C program that monitors the lid and lock or lock and suspend the system based on whether it's connected to power. It also inhibits the systemd-logind lid events to prevent any surprises.


How do I make the Dash open up fullscreen in 2D? How to make the dash in Unity 2D open up full-screen?

11.04
I've found a workaround to do that.
Open the file /usr/share/unity-2d/places/dash.qml.
Find this code:
        if (currentPage != undefined) {
        currentPage.visible = false
    }
    currentPage = page
    currentPage.visible = true
    dashView.dashMode = DashDeclarativeView.FullScreenMode //AND ADD THIS LINE
}

NOTE: I've tested this on the daily build of Unity-2d from PPA, I'm not sure it works on the Natty version.
EDIT: The code on the Natty version it's similar, and is between the line 42 and 50.

Hopefully this article covers what you want:

http://www.omgubuntu.co.uk/2011/03/quick-tip-enable-full-screen-dash-in-natty-desktop/


Difference between 'google-chrome-stable' and 'google-chrome' binaries There are two binaries in my /usr/bin directory, google-chrome and google-chrome-stable. I wonder if both belongs to the same package.

$ ls /usr/bin/ | grep google
google-chrome
google-chrome-stable

Which one to use BTW?

In your case it's all the same. google-chrome starts the
configured version, see at the end of my answer.

First let's start a little test:

% ls -laog /usr/bin/google-chrome
lrwxrwxrwx 1 31 Mär 17  2015 /usr/bin/google-chrome -> /etc/alternatives/google-chrome

% ls -laog /etc/alternatives/google-chrome
lrwxrwxrwx 1 27 Mär 17  2015 /etc/alternatives/google-chrome -> /usr/bin/google-chrome-stable

As you can see

/usr/bin/google-chrome

is a symbolic link to

/etc/alternatives/google-chrome

and

/etc/alternatives/google-chrome

is a symbolic link to

/usr/bin/google-chrome-stable

If you have installed e.g. google-chrome-beta and google-chrome-stable, you can start

sudo update-alternatives --config google-chrome

to change the behavior, eg. in my case

There are 2 choices for the alternative google-chrome (providing /usr/bin/google-chrome).

  Selection    Path                           Priority   Status
------------------------------------------------------------
* 0            /usr/bin/google-chrome-stable   200       auto mode
  1            /usr/bin/google-chrome-beta     150       manual mode
  2            /usr/bin/google-chrome-stable   200       manual mode

Press enter to keep the current choice[*], or type selection number:

Google-Chrome-Stable version will be tested out and bugs will fix before the public release

More information available in below link

https://code.google.com/p/selenium/wiki/ChromeDriver

https://productforums.google.com/forum/#!topic/chrome/zdycfubS1zg


repository and update but what then.. my issue being..

when looking into a program and when i deside to install there is often the following two lines available.

sudo add-apt-repository ppa:#######.dev/stable
sudo apt-get update

which i prosume the program is added in the repository and then update (all) the programs in the repository including the new to be installed program that then is installed.

but after that i fail to actually start the intended program, or look it up under search. in this particular case inkscape..

i also tried (afterwards) to install via ubuntu software but it stops at 9%, could be because it is already installed but also had issues with ubuntu software so i prefered the install via terminal

strangely enough sometimes the program does appear in time. so i also rebooted but that doesn't work either.

what am i doing wrong / not doing here.

Kind regards

So step 1 is adding the repo

Step 2 is to update and finally

Step 3 is to install

An example of this is the following

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

sudo apt-get update

sudo apt-get install wine

The adding of the repository enables you access to said repository.

The update performed after is so that your system recognizes the changes that have been made. The change in this case being the addition of a repository.

The install command run afterwords is what actually installs the program.

In short adding a repo and updating the system doesn't auto install the program you want. You still need to apt-get install it.

I suggest that you try and uninstall the program, remove the repo and repeat the steps I've listed. Or simply go through the software center. It's possible that something broke during your install. We'd need some terminal output to assist further.

There is a difference between repositories and PPA (Personal Package Archives). Please see this link for more information regarding them.
What's the difference between a PPA and a repository?

extensive answer

sudo add-apt-repository ppa:wrinkliez/ppasearch
sudo apt-get update
sudo apt-get install ppasearch

inkscape instead of ppasearch in your case

https://askubuntu.com/questions/4983/what-are-ppas-and-how-do-i-use-them


How to make gnome-terminal cursor green I have customized my Terminal look a great deal now, and to add the finishing touches I wish to make my gnome-terminal cursor green (it is currently white), however there appears no way to do this in the settings GUI, so how could one achieve this? I am running Ubuntu GNOME 15.04 with GNOME 3.16.

Information Update:

This is the current look of my Terminal:

And I have configured this with:

PS1='${debian_chroot:+($debian_chroot)}\[\033[00;37m\][\[\033[00;32m\]\t\[\033[00;37m\]] \[\033[01;34m\]\u\[\033[00;37m\]@\[\033[01;34m\]\h\[\033[00;37m\]:\[\033[01;34m\]\w\[\033[01;32m\]$ '

In .bashrc.

Following command will change terminal cursor to green:

echo -e "\e]12;green\a"

Above command will print extra new line. If no new line required:

echo -ne "\e]12;green\a"

For permanent changes put above command in .bashrc file.

Further if you want to make your cursor visible or invisible:

tput cnorm  # make cursor invisible
tput civis  # make cursor visible

More information can be found at following link:

How do I change the color of current cursor position indicator?

You could try this:

sudo nano #terminal-cursor-ds:#

and then type this in

cusor window color {
   {window frame cursor}
   {color="true"
   {color="green"
}

and then save the file, and then this in the terminal:

sudo apt-get install --reinstall gnome3
sudo dpkg-reconfigure term

and it might work fine this way.


Permission Denied when using ./configure I tried to install Reaver. The read me file gives a procedure and the first step is to use the following code in the corresponding location.

root@ubuntu:/media/New Volume/reaver-1.4/src# ./configure

This was the result

bash: ./configure: Permission denied

I tried changing the file permission using chmod. But after the command is executed it changes it's permission back to the default one.

I had this error because I was trying to run the command on a mounted partition that had the "noexec" flag on.

After remounting to remove this flag, everything worked fine. With this command:

sudo mount -o remount,exec /media/MOUNTEDDISKNAME


What is the difference between `ssh -Y` (trusted X11 forwarding) and `ssh -X` (untrusted X11 forwarding)? What is the difference between ssh -Y (trusted X11 forwarding) and ssh -X (untrusted X11 forwarding)? As far as I have understood it, it has something to do with security, but I did not grasp the difference and when to use which.

Both options have something to do with X11 forwarding. This means if you enable this, you can use a graphical client through your SSH session (e.g., use Firefox or something else).

If you use ssh -X remotemachine the remote machine is treated as an untrusted client. So your local client sends a command to the remote machine and receives the graphical output. If your command violates some security settings you'll receive an error instead.

But if you use ssh -Y remotemachine the remote machine is treated as a trusted client. This last option can open security problems. Because other graphical (X11) clients could sniff data from the remote machine (make screenshots, do keylogging and other nasty stuff) and it is even possible to alter those data.

If you want to know more about those things, I suggest reading the Xsecurity manpage or the X Security extension spec. Furthermore, you can check the options ForwardX11 and ForwardX11Trusted in your /etc/ssh/ssh_config.

The -X option enables X11 forwarding:

-X   Enables X11 forwarding.  This can also be specified on a per-host
     basis in a configuration file.

     X11 forwarding should be enabled with caution.  Users with the
     ability to bypass file permissions on the remote host (for the
     user's X authorization database) can access the local X11 display
     through the forwarded connection.  An attacker may then be able
     to perform activities such as keystroke monitoring.

     For this reason, X11 forwarding is subjected to X11 SECURITY
     extension restrictions by default.  Please refer to the ssh -Y
     option and the ForwardX11Trusted directive in ssh_config(5) for
     more information.

The option -Y, corresponding to the ForwardX11Trusted directive in ssh_config(5), is even less secure because, it removes X11 SECURITY extension controls.

-Y      Enables trusted X11 forwarding.  Trusted X11 forwardings are not
        subjected to the X11 SECURITY extension controls.

It's more secure to use -x

-x   Disables X11 forwarding.


FireFox in14.04 on a 32 bit mechine? It will not run any videos. I have been fighting this for weeks it seems. Installing with the Software Centre fails. I had a command line last week that got Firefox to run most videos. But a major crash killed all my documents. Now another clean install of Ubuntu 14.04 and the same stuff is still happening. In FaceBook Chromium and FireFox will not start videos or run the games.

You need to install Flash player from the rpm fusion repository to play videos in your browser.

To get Flash up and running, open a new Terminal window (press Ctrl + Alt + T) and copy paste the following lines :

  sudo add-apt-repository ppa:nilarimogard/webupd8
  sudo apt-get update
  sudo apt-get install freshplayerplugin

This will install pepper flash(google chrome's flash player) to firefox.

If Firefox was running when you installed it, you will have to restart Firefox for changes to take place.

If that doesn't work, copy paste the following :

sudo apt-get install ubuntu-restricted-extras
sudo apt-get update

Installing this package will pull in support for MP3 playback and decoding, support for various other audio formats (GStreamer plugins), Microsoft fonts, Flash plugin, LAME (to create compressed audio files), and DVD playback.

The problem is to old a machine and not enough RAM. I dropped back to 12.04.5 and dumped Chromium for Google Chrome. Now back to things working reasonably well.


Any inputs in the Ubuntu login GUI result in total freezing of the system 1. THE SITUATION

As of about two days ago, upon attempting to log into my Ubuntu machine, any inputs in the Ubuntu login GUI result in a total freezing of the system. Prior to UN/Password being submitted all elements of the interface behave as expected (to include widgets, mouse, keyboard etc.) The only recourse is to force shutdown.

Background details:

Ubuntu 16.04 LTS
MSI 64x single boot (UEFI)
Admin boot password is active
Any GUI-based login attempts lock the entire system requiring forced shut down

I've been trying to figure this one out since Saturday morning (almost two days now).

2. KNOWN FACTS

No errors currently exist in the system bios
Live images can boot into both Legacy and UEFI. (Tested with Kali live, Ubuntu Live, Grub2 Repair Disk, and the super awesome USB version of SystemRepairCD )
The projects I was working on prior to the manifestation of the issues at hand involved installing Google Cloud SDK, Firebase, NPM, and NodeJS.
Last week I set up a WAVES blockchain node

3. HYPOTHESIS

The problem likely exists within a PATH conflict. I recall having trouble with some bugs related to NPM and NodeJS permissions and so (as is suggested in the official documentation, and as is suggested by Firebase documentation), I set up an alternative PATH.

  Please see the following for reference:
  NPM: Fixing NPM Permissions

So all of that having been said, the problem remains. Additionally I attempted the following at the GUI login page:

(Control) + (Alt) + (F1)

The command froze my system... Again.

Please assist me with this error as I really need to be operational again before the work-week begins.

Thank you all in advance.

UPDATE

(20170724) It appears as if several other people are having issues with GUI related errors which come from the newest line of NVIDIA GTX graphics cards.

Similar occurrence
NVIDIA control panel tool

THE SOLUTION

This post explains the basis for a working solution: How to change proprietary video driver using the command line?

In summary, the most recent Ubuntu update threw off the synergistic balance between many of the latest NVIDIA mobile graphics cards and the Ubuntu system. As a result, users were met by a frozen GUI or a command line upon attempting to log in after the update completed. Ultimately, the working solution is to take the following steps:

REBOOT YOUR MACHINE

This may involve a forced shutdown if you're stuck at the frozen GUI login page. To perform this, simply press and hold the power button till your system shuts down.
Press the power button again to initiate the Power-On sequence.

ENSURE SAFETY BOOT IS DISABLED

It is important that you perform this step as it will save you from having to perform another more complicated step during this process.
"Safety Boot" is disabled via your BIOS/UEFI boot menu.
Accessing the BIOS menu can be a matter of frustration for some, as the methods of entry are different for many computers (it's based on your hardware, so you may end up having to look it up). That being said, MANY machines can be forced into the boot menu by consistently pressing (or holding) either the DELETE, F10, F2, SHIFT, or the ESC buttons several times during the initial booting process until the menu appears.
Once you enter the BIOS menu, navigate through to the "Safety Boot" setting and ensure that it is disabled. (Not all machines are equipped with Safety Boot)

REBOOT YOUR MACHINE

After making sure Safety Boot is disabled, restart the system again

ACCESS THE GRUB MENU AND LOAD THE PREVIOUS UPDATE

For some systems, the GRUB menu is displayed every time the computer is turned on. For other systems (like mine) you'll have to press and hold the SHIFT key while booting up the system to access GRUB.
Upon getting to the menu, navigate to the "Advanced Options" section and select the previous update of Ubuntu (just look at the version numbers). There is no need to access the system via safety mode etc. Simply use the previous edition of Ubuntu which predates the faulty GPU driver update.

DOWNLOAD ALTERNATIVE DRIVERS

Once inside the system you'll need to get the Ubuntu driver tool by typing the following commands into your system Terminal:

sudo apt install ubuntu-drivers-common
sudo apt-get update

Now run the tool with the following command:

sudo ubuntu-drivers devices

This will give you a readout of your graphics cards and the available drivers which correspond to them. Here is an example of what this list may look like:

== /sys/devices/pci0000:00/0000:00:01.0/0000:01:00.0 ==

vendor   : NVIDIA Corporation
modalias : pci:v000010DEd00000DDAsv000017AAsd000021D1bc03sc00i00
model    : GF106GLM [Quadro 2000M]
driver   : xserver-xorg-video-nouveau - distro free builtin
driver   : nvidia-304-updates - distro non-free
driver   : nvidia-304 - distro non-free
driver   : nvidia-331 - distro non-free recommended
driver   : nvidia-331-updates - distro non-free

Notice that one of the options says "recommended". That's the one to get. Just download and install that driver (and reboot the system) with the following commands:

sudo apt-get install nvidia-331
sudo apt-get update
sudo reboot

REBOOT AND UPDATE

You can now log into your user account via the Ubuntu GUI.

SUPPLEMENTAL RESOURCES

lshw BEFORE the fix (screenshot)
lshw AFTER the fix (screenshot)
Installing Binary Drivers using the Terminal (Official Ubuntu Documentation)

I have noticed that when I try to use the new default of Linux version 4.10.x, then it fails to log in. I have tried to use recovery mode, but that still failed.

I have to go into the advanced mode (holding onto shift as the computer starts up) and use the previous version. Linux 4.8.0-58, and then it works. I have an NVidia Quadro FX 4600 and an Intel Core Quad machine.


How to open Nautilus at current command line directory? I was wondering if anybody knew a command that would allow me to open a Nautilus (if that's the right name for the Ubuntu graphic/window explorer) window from the command line at the current directory that the user is at.

So, if I open a command line, and type:

cd /home/myUser/some/long/path/to/a/directory

Then, I'd like to be able to issue some command:

nautilus open-sesame

And have a graphic window opened to /home/myUser/some/long/path/to/a/directory. Is this even possible?

You can type in the terminal:

cd /home/myUser/some/long/path/to/a/directory

and then:

nautilus .

The above command will open nautilus in the folder /home/myUser/some/long/path/to/a/directory (the period is the current directory)

Or in the Terminal just type:

nautilus /home/myUser/some/long/path/to/a/directory

To open nautilus from terminal.

nautilus .

To open nautilus in the background and still use the terminal.

nohup nautilus . > /dev/null 2>&1 &

You can also make that an alias.

alias open='nohup nautilus . > /dev/null 2>&1 &'

You can also add that alias to .bash_aliases, to have it persistent.

echo "alias open='nohup nautilus . > /dev/null 2>&1 &'" >> .bash_aliases

So now, after restarting the terminal, you can just type open.


Unable to run gedit as a different user I login as user 'foo' and if I am able to run gedit and edit files in my Ubuntu 12.04 machine with a DISPLAY setting as :0

If I "su - bar" and then try to edit files, I get a no protocol specified error and it doesn't open the necessary files. What coule be the problem here?

gedit is a graphical program, so just as you would not run it as root with straight sudo, you shouldn't run it as another user with straight sudo or straight su.

Instead, if you (i.e., foo) have the power to run programs as another user with sudo, this is probably the easiest way for footo run gedit as bar:

xhost +local:bar
gksu -u bar gedit

If you don't have the power to run programs as another user with sudo but you can su to bar, then this is the easiest way:

gksu -w -u bar gedit

The -w flag (equivalent to --su-mode) makes gksu (which is a frontend for both sudo and su) use su instead of sudo.

You shouldn't need to run any corresponding xhost command to make gksu -w ... work.

If you want a graphical terminal instance (gnome-terminal) from which you can run anything as bar including graphical applications, you should consider just running a new instance of gnome-terminal as bar (which you can do the same way as running gedit, detailed above).

The syntax you provide doesn't look right.  If you want to switch to user 'bar', then I believe you should use "su bar".  But if that's not right, I would think you would get an error at the time you try to switch users.  Maybe it's a typo in your question or su takes it anyway.

I think it's more likely that the problem is gedit is a gui-based editor and so is trying to launch in that user's x session, which wouldn't exist if you change changed users via the terminal.  What happens if you use "vi file_to_edit"?  Vi is a terminal-based editor and shouldn't be affected by gui difficulties.

edit:
I need to get some computer glasses, I thought the command you put was "su -bar".  But "su - bar" is valid syntax.


How to install PHP 7? PHP 7 came out yesterday and I would like to give it a try.

PHP 7.0.0 comes with a new version of the Zend Engine, numerous improvements and new features such as

Improved performance: PHP 7 is up to twice as fast as PHP 5.6
Significantly reduced memory usage
Abstract Syntax Tree
Consistent 64-bit support
Improved Exception hierarchy
Many fatal errors converted to Exceptions
Secure random number generator
Removed old and unsupported SAPIs and extensions
The null coalescing operator (??)
Return and Scalar Type Declarations
Anonymous Classes
Zero cost asserts

php.net

Is that possible to install it on current Ubuntu version?
Is there any current limitations or known compatibility issues?

You can do the following:

sudo apt-get install python-software-properties software-properties-common
sudo LC_ALL=C.UTF-8 add-apt-repository ppa:ondrej/php
sudo apt-get update

Optionally purge PHP 5:

sudo apt-get remove php5-common -y

Or directly purge it including configuration files:

sudo apt-get purge php5-common -y

And finally install PHP 7:

sudo apt-get install php7.0 php7.0-fpm php7.0-mysql -y

Optionally clean up unneeded packages afterwards:

sudo apt-get --purge autoremove -y

Alternatively, you can install PHP 7.0 from sources using this script script or following instruction on this blog.

EDIT:

PHP5 has now been replaced with PHP7 as the default PHP in Ubuntu 16.4 so,  to install PHP7 on Ubuntu 16.04:

sudo apt-get install php7.0

Or

sudo apt-get install php

I've collected a few different resources and resolved many issues to fully setup a build of PHP 7 on Ubuntu 15.04 and 15.10.  Although it isn't a Debian package script, it does setup Ubuntu dependencies and configuration. The resources can be found over here.

You may need to select a release branch over just master and rerun the script.


How to use snapshots with BTRFS in Ubuntu along with a separate HOME partition My goal is to make snapshots while upgrading software. I installed Ubuntu primary partitions and Using MBR with Legacy BIOS with a separate HOME partition in another HDD formatted in XFS and root in *"/" in BTRFS

I know there's this package called apt-btrfs-snapshot.

This my system layout :

$lsblk
NAME   MAJ:MIN RM   SIZE RO TYPE MOUNTPOINT
sda      8:0    0 223.6G  0 disk
├─sda1   8:1    0 215.6G  0 part /
└─sda2   8:2    0     8G  0 part [SWAP]
sdb      8:16   0 465.8G  0 disk
└─sdb1   8:17   0 465.8G  0 part /home

Note:

I have to get back to BTRFS when I reinstall . I've been using Ext4

from your screenshot of the disks tool i can see that you are trying to create an lvm physical volume using the extended partition (/dev/sda1), you can't do this because an extended partition is only a container for other partitions, in this case your btrfs (/dev/sda5) and swap partitions (/dev/sda6), but not in an lvm compatible way. This is also the reason why lvmdiskscan cannot see it.

The simplest solution would be to , after backing up the data, use the partition with the BTRFS filesystem as your lvm physical volume then create a logical volume within it to restore the data to, assuming it wasn't too full. The command you were trying to run would then be

sudo pvcreate /dev/sda5

A better choice would be to repartition the SSD (ideally with a GPT instead of MS-DOS partition table, then you can make many many partitions without the limitations of older hardware requiring extended partitions) to not use the extended partition at all.  This is not essential given that you are using LVM which allows you to ignore those limitations because of its abstractions. Don't repartition if you need to preserve an existing OS.

FYI, btrfs is optimised for lots of small files like a mail server , its not the most efficient filesystem for a home dir. ext4 might be a better choice as its more general performer


Netplan configuration error: "Invalid YAML ... did not find expected key." I'm trying to connect to internet using static IP, but when I enter sudo netplan apply command, the console returns the following error:

Invalid YAML at //etc/netplan/01-netcfg.yaml line 8 column 5: did not find expected key.

How to fix this? The content of my 01-netcfg.yaml looks like:

network:
version: 2
renderer: networkd
ethernets:
enp0s3:
            dhcp4: no
            dhcp6: no
            addresses: [10.0.2.15/64]
            gateway4: 10.0.2.0
            nameservers:
            addresses: [8.8.8.8,8.8.4.4]

So, with regards to the specific error you're getting, you've failed basic YAML syntax and indentation, which is one of the reasons netplan is complaining.  YAML is extremely indentation-oriented for how it interprets commands, config arguments, etc.  You need to have proper indentation for YAML configs to be parsed.  Surprise, you aren't doing that at all, and breaking YAML syntax.  That's why netplan is complaining because you aren't providing proper YAML.

But even more importantly than the YAML syntax which will make Netplan work, you have some critical failures with your network configuration, and you really need to fix these regardless.  These failures are, specifically:

10.0.2.15/64 is not a valid IPv4 CIDR range.  The acceptable CIDR ranges are between /0 (for all IPv4) and /32 (for a single address) for IPv4.  Most networks are /24 for the CIDR range (with this IP range, that would encompass 10.0.2.1 - 10.0.2.255 as usable address space, though I would assume the .1 is the Gateway and the .255 is the Broadcast, but that might differ in your network so double check all the values!).  The proper CIDR range is needed so the system knows what its netmask and reachable IP space is.
10.0.2.0 isn't a proper gateway address.  The .0 address is not a usable address in IP subnetting, as it's usually held by the network prefix alone.  And since your netowrk config attempts to do a /24 but horrendously fails, this gateway should probably be 10.0.2.1 - but again, double check these values with your network admin first.

So, fixing your indentation and fixing the network to assume it's a /24 based on the attempted IP and gateway you specified, your YAML should look like the below, with the proper indentations.  And compared to your existing one, you really need to learn how indentation works.

network:
  version: 2
  ethernets:
    enp0s3:
      dhcp4: no
      dhcp6: no
      addresses: [10.0.2.15/24]
      gateway4: 10.0.2.1
      nameservers:
        addresses: [8.8.8.8, 8.8.4.4]

When I edited the .yaml file and executed:
$ netplan try  it failed.

In my case I could solve it leaving the space that had the original file: This is on Ubuntu Server 18.04.1 LST. Backup the original file before edit it. Good luck.


ssh: automatically accept keys I've written this small utility script:

for h in $SERVER_LIST; do ssh $h "uptime"; done

When a new server is added to $SERVER_LIST, the script is stopped with:

The authenticity of host 'blah.blah.blah (10.10.10.10)' can't be established.
RSA key fingerprint is a4:d9:a4:d9:a4:d9a4:d9:a4:d9a4:d9a4:d9a4:d9a4:d9a4:d9.
Are you sure you want to continue connecting (yes/no)?

I've tried yes:

for h in $SERVER_LIST; do yes | ssh $h "uptime"; done

with no luck.

Is there a way to parametrize ssh to automatically accept any new key?

Use the StrictHostKeyChecking option, for example:

ssh -oStrictHostKeyChecking=no $h uptime

This option can also be added to ~/.ssh/config, e.g.:

Host somehost
    Hostname 10.0.0.1
    StrictHostKeyChecking no

Note that when the host keys have changed, you'll get a warning, even with this option:

$ ssh -oStrictHostKeyChecking=no somehost uptime
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
@    WARNING: REMOTE HOST IDENTIFICATION HAS CHANGED!     @
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
IT IS POSSIBLE THAT SOMEONE IS DOING SOMETHING NASTY!
Someone could be eavesdropping on you right now (man-in-the-middle attack)!
It is also possible that a host key has just been changed.
The fingerprint for the RSA key sent by the remote host is
31:6f:2a:d5:76:c3:1e:74:f7:73:2f:96:16:12:e0:d8.
Please contact your system administrator.
Add correct host key in /home/peter/.ssh/known_hosts to get rid of this message.
Offending RSA key in /home/peter/.ssh/known_hosts:24
  remove with: ssh-keygen -f "/home/peter/.ssh/known_hosts" -R 10.0.0.1
Password authentication is disabled to avoid man-in-the-middle attacks.
Keyboard-interactive authentication is disabled to avoid man-in-the-middle attacks.
ash: uptime: not found

If your hosts are not often reinstalled, you could make this less secure (but more convenient for often-changing host keys) with the -oUserKnownHostsFile=/dev/null option. This discards all received host keys so it'll never generate the warning.

With 18.04, there's a new possibility: StrictHostKeyChecking=accept-new. From man 5 ssh_config:

If this flag is set to “accept-new” then ssh will automatically
add new host keys to the user known hosts files, but will not
permit connections to hosts with changed host keys.  If this flag
is set to “no” or “off”, ssh will automatically add new host keys
to the user known hosts files and allow connections to hosts with
changed hostkeys to proceed, subject to some restrictions.

In order to add a list of servers automatically we can do below:
Add servers IP in file servers-list
The IPs should be added in below format.
Output of cat servers-list
123.1.2.3
124.1.2.4
123.1.2.5

Change above IPs by replacing yours.
Below command will add all servers from the list.
ssh-keyscan -H "`cat servers-list`" >> ~/.ssh/known_hosts


SD card content not showing up in Ubuntu I have burned OS image (.img) into a new SD card (Sandisk 16GB) use LibreELEC USB-SD creator tool on Ubuntu laptop. I assume I don't need to format SD card before writing. Then I tried browse SD card for files, but Ubuntu not able to show the contents of sd card. It only show space available on SD card.
I tried also to browse SD card on Windows PC, but it don't recognized it, when click on SD card drive icon, Windows show alert that SD card first need be formatted. There is also listed volume 537 MB, it can't be opened, when try click to mount it, error message is displayed:

Unable to access "537 MB Volume"

Error mounting /dev/mmcblk0p1 at /media/venitek/3463-3434: Command  line 'mount -t "vfat" -o "uhelper=udisks2,nodev,nosuid,uid=1000,shortname=mixed,utf8=1,showexec,flush"
"/dev/mmcblk0p1" "/media/venitek/3463-3434"' exitedd with non-zero exit status 32: mount: /dev/mmcblk0p1: can't read superblock

Edit: here is output fdisk -l command:

$ sudo fdisk -l
Disk /dev/sda: 465.8 GiB, 500107862016 bytes, 976773168 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disklabel type: dos
Disk identifier: 0xb45e11b8

Device     Boot     Start       End   Sectors   Size Id Type
/dev/sda1            2048    718847    716800   350M de Dell Utility
/dev/sda2          718848   7010303   6291456     3G  c W95 FAT32 (LBA)
/dev/sda3  *      7010304 960389119 953378816 454.6G 83 Linux
/dev/sda4       960391166 976771071  16379906   7.8G  5 Extended
/dev/sda5       960391168 976771071  16379904   7.8G 82 Linux swap / Solaris

Partition 4 does not start on physical sector boundary.

Disk /dev/mmcblk0: 14.9 GiB, 15931539456 bytes, 31116288 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: dos
Disk identifier: 0xbe03dce7

Device         Boot   Start     End Sectors  Size Id Type
/dev/mmcblk0p1 *       8192 1056767 1048576  512M  c W95 FAT32 (LBA)
/dev/mmcblk0p2      1056768 1122303   65536   32M 83 Linux

I tried also commmand dd if=/dev/sdb1 bs=1024k count=10 | less, it show just vertical list of tilde ~ chars, not sure if it's readable.

The ability to write .img or .iso files is built into Ubuntu, don't use some weird third party tools. Either just double-click on the .img file in Nautilus (the file browser), or right-click on it and then select to pass it to the image writer. Select your SD card as target and choose to "recover" the image.

If your Windows can read the resulting USB or not depends on the file system that is written to the card.

Please follow the below steps and it should fix this for you.

Remove any SD card that are inserted into the SD card reader.
Launch the terminal.
Run the following command to reinstall udisks2.

sudo apt-get install --reinstall udisks2

You will have to enter root password to complete reinstallation.
After the installation is complete, close the terminal and reboot the PC.
Try inserting a SD card into the SD card reader slot. It should work now.


How to access SVN from other machines I have limited network knowledge, I followed this guide to install subversion on a ubuntu system with the latest version :

http://www.howtogeek.com/?post_type=post&p=195

I've restarded the apache server and the computer is hooked on the school's network. How do I figure out the svn url? I think that right now it can't map to a domain so it's using the localhost.

To make it simple, what I want to do is write the svn url on another machine to access the data of the ubuntu server.

First, Make sure everything's working locally:
 - Open a web browser on the system where you set up subversion
 - According to the tutorial provided, your svn-repository should be available under "/svn", so goto http://localhost/svn and check, if you can see the repository contents or the popup asking to provide username and password
 - If you get some error you probably have done something wrong in your svn installation. In this case, please check again your tutorial (BTW, there's also an ubuntu help page for subversion: https://help.ubuntu.com/community/Subversion)

Second, if your can see your svn contents, you need to figure out the IP address that is given to your system:
 - Open up a terminal an run

ifconfig

- Search for an entry beginning with "eth", e.g. eth0. If your computer has more than one network card, you might find more entries here. I'll come back to that later
 - Look for an entry called "inet addr" and take the numbers that are directly displayed after, e.g. something like 192.168.1.15. That's the IP address of your computer in your school's network.
 - That's already enough for a first try, so open a web browser on another computer and point it to http://[the ip address you just figured out]/svn
For the sample IP address I used above, this would be http://192.168.1.15/svn

Remarks:
 - IP address may change, depending how your schools network is configured. So try to get the fully qualified domain name (FQDN) of your svn server. This should not change. (It's just the same as on the internet, e.g. instead of typing one of google's IP addresses, it's easier to type google.com). To find out your FQDN, type

nslookup the ip address you just figured out

on any computer of your schools network
 - Look for the entry "name =" at the bottom. That's your FQDN! Now enter that name instead of the IP address in your browser
 - If you have more than one network card in your computer, you may find more than one eth entry (e.g. eth0 and eth1). If you can find IP addresses behind the "inet addr" both entries, the easiest way would probably be to try all of them the way I described!
 - If you experiencing difficulties or problems when trying to get the IP address or the FQDN, or if you got your IP but you're not able to connect to the subversion server from another machine, it's also a good idea to talk to a system administrator at your school. I'm sure, they'll be able to help you with that!

http://www.james-bennet.com/svn.htm

I did this myself and documented it.


Disable gnome-panel launcher (Alt+F2) I'm running Unity and a gnome-panel panel at the bottom at the same time. Is there a way to disable the gnome-panel's  launcher? At the moment, both Unity's and gnome-panel's launcher pop up when I press Alt+F2.

Thanks in advance!

You can disable Gnome Panel launcher using Gnome lockdown feature.

Execute this command:

gconftool-2 -t bool -s /desktop/gnome/lockdown/disable_command_line true

(You can inspect this option using gconf-editor) While Unity will ignore this setting, Gnome launcher will be effectively disabled.


Coolers noise at Dell XPS 15 9550 without heavy loading I have a Dell XPS 15 9550. Succesfully installed Ubuntu 16.04 alongside Windows. All is fine, but coolers works on max without using something heavy. At Windows all is ok. I read that this is known problem at laptops with Linux, but no one tutorial doesnt helps me. May be here someone know how to resolve this problem?

This should solve it, did it for me. The culprit is gvfsd-smb-browse process.

Add the statement below to [global] section of your /etc/samba/smb.conf

name resolve order = wins lmhosts bcast

https://itsfoss.com/fix-gvfsd-smb-high-cpu-ubuntu/


How to insall mysql-proxy in ubuntu 16.04? I have tried installing using sudo apt-get as below but got error

majid@K53SC:~$ sudo apt-get install mysql-proxy
Reading package lists... Done
Building dependency tree
Reading state information... Done
E: Unable to locate package mysql-proxy

Tried to download linux-Genereic (https://downloads.mysql.com/archives/proxy/) and extract and run; but mysql client can't connect to server via proxy:

Terminal 1:

$ mysql-proxy --proxy-address=127.0.0.1:4040 --proxy-backend-addresses=localhost:3306 --proxy-lua-script=/home/majid/Documents/first_example.lua --plugins=proxy
2016-11-01 20:34:20: (critical) plugin proxy 0.8.5 started
we got a normal query: select @@version_comment limit 1

Terminal 2:

majid@K53SC:~$ mysql -h 127.0.0.1 -P4040 -u root -ppassword
mysql: [Warning] Using a password on the command line interface can be insecure.
Welcome to the MySQL monitor.  Commands end with ; or \g.

and it stays there; nothing happens.

so what is correct way to install and use mysql-proxy in Ubuntu 16.04?

Regards

Edit:

As per David Foerster's comment I have downloaded the Deb package Trusty, and installed.
I get now as below:

Terminal 1:

$ mysql-proxy --proxy-address=127.0.0.1:4040 --proxy-backend-addresses=localhost:3306 --proxy-lua-script=/home/majid/Documents/first_example.lua --plugins=proxy

Terminal 2:

$ mysql -h 127.0.0.1 -P4040 -u root -ppassword
mysql: [Warning] Using a password on the command line interface can be insecure.
ERROR 1043 (08S01): Bad handshake

The mysql-proxy project seems to be abandoned since over 2 years which is the likely reason for its removal from the Xenial repositories. It's probably incompatible with newer MySQL releases.

The 3-years-old INSTALL notice recommends version 5.1.x while the Xenial repositories include MySQL 5.7 and no older release.

MariaDB addressed this with MaxScale MySQL proxy. It's available for download on their website. Additionally if you use AWS you can run wrapped up MaxScale from the Marketplace as SQLSplitter https://www.youtube.com/embed/IGkEdceW0so


Video playing is slow on 12.04 I started using Ubuntu a very short time ago, and it was working perfectly! I upgraded to 12.04 yesterday, and today I realize that everything is running slow. For example, video streaming online, from sites such as Youtube is not working correctly, audio and video breaks constantly. I have a 64 bit system, with a Intel® Core™2 Duo, 2.10GHz × 2 . I don't know what more to add.

I tried free -m on the terminal, it returned that I had only 524MB free from 3858MB. All that i have running at this point is Mozilla Firefox.

From your brief description of videos playing slowly in Firefox, it's possible that you no longer have a genuine (proprietary) version of the Adobe Flash Player installed.

This is a really easy way to do that:

sudo apt-get install ubuntu-restricted-extras

This installs Adobe Flash Player along with a bunch of other things that are not open source, but you're likely to benefit from such as non-free codecs for Ubuntu's built-in video players.

If you find an error installing this package, it's possible that you don't have the non-free repositories enabled.  You'll want the top four of these checked under Software Sources in your system configuration.

I experienced a similar problem. I found the solution in https://askubuntu.com/a/131040/1736.

See the post entitled in "tl;dr"


How to install python-uno package in Ubuntu 14.04? I got the following error while installing python-uno:

Package python-uno is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source
However the following packages replace it:
  libreoffice-script-provider-python

E: Package 'python-uno' has no installation candidate

Since it is asking for libreoffice-script-provider-python,

 sudo apt-get install libreoffice-script-provider-python

This will install python3-uno package, and the interface for LO to use UNO.

open the terminal and run the following command...

sudo apt-get install libreoffice python-genshi python-cairo python-lxml python-setuptools
sudo apt-get install libreoffice-script-provider-python

easy_install uno


How to clear Skype chat history? It seems that in the Window version of Skype, there is an option to clear chat history. It is supposed to be Tools > Options > IM & SMS > Clear history button but effectively nothing similar is here:

This option is not present on the version that come with my Ubuntu 13.04. In the privacy settings there is this option:

and somewhere in the Skype forum it is said that changing that to Disable History and then restarting Skype will get rid of the chat history. Tried that, don't work.

Searching a bit I found that you have to eliminate some file in the Skype directory; I did that from the directory I have:

cd $HOME/.Skype/my_skype_name/
rm chat*.dbb user*.dbb

...still no go. Before I get rid of all the .Skype directory and re-configure all Skype, is there anyone that know how to do it? The content of the directory is:

alert2048.dbb       chatsync             httpfe           msn.db-journal
alert4096.dbb       config.lck           keyval.db        msn.lock
bistats.db          config.xml           keyval.lock      profile16384.dbb
bistats.db-journal  contactgroup256.dbb  main.db          sms512.dbb
bistats.lock        dc.db                main.db-journal  transfer256.dbb
call256.dbb         eas.db               main.lock        voicemail
callmember256.dbb   eas.db-journal       msn.db           voicemail256.dbb

Removing all other *.dbb doesn't work, either.

Lesson: never put sensitive data on a Skype chat.

I was instructed by Skype customer service to do following:

Go to Options -> Privacy and set "Keep chat history for.." to Disable History, then sign out & sign in.
Go to $HOME/.Skype/my_skype_name/ and delete only main.db. Sign out & Sign in.

It worked.

Found this, Helpful, I guess:
http://adminspot.net/topic/5042-removing-skype-chat-history-linux-ubuntu-should-work-for-other-distros-as-well/

Quote:
"Found this on the net thanks to the original poster

The current Linux version for skype 2.2 beta is lacking a delete history button
and there does not seem to be a bug ticket so, If you want to clear your chat
history.

With Skype not running open your home folder select show hidden files
find the one .skype rename it to .skypeold (or what ever).

Once you have logged back on skype you can delete the renamed folder

Bear "


Apt update error - "An error occurred during the signature verification" (Chrome) When updating I got the following message:

W: An error occurred during the signature verification. The repository is not updated and the previous index files will be used.
GPG error: http://dl.google.com/linux/chrome/deb stable Release:
The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 6494C6D6997C215E
W: Failed to fetch http://dl.google.com/linux/chrome/deb/dists/stable/Release.gpg
The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 6494C6D6997C215E
W: Some index files failed to download. They have been ignored, or old ones used instead.
Reading package lists... Done
Building dependency tree
Reading state information... Done
Calculating upgrade... Done

I'm on Ubuntu 16.04 and currently using Chrome 60.0.3112.90. Any suggestions? I'm also trying to install libimobiledevice but apparently the system is not reading the repository where I just added the PPA as I can't install it. Thanks in advance for any help.

Apparently Google changed key for Chrome Linux repo. You can fix it by importing new repo key from Google:

wget -q -O - https://dl-ssl.google.com/linux/linux_signing_key.pub | sudo apt-key add -

Now you should be able to update the system without any errors.

This works for APT-based distros: Debian, Ubuntu and derivatives (Linux Mint, Kubuntu, Xubuntu, Lubuntu, etc.)

For more info and a fix for RPM-based systems (Fedora, CentOS, openSUSE, etc.) see official Google Linux repositories page.

This should fix it for you

wget -q -O - https://dl-ssl.google.com/linux/linux_signing_key.pub | sudo apt-key add -

See:
Google Chrome PPA upgrade invalid signature


How do I remount a filesystem as read/write? I'm trying to mount an hfsplus filesystem in a Xubuntu 12.04 VM (kernel version 3.2.0-23-generic) but when I type mount -o remount,rw /dev/sdb3 in command line it returns not mounted or bad option. Any help would be appreciated.

The correct syntax is:

sudo mount -o remount,rw /partition/identifier /mount/point

Where mount/point is /partition/identifier's corresponding mountpoint, as listed by the following command:

mount -v | grep "^/" | awk '{print "\nPartition identifier: " $1  "\n Mountpoint: "  $3}'

For example, say that the above command gives this:

Partition identifier: /dev/sda1
 Mountpoint: /

Partition identifier: /dev/sda2
 Mountpoint: /boot

Partition identifier: /dev/sda3
 Mountpoint: /test

The following would be the correct syntax. (We start by unmounting it, if it's already mounted.)

sudo umount /test
sudo umount /dev/sdb3
sudo mount -t hfsplus -o rw,remount -force /dev/sdb3 /media/untitled

If you have dual boot Windows and Ubuntu, careful to shut down Windows completely. If you sleep or hibernate, then Ubuntu can only mount as read only.


SSH into Ubuntu over Serial port I have connected to my Ubuntu box using its serial port on windows(using putty connection is working fine.)

According to the question https://serverfault.com/questions/892892/how-to-use-ssh-over-serial-without-using-pppd-or-how-to-transfer-tcp-over-ser,
it appears I should be able to SSH into the machine over a serial port.

What packages are needed or alternatively how do I set this up?

http://patrickst.blogspot.com/2011/11/tcpip-over-slip-on-gnulinux-ubuntu.html

https://learn.adafruit.com/welcome-to-circuitpython/advanced-serial-console-on-mac-and-linux

SSH is meant to accept (secure) connections over TCP/IP. To use SSH over a serial port, you'd need something acting as a TCP client and "forwarding" data from/to the serial port, such as socat.

This (source) should be enough, assuming /dev/ttyS1 is your serial port, 115200 is the desired baud rate ("Speed" when using PuTTY for Serial connection) and you have sshd listening on port 22 (which is the default):

socat -d -d tcp:127.0.0.1:22 file:/dev/ttyS1,b115200

-d -d, according to the manual:

  Prints fatal, error, warning, and notice messages.

I have not tested this, as I do not have a serial port at the moment.

If you just need login and run shell commands over the serial port, you can run getty, agetty or even screen on a serial port.
The SerialConsoleHowto guide is outdated, but this answer might help.

Download putty.exe from here.
You should know the number of COM port and the baud rate of the port.

If you don't know both, try to fix speed at 115200 then try COM1 to COM8.

Start putty.exe

Choose "Serial" in "Connection type"
Set baud rate in "Speed"
Set COM port name in "Serial line"
Press "Open"


How can I measure the execution time of a terminal process? I'm trying to measure the execution time of a process that I call via the command line (i.e., I want to find out how long it takes to for the process to finish). Is there any command that I can add to the command calling the process that will achieve this?

Add time before the command you want to measure. For example: time ls.

The output will look like:

real    0m0.606s
user    0m0.000s
sys     0m0.002s

Explanation on real, user and sys (from man time):

real: Elapsed real (wall clock) time used by the process, in seconds.
user: Total number of CPU-seconds that the process used directly (in user mode), in seconds.
sys: Total number of CPU-seconds used by the system on behalf of the process (in kernel mode), in seconds.

1) Open bashrc file

gedit ~\.bashrc

2) Find the following text:

if [ "$color_prompt" = yes ]; then
PS1='${debian_chroot:+($debian_chroot)}\[\033[01;32m\]\u@\h\[\033[00m\] :\[\033[01;34m\]\w\[\033[00m\]\$ '

3) And replace with:

if [ "$color_prompt" = yes ]; then
PS1='${debian_chroot:+($debian_chroot)}\[\033[01;32m\]\u\[\033[00m\] [\d|\t]:\[\033[01;34m\]\w\[\033[00m\]\$ '

4) Restart terminal to check.

Sample output in terminal


How do I restore Déjà Dup backups without Déjà Dup? So I'm trying to restore my backup files with Déjà Dup, however, each time I enter in the correct password, it keeps asking for it over and over again.

This seems to be a bug, and I have found a couple of bug reports already reported on this issue. I am currently using 12.04, it did not also work in 12.10.

Is there any other software that can restore these backups?

Déjà Dup is a (very useful) frontend to the duplicity command line program.

There are instructions on using it to restore backups on the GNOME wiki:

Apps/DejaDup/Help/Restore/WorstCase - GNOME Wiki!

You can't. You need to reinstall Deja dup manually or google another program to restore your backup.


What happens when I click "Send" after Ubuntu experienced an internal error? I am using Ubuntu 18.10. Sometimes, when some program has just crashed, a window pops up saying the following:
"Sorry, Ubuntu 18.10 has experienced an internal error. Send problem report to the developers?"
Then there are three buttons: "Show details", "Don't send" and "Send".

If I click "Show details" then it does show details nicely, for example that "gjs-console crashed with SIGABRT" and lots of other info. It seems like a good idea to send this to the developers, so I click "Send". Then the window is closed. I do not get any confirmation that anything was actually sent. I would have liked to get some confirmation like "OK, problem report sent successfully" or something but there is no such confirmation so I am a little worried that something went wrong when I clicked the "Send" button.

My questions:

Is anything actually sent to the developers?
Is there any way for me to verify that something was actually sent?
Can I even see the details of the resulting automatically generated problem report in a public bug tracking system somewhere?

EDIT: according to an answer here: How can I find my Bug-report on launchpad that I submitted from the Desktop? it should be possible to see the resulting bug report by going to https://bugs.launchpad.net/~/+reportedbugs but that does not work for me -- that page just says "There are currently no open bugs."
So I am still not sure if any problem report was really sent and if so, where did it end up.

EDIT 2: this seems related also: How can I track a bug that caused a crash and was reported via apport / whoopsie? but after reading that I still don't know how to verify if a problem report was really sent.

EDIT 3: in /var/log/syslog there are a few lines mentioning "whoopsie" saying for example "Uploading /var/crash/_usr_bin_gjs-console.1000.crash." and "Sent; server replied with: No error" which sounds good. Also, the file /var/crash/_usr_bin_gjs-console.1000.crash does seem to contain all the collected error report info.

If I am right, the information lands here:
https://errors.ubuntu.com/

They do a lot of thinking work:
https://wiki.ubuntu.com/AutomatedProblemReports

It seems the best solution so far is Apport with whoopsie. But the Documentation says disabled by default.
https://wiki.ubuntu.com/Apport

I think this is more a concept, but looks like your Idea (tell the User an ID) is already covered:
https://wiki.ubuntu.com/ErrorTracker

All together the Error Reports are collected and one main issue to solve is to automatic group the entries. Beside the issue with sensitive data in the report, but this is less fun.

Usually, the system collects system logs, timestamps when an error occurred and additional information regarding which module failed.


How can I change or hide the ~/snap directory? I'm not particularly fond of apps cluttering my $HOME directory with their own files or directories. It's rarely a problem, because most apps have the courtesy to hide their data by prefixing it with a dot or conforming to the ~/.config standard. But not snap.

Q1: Have I misunderstood this directory?  Is ~/snap really a directory which I'm supposed to enter and access on a daily basis on a par with ~/downloads, ~/pictures, ~/work, etc?

Q2: In any case: Can I move it e.g. ~/.snap?  I can't find anything like /etc/snap, /etc/default/snap, or ~/.config/snap to tweak things. I tried export SNAP_USER_DATA=$HOME/.snap but it didn't work.

So..

A1: No; ~/snap is not supposed to be accessed manually on a daily basis; it's a  settings directory.

A2:  No; ~/snap cannot be changed; it's cluttering your home dir by design.

However
there is already a bug report on this issue, but it's currently only prioritized as wishlist. If you're affected by this bug (and you are if you have a ~/snap =) then let the kind developers know, and encourage them to fix the bug by raising its significance:

Go to the bug report
Login to Launchpad (top right corner).
Click This bug affects N people. Does this bug affect you? (near top left)
Click Yes, this bug affects me

In the meantime do like @Rinzwind suggests and simply hide the directory from Nautilus by typing this in a shell:

echo snap >> ~/.hidden

Alternative get completely rid of snap by downright uninstalling everything related snap, as described here.

I think I actually have a solution for this! Well kinda. There's a Nautilus extension called "Nautilus Hide" that will hide files and folders without changing their name. It basically writes the name of the folder to a file that Nautilus uses to see if a folder should be hidden or not.

Works like a charm!

https://github.com/brunonova/nautilus-hide


Is there any useful software for filling out pdf-forms other than Adobe Reader? I have some pdfs that allow me to fill out forms and which also have a print button which is invisible on the printed output. At the moment I have to use Adobe Reader for this, but I'd prefer not to.

I tried Foxit Reader, but with it I can't even fill out the forms. With the standard pdf reader of Ubuntu 10.10 I can fill out the forms, but can't use the print button and when I try to print the document from the menu, the print button shows up in the printed copy, which is useless.

Are there any other pdf-readers which would allow me to fill out forms and use the button in the pdf to print, which would also keep the button invisible in the printed output?

Evince Document Viewer (Installed by Default)

Here is a screenshot of an editable PDF file being filled in my desktop for you to see Evince Document Viewer in action.

Like this, there should be some other good PDF readers that will allow you to perform this task, but this is working for me and it is really lightweight.

Good luck!

You can use "Adobe Acrobat Reader DC" along with wine although Adobe discontinued their PDF reader software for Linux several years ago. It works perfect for me.

First install wine and winetricks

sudo apt install wine-stable winetricks

Prepare wine to receive Acrobat Reader DC installation:

winetricks mspatcha

Download the latest version of Adobe Reader for Windows 10 from official site http://get.adobe.com/uk/reader/otherversions/

A file with extension exe will be downloaded. (AcroRdrDC1801120040_en_US.exe)
Now install that exe file in wine:

wine AcroRdrDC1801120040_en_US.exe

(Use the same name as that of downloaded exe file)

Click Install button.

Wait until the setup is completed and click on Finish.

Now search for Acrobat Reader in applications menu and open it.

Select Always open with Protected Mode Disabled. (Adobe Reader DC runs in protected mode by default to provide an added layer of security)

Accept Licence.

Now you can open your files using Acrobat Reader DC even on Ubuntu.


Unable to install .deb files I am recently change from Kubuntu to Xubuntu. I think some files might be deleted. I am trying to install Vlc Player and other .deb packages it throws following error. Please help

Error:

root@Aravinth:/home/aravinthan/Softwares/Players# sudo dpkg -i vlc-media-player-2-    1-4-es-en-br-fr-de-it-cn-ubu.deb
(Reading database ... 312909 files and directories currently installed.)
Preparing to unpack vlc-media-player-2-1-4-es-en-br-fr-de-it-cn-ubu.deb ...
Unpacking vlc (2.1.4-1) over (2.1.4-1) ...
dpkg: dependency problems prevent configuration of vlc:
vlc depends on vlc-nox (= 2.1.4-1).
vlc depends on libtar0.
vlc depends on libvlccore7 (>= 2.1.0).

dpkg: error processing package vlc (--install):
dependency problems - leaving unconfigured
Processing triggers for mime-support (3.55ubuntu1.1) ...
Processing triggers for bamfdaemon (0.5.1+14.10.20140925-0ubuntu1) ...
Rebuilding /usr/share/applications/bamf-2.index...
Processing triggers for desktop-file-utils (0.22-1ubuntu2) ...
Processing triggers for gnome-menus (3.10.1-0ubuntu2) ...
Processing triggers for man-db (2.7.0.2-2) ...
Errors were encountered while processing:
vlc
root@Aravinth:/home/aravinthan/Softwares/Players#

and i am trying to install vlc-nox and it requires these following lib. what can i do?

root@Aravinth:/home/aravinthan/Softwares/Players# sudo dpkg -i vlc-nox_2.1.4-1_amd64.deb
Selecting previously unselected package vlc-nox.
(Reading database ... 312909 files and directories currently installed.)
Preparing to unpack vlc-nox_2.1.4-1_amd64.deb ...
Unpacking vlc-nox (2.1.4-1) ...
dpkg: dependency problems prevent configuration of vlc-nox:
 vlc-nox depends on liba52-0.7.4.
 vlc-nox depends on libass4 (>= 0.9.7); however:
  Package libass4:amd64 is not installed.
 vlc-nox depends on libavcodec54 (>= 6:9.1-1) | libavcodec-extra-54 (>= 6:9.13); however:
  Package libavcodec54:amd64 is not installed.
  Package libavcodec-extra-54 is not installed.
 vlc-nox depends on libavformat54 (>= 6:9.1-1); however:
  Package libavformat54:amd64 is not installed.
 vlc-nox depends on libavutil52 (>= 6:9.1-1); however:
  Package libavutil52:amd64 is not installed.
 vlc-nox depends on libbasicusageenvironment0; however:
 vlc-nox depends on libcddb2; however:
 vlc-nox depends on libgnutls28 (>= 3.2.10-0); however:
  Package libgnutls28:amd64 is not installed.
 vlc-nox depends on libgroupsock1; however:
 vlc-nox depends on libkate1 (>= 0.3.0); however:
 vlc-nox depends on liblircclient0; however:
 vlc-nox depends on liblivemedia23; however:
 vlc-nox depends on libmodplug1; however:
 vlc-nox depends on libpostpro
dpkg: error processing package vlc-nox (--install):
 dependency problems - leaving unconfigured
Processing triggers for man-db (2.7.0.2-2) ...
Errors were encountered while processing:
 vlc-nox
root@Aravinth:/home/aravinthan/Softwares/Players#

what's my Problem?

Maybe you need gdebi, it can help you auto-install what the dependences when you install .deb.

First, you should install it
sudo apt-get install gdebi

then, you can
sudo gdebi xx.deb


How do I disable the fourth button on an Apple Mighty Mouse? I have an Apple Mighty Mouse, but it's been banged up a bit. The side buttons (4th buttons) are way too easily pressed. When I'm using Firefox, the 4th button can accidentally click and I'd go back one page, which can be really aggravating. How can I disable the 4th button (on either Firefox or Ubuntu) without getting any new hardware?

Those buttons (forward and back) drive me crazy too! Here's what worked for me:

Open a terminal (CtrlAltT by default),  and run:

$ xev | grep -A2 ButtonPress

This will pop open a window. Move the mouse into that window, and press the button(s) that you wish to disable. Look at the third line for each button-press, which will look something like:

ButtonPress event, serial 37, synthetic NO, window 0x4000001,
    root 0x2f2, subw 0x0, time 355888399, (114,122), root:(114,174),
    state 0x10, button 8, same_screen YES

Note the number after button. For me, the back/forward buttons were numbers 8 and 9.
Close the xev window, and create/edit an .Xmodmap file in your home directory:

$ cat >> ~/.Xmodmap
! Disable buttons 8 and 9
pointer = 1 2 3 4 5 6 7 0 0

In your case, to just disable button 4, you'd want pointer = 1 2 3 0 5 6 7 8 9.
 Press CtrlD to return to the prompt, then test it out:

$ xmodmap ~/.Xmodmap

This will load the .Xmodmap file and your button(s) should be disabled immediately.

Most desktop environments should load this file automatically next time you log in, making the change permanent.

This is an old question, but I hope this answer helps someone.

its simple. just follow these steps:

Go into system settings found in your dock or by searching after pressing Alt-F2
Go into "mouse and touchpad" (or something similar, thats just what it says for me)
Go change the setting you want


Linker error: /usr/bin/ld: cannot find -lgcc_s I am trying to compile symlinks (tar.gz-file), which is a very small tool with one line for compilation:

gcc -Wall -Wstrict-prototypes  -O2 -N -s -o symlinks symlinks.c

which gives the error

....
/usr/bin/ld: cannot find -lgcc_s
/usr/bin/ld: cannot find -lgcc_s
collect2: ld returned 1 exit status

The output of

/sbin/ldconfig -p | grep libgcc

is

libgcc_s.so.1 (libc6) => /lib/i386-linux-gnu/libgcc_s.so.1

and trying to include the mentioned directory directly

gcc -Wall -Wstrict-prototypes -L /lib/i386-linux-gnu/  -O2 -N -s -o symlinks symlinks.c

produces the same error.

Three questions:

Why does it not work with the first command, as the lib seems to be in the search path
Why does including the path itself does not help
How to fix this?


How can I disable bluetooth auto connect for specific devices? I have bluetooth headsets and speakers that I connect to different computers. These bluetooth devices will connect to the last computer they were connected to when powered on, but I'd like to disable that for these specific devices that we use among different computers. As it stands, it is quite annoying to have to find the computer the device auto connected to and manually disconnect before being able to connect to the new computer. Is it possible to disable auto connect for specific devices? And if so, how would I do that?

User Elder Geek provided a solution here  that looks like it may work:

Install blueman bluetooth manager from the Software Center or with this command:
sudo apt install blueman

Note: Installation requires the universe repository to be enabled in your software sources.

Open Blueman from the Dash.

Select the headset from the list

Click Setup...

A window will open up, on that window, check Do not connect.

Click the Next button.

In console type one by one:
bluetoothctl
devices

to get the address of the device you want.
Create a text file anywhere on your computer with any name.
(Try to stay away from root or certain system folders, you can use home or desktop)
#!/bin/bash
sleep 5; echo "disconnect XX:XX:XX:XX:XX:XX" | bluetoothctl

Type that in the text file and save.
(XX:XX:XX:XX:XX:XX is device address)
In properties of the file, or in console, make the file executable.
In system settings, add the file to autostart.
(Or in console, use whatever you are using to autostart programs or scripts.)
In the code above;
#!/bin/bash

turns the file into an executable script.
sleep 5

makes it wait for 5 seconds.
echo

Writes the command next to it.
disconnect XX:XX:XX:XX:XX:XX

disconnects from the device, whose address is specified as XX:XX:XX:XX:XX:XX
bluetoothctl

is the bluetooth environment command to configure bluetooth devices.
If 5 seconds is not enough, use a bigger number.
If you change the disconnect command to connect, you can use the same script to auto connect bluetooth devices.


How do I make firefox hello recognize my usb webcam? I have a labtec usb webcam. It works well with cheese. It doesn't work with firefox hello.

lsusb output

Bus 002 Device 004: ID 093a:2626 Pixart Imaging, Inc.

It looks like you need to add a rule to allow the detected device to operate

sudo nano /etc/udev/rules.d/10-local.rules

alternately you can use gedit or vim

ADD this piece of text with the appropriate bus, Vendor ID and Device ID
and your hardware will be up and running.. You can enable the rules yourselves or you may want to reboot..


How to 'Expo' One Big Wall with Dual Monitors With Dual Monitors, when I use the Expo, it clones repeating itself in each monitor. With 10.10 I solved this with the option 'One Big Wall' but this doesn't work on 11.04

I have a nvidia 560Ti with proprietary drivers.

Let's have some fun here.... I just read on some sites, and I just got some fix. I didn't try it yet because have no testing box.

You need to install a package from the new PPA (which are you going to insert it into your ubuntu).

sudo add-apt-repository ppa:disper-dev/ppa

sudo add-apt-repository ppa:nmellegard/disper-indicator-ppa

sudo apt-get update

sudo apt-get install disper disper-indicator

After the installation completed successfully, run this command from the terminal

disper -e

It will detect the resolution automatically and extend the desktop, without cloning them. I hope this guide will help you. But if this way is not working, you might try the second one....

The second directly use the system that already pre-installed in the machine called xrandr. You might want to use the graphical one, called grandr

sudo apt-get install grandr

For me, grandr is very useful to set the custom resolution for the each of the monitor. And then, to activate the extended view, you can use this command line. Insert it into your terminal and it will work like a charm....

xrandr --output VGA1 --auto --right-of LVDS1

Assume that your are using the LVDS display (from the laptop) and the VGA display from the connected Monitor. How to know my monitor? Easy, by using the xrandr -q directly from your terminal. This my output :

If the terminal shows VGA1 and VGA2, just replace my command line above. And of course, feel free to examine with the command line given. Maybe it is fun (I guess)

Psst : I've already tried this with Ubuntu with the LXDE and XFCE environment for the second opinion. For the first one, I didn't try yet because I have no nVidia-powered box to test on. Enjoy.

Erm.... for the KDE users, don't worry because you can set the extended diplay directly from the System Setting.


Black screen if no DVD drive is present I have used an external USB-attached DVD drive to install Kubuntu 14.04 Beta 2, 64bit edition on an older HP Mini, without any problem (standard installation, auto-partition the hard drive, standard Plasma Desktop). Everything works as long as the DVD drive is present during boot. If I boot without the DVD drive (which is the normal mode for a portable device), I get the infamous black screen with mouse pointer. The KDE boot splash screen shows up, but before the last symbol (the KDE symbol) comes fully up, the screen slowly turns to black.

I can get a terminal with CTRL+ALT+F1, but if I do startx, I eventually get to the same black screen. Curiously, the guest account works (after a fashion), albeit with a somewhat mangled Plasma/Netbook-like desktop. This (and the fact that simply the presence of an optical drive fixes the problem) I take to mean it's not a driver problem, but probably is an issue with KDE?!?

I have spent a lot of time googling and trying various solutions (upgrading the system, doing a systems restore from grub, moving ~/.kde and let KDE rebuild, ...) but it seems that other people have not had this particular problem, or I am not asking the right question.

Any help is appreciated. I will gladly supply any further information for diagnostics.
/etc/fstab is identical with and without the DVD drive.

I just had the same problem with different hardware (samsung n130, 32 bit, Kubuntu 14.04, KDELibs 4.13.3) and could solve the problem with the following steps:

System settings > Workspace behaviour > Workspace
Global options for the Plasma Workspace, changed Workspace type from Desktop to Netbook
Log-off, remove DVD-drive, Log-in (successful, including KDE)
Workspace type had changed to Desktop
after system restart the problem is still fixed


Integrate thunderbird in Gnome 15.10 I'm using gnome shell. Many of the gnome apps (e.g. gnome contacts, the calender in the panel) use the evolution address book/calendar.. How can I tell them to use the data from thunderbird?

I tried evolution for a while, but while it works fine for contacts and calendar, it just is not reliable enough for emails. Is there any way to replace it with thunderbird?

I tried the following now:

# remove evolution packages
sudo apt-get remove evolution evolution-common evolution-data-server evolution-data-server-common evolution-data-server-online-accounts

# install thunderbird
sudo apt-get install thunderbird tunderbird-common thunderbird-gnome-support thunderbird-local-en

I hope I did't miss anything.


About chrome page loading issue I'm a stranger here :)

Actually, I have used Ubuntu as a main OS with my notebook about for a year.

And Chrome has been a my primary web browser. You know, chrome was the best browser for me 2 weeks ago.

Suddenly Chrome's web page loading speed was low and I tried to find that reason many times but failed to do it.

Even though, with more and more googling, I can't take care of it. I removed chrome and re-install it over and over again, that didn't work at all.

Anyway I got to know existence of Chromium that is open source version of Chrome and I installed it. Wow, Chromium works!!!!

Yeah, about a week, Chromium was good for me. But finally, the same situation I mentioned above was brougt about for me.

As a last action to be taken, I use chrome in my virtual machine installed windows 7.
You know, in my guest Os ( win 7) chrome works well. How could it be?

That's all I tried to tell you guys. Anyone can help me?

Try to disable GPU acceleration on settings board.

To fix it:
go to settings.
search for "acceleration" on the search box.
clear the check box on the "Use hardware acceleration when available."
restart it.

It is bug in chromium.
you can see here.

Try to Update The Packages using these commands in terminal (Alt+ctrl+T) ...

sudo rm /var/lib/apt/lists/* -vf

sudo apt-get update


How do I use tree to show the path to filenames containing a particular string? I have got a rather large file system, and let's say that I want to find all the files and directories in a certain area of my file system which contain the String ActionListeener, and to do this I want to use tree. So if I do:

tree ~/ | grep ActionListeener

The result will be:

│   │   │           └── ActionListeener.class
│   │           └── ActionListeener.java

So I now know that these files do exist somewhere a little deeper into my file system, but I have no idea about which folder contains the sub-folder, which contains the sub-sub-folder, and so on, to the files.

So really my question is, how can I get the tree command (by maybe piping the output to something else) to show me the folder and path which leads me to those particular files which contain that String?

OS Information:

Description:    Ubuntu 15.04
Release:    15.04

Package Information:

tree:
  Installed: 1.7.0-3
  Candidate: 1.7.0-3
  Version table:
 *** 1.7.0-3 0
        500 http://gb.archive.ubuntu.com/ubuntu/ vivid/universe amd64 Packages
        100 /var/lib/dpkg/status

Use tree's pattern matching (-P) in combination with --prune:

$ tree
.
├── archlinux-simplyblack
│   ├── angle-down.png
│   ├── archlinux.png
# snip
    ├── reboot.png
    ├── shutdown.png
    └── theme.conf

8 directories, 78 files
$ tree -P 'reboot*' --prune
.
├── maui
│   └── reboot.png
└── maui-dark
    └── reboot.png

2 directories, 2 files

From man tree:

-P pattern
      List  only  those files that match the wild-card pattern.  Note:
      you must  use  the  -a  option  to  also  consider  those  files
      beginning   with  a  dot  `.'   for  matching.   Valid  wildcard
      operators are `*' (any zero or more characters), `?' (any single
      character),   `[...]'   (any  single  character  listed  between
      brackets (optional - (dash) for character range may be used: ex:
      [A-Z]),  and  `[^...]'  (any  single  character  not  listed  in
      brackets) and `|' separates alternate patterns.

--prune
      Makes  tree prune empty directories from the output, useful when
      used in conjunction with -P or -I.  See BUGS AND NOTES below for
      more information on this option.

Try tree -P '<your_regex_or_file_name>' <tree_root_directory> --prune

In your case: tree -P 'ActionListeener' ~ --prune


Why does `at` remove my scheduled events? I set an at scheduler command like

at -f **its_time** 23:57

when in the its_time file I put

libreoffice /home/user/ist_time.odt

I scheduled but the "system" or whatever is removing yourself my at commands.
I check atq and they are there.
But when the time’s up, the at command doesn't execute.

What’s going on?

Read man at. Your at job doesn't have access to your DISPLAY, and libreoffice wants access. If you want to access your display, read man xhost, and add export DISPLAY=:0 to your at job.

Beware: The at environment differs from your interactive environment. I often run (echo "=== set ===";set;echo "=== env ===";env | sort;echo "=== alias ===";alias) in various environments to keep track. I've used this in  at, batch, cron, interactive, interactive ssh, non-gui, ssh and term environments.


How to install erlang in Ubuntu 12.04? Just as the title says, how do I install erlang in my Ubuntu 12.04?

Here is how. Open a terminal and type

sudo apt-get install erlang erlang-doc

You should be able to search the software repository to see if the package you are looking for is in and the repository, and that the version of the software is in the repository.

You can open the terminal with Ctrl+Alt+t, after doing so simply run the commands below:

:~$ apt-cache search erlang

// if erlang exists in the current repository, you can check its dependencies with:
:~$ apt-cache depends erlang

// if erlang is in the repository and its the version you want to install
// gain super-user privileges
:~$ sudo bash

// and install with apt-get
:~# apt-get -y install erlang
:~# apt-get -y install erlang-doc
:~# exit
:~$

I hope this helps!


How do I install a 32-bit proprietary deb on a 64-bit system without causing dependency problems? I know Guitar pro doesn't support 64 bit, but i did get it to work with this command

jeggy@jeggy-XPS:~$ sudo dpkg --force-architecture -i GuitarPro6-rev9063.deb
[sudo] password for jeggy:
Selecting previously unselected package guitarpro6:i386.
(Reading database ... 285729 files and directories currently installed.)
Unpacking guitarpro6:i386 (from GuitarPro6-rev9063.deb) ...
dpkg: dependency problems prevent configuration of guitarpro6:i386:
 guitarpro6:i386 depends on gksu.
dpkg: error processing guitarpro6:i386 (--install):
 dependency problems - leaving unconfigured
Processing triggers for bamfdaemon ...
Rebuilding /usr/share/applications/bamf.index...
Processing triggers for desktop-file-utils ...
Processing triggers for gnome-menus ...
Errors were encountered while processing:
 guitarpro6:i386

And even after i get that error the program perfectly works fine and updating and adding PPA's to the system works great, but when I'm trying to install some other software i get this error:

jeggy@jeggy-XPS:~$ sudo apt-get install elinks
Reading package lists... Done
Building dependency tree
Reading state information... Done
You might want to run 'apt-get -f install' to correct these:
The following packages have unmet dependencies:
 elinks : Depends: libfsplib0 (>= 0.9) but it is not going to be installed
          Depends: liblua50 (>= 5.0.3) but it is not going to be installed
          Depends: liblualib50 (>= 5.0.3) but it is not going to be installed
          Depends: libtre5 but it is not going to be installed
          Depends: elinks-data (= 0.12~pre5-7ubuntu1) but it is not going to be installed
 guitarpro6:i386 : Depends: gksu:i386 but it is not going to be installed
E: Unmet dependencies. Try 'apt-get -f install' with no packages (or specify a solution).

And whenever i write "apt-get -f install" i get this

jeggy@jeggy-XPS:~$ sudo apt-get -f install
[sudo] password for jeggy:
Reading package lists... Done
Building dependency tree
Reading state information... Done
Correcting dependencies... Done
The following packages were automatically installed and are no longer required:
  dconf-gsettings-backend:i386 python-levenshtein python-indicate libav-tools libstartup-notification0:i386
  libxmuu1:i386 libavfilter-extra-2 libbabl-0.0-0 libgegl-0.0-0 libgconf2-4:i386 python-vobject libgtk-3-0:i386
  libpam-cap:i386 python-utidylib libdconf0:i386 python-iniparse python-xmpp libpam-gnome-keyring:i386
  libxcb-util0:i386 python-farstream
Use 'apt-get autoremove' to remove them.
The following packages will be REMOVED:
  guitarpro6:i386
0 upgraded, 0 newly installed, 1 to remove and 7 not upgraded.
1 not fully installed or removed.
After this operation, 84,0 MB disk space will be freed.
Do you want to continue [Y/n]? y
(Reading database ... 286979 files and directories currently installed.)
Removing guitarpro6:i386 ...
dpkg: warning: while removing guitarpro6:i386, directory '/opt/GuitarPro6/updater' not empty so not removed.
dpkg: warning: while removing guitarpro6:i386, directory '/opt/GuitarPro6/Data/Soundbanks' not empty so not removed.
Processing triggers for bamfdaemon ...
Rebuilding /usr/share/applications/bamf.index...
Processing triggers for desktop-file-utils ...
Processing triggers for gnome-menus ...

And now Guitar Pro is deleted.
How can i install Guitar Pro and still be able to install other software afterwards?

Warning:

  The GuitarPro deb is dangerously packaged!

  On a 64-bit system, if you apt-get -f install after trying to install it, apt-get will want to remove the following system critical packages, which can ruin your Ubuntu installation!

The following packages will be REMOVED:
gksu guitarpro6:i386 libgksu2-0 libpam-gnome-keyring sudo ubuntu-desktop
ubuntu-minimal update-manager update-notifier xauth xinit xorg
  sudo? update-manager?? X! What are the developers thinking?!  It also makes apt-get think a bunch of i386 packages are installed when none have been. Here's the full gory pastebin.

Safely Install GuitarPro without apt-get wanting to remove it

I believe the above behavior comes from the deb's dumb dependency on gksu:i386 (which is the graphical root elevation package)
Unfortunately, the only safe way to install this and not have to deal with apt-get's whining is to manually install it and its dependencies. Here's how:

How to manually examine and safely install a binary i386 deb with its dependencies

First, remove the current half-installed packaged with sudo dpkg --remove guitarpro:i386
Now, change to the directory where your deb file is stored. For easy typing let's create a short symlink - my deb called gp6-full-linux-demo-r11100.deb, yours may differ:

ln -s gp6-full-linux-demo-r11100.deb gp6.deb

1. Examine the deb's architecture and dependencies

First, we examine the deb's dependencies without installing it.

dpkg-deb -I gp6.deb shows us:

 new debian package, version 2.0.
size 172147458 bytes: control archive= 75020 bytes.
 375 bytes,    10 lines      control
335109 bytes,  2770 lines      md5sums
Package: GuitarPro6
Version: 6.1.3
Section: non-free/audio
Priority: optional
Architecture: i386
Depends: libc6 (>= 2.1.3), libstdc++6, libasound2, libxml2, libxslt1.1, libportaudio0, libportaudio2, libglu1-mesa, gksu, libssl0.9.8
Installed-Size: 222632
Maintainer: Arobas Music
Description: http://www.guitar-pro.com
Guitar Pro 6, Linux Version.
So this is an i386 application, and all its dependencies are also going to be i386.
The first thing to do is install the ia32-libs i386 compatibility package, if you haven't already:

sudo apt-get install ia32-libs

Let's also copy and paste the package's dependencies in a text file, for later.

2. "Extract" the deb into a tar archive and examine its contents

Let's extract the deb to a tar archive now so we can examine its contents without having to install it:

dpkg-deb --fsys-tarfile gp6.deb > gp6.tar

And open up the File Manager (Nautilus), and mount the gp6.tar as an archive by right-clicking and selecting Open in Archive Mounter; after that you'll see gp6.tar added to the bottom the left sidebar, with an eject icon next to it:

Go to the View Menu for File Manager, and change the Sidebar to the Tree view option instead of Places:

Now expand the gp6.tar tree in the sidebar by clicking on the triangles; repeat for each level until you can see the folder structure of the file:

From the structure, we see that the program's files go into two locations: /opt and /usr/share:

Anything that goes into /opt is self-contained and will not affect anything else on the system.
We see that /usr/share only contains icons/bitmaps, which are harmless.

3. If it's safe, "install" the program by extracting the tar file

Go back to the terminal, and make sure you are in the directory containing the downloaded deb/tar files. Then type:

sudo tar -C / -xvf gp6.tar

This will extract the program files in the appropriate locations, showing you the file names and progress. (Sample Output)

The -C switch tells tar to perform this operation relative to the root directory, not the current directory.

4. Figure out which dependencies are missing with ldd, install them, and rock-and-roll!

Open up the /opt/GuitarPro6 folder in the File Manager:

We see that the executable is called GuitarPro (with the diamond-"gears" icon), and also that a lot of lib-xxxx files are included in the folder.
This is normal for binary-only programs; they try to include the versions of the specific libraries they need, since those may not be available from the repositories of a specific distribution.

Along with these included libraries and the ia32-libs package, most 32-bit dependencies should have been installed. Instead of blindly installing the dependencies we saw in the deb file info via apt-get--which can cause problems-- let's figure out if we're actually missing anything.

Go back to the terminal, and change to the GuitarPro directory with cd /opt/GuitarPro6

Using ldd

Type ldd GuitarPro | grep found, and the output will be libportaudio.so.2 => not found

ldd prints the dependencies (shared libraries) of a program, and whether they exist or not on the system. Here's what the full output of GuitarPro looks like.
To make life easier, we simply filter for the ones that do not exist via grep found.

Here, only the libportaudio2 library is missing. But the dependencies said libportaudio0? (see step 1.) Which is it??

Let's search for the available versions using apt-cache search libportaudio from the terminal.
That's tells us that both libportaudio2 and libportaudio0 packages are available. Let's install the 2 first, with

sudo apt-get install libportaudio2:i386
The :i386 part is very important, since our program is 32-bit. If apt-get asks to replace/remove libportaudio2 and/or other files, that's OK, because some libraries cannot be installed simultaneously in both 32- and 64-bit versions.

Let's double-check dependencies one final time: ldd GuitarPro6 | grep found gives us nothing (that's what we want!)

If you get the error ./GuitarPro: /opt/GuitarPro6/./libz.so.1: version ZLIB_1.2.3.3 not found (required by /usr/lib/i386-linux-gnu/libxml2.so.2) this means that Guitar Pro is using a wrong version of libz, fix this by removing the libz.so.1 file from the GuitarPro6 directory:

sudo rm libz.so.1

Guitar Pro will fall back to the libz version of your system.

Exit the terminal and go back to the /opt/GuitarPro6 folder in the File Manager. Double-click GuitarPro and...

Clean-up the Download folder by deleting the tar file from the File Manager.

5. The launcher shortcut has already been added

Because the package already contained a GuitarPro6.desktop shortcut that was extracted to /usr/share/applications, there is no need to manually create one. It's sitting there in the Launcher:

Try this:

Download from http://www6.guitar-pro.com/en/index.php?pg=download the .deb file but don't install it.

Download and install getlibs
Then:

sudo apt-get install libportaudio0
getlibs -l libportaudio.so.2
dpkg -i –force-all /path/to/GuitarPro6Demo2.deb

Finally, launch it with (ignore errors):

/opt/GuitarPro6/gp-launcher.sh


Chrome won't start from the launcher I have Ubuntu 13.10 64-bit and chrome 64-bit.

I can start chrome from the command line with google-chrome-stable and lock it to the launcher, but when I try to launch chrome from the launcher nothing happens.

What do I have to do to make chrome working with the launcher?

You probably have an old version, or a version with an error, of the .desktop file in ~/.local/share/applications. The "reading priority" of the launcher is:

the local directory for desktop files in in ~/.local/share/applications,
the global directory for desktop files in /usr/share/applications.

That means that if you start the application from the "right" (global) .desktop file, the launcher will check for a local version of the .desktop file on the next occasion and use the contents of that file.

You will have to remove the local .desktop file, log out and in, and lock the icon to the launcher again.

Your Chrome window may be off screen. Try checking your workspace settings.

To see that the process is still there.

In the terminal type:

ps ax | grep -i chrome

In the terminal type:

dconf reset -f /org/compiz/
unity --reset-icons &disown

If the window still is not showing up, you may need to reboot the system so the changes apply.


Is there some way that I can see performance in Ubuntu? I am a new Linux user. In Windows, I used to monitor and sometimes improve my performance by using a software called "Advanced Systemcare". Is there some kind of software like this for Ubuntu? or someway that I can monitor how the things are going?

Thank You!

The Windows architecture is built around a central database called "the Registry" which overtime as programs are added and deleted becomes insanely large and the system bogs down. As such every few years many users find deleting Windows and reinstalling it along with all currently used programs makes things seem 2 to 10 times faster.

Within Linux there is no Registry, and such performance penalties aren't suffered. Hence there is no need for a program like IObit Advanced Systemcare.

If your web browser slows down in Windows or in Linux (or Mac for that matter) because of too many extensions, Google and Firefox have methods of dealing with that differently.

The annoying malware pop-ups you find in Windows web browsers do not seem to occur (to me at least) with Linux web browsers. Free programs you download in Windows often come with embedded pop-up advertising malware that slows down your system. In Ubuntu almost everything is free and  designed to be downloaded via sudo apt-get install, instead of via the web browser.

Like any other system, if you have limited RAM, buying more RAM will speed up Linux. Also if you have an HDD (hard disk drive), spending $100+ on an SSD (solid state dive) will speed things up tremendously.

Your question body is primarily about speeding up the system however your question title is about monitoring system performance. To monitory the system I personally like to use conky but other people have their own preferences.

Here is what my Conky display looks like:

When the image first starts you see what operation looks like under low load. The CPU's have low percentage utilization ~6%. The CPU speed is low ~1300 Mhz.

After opening Google Chrome (with 10 tabs) CPU utilization spikes up across all 8 CPUs to ~40% and the CPU speed jumps to maximum of 3400 Mhz.

Below the CPU information the names of the 10 top CPU consuming programs (processes) appear on my Conky display. Below that are displayed the amount of RAM used (26%) and amount of disk space (really an SSD) used (73%). Below that (but cut off from this picture) it shows the amount of ISP gigabytes consumed for the month. This helps prevent over billing.

If you would like to learn more about Conky I recommend this site: Post your .conkyrc files w/ screenshots

If you are looking for off-the-shelf system performance monitoring tools in general here is one thread: What can replace system monitoring in the top Gnome Panel in Unity?

You will find other system monitoring tools recommended in Ask Ubuntu if you do a search.

Hope this helps.

The ubuntu command "top" is a dynamic real time view of the running tasks and system.  It can sort by CPU or memory


Intel Ethernet not working - *Network UNCLAIMED First time Ubuntu user and already having an issue! My ethernet is no longer working (showing *-network UNCLAIMED). Wonder if anybody can help. Outputs are as below.

sudo lshw - C net:

    *-network UNCLAIMED
    description: Ethernet controller
    product: Ethernet Connection (2) I219-V
    vendor: Intel Corporation
    physical id: 1f .6
    bus info: pci@0000:00:1f.6
    version: 31
    width: 32 bits
    clock: 33MHz
    capabilities: pm msi cap_list
    configuration: latency=0
    resources: memory:ef100000-ef11ffff

lspci -knn | grep Eth -A3; uname -a:

    00:1f.6 Ethernet controller [0200]: Intel Corporation Ethernet Connection (2) I219-V [8086:15b8] (rev 31)
    Subsystem: Gigabyte Technology Co., Ltd Ethernet Connection (2) I219-V [1458:e000]
    Kernel modules: e1000e
    05:00.0 PCI bridge [0604]: Intel Corporation DSL6540 Thunderbolt [Alpine Ridge] [8086:1578]
    Kernel driver in use: pcieport
    Linux ubuntu 4.10.0-30-generic #34~16.04.1-Ubuntu SMP Wed Aug 2 02:13:56 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux

dmesg | grep e100:

    [    0.834386] e1000e: Intel(R) PRO/1000 Network Driver - 3.2.6-k
    [    0.835415] e1000e: Copyright(c) 1999 - 2015 Intel Corporation
    [    0.885478] e1000e: 0000:00:1f.6: Interrupt Throttling Rate (ints/sec) set to dynamic conservative mode
    [    1.799124] e1000e: probe of 0000:00:1f.6 failed with error -2

sudo modprobe e1000e:

no output

To be honest, I'm not sure what else I could pull that would help. The device is also stand-alone which i'm sure doesn't help.

Thanks!

To just help you onto the next step in trying a newer kernel.

You can download the needed packages from multiple places and in multiple ways. One way you could get them is to download them from packages.ubuntu.com You will need this 3 packages for kernel 4.10.0-30-generic:

linux-image
linux-headers-amd64
linux-headers-all
linux-image-extra


How do I create EFI boot partition after it has been created by ubuntu installer in a system running Windows 8.1 pro I am trying to reinstall Ubuntu on my laptop that has Windows 8.1 pro installed on it already. It is asking me to create a separate partition for boot loader code. It is also asking me to go back to the partition menu and correct the error and that if I do not correct this error, boot loader installation will fail later. I already have a partition labelled: /dev/sda2 fat32 /boot/efi which is 104MB in size and 33MB has been used out of it. It labelled that as "Windows Boot Manager". Do I need to delete the OS Partition labelled Ubuntu 14.10 (14.10)? How do I complete the installation?|

You need to correctly identify your EFI System Partition (ESP) and flag it as such in the installer. You do this in the dialog that asks for the filesystem type, IIRC. At one time, the Ubuntu installer called the ESP the "EFI boot partition," but I believe that name has been changed to "EFI System Partition" in the latest (development?) versions of the Ubuntu installer. Note that when you flag the partition in this way, you don't need to explicitly set the mount point to /boot/efi; the installer does that automatically.

It sounds like /dev/sda2 is your ESP, and you've simply set it as a normal FAT partition mounted to /boot/efi rather than setting it as an ESP.

First of all check the partitions in your windows 8.1. There should be unallocated space there available to install Ubuntu Linux. All the empty logical partitions won't be recognise by Ubuntu as  free spaces. There is a primary partitions available to make it as Unallocated space.

Let me know how many logical partitions and primary partitions available in your Laptop?