How do I cherry pick packages from a PPA?

Found one way to do it.

The trick is using two pinning clauses. The first to disallow ALL packages from the PPA and the second to select the ones you want.

So for the example above, I first add the ppa as usual:

$ sudo add-apt-repository ppa:webapps/preview
...
$ sudo apt-get update
...

Now if i run apt-cache policy, it will show me that there's a newer version of chromium-browser available and that it will install with an upgrade because it's in the same priority (500) as my current chromium-browser.

$ sudo apt-cache policy chromium-browser
chromium-browser:
  Installed: 18.0.1025.168~r134367-0ubuntu0.12.04.1
  Candidate: 20.0.1132.47~r144678-0precise1+webapps3
  Version table:
     20.0.1132.47~r144678-0precise1+webapps3 0
        500 http://ppa.launchpad.net/webapps/preview/ubuntu/ precise/main amd64 Packages
 *** 18.0.1025.168~r134367-0ubuntu0.12.04.1 0
        500 http://us.archive.ubuntu.com/ubuntu/ precise-updates/universe amd64 Packages
        500 http://security.ubuntu.com/ubuntu/ precise-security/universe amd64 Packages
        500 http://ppa.launchpad.net/chromium-daily/beta/ubuntu/ precise/main amd64 Packages
        100 /var/lib/dpkg/status
     18.0.1025.151~r130497-0ubuntu1 0
        500 http://us.archive.ubuntu.com/ubuntu/ precise/universe amd64 Packages
E: Unable to parse package file /etc/apt/preferences.d/webapps-preview-pin-400 (1)
$

That's great as far as that package but I don't want the others in this ppa (which also have a 500 priority) to install. Right now if I try to upgrade, I'll get more than just the chromium packages I want from that repository:

$ sudo apt-get upgrade
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages have been kept back:
  bamfdaemon gwibber gwibber-service gwibber-service-facebook gwibber-service-twitter indicator-appmenu libbamf0 libbamf3-0 shotwell
The following packages will be upgraded:
  chromium-browser chromium-browser-l10n chromium-codecs-ffmpeg gwibber-service-identica indicator-messages indicator-status-provider-mc5
  indicator-status-provider-pidgin libindicator-messages-status-provider1
8 upgraded, 0 newly installed, 0 to remove and 9 not upgraded.
Need to get 25.3 MB of archives.
After this operation, 5,034 kB of additional disk space will be used.
Do you want to continue [Y/n]?

So what I can do is tell  apt that I want all the packages in that ppa, webapps-preview in this case, to have a lower priority except the ones with "chromium" in their name. The mechanism for this is pinning a package

I create a file in /etc/apt/preferences.d/ with two clauses. The first one says give all the packages in the webapps-preview ppa a lower priority than the regular one (so that they are not preferred even if they have a higher version number. The second clause partly overrides the first by saying give the packages in that ppa  with "chromium" in their name the same priority as other packages so that it will get installed (by it having a higher version number).

$ cat /etc/apt/preferences.d/webapps-preview-pin-400
Package:  *
Pin: release o=LP-PPA-webapps-preview
Pin-Priority: 400

Package:  *chromium*
Pin: release o=LP-PPA-webapps-preview
Pin-Priority: 500

To identify the correct string for "Pin: release" option we can use apt-cache policy again.

$ apt-cache policy
...
500 http://ppa.launchpad.net/webapps/preview/ubuntu/ precise/main i386 Packages
    release v=12.04,o=LP-PPA-webapps-preview,a=precise,n=precise,l=preview,c=main
    origin ppa.launchpad.net
...

For apt versions < 0.8.14 pinned packages have to be specified explicitly as wildcards do not work:

$ cat /etc/apt/preferences.d/webapps-preview-pin-400
Package:  *
Pin: release o=LP-PPA-webapps-preview
Pin-Priority: 400

Package:  chromium-browser chromium-codecs-ffmpeg chromium-browser-l10n chromium-codecs-ffmpeg-extra
Pin: release o=LP-PPA-webapps-preview
Pin-Priority: 500

And now, when i try to upgrade I get only the packages I want from that ppa and not the other ones.  All nicely cherry picked for me:

$ sudo apt-get upgrade
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages will be upgraded:
  chromium-browser chromium-browser-l10n chromium-codecs-ffmpeg
3 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
Need to get 25.1 MB of archives.
After this operation, 5,026 kB of additional disk space will be used.
Do you want to continue [Y/n]?


The Easystroke gesture-recognition app should be able to define some new multitouch gestures as well as edit existing ones. Apple's multi-touch trackpad and corresponding gesture recognition, is by far the best implementation of gesture tracking we've seen yet. Easystroke however, is a fair contender with the mac gesture recognition. Easystroke allows users to create gestures with their mouse that will perform specified actions, such as open a web browser or view mail.

Find more tips/tricks and application details at the developer page.

Touchegg & uTouch

Touchegg combined with the uTouch metapackage allow users to create and edit multi-touch gestures on a trackpad. These applications when downloaded from the Ubuntu Software center create an editable config file.


How to install and activate NVIDIA drivers without Jockey?

If you decide you want to install the NVidia driver from the .run file provided on the NVidia website:

Getting the Driver

Put in information about your video card.
Review the license and release information (this page will be different, for different video cards, and different CPU's - 32-bit vs. 64-bit).
Download the driver (also different!).

These .run files are shell scripts with binary data embedded in them. Thus they cannot be treated as text files, even though shell scripts usually are text files. If your web browser tries to display their contents as text:

You can try right-clicking on the download link ("Agree & Download") and clicking Save Link As....
You can download with wget, a download utility that tends to be smarter about these things than most web browsers. To do this, right-click on the download link, click Copy Link Address (or Copy Link Location) and pass it to the wget command. For example:

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

Installing the Driver

You cannot install by double-clicking on the .run file. You don't want to open the file in a text editor (most of it isn't plain text anyway, so you'll see all those red escapes like in the screenshot you showed us). Furthermore, to run successfully, it must be marked as executable and the GUI must be turned off.

Once you have the .run file, quit all running programs, log out, and switch to a virtual console (by pressing Ctrl+Alt+F1.

Log in by entering your username and password as prompted. As you enter your password in the Terminal (here and later), it won't look like anything is happening--no placeholder characters like * will appear
Go to wherever you downloaded the driver. For example: cd ~/Downloads

(The ~/ part represents you home folder, and can usually be left out.)

If you want, you can actually download the driver now with wget. But the advantage of downloading it from a Terminal window is that you can paste the name in from your web browser.
See the name of the driver: ls *.run
Mark it executable: chmod +x *.run

(If there's more than one .run file, you may want to specify the whole filename, so as to make just the right one executable.)
Quit the GUI: sudo stop lightdm
Run the driver installer with sudo (it must be installed as root) and ./, for example:

sudo ./NVIDIA-Linux-x86_64-304.64.run

After ./, you can just type the first few characters, then press Tab and the shell will guess the filename for you.

You'll then be prompted for more information and the installer will attempt to install the driver.
After installing the driver you'll likely have to reboot for it to work (sudo reboot or Ctrl+Alt+Delete).

But if you want to try reloading the GUI, you can do so: sudo start lightdm

This might not be necessary, but you can try switching back to the GUI with Alt+F7.


What to do?! Upgrading from 12.10 to 13.04 failed :(

Failed upgrades often lead to broken package systems.

Run the following commands in a terminal:

sudo dpkg --configure -a
sudo apt-get update
sudo apt-get install -f
sudo apt-get upgrade
sudo apt-get dist-upgrade
sudo dpkg --configure -a

That should fix any package problems you are having, if that doesn't work then please post the output.

I would definitely run these commands to see if it will fix it before considering a fresh re-install. Though if these commands do not fix your problem then a re-install is the way you might have to go.


Problem when attempting to put Ubuntu One in panel (12.04)

ubuntuone-indicator package was renamed to indicator-ubuntuone

So installation command should be:

sudo apt-get install indicator-ubuntuone

Launchpad page of this PPA: Unofficial Ubuntu One packages


Every python version get its own environment and modules, so a modules installed for python3.x it is not available to python2.x

Also keep in mind that python get also virtual environment and as per before described the modules and libraries installed in a python3 virtual env are not available in to another virtual environment or in the python3 system installation.

To avoid this situation you can use requirements.txt file and install with pip the necessary modules and libraries needed by your app.
an requirements.txt files example:

numpy
panda

and install modules with:

pip install -r requirements.txt

this will install panda and numpy at the latest version, if you want to install them to a specific version create the requirements.txt file like this:

numpy==1.1
panda>=2.5
math>=1.1,<=1.5

the first install numpy exactly at the provided version, the second install panda at any version is major than 2.5 and the last one install math  in a version between the provided.

NOTE: (the software version could not match with the real version)


I don't know of any alternative boot loader for newer Windows versions. Grub and others only call Microsoft's bootloader when you select the corresponding menu entry.


Select monitor for indicator information

I haven't found a way to set a specific monitor (left vs. right) but you can have the notification appear in whichever screen has focus (following the mouse).

You can use dconf editor and go to apps > notify-osd and change multihead-mode to focus-follow

or from the terminal:
gsettings set com.canonical.notify-osd multihead-mode focus-follow

You can test this with notify-send test


Make f1-12 keys work as standard function keys on Macbook Pro 5,3

This worked for me on MBA.

Here's another sentence to make it 30 characters.  I'll remove this if I think of anything else to add.


Distinction between apt-cache and dpkg -l

apt is for managing remote repositories, dpkg - for locally installed packages. They're related. apt is front end to dpkg. When you run apt-get install package it gets .deb file, and installs it via dpkg. So numbers differ because there's a lot of packages available, but only fraction is installed locally on your system.

apt-cache can show both installed and non-installed packages, because it queries the apt cache - listing of what is available in remote repositories ( that cache is what you get when you do apt-get update). For instance,

$ apt-cache policy terminator
terminator:
  Installed: (none)
  Candidate: 1.91-1

$ dpkg -l terminator
dpkg-query: no packages found matching terminator

Note that there is another tool which can query list of installed/removed local packages, and that's dpkg-query. For instance,

$ dpkg-query -l 'libc6'
Desired=Unknown/Install/Remove/Purge/Hold
| Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend
|/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)
||/ Name                 Version         Architecture    Description
+++-====================-===============-===============-=============================================
ii  libc6:amd64          2.27-3          amd64           GNU C Library: Shared libraries
ii  libc6:i386           2.27-3          i386            GNU C Library: Shared libraries

$ dpkg -l libc6
Desired=Unknown/Install/Remove/Purge/Hold
| Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend
|/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)
||/ Name                 Version         Architecture    Description
+++-====================-===============-===============-=============================================
ii  libc6:amd64          2.27-3          amd64           GNU C Library: Shared libraries
ii  libc6:i386           2.27-3          i386            GNU C Library: Shared libraries

As per dpkg manual

  dpkg can also be used as a front-end to dpkg-deb(1) and dpkg-query(1). The list  of  supported actions  can  be found later on in the ACTIONS section. If any such action is encountered dpkg just runs dpkg-deb or dpkg-query with the parameters given to it, but no specific options  are currently passed to them, to use any such option the back-ends need to be called directly.

As far as dpkg-query goes, it should be noted that this tool is focused on querying the database of installed packages, and can output information in particular format(-f option plus -W action). For instance,

$ dpkg-query -W -f='PACK:${Package}\nARCH:${Architecture}\nSTAT:${Status}\n---\n' libc6
PACK:libc6
ARCH:amd64
STAT:install ok installed
---
PACK:libc6
ARCH:i386
STAT:install ok installed
---

Interestingly enough, dpkg database maintains listing of packages that are selected for removal or were removed at some point. dpkg-query can also take glob pattern as an argument, and depending on presence of absence of it show only installed/configured packages or all packages.


How to launch the vscode after it has been installed through snap?

If

code

doesn't work try

snap run code


CSV data spreadsheet import has unexpected CR\LF

I assume that there's a difference between the count of header fields in line 1 and the count of data fields in line 2 to 2+n.

Your screenshot doesn't show the complete csv source, so i can't tell for sure. But it looks like you have 14 or 15 header fields, but at least 18 data fields. So, LO assumes your data table has 14 or 15 columns, and will try to allocate 18 data items there, which works only by putting three (or more) data fields in a new row.

Thus, the solution is to adjust either the header fields or the data fields, so their count is the same.


Touchpad doesnt work before and after login,but usb mouse works

I had a similar problem on my new laptop. I tried some of the things above, but what finally worked for me was the following:

sudo apt install xserver-xorg-input-synaptics
sudo apt install synaptic


Installed Ubuntu (14.04 LTS) "Trusty Tahr" on an "old" Window OS computer

I would use the graphical application "GParted partition editor" to reduce the size of the Windows partition and increase the size of your Ubuntu partition.  'gparted' is a very powerful tool, so use cautiously.  I would assume you could delete the partition.  But not sure how the 'grub2' boot loader will react with the missing partition.


Try:
sudo apt install --reinstall xkb-data


Clicking URLS opens a new tab in FireFox

Are you tapping close to an edge or corner by any chance? Depending on your hardware model and software configuration, tapping near some edges emulates the second (middle) or third (right) mouse button. In Firefox, by default, middle-clicking on a link opens it in a new tab.


I3 WM with auto internet connectivity and a gnome panel

Install wicd-gtk

then, add the following autorun in your .i3/config :

exec wicd-gtk -t

this should give you auto-internet connectivity.  You can choose the network to auto-connect in the wicdt-gtk gui.


I was having similar problems with Ubuntu 12.10 and a Nvidia ASUS GT640 graphics card. Trying proprietary 310 Nvidia driver wasn't helping since it makes my desktop dramatically loosing performance.

Then, I thought about switching to the pre-build of Ubuntu 13.04 (got the .iso from here: http://cdimage.ubuntu.com/daily-live/current/). So I burnt it and made a fresh install.

The first impression was good, the desktop behaviour with the open-source driver was quite much better than using it with Ubuntu 12.10.
I decided to try out Steam for Linux. The in-game behaviour was still lacking a lot (Tried TF2). Then I've went to the Ubuntu Software Center application and installed the proprietary, tested 310 Nvidia driver.

Once I restarted the system, everything went Ok for me! Good screen resolution, good desktop behaviour, and surprise! Steam for Linux In-game behaviour quite NICE! playing TF2 with my profile recommended configuration happily! :D

I recommend to give Ubuntu 13.04 the chance! Try it, it worked in my case.

My computer's profile:
CPU: AMD Athlon x64 3.0 Ghz x2 (6000+)
RAM: 4Gb DDR2 667Mhz
GPU: Nvidia ASUS GT640 2Gb

Hope these help you! And I apologyze for my english poor skills ;p


How to Show Username on Top Panel Ubuntu 16.04 LTS

On the top right hand corner click the gear icon and go to System Settings...

Next, go to User Accounts.

You will then see a checkbox at the bottom of the window that says:

  Show my login name in the menu bar

Enable that checkbox. Your username will then appear in the top menu bar.

Here's a screenshot that might help you:


Skype new install not working on updated 16.04.4 LTS

Try this:

This will remove the install currently there.

sudo apt-get remove skypeforlinux-64.deb

Then try downloading a fresh version and then running

sudo dpkg -i skypeforlinux-64.deb

Then run the following

sudo apt-get -f install skypeforlinux-64.deb

The -f flag should pick up any needed dependencies that might be missing.

Let us know if that helps in any way.


How to display a random line from a text file?

You can use shuf utility to print random lines from file

$ shuf -n 1 filename

-n : number of lines to print

Examples:

$ shuf -n 1 /etc/passwd

git:x:998:998:git daemon user:/:/bin/bash

$ shuf -n 2 /etc/passwd

avahi:x:84:84:avahi:/:/bin/false
daemon:x:2:2:daemon:/sbin:/bin/false


Ubuntu 10.04 LTS Minimal requirements (special)

Download a couple of ISO images, make Live CDs and test. If it boots from CD, loads the desktop and doesn't crash after loading a few application, it probably will install and work. Xubuntu will likely be a better choice, regardless of release.


Disabling KSM appears to solve this (with the downside of having it disabled) - all the credits goes to Serge Hallyn from ubuntu team for suggesting it.

There appears to be a bug (or several) related with KSM on ubuntu 14.04, you can find a couple here and here.

To disable it, edit /etc/default/qemu-kvm and change this line:

KSM_ENABLED=1

to

KSM_ENABLED=0

then restart qemu

sudo restart qemu-kvm

I'll update this again if this is sorted out so it is possible to have KSM enabled again.


A list of wireless connections doesn't appear in Asus k501ux

The wireless adapter is blocked by rfkill.

It is an Asus UEFI issue.

This can be fixed by

sudo tee /etc/modprobe.d/asus.conf <<< "options asus_nb_wmi wapf=4"

Reboot after this command and test.

This solution should help. A quirk for this Asus laptop has been added to upstream kernels. It is actually the same fix as this options asus_nb_wmi wapf=4.


How can I access UbuntuOne contacts and notes with Python?

There are a number of different ways of working with your Ubuntu One data, you'll be pleased to hear.

If your Python application is running on Ubuntu

Your contacts data is stored in Ubuntu One, and is also synced to your desktop. Contacts data is available in the desktopcouch storage system. You can find out more about desktopcouch in the documentation.  There will be more information available over the next few months as part of the Ubuntu One app developer programme.

A short summary: desktopcouch is your own personal CouchDB, running on your Ubuntu desktop, and your contacts are stored in it. So you can use the desktopcouch.records library to get access to your contacts:

from desktopcouch.records.server import CouchDatabase
CONTACT_RECORD_TYPE = 'http://www.freedesktop.org/wiki/Specifications/desktopcouch/contact'
db=CouchDatabase('contacts')
contact_names = []
for row in db.get_records(record_type=CONTACT_RECORD_TYPE):
    first_name = row.value.get('first_name', '')
    last_name = row.value.get('last_name', '')
    contact_names.append('%s %s' % (first_name, last_name))
print contact_names

There are more examples of how to work with desktopcouch data in the desktopcouch documentation page. The data format for contacts is defined here.

You can create any other databases that you like in desktopcouch; simply do

db = CouchDatabase("my_new_db", create=True)

and then work with that database; your new database will be synchronised to your personal cloud and to all your machines, and you can store whatever data in it you want.

If your Python application is not running on Ubuntu, or you want to access the data at Ubuntu One directly

Your data is stored in your own personal CouchDB in the cloud at Ubuntu One as well as in desktopcouch on your Ubuntu desktop. You can access it directly in your personal cloud if you choose. You'll need to be familiar with OAuth for this. First, obtain an OAuth token for Ubuntu One; you can do this from an Ubuntu desktop by looking in the keyring. Next, OAuth sign a request to https://one.ubuntu.com/api/account/ which will return some JSON, including your "couchdb_root", which will look like https://couchdb.one.ubuntu.com/u/abc/efg/12345.

Your personal cloud contacts database is then available at https://couchdb.one.ubuntu.com/u%2Fabc%2Fefg%2F12345%2Fcontacts (it's your couchdb_root with "contacts" on the end, and the / escaped to %2F). You can then work with this as with any CouchDB by OAuth-signing your curl requests to it. The CouchDB guide explains how to work with CouchDB over HTTP.

Working with notes is a little more complicated: the primary store for notes is the Tomboy application. Tomboy will sync your notes to Ubuntu One, and they are available in your personal cloud CouchDB (a database called "notes"), and that "notes" DB is also synced into desktopcouch. However, if your application is running on the Ubuntu desktop, I'd recommend that you use Tomboy's comprehensive D-Bus API to work with your notes directly at the source, rather than editing the desktopcouch copies and waiting for those changes to be synced up to Ubuntu One and then down to Tomboy again! This Ars Technica article explains some of how to do that, and the Tomboy team are lovely people who will be eager to help.

We (Ubuntu One) are building up an application developer programme to make it even easier to answer this sort of question and provide guidance and documentation; I'd love to hear what you're planning to do and how I can make it easier for you, so do please drop me a line (stuart.langridge @ canonical.com, or http://kryogenix.org/contact) if I can help, or post more questions to askubuntu!


How to open a file in it's own application like `start` in Windows and how to use `start .`?

xdg-open (ref man xdg-open) is one way of doing it, and this can be aliased to for example the keyword start (which is otherwise not commonly used on Ubuntu):

Add the following to ~/.bash_aliases;

alias start='xdg-open'

Logout/login from your current shell (or run the same manually), then try this;

start .

It will open current window in Nautilus file browser. God bless!


Can I install Ubuntu on a Windows computer without affecting other users?

is it possible to have Ubuntu only installed onto one user?

No, you cannot install Ubuntu without affecting the ENTIRE computer, and therefore all users using it.
Why?
Let me explain: whether you install Ubuntu from Windows (Wubi), or alongside Windows by booting from an Ubuntu Live-CD, Ubuntu will make three changes that will affect the entire computer and all its users:

It will change the way the computer starts up (in technical terms, modify the bootloader)
It will occupy a significant amount of hard disk space (at least 4 gigabytes or so.)
While Ubuntu is running, the other users cannot login to Windows (because it cannot run at the same time as Ubuntu).

Minimally-invasive installation: run in a virtual machine
I assume you are using Windows. If you have administrative rights, you can try installing Ubuntu in a virtual machine using VirtualBox or VMWare Player. Both are free. But this can also affect users in two ways:

Ubuntu will still occupy a significant amount of hard disk space (at least 4 gigabytes or so.)
Running a virtual machine will also use a significant amount of RAM (at least 1024 MB recommended) and some CPU (processor) time, which can affect the responsiveness of the system for other users using it without you logging out.


Minecraft, Java, Ubuntu and a SOCKS proxy

MineCraft does not have support for proxying of data.  In Java, in order to support proxies, you need to have that support compiled in, or change your networking settings to use a proxy.

However, Minecraft does not look at the network settings, so unless your proxy is set to all Internet traffic being sent via a proxy (which sometimes breaks things), it will not work.

(Setting up proxy support in Java apps can be a pain, so I understand why the Minecraft devs left that out)


What is the /opt/mingw64 /opt/mingw32 equivalent for Ubuntu

I just installed the packages and it looks like it installs them into /usr if you install using the Software Center or apt. Below is the screenshot.


You can delete your folders through the Ubuntu One Website (http://one.ubuntu.com).

After you login, access the Files Tab. Click the "More" link on the folder you wish to delete in order to view the options. The "Delete Folder" option will then be visible.


The important part is to set it to be readable only by root, so root:root and permission 400 is suitable.

The -des3 option allows for encrypting the private key with a passphrase.  Doing this would mean that every time a web or mail server starts or restarts you must enter the passphrase.  This would be impractical for a server certificate.

If you don't want to use a passphrase to protect the private key then I don't believe there is any reason to use -des3.


Optimize performance on Raspberry Pi 3 with Ubuntu MATE 16.04 LTS

If you do not need a GUI the best you can do in terms of optimization is set the default system target to multiuser. This can be done using

sudo systemctl set-default multi-user.target
sudo systemctl isolate multi-user.target

This will also prevent any services from running that are apart of the graphical target.

You also might want to take a look into preload and start purging programs that you are not using.


How do I add or manipulate Application/System Indicators in the login screen?

One way that I have tried in Ubuntu 14.04 using LightDM (Default); Using Some config files stored in /usr/share/unity/indicators/

Let's say you want to hide keyboard indicator:

Open corresponding file for editing

sudo nano /usr/share/unity/indicators/com.canonical.indicator.keyboard

Comment object paths for the mode you want to hide in, example this will hide it in the greeting screen and lock screen

[Indicator Service]
Name=indicator-keyboard
ObjectPath=/com/canonical/indicator/keyboard
Position=80

[desktop]
ObjectPath=/com/canonical/indicator/keyboard/desktop

#[desktop_greeter]
#ObjectPath=/com/canonical/indicator/keyboard/desktop_greeter

#[desktop_lockscreen]
#ObjectPath=/com/canonical/indicator/keyboard/desktop_lockscreen

[ubiquity]
ObjectPath=/com/canonical/indicator/keyboard/desktop

Reboot or just restart display manager

sudo service lightdm restart


Is the only way to add a quicklaunch in LXQt by mouse?

That's correct; as of LXQt 0.13 there is no way to modify this within the LXQt Panel settings; it's mouse only.


Fan works more in Ubuntu for same temperature than Windows

Seems your laptop BIOS has a Fan Always on while on AC power setting. You could try disabling it to see it improves your situation.

Power on or restart the computer, and then press esc when the "Press the ESC key for Startup Menu" message displays at the bottom of the screen.
Press F10 to enter Computer Setup.
Select System Configuration from the top menu. Select Device
Configurations.
Deselect "Fan Always on while AC Power".

Source: http://h20564.www2.hp.com/hpsc/doc/public/display?docId=c03944281


What BIOS settings must I change on a Compaq dc5750 small form factor to install Ubuntu?

The installer error you encountered indicate a failure to access you hard disk(s) for partitioning. This may be due to wrong or not working settings in the BIOS storage access.

In the HP BIOS configuration tool - running with F10 on boot - you may find this in the Storage -> Storage Options -> SATA Emulation menu. Remember the settings there and try with IDE.


installing ubuntu 12.04 alongside windows 8 on lenovo e420

If the computer shipped with Windows 7, chances are it doesn't support Secure Boot, so you can skip any instructions that tell you to use it.

Before proceeding, though, you should determine whether Windows is booting in BIOS mode or in EFI mode. You can tell this by examining your partition table -- if it's MBR, Windows is booting in BIOS mode; and if it's GPT, Windows is booting in EFI mode. (See here for more information.) It's important to install Linux in the same mode as Windows is using. If you don't, you'll have to re-install your boot loader and/or jump through some extra hoops.


Is there any problem with using wine program loader?

Seems stable enough for me for the (very) few legacy Windows applications I need to use it for although others say that there can be issues with some of the weightier programs which may be best run in VMware.

Where there are Linux alternatives for the applications you wish to use, it may be best to follow that route, if you are able.


Install from Ubuntu Software Centre to a location of my choice

The packages are not downloaded to the $HOME folder. And Software Center doesn't do the downloading. You cannot install packages to a separate directory, other than where the package indicates the files are to be put. The packages are installed the same way if you use Software Center, apt-get on the command line, or any other tool, such as synaptic.

However, in the case of For Purchase apps (whether they are for a price, or free), the data is generally stored entirely in /opt, except for a few small files to make the app available to launch in the Unity dash, and similar. In this case, you can simply make an ext4 partition and mount it as /opt on boot by adding the appropriate configuration to a new file in /etc/fstab.d/. You can mount the partition elsewhere first, to copy any data which already exists in /opt over to the new partition.

For the case of games installed via Steam however, they are outside the realm of Ubuntu's package management, and always installed into the Steam application data and profile directories, which default to being a hidden folder within $HOME. It would be possible to mount a partition in this location, with all the Steam data, as well.

If you mean where the packages themselves are downloaded to, prior to installation, they are stored in /var/cache/apt/archives and you can mount a separate partition there, or simply clean out the directory occasionally to free space if necessary.


dpkg: dependency problems prevent configuration of shim-signed

Reinstalling grub-efi and updating grub fixes the issue.

sudo apt-get purge grub\*
sudo apt-get install grub-efi
sudo apt-get autoremove
sudo update-grub


Ubuntu on armhf: "using PPAs with apt-get source -b"?

Okay, I've tried this method and it works. :-) For the next person who stumbles on this:

sudo add-apt-repository ppa:(name of PPA)
sudo dpkg --add-architecture amd64
sudo apt-get update
apt-cache policy (package name) #Just to make sure it's there
sudo apt-get source -b (package name)
sudo dpkg --remove-architecture amd64 #Do this whether the package compiles correctly or not
sudo apt-get update

At this point, if the package didn't compile due to missing dependencies, it's safe to install them (that is, there's no chance they will be drawn from the wrong architecture/repository). They shouldn't anyway, but this is insurance.

sudo apt-get source -b (package name) #if necessary

Once you've successfully compiled, look for the armhf deb file in your current directory (the folder you've been working in) and: sudo dpkg -i (package name).deb.

So... there may be a more elegant way to accomplish this, but I leave that to more knowledgeable users.

Note: Packages installed this way will not update automatically. You will have to remove the original package, compile the updated package yourself, and re-install. As long as you don't purge the original installation, all of your preferences should be retained.


Why does LightDM only show a custom wallpaper on the login screen if I have selected one of the default wallpapers?

I bet you use an encrypted home folder - which is readable not before you log in. What you can do is to copy your background image for instance to /usr/share/backgrounds (as root, i.e.: sudo cp ~/Pictures/backgroundimage.png /usr/share/backgrounds/) and set it as background image out of this un-encrypted folder.


Lubuntu 14.04 Problem starting lxsession-default-apps

The /usr/share/app-install directory is created when you install the app-install-data package. This package provides metadata about applications that is used by the Ubuntu Software Center and (in your case) the Lubuntu Software Center.

I don't know why this isn't a dependency for lxsession-default-apps, but it resolves "No such file" error and gets it to load.


Installation of Software Center in Ubuntu 16.04

Press Ctrl + Alt + T to open a terminal window, then issue command:

sudo apt-get install software-center


Graphical authentication works; why does sudo say my password is wrong?

First... A Probable Workaround

It's likely you can work around this problem until it's solved by using pkexec in place of sudo when you want to run a command as root. See "Maybe sudo is Broken" below for details.

It's not definite that this will work. If not, one of the other solutions or workarounds here might. If not, this will probably still help you gather information about the problem, which you can add to your question.

(People with this problem other than the asker of this question can create a new question with information about what happened when they tried the techniques here.)

The Basics of This Situation

Most of the time, when people report they cannot effectively enter their password for sudo in a terminal, but can authenticate with it graphically at least some of the time, it is because they don't realize that no placeholder characters (like *) are supposed to appear. Here, it seems that is not the case. If you entered your password correctly and in full before pressing Enter, there really is some problem.

To figure out what it is, more information is necessary. Here are some possible causes of sudo not accepting the password in the terminal even though you can enter it graphically to install software.

1. Maybe the Password is Blank

Suggested by Bruno Pereira.

If your password is blank, i.e., zero characters long, i.e., you just press Enter when asked for your password, change it to something that is not blank.

It's likely you can change your password in System Settings (since you can perform at least some administrative tasks graphically). If that doesn't work, and you can install software, you can install gnome-admin-tools , run users-admin (another graphical utility), and change your password that way.

If that doesn't work, try running pkexec passwd $USER. (pkexec will prompt graphically for your password if a GUI is available and working, even when used to run CLI commands.)

If that doesn't work, try any of these methods; if that doesn't work, try this method.

2. Maybe the Password Contains Weird Characters

If your password contains characters other than the numerals (0-9), capital (A-Z) and lower-case (a-z) letters with no accent marks, and punctuation that appear on a US/English keyboard, change it so it does. If you're using a different locale, then to be safe, you can (temporarily) change your locale as well.

Spaces are ordinarily fine in passwords but as you're having problems it makes sense to try it without them. They're relatively uncommon, so there could be an undiscovered bug triggered by a combination of having a password with spaces in it and some other condition.

3. Maybe the Password is Perfectly Ordinary, But Was Stored Wrong

Even if all one or more characters of your password are commonly used, it's still a good idea to change your password to see if it solves the problem. Also, if you change your password and it does not solve your problem, that is another important piece of information.

I've talked to people in this situation, where changing the password fixed the problem, even though there was nothing particularly wrong with or strange about it originally. I suspect that the problem might have to do with how the password is stored, but it could be that the underlying cause is coincidentally corrected by setting the password, or that the situation was (albeit repeatedly by different people) misreported to me, or that I misunderstood.

4. Maybe You're Not Typing What You Think You Are

Make sure your keyboard layout is what you think it is when you put in your password.

5. Maybe Your Terminal is Misinterpreting Input

Perhaps the password that is being seen is not what you're actually entering. To see if this is the case:

Enter it in the terminal when not entering your password (don't "run" it, and still don't tell us what it is).
Try it in a different terminal application. You're using Terminal; try xterm. (Press Alt+F2 and run xterm.)
Try it on a virtual console. Press Ctrl+Alt+F1 and see if you can log in. Like when running sudo, it's normal for you not to see anything happening as you enter your password. Just type it in and press Enter when you're done.

Whether that succeeds or fails, knowing if it worked provides useful information.

Then try actually running sudo.

To get back to the GUI, press Alt+F7.

6. Maybe sudo Works, But Not when Invoked from the Command Line

To check this, run gksudo xclock. You'll be prompted graphically for your password, but sudo will be used "under the hood."

If that works--that is, if a simple graphical clock application appears--then sudo works, but (assuming it also failed when you tried running it in another terminal app and in a virtual console), something is wrong with the way it is taking input from command-line interfaces.

7. Maybe CLI Password Authentication is Broken

This could occur if there is a common problem preventing sudo and other, different ways of asking for passwords on the command line, from working right.

Run su $USER -c 'echo Success'. You'll be prompted for your password. Type it in (again, it's normal to have nothing appear on the screen as you do), press Enter, and see if Success appears.

If you were unable to get past authentication there, then the problem affects both terminal-based sudo and terminal-based su.

8. Maybe sudo is Broken

Try running a command with PolicyKit: pkexec echo Success

A GUI window should come up and ask you for your password; if authentication succeeds, Success will appear in the terminal.

If this works, you have a workaround for the problem: use pkexec instead of sudo.

If sudo is broken, you might be able to fix it, depending on what is wrong with sudo:

8.1. Maybe the installation is messed up.

Try reinstalling sudo with:

pkexec apt-get update && pkexec apt-get --purge --reinstall sudo

That may fix a corrupted or misconfigured installation.

8.2. Maybe sudo is misconfigured in /etc/sudoers.

For misconfigurations relating to unexplained password authentication failures, check the Defaults lines in /etc/sudoers by running:

pkexec grep Defaults /etc/sudoers

In Ubuntu the output is normally:

Defaults    env_reset
Defaults    secure_path="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"

If you see rootpw, runaspw, or targetpw, this means sudo is not necessarily asking for your password.

This is particularly likely if you are prompted [sudo] password for root: or [sudo] password for some-other-username instead of [sudo] password for your-username. But it's worth checking for in any case (as it's easy to check).

Even if you don't see any of those three ...pw terms, you still might see something wrong; if your output of pkexec grep Defaults /etc/sudoers is not the same as what's shown above, you should look into that (for example, you can include it when you edit your question to provide details about what happened when you tried all these techniques).

If this doesn't reveal anything, take a look at all of /etc/sudoers. You can use pkexec less /etc/sudoers or open the file in an editor with pkexec visudo. If you don't see anything wrong, I recommend still posting the contents of the file in your question.

If you find a problem in /etc/sudoers and know what has to be changed, you can edit it using pkexec visudo.

8.3. Maybe sudo is misconfigured in /etc/sudo.conf.

Normally on Ubuntu, /etc/sudo.conf does not exist. And that is good--it works normally in that situation. If /etc/sudo.conf does exist, sudo may be configured to work in a radically different way. (Or it might be configured to work exactly the same way, and have nothing to do with your problem. Or anything in between.)

If this file exists, regardless of what's in it, please provide its complete contents.

If /etc/sudo.conf exists, by default the only uncommented lines (i.e., the only lines that don't start with #) are:

Plugin sudoers_policy sudoers.so
Plugin sudoers_io sudoers.so

This uses the sudoers module to control the security policy and interface of sudo. If any other module is used, things can be quite different, so that's very relevant information.

8.4. Maybe this is a PAM problem, presenting unusually.

This is kind of a stretch, but maybe sudo is configured to use pluggable authentication modules and its PAM configuration has a problem.

This is a stretch because usually you are not asked to enter a password at all when this happens.

To check, run:

ls -ld /etc/pam.d
ls -l /etc/pam.d/sudo
cat /etc/pam.d/sudo

The text in the terminal should look like this:

$ ls -ld /etc/pam.d
drwxr-xr-x 2 root root 4096 Jan 16 01:44 /etc/pam.d
$ ls -l /etc/pam.d/sudo
-rw-r--r-- 1 root root 239 May 31  2012 /etc/pam.d/sudo
$ cat /etc/pam.d/sudo
#%PAM-1.0

auth       required   pam_env.so readenv=1 user_readenv=0
auth       required   pam_env.so readenv=1 envfile=/etc/default/locale user_readenv=0
@include common-auth
@include common-account
@include common-session-noninteractive

If any of the bold text differs at all, that suggests a problem.

I got this idea from the upstream sudo troubleshooting page (but that page does not suggest the problem will happen this way).

9. Maybe It's Something Else

Maybe none of the situations covers your problem. Or maybe the problem is that sudo is broken, but none of the sub-situations for that apply.

If that's the case, don't give up! (Unless you want to.)

Just provide as much more information as possible, including what happened when you tried each technique or diagnostic step. This will likely shed light on the problem.

This answer is moved, with slight modification, from this question (where it didn't really belong, as it's not clear the OP there really has this problem). Thanks to gertvdijk for helping me recognize the ambiguity there and suggesting this be posted elsewhere instead. (He is not responsible for any errors here, however.)


If you go the ppa's site, you can download this .deb for 32bit, or this .deb for 64bit, and install it.


Solved it by.

    kiri@xxx-cpu:~$ sudo apt-get update
    kiri@xxx-cpu:~$ sudo apt-get -d install --reinstall gdm
    kiri@xxx-cpu:~$ sudo apt-get remove --purge gdm
    kiri@xxx-cpu:~$ sudo apt-get install gdm
    clicked on install lightgdm
    kiri@xxx-cpu:~$ sudo reboot


commandline request to get ipv6 address as from test-ipv6.com

I found this on a gist
curl -s ipv6.icanhazip.com | xargs echo -n


Internet doesn't works in browser if network interface is changed

This could be a DNS issue.

Try to ping by name ("ping google-public-dns-a.google.com"), ping by name the site you are trying to reach ("ping askubuntu.com"), open the site in the browser by IP address (http://216.58.213.238 for google.com).

Check DNS address in the network settings of the active adapter.


How to stop the terminal from wrapping lines

It depends on what application you are using.

If you are viewing a file or command output using less, passing the -S option (a.k.a. --chop-long-lines) will cause output to be chopped off rather than wrapping to a new line.  You can use the horizontal arrow keys to view the rest of the line.

For generic non full screen applications, you can turn off line wrapping by sending an appropriate escape sequence to the terminal:

tput rmam

This mode can be cancelled with a similar escape:

tput smam

Details on adjusting the behaviour for a few other command line tools can be found here:

http://tomayko.com/writings/StupidShellTricks


How to make /bin/ps, called with aux as its argument, write to a file?

Looking through the list of command-line options accepted by ps in the ps manual page (accessible there and by running man ps) reveals it doesn't have an option for logging to a file. Many commands do not. But you can still make it do what you want.
Redirecting with > or >>, as John1024 explains sends the standard output of your program to the file or device named to the right of >/>>. It sounds like this is what you want.
However, if you want to write the output to a file and also see it yourself in the terminal, then you may wish to use the tee utility instead.
ps aux | tee file
This usage (| tee file) is like > file, but it shows you the ouput as well. If you want to see the output and append it to the file (rather than overwriting), use the -a flag:
ps aux | tee -a file
That usage (| tee -a file) corresponds to >> file.
How does tee work?
tee duplicates its standard input, writing it both to the file (or list of files) given as its command-line arguments, and to standard output.
Ordinarily--that is, when a program or command is run in the simplest way--its standard input is received from the user. It's what the user types as the program runs.
But the pipe operator, |, connects the standard output of the command to the left of it, to the standard input of the command to the right of it. In the examples above, this causes ps aux to send its output to the input of tee instead of to the terminal (and tee to receive its input from the output of ps aux, instead of from the terminal).
tee then writes what it's received both to file and to the terminal.
By the way, one common use of pipes is when you anticipate the output of a command will be long, and you want to be able to navigate up and down in it. You can then pipe its output to less. For example: dmesg | less.
Redirecting/piping error output too.
The redirection and piping solutions discussed above and in John1024's answer change where standard output goes, but they leave standard error alone. That is, most error messages (and some other messages, depending on the program) are unaffected--even in ps aux > file, errors will appear on the screen and not in file.
This is usually what you want. And especially in the case of ps aux, it's unlikely you want error messages in your output file--errors are unexpected, and you'd probably want to see them right away. An error would likely render the file you're trying to make unsuitable for your task, anyway, assuming your goal is to produce a table of running processes and their characteristics.
However, if you do want error output to be treated just the same as regular output, you can use the &-suffixed version of the redirection and piping operators:

>& (or &>) in place of >: ps aux >& file or ps aux &> file
&>> (not >>&) in place of >>: ps aux &>> file.
|& (not &|) in place of |: ps aux |& tee file, or ps aux |& tee -a file to append.

bash, the default interactive shell in Ubuntu, supports the &ed operators. This is the shell you're using unless you've deliberately switched to another one, so for interactive use (and for scripts where you know they'll be run with bash), you can definitely feel free to use it.
Redirecting/piping error output too, on shells that don't have the &ed operators.
Some shells (like dash, which provides sh on Ubuntu) do not support them. In that case you'd get errors like:

dash: 2: Syntax error: Bad fd number (when trying to use >& — in contrast, &> and &>>, when unsupported, get interpreted as & > and & >>, which do something different)
dash: 1: Syntax error: "&" unexpected (when trying to use |&)

When working in a shell where >&, >>&, and |& are unsupported, you can send both standard output and standard error through a redirection or pipe in the traditional way, by specifying separately that standard error is first to be redirected to standard output.
This is achieved with 2>&1. (1 is the file descriptor for standard output, and 2 is the file descriptor for standard error.)
For a redirection (i.e., when you'd like to be able to use >& or >>&), put 2>&1 at the very end:
ps aux > file 2>&1
ps aux >> file 2>&1
For a pipe (i.e., when you'd like to be able to use |&), put 2>&1 right before the | pipe:
ps aux 2>&1 | tee file
ps aux 2>&1 | tee -a file


I have done an example which should only copy files instead of rename. Comments indicate some of the logic. I'm not a bash expert, but I tested this on a file.

You should create this file in the same directory as your source files, and name it something like pdbqt-mover.sh.

Either call it by typing bash pdbqt-mover.sh or you'll have to set permissions on the file so you can execute it using ./pdbqt-mover.sh.

#!/bin/bash
# process only files starting with 100000cpds_ligand_ and ending in .pdbqt
for infile in 100000cpds_ligand_*.pdbqt; do

  # get the pv-* string from lines beginning with "REMARK  Name = "
  # get the group matching PV-**** up to the end of the line
  pvnum=$(sed -n 's/^REMARK  Name = \(PV-\S*\)/\1/p' "$infile")

  # construct the output filename
  outfile="$pvnum".pdbqt

  # only copy if the output file doesn't exist
  if [ ! -f $outfile ] ; then
    # cp instead of mv
    cp "$infile" "$outfile"
    echo "Copied $infile to $outfile"
  else
    echo "File $outfile exists! Skipping"
  fi
done


My computer does not show log-in window at one go. To log-in, I have to force-start the computer twice

Ensure your computer is running the latest BIOS available. This is important because an out-of-date BIOS can have bugs, and those bugs sometimes affect things like UEFI, non-Windows operating systems, or other components.

★ You have a problem with grub.

Once you logged in to ubuntu. Then try the below Command to update-grub.

# sudo update-grub

Now, Restart your pc.
If the problem is still, Then problem in your pc bios.


system crashed during update from 11.10 to 12.4 64bits

if you can boot into a terminal /ctrl/alt/F1 log in with your username and password then try sudo apt-get -f install [fix broken packages]  or sudo apt-get update[update packages [sudo apt-get upgrade]upgrades packages dpkg--configure-a[try to fix broken packages,


Issues running ubuntu 15.10 on Acer r3 131t acpi need to be of

Eliminating the need for noapic and apci=off with my Acer R3 131t for a Ubuntu 15.10 install, required me to boot back into Windows, and do a Firmware / BIOS update from the Acer webpage. (I forget the software version number, maybe going from version 1.6 to 1.9. They put it out in August 2015 I believe.)


Mounting sdb as a secondary storage drive

I guess you want to mount it? The fact that it might be bootable does not change anything. Btw. sdb is the whole drive, please do not mount the drive (sdb), mount the partition instead (sdb1)

As superuser edit your /etc/fstab and add a second list of this kind:

UUID=072aa6ac-20a8-4c76-84c2-d68173d98744 /foomountpoint ext4    errors=remount-ro 0       1

Replace foomountpoint by your mountpoint. This folder should exist and be empty!

The UUID you can find when invoking:

ls -la /dev/disk/by-uuid

mkr@mkrubuntu:~$ ls -la /dev/disk/by-uuid/
insgesamt 1
lrwxrwxrwx 1 root root  10 2012-01-16 07:53 072aa6ac-20a8-4c76-84c2-d68173d98744 -> ../../sda6


You can use cdrskin to get this information. Here are the two options that might be of use (from man cdrskin, emphasis mine):

  -minfo
  Print information about the loaded media.  This  includes  media type, writability state, and a quite readable table of content.
  -msinfo
                Retrieve multi-session info for preparing a follow-up session by
                option -C of  programs  mkisofs,  genisoimage,  or  xorriso  -as
                mkisofs.    Print   result  to  standard  output.   This  option
                redirects to stderr all message output except the one of  option
                --tell_media_space  and its own result string, which consists of
                two numbers.  The result string shall be  used  as  argument  of
                option -C with said programs.  It gives the start address of the
                most recent session and the predicted start address of the  next
                session  to  be appended. The string is empty if the most recent
                session was not written with option -multi.
                To have a chance for working on overwriteable media, this option
                has to be accompanied by option --grow_overwriteable_iso.

The manpage also has a list of examples, one of which shows the use of -msinfo:

  Get multi-session info for option -C of program mkisofs:c_values=$(cdrskin dev=/dev/hdc -msinfo 2>/dev/null)
mkisofs ... -C "$c_values" ...

To sum it up, you should be able to test for a CD/DVD to be appendable with the following script:

#!/bin/bash
if [ "$(cdrskin -msinfo 2>/dev/null)" ]; then
  echo "Medium is appendable"
else
  echo "Medium is blank or closed"
fi

Oneliner version:

[ "$(cdrskin -msinfo 2>/dev/null)" ] && echo "appendable" || echo "blank or closed"

cdrskin takes the default drive which should be fine for nearly everyone. If it uses the wrong device, specify it explicitly with the option e.g. dev=/dev/sr1. If in doubt you can display information about a device with the option -checkdrive.


What are Snap packages and what are the difference between Click packages and Snap packages?

Click packages are isolated, so run in confinement with a "personal" directory and thus cannot provide dependencies to other programs. Intended originally for Ubuntu Mobile/Touch but later for the desktop, they were directed towards user applications because of their bundled dependencies and protected nature (e.g. you could have multiple versions of the same application, all using different libraries and all unaware of each other).

Ref: https://click.readthedocs.io/en/latest/

And the answer to a familiar (to you!) question here: What are Click packages?

Snappy packages are an iteration of the packaging concept, in that they can provide functions to other packages, and don't have to be confined. They can thus be the basis for system-wide applications/functions as well.

Ref: http://www.webupd8.org/2015/04/ubuntu-desktop-to-eventually-switch-to.html


The file or folder /home/XXX/... does not exist. and cannot be deleted

to remove the folder use -

sudo rm -f /path/to/the/folder

to remove the folders inside it recursively use-

sudo rm -r -f /path/to/the/folder

here -r stands for recursive and -f stands for force , please make sure to write exact path and exact name of folder.

hope thats what you want.


Hide stdout of a process only when it is running in background

Redirecting a running process's output is not easy. But there might be alternatives if you work from the start:

some_long_runnning_command | tail -n 1000 & pkill -STOP tail

With this method, since the tail has SIGSTOP sent to it, it won't output anything until you explicitly bring it to the foreground using fg (or something similar) and until the script has finished. Adjust the 1000 to get as many lines as you want.

A better alternative might be grep:

some_long_runnning_command | grep . --color=never & pkill -STOP sed

You can signal SIGCONT and SIGSTOP to grep to start and stop the output as you want.

This can probably be combined with the re-attachment of open file descriptors from the SO question linked above (maybe with the script in this answer) so that this can be done with processes already opened.

If buffering is indeed a problem with grep, as Volker Siegel points out, then one might consider using a more complex set of commands. First, note that sort uses temporary files, so buffering should not be a problem for it. It will act like a combination of tail and grep - waiting until the command is finished, like tail, and keeping the entire output, like grep. Something like:

some_long_runnning_command | awk '{$0=";"$0}1' | sort -k1.1,1.1 --stable | sed 's/^;//' & pkill -STOP sed

The loss here is that you can't start and stop the output at will, and there's the huge computation expended in an useless sort, as well as the work expended in adding and removing the ;.

Further tests reveal that Volker is indeed correct:

For a script like (call it test.sh):

#! /bin/bash
for i in $(seq 1000000); do echo $i; echo $i > /tmp/log; done

and the command:

./test.sh | grep . --color=never & pkill -STOP grep

the number in /tmp/log was stuck at 12768 (with a similar figure for .
And with the command

./test.sh | awk '{$0=";"$0}1' | sort -k1.1,1.1 --stable | sed 's/^;//' & pkill -STOP sed

The script ran to completion (/tmp/log had 1000000) without a peep from sed.

I still haven't managed to integrate this with the GDB method, but this as it is can be made to function as a function, similar to John1024's. The problem is that you have no good way of knowing if the process has ended, since the shell only notifies you if the entire job has ended. So you'll have to use a checking function:

function check ()
{
    local PROC=${1:-$(jobs -p %%)}
    kill -0 $PROC 2>/dev/null && echo "The process is still running." || echo "The process is not running."
}

function bg ()
{

    "$@" | awk '{$0=";"$0}1' | sort -k1.1,1.1 --stable | sed 's/^;//' &
    local PID=$!
    sleep 0.1s
    kill -STOP $PID
    cat <<EOF
To get the output, do:
    kill -CONT $PID
To check if the process has finished, do:
    check $(jobs -p %%)
EOF
}

You could wrap the "$@" in another function which will notify you once the job is done, using something like notify-send or write.

It's been a nice exercise, but ultimately the simplest way is to redirect to /dev/null and forget the output: How to redirect the output of an application in background to /dev/null.


cannot boot Ubuntu after removing packages?

I am not sure what you mean by the following:

  After I tried to restart the login, I tried to fix it usinh recovery mode but it's not working.

Can we please clarify? Do you mean one of the following:

You cannot boot. Your boot fails with some kind of output on the screen before anything noticeable happens.
You cannot boot. Your boot does not get beyond the purple Ubuntu boot screen.
You can boot, but not into the desktop?
You can boot, but into the desktop, but there is something wrong with programs that you use , data you once had, or some combination of the two.

If you can boot, but not into the desktop, there's a way to get a terminal without going into the desktop. If greeted with a black screen after booting, where your computer seems to stall, press Shift+Alt+F1 to get the first terminal. Once Ubuntu is started, there are six terminals (F1 - F6). The desktop is always in F7 (Shift+Alt+F7); by default, after booting, Ubuntu starts in the desktop mode.

If you cannot log in, then you might need to fix your partition table or bootloader; you might need to fix something in GRUB.

Since your disk is encrypted, you might have permanent data loss. If you cannot boot into your system, there might not be a computationally feasible way to obtain your encrypted data.

(Did that help, Ayman?)


How to change ubuntu's server date and time via command line?

You can set the system date with this command:

sudo date --set="2015-09-30 10:05:59.990"

Then when using date, it should be showed correctly.

Now you should also the set hardware clock in the BIOS of the system, that the setting persists over a reboot (dureing the startup the system time is set to the value of the hardware clock). Do that with hwclock:

sudo hwclock --systohc

This gets the system clocks (sys) value and sets the hardware clock (hc). Check it with the hwclock command. Both hwclock and date should now show the same date and time.

To set your timezone, you can use this command:

sudo dpkg-reconfigure tzdata

BTW: If you use a this machine as a server, I strongly recommend using an NTP-Client to sync the time over network. So you can guarantee that all your servers have the exactly same time set. This will sync the time while the machine runs. If you have applications which are dependent of synced time over server, I recommend the NTP-Daemon. The longer it runs in the background, the more precise is the time.


I was going to suggest Bootchart but I feel like it might stop logging at login.

Networking and sshd come up well before the desktop so you might be able to SSH in from another device and run htop (or top if you don't have htop installed) so you can see what is nomming on the CPU.

You've got (over) 15 seconds to inspect things - so that should be enough.

If you don't have another computer/phone you can SSH in from, you might even be able to switch to a TTY (ControlAltF1) and run htop (et al) from there while you desktop loads. It'll be harder to do but should render a similar effect.


If I dual boot Ubuntu 16.04 will my files that are not related to the Operating System stay on that PC

No. That's the whole point of a dual-boot: to keep one OS intact, while also having another OS installed alongside the first.

Be careful, though. Make sure that you are choosing the right option (the Install Ubuntu alongside Windows option). This will shrink the Windows partition to half its original size and install Ubuntu in the newly created space. Do not choose any options that include the word erase or wipe or any synonym of either.

If there is no option for a dual-boot, you will have to do some somewhat advanced partitioning and options. They aren't difficult, but they can easily be messed up. If you run into the problem of only seeing Wipe Hard Drive and Install Ubuntu and Something Else... as options, comment and I can provide you with an existing Q&A. Please don't ask a new question about it, as it will be closed as a duplicate.


_________________________________________________ L X C _________________________________________________________

                           Linux Containers ( Ubuntu )

  Overview

  Linux Containers (LXC) are lightweight virtualization technology and provide a free software virtualization system for computers running GNU/Linux, This is accomplished through kernel level isolation, It allows one to run multiple virtual units (containers) simultaneously on the same host.

A container is a way to isolate a group of processes from the others on a running Linux system. By making use of existing functionality like the Linux kernel's new resource management and resource isolation features (Cgroups and name spaces), these processes can have their own private view of the operating system with its own process ID (PID) space, file system structure and network interfaces.

Containers share the same kernel with anything else that is running on it, but can be constrained to only use a defined amount of resources such as CPU, memory or I/O. By combining containers with other features like the Btrfs file system , it will be possible to quickly set up multiple lightweight isolated Linux instances on a single host. Therefore containers are better compared to Solaris zones or BSD jails.

  Installation

Making LXC easier

One of the main focus for Ubuntu LTS was to make LXC dead easy to use, to achieve this.
Creating a basic container and starting it on Ubuntu

 sudo apt-get install lxc
 sudo lxc-create -t ubuntu -n my-container
 sudo lxc-start -n my-container

Log In

sudo lxc-console -n my-container -t 1

This will default to using the same version and architecture as your machine, additional option are obviously available (–help will list them). Login/Password are ubuntu/ubuntu.

For Detail Host Configuration

  For More About LXC

Debian

Oracle

sourceforge

LXC Web Panel

  For Newbie I would recommend to use LXC Webpanel, The good part is that if you make a container through cli mode, It will show up in LXC Web Panel

  sudo apt-get install lxc debootstrap bridge-utils -y
  sudo su
  wget https://lxc-webpanel.github.com/tools/install.sh -O - | bash

Open Web Browser and Connect

                       http://your_ip_address:5000/
                Login with user admin and password admin

Overview

  Containers Overview

  LXC Network

  Container Settings

Resource Limitation

  User Modification ( Create, Delete Modify )


let `conda install` use a manually pre-downloaded package

I encountered the same problem. There is a way to change the time out limit:

conda config set remote_read_timeout_secs 120

for example. However in my case it does not work. It turns out that there is a bandwidth limit in our lab and when the download speed exceeds that limit, its network is simply cut.


How do you configure a TACACS+ tac_plus server on Ubuntu 16.04 that authenticates against Microsoft Active Directory?

I've moved the guide to https://networkengineering.stackexchange.com/questions/45436/how-do-you-configure-a-tacacs-tac-plus-server-on-ubuntu-16-04-that-authenticate so I only have to maintain it in one location.


I need the best film production video editor

I've been using Kdenlive for a couple of years now and really like it! I only ever had one issue with it. And it's great because you can proxy the clips which help a lot while editing on an older machine. These are examples https://www.youtube.com/user/garykennedy message through there if you need any help.


How to mount an ISO (or NRG) image and rip it as if it were a physical CD?

Try this:

sudo mount -o loop ~/iso.iso /media/cdrom0

Then try ripit --device /media/cdrom0


xport list of duplicate images on digikam/findimagedupes/fsplint/geeqie

If there is the need to make interpolations and resizing there is room for errors, and similar (different resolution) images may be marked as duplicated. There is therefore the need for human verification.

Take a look at imagemagick. The webpage looks ancient, but it's still good.


The proper way to manage service daemons is managing links on /etc/rc?.d, there are some tools which allow you to easily manage the startup order without having to manually change the links.
Install the package "sysv-rc-conf" and run "sysv-rc-conf" from the terminal.

Please note that it doesn't allow you to manage services which use the new Ubuntu init system (upstart), there is no easy way to manage those yet.


What is easiest solution for twisted cable connection between two PCs running Ubuntu

Connect the 2 pcs directly using a cross network cable and use the ifconfig command to assign the fixed addresses between the pcs.

ie:

ifconfig eth0 192.168.1.1 netmask 255.255.255.0 broadcast 192.168.1.255

for pc1, and

ifconfig eth0 192.168.1.2 netmask 255.255.255.0 broadcast 192.168.1.255

for pc 2, where eth0 is your network interface name (check ifconfig -a for all your interfaces).

Use ping to see if you have connection between pcs: from pc1 > ping 192.168.1.2, from pc2 > ping 192.168.1.1

If you can ping you can connect, the use of NFS is really simple and fast to use, check it here: Ubuntu NFS howto


shotwell bugs with a canon PowerShot A3100 IS

I have a Canon Ixus 115 HS which also produces videos and pictures and I use gthumb to import material from the card. You can of course just access the camera and drag and drop material to your home folder, but some photos need to be rotated after import and gthumb can do that; however, I uncheck the setting 'rotate photos physically' on import, as I find it works properly only if I import them and then select the ones to be transformed. (You do this from the menu: tools: rotate physically.) This seems to be the way to get the EXIF orientation correct. The 'physical' transformation is important because it is lossless, and if jpgs are modified they can lose quality.

Also, you can't add things back onto the card with gthumb; depending on how your camera is recognised (as a digital camera or usb mass storage device), you may need to take the card out and put it in a card reader to do this. However, on the menu of some cameras you can select whether it will be seen as a usb device or camera when connected to a PC.

You mention drivers- actually gphoto2 is the service that helps digital cameras be recognised and mounted in Unix; it will be running as default as it is used by other photo apps as well. There is a list of supported cameras at gphoto.org.
However, even if yours is not listed it should still work.

If you don't like gthumb, try Digikam for KDE, even though it means you'll need to install some of the KDE desktop files.


Upgraded PHP on Ubuntu but old version still in use

See last edit above.  Basically, Ubuntu needed to install some updates, and once this had happened, php 5.4 was in use.


Reparing ubuntu installation using usb drive

The only way to easily fix all your broken packages is to boot on an Ubuntu 13.10 usb drive, choose Try Ubuntu, then follow this procedure from the Ubuntu community documentation.


Best RAID solution with a hardware RAID card?

While I don't want to point you away from askubuntu, you may find more input on serverfault, or other linux forums. What you will get here is most likely opinions based on personal experience (and possibly limited to Ubuntu), which would be all I could offer you.

That being said, the RAID card you have is known to be one to run VERY hot. So the fan requirement is well known.

I personally would not sell any of the hardware, since you will never recover anywhere close to the amount you originally spent. Hang on to it, and use it.

Now, as far as your question regarding using dmraid, I would steer away from it. The only reason I would use it is if I didn't have a Hardware RAID card (you do) and if I had to dual-boot with Windows and Linux.

If all you are going to run on it is Ubuntu, and you don't want to use the RAID card, you could simply use mdraid (not to be confused with dmraid), which is very mature by now. I have a couple mdraid RAIDs in use for many years now, without any issues. The nice thing about mdraid is that you can move controllers without major problems. But you will most likely want to have a separate boot drive, for ease of setup.

Again, it really does depend on how "mission critical" your setup will be. The more it needs to be 100% reliable (which nothing is), the more you will have to invest into Hardware RAID and redundancy.

Just my 2 cents. Others will most likely have a different opinion/experience. :)


How to change the notifications dialog theme?

Try to remove Gnome notification daemon and install the Ubuntu notify-osd package:

sudo apt-get remove notification-daemon
sudo apt-get install notify-osd


Exclude documentation from .deb installation (DPKG)

Onetime option: --path-exclude could be used to filter out unwanted files when installing a package:
dpkg -i --path-exclude=/usr/share/doc/* ...

Permanent solution: Create a file /etc/dpkg/dpkg.cfg.d/01_nodoc which specifies the desired filters. Example:
path-exclude /usr/share/doc/*
# we need to keep copyright files for legal reasons
path-include /usr/share/doc/*/copyright
path-exclude /usr/share/man/*
path-exclude /usr/share/groff/*
path-exclude /usr/share/info/*
# lintian stuff is small, but really unnecessary
path-exclude /usr/share/lintian/*
path-exclude /usr/share/linda/*

Skip recommended dependencies (APT)
Then change /etc/apt/apt.conf.d/99synaptics or create new file containing:
APT::Install-Recommends "false";

By the way, this is the permanent option of muru's answer for this question.
References:

Reducing the size of the Debian Installation Footprint
Ubuntu Wiki: ReducingDiskFootprint
man dpkg


Trying to move from MBR to GPT raid1 and grub won't start

FIXED. Good grief what a pain.

Short answer: fixed with boot-repair and selecting ATA disk support

Long answer: replacing/upgrading software RAID1 to larger drives with GPT is doable but tricky.

First step: make a bootable USB for your system. Not a rescue/livecd - you may want to have one anyway but make sure your own system is bootable from USB. SystemrescueCD booted my system and somehow degraded a different mirror so be careful.

Optional: I created a virtualbox mock up of my 18.0.4 system with the same MBR RAID1/LVM to test everything. I confirmed some problems/issues with grub-install so it was worth it.

Bootable USB: I used YUMI/Multiboot and copied my kernel and initrd to the USB /boot and edited /multiboot/syslinux.cfg to add:

label Mysystem
menu label Mysystem
MENU INDENT 1
KERNEL /boot/vmlinuz-4.15.0-47-generic
APPEND ro noapic root=/dev/mapper/system-root
INITRD /boot/initrd.img-4.15.0-47-generic

Boot-repair

You can try the default repair.
Note that purging grub will delete /etc/default/grub. With Ubuntu defaults my system would have a kernel panic. Also default Ubuntu grub.cfg hides important boot messages. After trying boot-repair a few times I gave up on purging GRUB and used Advanced options
My system ended up needing the ATA disk support

Converting MBR to GPT

This assumes you have backups or you're sure you won't have a drive failure while converting. Breaking the mirror and repartitioning is destructive so you will be relying on one drive for a while. Rebuilding mirrors may stress an old drive so you've been warned.

I had another drive/mirror as a backup in case I needed to recover.

Fail the drive you want to convert:

mdadm /dev/md0 --fail /dev/sdb1
mdadm /dev/md0 -r /dev/sdb1

Create new GPT partition with gdisk. You need a 1 MB bios-boot for grub. I added an EFI partition in case I move the drives to a new system. Rest of the drive is allocated to RAID and the added back to /dev/md0. It's OK to make a larger RAID partition on the new drive. The original /dev/md0 will stay the same until you grow it.

after gdisk:
Number  Start (sector)    End (sector)  Size       Code  Name
   1            2048            4095   1024.0 KiB  EF02  BIOS boot partition
   2            4096          208895   100.0 MiB   EF00  EFI System
   3          208896      7814037134   3.6 TiB     FD00  Linux RAID

I had a problem with grub-install failing, and boot-repair not fixing or complaining either (even after purging grub).

Wiping the bios-boot partition seemed to fix grub-install. Make sure it's the correct drive/partition!

dd if=/dev/zero of=/dev/sdb1

Then: (note the change in raid partition!)

mdadm /dev/md0 -a /dev/sdb3

Best to wait for the raid to finish rebuilding. Grub-install should work on the new drive.

At this point you should have raid1 with your old MBR drive and a new GPT drive. If you're not replacing the MBR drive, you could repeat the process of failing, GPT partitioning and re-adding to /dev/md0.

But I wanted to replace the MBR drive with a larger one so I had to shut down. This old drive was going to be my backup and I didn't want to fail it in mdadm, just in case there were problems. So I pulled the drive giving me an offline backup.

If you fail the old drive, replace it and reboot, hopefully Ubuntu boots with a degraded array and you can repartition with GPT and re-add to the array.

My mdadm radi1 system seems to boot with a degraded mirror, so failing the drive then shutting down might have worked for me.

However, if your drive actually fails, or you replace it without failing it, Linux may not boot properly and drop you into initramfs.

The problem is in /scripts/local-block/mdadm:

mdadm -q --assemble --scan --no-degraded || true

This prevents starting /dev/md0 properly so it can't mount the root filesystem.

You can get the system up from the initramfs shell:

# /dev/md0 is "up" but not mountable so stop it
mdadm --stop /dev/md0

# start it degraded
mdadm -q --assemble --scan

# if /dev/md0 is extfs it should be mountable now
# I use lvm and had to start manually:
lvm vgchange -ay

You may want to fix the iniramfs scripts. Ubuntu docs may be incorrect about the BOOT_DEGRADED option. The script is /usr/share/initramfs-tools/scripts/local-block/mdadm and you would need to rebuild your initrd etc.

After booting, you can finish partitioning the replacement drive with GPT and re-installing grub

Resizing

The whole point of all this was to use GPT and make use of a larger drive.
After /dev/md0 was fully synced and the system was working/bootable I extended the RAID, physical volume, logical volume and ext4 filesystems.

On new larger drives you should have made new, larger RAID partitions. (If you didn't, you should be able increase the partition without data loss using gparted).

Make sure the array is up and synced [UU] and state clean

# cat /proc/mdstat
Personalities : [linear] [multipath] [raid0] [raid1] [raid6] [raid5] [raid4] [raid10]

              md0 : active raid1 sdb3[3] sda3[2]
              3906783047 blocks super 1.2 [2/2] [UU]
              bitmap: 2/8 pages [8KB], 262144KB chunk

# mdadm -D /dev/md0
/dev/md0:
           Version : 1.2
     Creation Time : Thu May  3 22:06:08 2018
        Raid Level : raid1
        Array Size : 3906783047 (3725.80 GiB 4000.55 GB)
     Used Dev Size : 3906783047 (3725.80 GiB 4000.55 GB)
      Raid Devices : 2
     Total Devices : 2
       Persistence : Superblock is persistent

     Intent Bitmap : Internal

       Update Time : Sun Jun  2 13:45:17 2019
             State : clean
    Active Devices : 2
   Working Devices : 2
    Failed Devices : 0
     Spare Devices : 0

Consistency Policy : bitmap

              Name : mysystem:0  (local to host mysystem)
              UUID : xxxxx
            Events : 1995897

    Number   Major   Minor   RaidDevice State
       3       8       35        0      active sync   /dev/sdb3
       2       8        3        1      active sync   /dev/sda3

Now you can extend the system for more disk space

# Grow the RAID. Docs suggest using a backup file on another drive
# mdadm didn't seem to use the backup file but doesn't hurt to include

mdadm --grow --backup-file=/mnt/otherdisk/grow_md0.bak /dev/md0 --size=max

# Have to grow the physical volume. By default uses all available space
pvresize /dev/md0

# You can extend logical volumes or create new ones
# I extended an existing one to use it all
lvextend -l +100%FREE  /dev/mysystem/data

#
resize2fs /dev/mapper/mysystem-data   # should be same as /dev/mysystem/data

At this point, I have a bootable mdadm raid1 and LVM, as well as a backup USB just in case


Ubuntu One Files > Menu > Settings > Configure auto-upload > Upload directory.

Since 1.0.4. We had some issues with the update, though. We'll republish soon as 1.0.4.1.


I think you didn't install the Sublime package via PPA. You might have downloaded the source.

Here is the steps to install the Sublime package via PPA

sudo add-apt-repository ppa:webupd8team/sublime-text-2
sudo apt-get update

sudo apt-get remove sublime-text*
sudo apt-get install sublime-text

After installing this Right Click on any php file now you will be able to see "Open with Sublime Text 2" or choose "Open with Other Application" and select "Sublime" from the list.

Hope this helps.


Can't use a new formatted partition after formatting with gparted. Permissions I guess

Your partition has been formatted with a filesystem which is owned by user and group root. Change it to your user id:

mount /dev/sda3 /mnt/
chown -R AlexN:AlexN /mnt/
umount /dev/sda3


Ubuntu 18.04, can't enable the mbstring PHP extension

Re-installed mysql-server
Re-installed php

sudo apt-get install php-{bcmath,bz2,intl,gd,mbstring,mysql,zip,fpm} -y

Re-installed phpmyadmin

sudo apt install phpmyadmin php-mbstring php-gettext

Restarted Apache2

sudo systemctl restart apache2

then, executed

sudo phpenmod mbstring


I asked this question in hopes to figure out a quality solution but it would appear all we should do is Google our questions instead of posting threads that may benefit others in the future.  That being said I shall go through the following and test.

Hope this helps the next person:

Ubuntu Server Guide, chapter LAMP
ApacheMySQLPHP
How to Install And Configure Apache In    Ubuntu
How to Install Apache Tomcat on Ubuntu 12.04
ApacheTomcat5 Installation
Installing Tomcat 6 on Ubuntu Apache Tomcat


Ubuntu One directory location on Windows

The short answer is: it's dangerous to allow that, and it only worked by accident.

We had a few reports of users who had HOME set accidentally (because of other software) and had unexpected results because of it, and we were not testing it at all.

Also, currently Ubuntu One doesn't do any checks to see if you are syncing folders in a removable device. If that was the case and the device would be unmounted, you would experience sudden and complete data loss.

One of the coming features we have in our roadmap is supporting syncing arbitrary folders, inside or outside the user's profile, in a proper, secure and consistent way.

If you want, I can try to give you a personalized build that supports HOME, but you have to keep in mind that it will be untested, and I can't guarantee it will not do completely evil things to your data.


Seems like the current jvm.cfg is invalid and the /usr/lib/jvm/java-6-sun is not expected to be in the first line.

Comment out this line (add # before it) and give it a try to see if errors/warnings still appear.


The only way for the moment to have HDMI Audio support in an Nvidia card is by first installing the proprietary drivers and then selecting the HDMI Audio as output.

Install Proprietary Drivers and Reboot PC

Go to Sound Settings

Make sure that in the Hardware Tab you can see the Nvidia card and then make sure that in the Output Tab you can select the Nvidia card. Select the Nvidia Card as the output and you should hear the sound.

This should be enough to have sound in any of the Nvidia Cards that support HDMI Sound.

I have tested this with:

Nvidia GeForce GT 440
Nvidia GeForce GT 220
Nvidia GeForce GT 9500
Nvidia GeForce GTX 460
Nvidia GeForece GTX 560 TI

I also recommend using the Nvidia PPA in this question: How do I install the Nvidia drivers? which I can say has improved my Nvidia card a bit.


How to add some additional DNS search domains without ignoring the ones returned by DHCP?

You will need to edit this file with your favorite editor:

sudo vim /etc/dhcp/dhclient.conf

Once in file, you should see a commented line with the word supersede next to it:

#supersede domain-name "...."

Uncomment that line, substitute the name supersede for append, then add the domain names you wish to search (follow the example below and leave a space after the first "):

append domain-name " ubuntu.com ubuntu.net test.ubunut.com";

Save the file and close.

All you need to do is restart your network connection. You can do this by unplugging and plugging in the physical network connect OR disable and enable your network connect (see picture below). After that you should be good to go:

To verify:

sudo cat /etc/resolv.conf

Disconnect Network

Connect Network


If you don't care about Windows and are happy with default Ubuntu partitioning, the "Erase disk and install Ubuntu" option while installing in either UEFI or Legacy mode is completely fine and is the easiest way.

If you want to manually partition your hard drive in UEFI then you can keep the Windows created ESP Partition or just create your own as the wiki says (recommended size is 200 MiB, ~300MB less than Windows). You can use GParted in Live mode if you prefer it.

Also while you still have Windows installed, extract its ProductKey
because you've already paid for it. You can use that to install a genuine VM version with this ISO inside Ubuntu.


Dell 7559 15.10 version hangs while booting Live version

I installed Xunbuntu 15.10 on DELL i7559.

On the GRUB menu, press 'e'.
On the line that starts by 'linux', insert  'nomodeset' after 'splash'.
Press F10 to boot.
Install Xubuntu from the desktop.

Again, before starting Xubuntu for the first time, modify the GRUB boot like previously. After rebooting, go to Additional Drivers in Settings and select one of the NVIDIA binary driver. I tried all of them and none of them works perfectly but they work. Reboot again but this time do not add nomodeset.

Now, here is the issue with the NVIDIA binary driver: when the computer wakes up from sleeping mode, it freezes.

The only way, I found to avoid this problem, it is unfortunately to use the Intel integrated graphic cpu instead of the NVIDIA graphic card. For this, in the Additional Drivers, select:

X.Org X Server-- Nouveau display driver...

and reboot. With this driver, the computer does not freeze when it wakes up but the NVIDIA card is not used.

Other issues:

Wifi does not start automatically when it comes back from sleeping mode.
The battery life is around 4 hours but it is around 8 hours under Windows.
Errors messages when rebooting.

Otherwise, all the features of the computer work.

In conclusion, I still use Xubuntu but I am disappointing by the issues mentioned above and also to see Windows more efficient on this computer than Linux. I am waiting for the version 16.04 to see if the issues will be fixed. If not, I think to eventually move to Windows.


The wiki on touchpad troubleshooting has some commands. The command evtest is used to log events. From the 2nd link:

  evtest is not installed by default in ubuntu installation. Instead you must install it by using apt-get.

sudo apt-get install evtest

  evtest should be used outside of X. This is because the X-driver grabs the device when active. This means that the kernel delivers hw events to the driver itself and not to any other device opener (ie-evtest). This is why we should switch to a VT so that the X-driver ungrabs the device node allowing others to receive events. (Thanks to Mattia Dongili and Peter Hutterer for help on this, in an email)

  evtest needs to be able to read from the device; in most cases this means it must be run as root.

From a terminal session ...

cat /proc/bus/input/devices

will show the event your touchpad uses. Look for something like
 H: Handlers=mouse2 event8`. And then on a virtual console type

sudo evtest /dev/input/eventX > ~/evtest

and the file ~/evtest will contain all the events (do take care: it will get LARGE quickly). The link also says to use an identifier so you can find what you are looking for in the log quicker (like starting a session by pressing a A and pressing an A again when you want to stop this session).


How to install python3.5 in ubuntu 18.10 cosmic

I'd give Miniconda a try, been using it for months and it's awesome. You can install almost any version of Python on virtual envs, without messing with the system itself or the vanilla Python installed on your Ubuntu.

Just download the Miniconda3 sh script installer for Linux and execute it on a terminal, because it will ask some questions like where to install it and so on:
https://docs.conda.io/en/latest/miniconda.html


Okay, you actually have two things to worry about:

Your sources are messed up, because they're pointing to Ubuntu 10.10 repositories, which don't exist anymore because the support for that version ended (and that's why you're getting the 404 Not Found errors).
After doing a quick search on the cinnamon package, it's only available for 13.04 in the repositories. To install it on 12.04, you'll need to do some extra steps to get the PPA (the repository) that provides it for 12.04.

Here's what you should do:

Steps to reset your repositories:

cd /etc/apt && sudo cp sources.list sources.list.back1

Taking a backup of your current sources.list file, because we're going to edit it.

gksu gedit sources.list

Opening up sources.list to edit it.

When the text editor opens up, delete everything inside the file, and copy everything from here and paste it in the file.

These are the proper repositories for 12.04, using the New Zealand .

Save and close the text editor.
sudo apt-get update

This will update your packages index with the new, correct sources we added.

Steps to get and install cinnamon on 12.04

sudo add-apt-repository -y ppa:gwendal-lebihan-dev/cinnamon-stable && sudo apt-get update

This adds the PPA that contains cinnamon for 12.04 and updates the package index.

sudo apt-get install cinnamon

This should successfully install cinnamon.


Intel Graphics Installer on Ubuntu 14.04 Trusty Thar

trusty thar is lts = long time support

it don't works with imported drivers, but
comes along with his own optimized code
and will be updated regularely

usually you don't need a "driver" from
other sources

read this:
https://01.org/linuxgraphics/forum/graphics-installer-discussions/do-not-use-ubuntu-14.04


Is it possible to restore traditional full-width scrollbars (15.10)

I can still remember the happiness I felt, when I read that those horrible "overlay scrollbars" were to be abolished with Ubuntu 15.10.

However, like you, I too hate the new "half-width scrollbars" with just the same passion.

The solution came to me, as I stumbled over the following askubuntu.com posting:
Is it possible to make the scrollbars wider in 15.10?
... to disable the new scrollbars, I then did the following:

sudo editor /usr/share/themes/Ambiance/gtk-3.0/gtk-widgets.css
modified the following entries inside the .scrollbar{} selector

the has-xxx-stepper settings determine if the scrollbar arrows are shown:
-GtkScrollbar-has-backward-stepper: 1;
-GtkScrollbar-has-forward-stepper: 1;
mouse hover color effects can be disabled by adding a default background-color:
background-color: @scrollbar_track_color;
the width of the scrollbar thumb can be adjusted by modifying the -GtkRange setting:-GtkRange-slider-width: 13;

hovering effects for vertical scrollbars can be disabled by changing the margin-left and margin-right settings for .scrollbar.vertical and .scrollbar.slider.vertical to 0px;
hovering effects for horizontal scrollbars can be disabled by changing the margin-top setting for .scrollbar.horizontal:hover and .scrollbar.slider.horizontal:... to 0px;

With this I can now enjoy constant-width scrollbars once again:

Edit: Just to make everything clear, here is a diff of all the changes I made:

diff /usr/share/themes/Ambiance/gtk-3.0/gtk-widgets.css /usr/share/themes/Ambiance/gtk-3.0/gtk-widgets.ori.css
1139,1140c1139,1140
<     -GtkScrollbar-has-backward-stepper: 1;
<     -GtkScrollbar-has-forward-stepper: 1;
---
>     -GtkScrollbar-has-backward-stepper: 0;
>     -GtkScrollbar-has-forward-stepper: 0;
1143c1143
<     -GtkRange-slider-width: 13;
---
>     -GtkRange-slider-width: 10;
1147d1146
<     background-color: @scrollbar_track_color;
1167c1166
<     margin-left: 0px;
---
>     margin-left: 2px;
1172c1171
<     margin-right: 0px;
---
>     margin-right: 2px;
1179c1178
<     margin-top: 0px;
---
>     margin-top: 2px;
1197c1196
<     margin-left: 0px;
---
>     margin-left: 7px;
1201c1200
<     margin-right: 0px;
---
>     margin-right: 7px;
1205c1204
<     margin-top: 0px;
---
>     margin-top: 7px;


how to remove a symlink from /usr/bin/python in Ubuntu

You have accidentally created a link at /usr/bin/python which points to a file called /python2.7.12.

This would usually give you an error saying that /usr/bin/python already exists, but because you used the -f (force) flag. It deleted that file before it put the new link in. If I were you I wouldn't use the -f flag at all.

If you do ever need to overwrite a file, I would reccomend using rm -i to manually delete it before creating the linik with ln -s

To fix this you just have to recreate the old link by running

sudo rm /usr/bin/python
sudo ln -s /usr/bin/python2 /usr/bin/python

IMPORTANT

When you are using ln you have to put the file that you are linking to first and have the name of the link second. See the man page: ln(1).

NOTE: You should always read the man page for a command before using it.


What is the correct software to open a .tar file?

A .tar file is an archive, similar to a .zip file. It is compressed. As with a .zip file, you have to extract (decompress) the contents.

You can extract the contents with any of several graphical tools, archive manager is fine, or from the command line as follows;

tar -xvf your.tar

Here are a few more examples of using the tar command.

Usually there will be a README explaining how to use the contents of the archive to play your game. Once you have finished extracting your archive, the contents may or may not need to be compiled. Here is a quick guide on compiling an application on Linux.


How to save installed files in other drives?

You can use symlink in order to move away some folder. I don't know where your software stores its files in your home, but imagine that folder is named ethereum.

Move the ethereum folder (or move it with Nautilus)

mv ~/ethereum /media/%USER/<location where is mounted your partition>

Then create the symlink

mv /media/%USER/<location where is mounted your partition>/ethereum ~/ethereum

This will create a special file a bit like a shortcut in your home.


Your wired connection is getting that IP address from somewhere, either static or handed out by DHCP.

It is unusual, though not impossible, for your address to be 192.168.0.xxx. Linksys routers default to 192.168.1.1 and yield addresses 192.168.1.xxx. Other manufacturers will have something different from the first "1" usually.

In any event, check to see what the base address is of whatever router you are using and ensure that your IP address has the same first 3 fields the same. Do this either via DHCP or a static address.

Otherwise you are not on the same network and you will get the type of results you are indicating.


Firefox add-on gmail watcher sound problem

Got it working by installing the vlc plugin


How to make hibernation work again on 15.10 after disabling encrypted swap

Solution: the problem was in /etc/initramfs-tools/conf.d/resume where was still some wierd old UUID. After replacing with the new one and invoking sudo update-initramfs -u it works now!

Maybe if I just did these steps, it would work:

comment-out the line with /dev/mapper/cryptswap1 in /etc/fstab and
enable the line with UUID under the # swap was on /dev/sda5 during installation line (= enabling swap with no encryption)
comment-out the only line in /etc/crypttab
edit /etc/initramfs-tools/conf.d/resume in order to contain the swap's UUID from /etc/fstab
sudo update-initramfs -u
reboot and check


Does the order in which devices are listed in fstab matter?

From man fstab (Lubuntu 19.04):

fstab - static information about the filesystems

The  file  fstab  contains  descriptive  information  about the filesystems the system can
mount.  fstab is only read by programs, and not written; it is  the  duty  of  the  system
administrator to properly create and maintain this file.  The order of records in fstab is
important because fsck(8), mount(8), and  umount(8)  sequentially  iterate  through  fstab
doing their thing.

If you had a separate /home (or other directory) partition, it'd be mounted on-top of /, so of course / should be listed first.  This can be taken advantage of, though usually not with default fstab mounts.


To be able to make use of features your printer offers you will have to download and install an appropriate driver. Sadly Kodak does not make any Linux drivers.

There is a sourceforge project that offers drivers for Kodak printers:

http://sourceforge.net/projects/cupsdriverkodak/

There you will also find Debian packages including packages for 64-bit Ubuntu for installation. However I have no idea if they install and run nicely, and to what extent your printer will be supported.

Sadly in the usual case (of many other printers) we see that the drivers offered are way behind their proprietary Windows counterparts both in comfort, and in printing quality.


How can I get Google Chrome multitouch support like in OS X?

I would suggest trying easystroke for this task. I have not used it myself (since my touchpad does not support multitouch :(...).

sudo apt-get install easystroke

BTW, Chrome does not have the feature in Ubuntu because while Ubuntu does support multitouch through the use of a tech called utouch, most applications and toolkits do not yet support utouch, and are waiting on X to pick up multitouch support itself, which is probably the better solution.


The solutions;

A 1] Right click your game's properties on the steam client and untick access steam community in game.

A 2] With bumblebee installed, firstly make steam start as optirun. Eg: Add a startup program with the command optirun steam (No capitals) and then make shortcuts to your games on your desktop, this can be achieved by right clicking the game on steam and clicking "create desktop icon" once the icon for the game has been made, right click it, go properties, and at "Command" add optirun before the command. This cannot be done as a "Custom launch command" Eg: -optirun or optirun, they just don't seem to work. The finished command should be something like optirun steam steam://rungameid/225260 but with a different ID obviously.

B 1] Right click your game's properties on the steam client and untick access steam community in game.


Does the clock that appears when you click the time appear in analog by default?

Does the clock that appears when you click the time at the top of the
screen, appear in analog by default?

No. The clock by default is digital but you can use TWEAKS to extend what is displayed such as the day of the week and the date.
However, I think you are you referring to the GNOME Extension Analogue Clock


Pip not working due to old version of pip existing

PIP is a Python package manager tool, it is like the top-level package administrator, it surely cannot install itself.
It seems your Python version is 3.5, you can upgrade your PIP by using
python -m pip install -U pip