Why kernel are updated regularly, even more frequent than os releases

You observation of more regular kernel updates is partly the fault of the kernel being one giant blob of stuff that needs to work very well with the (in Ubuntu case, apt) package system (or your system will be unbootable!)

While various software bugs and security flaws serious enough to push an update are only affecting those with the respective software installed, everyone using GNU/Linux will have the Linux kernel installed. So while various apps get various updates - everyone gets the kernel updates. Consequently, each individual gets many kernel updates but only few other software updates in comparison - simply because his system has only specific software installed.

There is a terrible flaw in some RAID driver that will occasionally
render important data unreadable? Ubuntu must ship an update, for anyone
potentially affected = everyone using a kernel version including the
fault = probably everyone using a supported version of Ubuntu.
A terrible flaw in the MP4 module of the nginx web server is discovered,
potentially allowing a third party to take over a streaming server? Most Ubuntu
users do not get an update, even most who are using nginx are not getting, because
they do not have that specific module installed, and only the package containing
that module need to receive a security update.
A terrible flaw in Windows is discovered, making user applications using the
Windows System certificate store accept malicious certificates and consequently
disclose some of their meant-to-be encrypted traffic. Since patchday was last week,
application vendors will work around the bug until next month. A single kernel
update is shipped for all collected updates then, also creating some illusion of
fewer updates.
A terrible flaw in a user application on Windows is discovered.
Since Windows does not have a package manager, nobody notices. The user reinstalls his machine months later, when realizing he was part of a large botnet.

Rule of thumb: If you don’t need feature updates, use the Long-Term-Support (LTS) updates. All updates shipped to those version are, to some extent, important bug and/or security fixes.

Another note on the frequency of updates on Linux distribution in general and Ubuntu specifically: The way Microsoft and apple deploy updates is, from a security standpoint terrible. It's not that they do better software and need fewer updates, it's that they deploy updates from an economic standpoint, which means they usually don’t, even though some users (but not a economically relevant share) is affected by bad bugs.

On Linux, you see security flaws fixed within hours of being known. On some proprietary systems, maintaining companies ask security engineers to withhold information about flaws from the public for 3 months (e.g. Microsoft) and only responsibly release those until a fix is released in the usual cycle, e.g once monthly (e.g. Microsoft).

Think about the implications of security flaws getting fixed in a well-planned, but SLOW way versus the way Linux does it: best-effort as fast as possible. You'll understand why many admins prefer the open-source and Linux approach, despite increased update frequency and all potential problems such comes with.

TL;DR: Fast an frequent updates are a good thing, as long as their installation is undisruptive and seldom causing fails in automatic mode.

Note: Kernel updates will become less of a hassle in the future. Architecture for handling installation and removal of older versions via apt is being improved right now, also various Linux distributions are eyeing and/or exploring methods of deploying smaller fixes as live-patches that can be applied to a more-or-less "running" system without you needing to care a lot about it.


Okay, fixed the issue.

I had to go in using ctrl + alt + f2 and logged into my account.  I then deleted my dropbox folder (to free enough space, which was around 800mb).

At that point, I did a sudo apt-get -f install which allowed me to finish downloaded LaTex.
Once it was fully downloaded, it told me there were dependency issues, so I uninstalled it using sudo apt-get remove tex-common and then a sudo apt-get autoremove to finish it off.
Once that was finally out of the way, I could then run sudo apt-get install ubuntu-desktop, and then sudo apt-get update.

Went back to the login screen, put in my password, and I was back in.

Frustrating, but taken care of.  Thanks.


Worse gaming performance after downgrading to 14.04 LTS?

I realized that 352.63 wasn't the latest driver and upgrading to version 358 fixed the problem. 3 days of low frame rates for this...

How I updated the driver:

First I added Nvidia's proprietary driver PPA and updated sources:

$ sudo add-apt-repository ppa:graphics-drivers/ppa
$ sudo apt-get update

Then I went into Settings > "Additional Drivers," selected the latest version, and clicked "Apply Changes."

Finally, reboot to apply changes.


PlayOnLinux uses scripts to install Windows games onto your computer and get them running through Wine. The scripts download and install various Windows-specific libraries that your games might need and gets your game to be run by a certain Wine version - normally one that the script author knows works with the game - and certain Wine settings (such as whether the Wine runs in 'Windows XP' mode or 'Windows 7' mode).

The game installed with the specific libraries and Wine version are put into a 'Wineprefix' which is a certain folder on your computer which runs programs with those libraries and Wine version. These are located at ~/.playonlinux/wineprefix.

Of course, understanding how Wine itself works is a different question altogether. You can learn more about Wine itself here.

Sources:
Own knowledge
PlayOnLinux Wikipedia entry


Ubuntu 11.10 - How can i install xserver-xorg-input-evtouch? apt-cache search do not show up

I use Ubuntu 11.10 64-Bit, and I don't see it either. Try searching: xserver-xorg-input, and trying one of those packages.


SMART support is available but goes back to Disabled on restart

Edit your /etc/rc.local file with your favourite text editor, ie: nano /etc/rc.local and add the command to enable smart support before the last line of the script:

#!/bin/sh -e
#
# rc.local
#
# This script is executed at the end of each multiuser runlevel.
# Make sure that the script will "exit 0" on success or any other
# value on error.
#
# In order to enable or disable this script just change the execution
# bits.
#
# By default this script does nothing.

smartctl -s on /dev/sda

exit 0

Save the changes with Ctrl+O and then Ctrl+X.

That script is runs on every boot so that would enable smart support for that disk on every boot.


Can't set SUPER key to open launcher [Kubuntu KDE Plasma 5]

If someday you decide to come back to Kubuntu , just try Ksuperkey
Simply run make and execute the resulted binary.All done !
It works well for me.
It maps the Super key to Alt+F1 when you "press and release" it , but the Super key still can be used in cooperation with other keys while you're just pressing and holding it.


My browser is lagging after I upgraded to Ubuntu 18.04

If they are not working properly like before, it maybe because you have less ram than you need! please install htop using this command:

sudo apt install htop

then open a terminal and type htop. now just open your browser and work with it. after you see lags on your system check the terminal you opened before. it will give you information about your resources and how much you are using of it.

if you are using HDD instead of SDD, and your Swap is configured, please check if it is used or not! it is good way to find out how much ram you need by default!!! (SDD hards mostly can work like RAM, but it cause highly usage on disk and your disk will be took damage faster than normal.


How update Unity (14.04LTS) at the same version that 15.10?

You need to choose what you prefer: polished stable soft or new versions with bugs. If you want to use new unity you have to upgrade to 15.04, and then to 15.10.


Yousician on Ubuntu 16.04 requires OpenGL3.2

I discovered I can't activate OpenGL 3.2 at this laptop because the gfx card won't support it.


Internet connection not working although it says it is connected

You are on the right track. the resolv.conf was changed for VPN use and was not changed back for normal use as a result of the crash. Deleting the old resolv.conf may help. You can make a backup copy of the file and delete the original with this single command:

sudo mv /etc/resolv.conf /etc/backup.resolv.conf

A new resolv.conf will be generated as and when needed. See the answer to the following question:

Can not access Internet (DNS names do not resolve) after update today

Also see:

http://www.stgraber.org/2012/02/24/dns-in-ubuntu-12-04/

Hope this helps.


Is it possible to create a live USB stick with a clone of my desktop installation

Check out remastersys. It allows you to create a LiveCD image from your running system. Once you have a CD image, it can be easily converted to a USBstick-image. Check Ubuntu Live USB creator


How do I use an older Java version without downgrading?

Nevermind. I'm currently working on a solution; this includes installing openjdk-7-jre and using the java7 command (to my knowledge; untested).


Super-Alt-8 and Super-Alt-+ scales too much

Unfortunately it's not possible. Delta values +1 and -1 are "hardcoded" and can't be changed. Maybe in future versions it will change. If that helps you can define the initial scale factor by running gsetting command.

Super-Alt-8 keeps original window unchanged:

gsettings set org.gnome.desktop.a11y.magnifier mag-factor 1.00

Super-Alt-8 original window zoomed a little:

gsettings set org.gnome.desktop.a11y.magnifier mag-factor 1.25

mag-factor value can also be changed from "Magnifier Preferences Dialog" as found in "Universal Access Panel". Just type "Universal Access" in GNOME search box and look for ZOOM options.

For more information follow link:

https://wiki.gnome.org/Projects/GnomeShell/Magnification


I solved my self.
started nautilus as root and shift-deleted the .local trash folder.

im still newbie in ubuntu


does this app profile prevent all programs installed by wine by playolinux and by winehq from accessing the internet?

UFW allows or blocks ports, not applications.

So although you can use standard applications rather than ports, ufw converts some application names into ports.

So ...

ufw allow 80
ufw allow http

both do the same thing, open port 80 to any server listening on port 80, Apache, Nginx, or any other web server.

UFW translates these names from /etc/services , however, /etc/services in NOT comprehensive.

So you can find services such as http in /etc/services, and use that syntax in UFW

But you will not find Apache, nginx, or specific web servers.

See https://help.ubuntu.com/community/UFW#Services

Likewise you can not use wine

I believe from your question you are looking or what is termed an application firewall, one where you allow or deny by application.

you could use apparmor, and some would advise you do so, but that is going  to be much more complicated.

See How to control internet access for each program? or similar for application level firewalls .

I am not sure how or if there is an easy option for wine or you you would have to specify each and every application run in wine.


What type of file am I looking for when attempting to add an executable to startup applications?

Seeing as you are coming from windows, I will try to give you a better understanding of how applications work on linux.

Executables do not normally have a file extension; the are normally found in /usr/bin (as opposed to C:\Program Files\Vendor\Program\Executable.exe), and simply have the application's name (for example, docky = /usr/bin/docky). Desktop files allow for applications to be run with an icon, optional arguments, etc.

To add an application to your start up files, you can open the startup applications manager, click add, and type the application's name (usually this is the name of the executable).

For example, to start emesene (a chat client) you would add emesene to your startup applications.

As a rule: any file can be marked as an executable, even if it is not a program. For this reason, you should be sure to get a better understanding of how executables in linux work, before trying to do any administrative tasks.


Pin virtualbox to core(s) on precise pangolin (12.04)

You are right VirtualBox is not the only process that needs to be contained, but it's more than just a front end.

Short answer: Try binding VBoxSVC.

Long answer:

You should probably use top (or better htop) in your computer to find the component that is doing the work in your situation, Virtualbox spans at least two background processes VBoxSVC, that at least in my computer looks like the main CPU user and VBoxXPCOMIPCD that looks like some kind of communication server.

Note that only one of each processes are spawn for each user even if multiple VMs are started by the same user. I don't know if binding just them will work for you own needs.

For further information this article have loads of information about how VirtualBox works.


Who to follow on Twitter if you are interested in Ubuntu?

These are people related to Ubuntu, in some capacity or other. Most of them are developers, and UI designers. Some are fansites. I will keep adding more as I find them.

Ubuntu Evangelist, and owner of Canonical: Mark Shuttleworth.

Unity’s Technical Lead and Canonical DX Team Member: Neil Patel.

Fansite: OMG Ubuntu.

Fansite: Ubuntu Gamer.

Blog and Fansite: Planet Ubuntu.

Linux.

Canonical Design Team Lead: Ivanka Majic

Ubuntu Engineering Director: Rick Spencer

UX & visual designer for Ubuntu: Mateusz Tomaszewski

Open Source Consultant, Developer: Richard Johnson

Ubuntu Community Manager: Jono Bacon

Official Twitter Channel of The Ubuntu Cloud: UbuntuOne

The Canonical Design Team: Ubuntu Designers

Project Manager at Ubuntu: Iain Farell


You need to enclose the whole command into double quotes. Without double quotes you are redirecting output of xterm command, which by itself doesn't do anything. In other words, you need to be specific about what you are redirecting

Demo:

xieerqi:$ xterm -e "printf hello world > /home/xieerqi/REDIR "

xieerqi:$ cat REDIR
hello
xieerqi:$ xterm -e printf hello world two > /home/xieerqi/REDIR

xieerqi:$ cat REDIR

xieerqi:$


Which version of Tweak Tool suitable for 14.04 LTS?

Its Unity Tweak Tool 0.0.6 version and it will be available in software center.


GPARTED : Merge partition with unallocated partition

Your sda4 "extended" is sort of secondary partition table. If you are not planning to use more than 4 partitions in the future - and it looks like you don't, as you want to assign all the available space - just delete it, and then extend your sda3.

In other words: sda4 is not an actual partition with files, and you don't have to worry about merging any data, just extend sda3.


How to create command line application in eclipse (c++ or java)?

In C++ you can use int system (const char* command); function.

Example:

/* system example : DIR */
#include <stdio.h>      /* printf */
#include <stdlib.h>     /* system, NULL, EXIT_FAILURE */

int main ()
{
  int i;
  printf ("Checking if processor is available...");
  if (system(NULL)) puts ("Ok");
    else exit (EXIT_FAILURE);
  printf ("Executing command DIR...\n");
  i=system ("dir");
  printf ("The value returned was: %d.\n",i);
  return 0;
}

Source: http://www.cplusplus.com/reference/cstdlib/system/

In your case you can use:

system ("sudo apt-get upgrade");

In Java is slightly more complicated. You can use exec method of the Runtime class in java.lang. See http://www.linuxforums.org/forum/programming-scripting/65117-c-c-system-function-analog-java.html


Assuming that return value is 1 for "cancel" and 0 for "ok" you will want to use:

#!/bin/sh
#InputBox1Test

title=$(zenity --entry --text 'Type what you want your Notification Title to Say!' --title 'Notification')
[[ "$?" != "0" ]] && exit 1
text=$(zenity --entry --text 'Type what you want your Notification body to Say!' --title 'Notification')
[[ "$?" != "0" ]] && exit 1
DISPLAY=:0.0 notify-send "$title" "$text"

You can make a longer traditional check like this:

if [[ "$?" != "0" ]] ; then
    exit 1
fi

however I like the shortcut of:

[[ "$?" != "0" ]] && exit 1

No matter which method you choose the importance is consistency with your programming style so those that follow in your footsteps and maintain your code can think inside your head.


In short, yes. You can add a ppa with the deb (Google does something similar for example).


Using GNU parallel:

max_processes=100
parallel bash _spawn.sh ::: $(seq 1 $max_processes)

This will run as many parallel processes that you have CPU cores at the same time

Check https://www.gnu.org/software/parallel/

To figure out how it run, N*CPU cores at a time, you can test it:

parallel 'sleep 1; echo arg {1}' ::: {0..100}

Output:

arg 0
arg 1
arg 2
arg 3
arg 4
arg 5
arg 6
arg 7

So I have 8 CPU cores and 8 // processes at a time


I read the link Zanna provided in comments but there is something else you should look at: Bay Trail Freezing. There are over 500 messages here from Bay Trail users (plus a few other Intel CPUs).
The messages start in December 2015 so scroll down 3rd from the end (as of October 24, 2016) and you will see this post:
Justin 2016-10-22 21:58:34 UTC
One week so far no crashes.  4.8.0-rc8-amd64

Options

GRUB_CMDLINE_LINUX_DEFAULT=intel_idle.max_cstate=5

In rc.local this script is run at boot...

 -----

#!/bin/bash
echo 1 > /sys/devices/system/cpu/cpu0/cpuidle/state3/disable
echo 1 > /sys/devices/system/cpu/intel_pstate/no_turbo

thanks

I've read hundreds of these posts and some users can report "success" one day and the report back with "failed again!" a few days later. Above the author recommends Kernel version 4.8.0-rc8 but I would recommend using stable kernel version 4.8.4 instead. A summary for doing this is:
cd /tmp
wget http://kernel.ubuntu.com/~kernel-ppa/mainline/v4.8.4/linux-headers-4.8.4-040804_4.8.4-040804.201610220733_all.deb
wget http://kernel.ubuntu.com/~kernel-ppa/mainline/v4.8.4/linux-headers-4.8.4-040804-generic_4.8.4-040804.201610220733_amd64.deb
wget http://kernel.ubuntu.com/~kernel-ppa/mainline/v4.8.4/linux-image-4.8.4-040804-generic_4.8.4-040804.201610220733_amd64.deb
sudo dpkg -i *.deb
sudo reboot

Note: Version 4.8.4 is the most current stable kernel as of October 24, 2016.
October 30, 2016 update
From today's bug mail the following solution was proposed:
thorsten: Try the commands below, and report back. These eliminate hang ups on
my N2930 with kernel 4.7 (Gentoo).

First start kernel with: intel_idle.max_cstate=0

Then give these commands as root:

echo 1 > /sys/devices/system/cpu/intel_pstate/no_turbo
echo 1 > /sys/devices/system/cpu/cpu0/cpuidle/state3/disable
echo 1 > /sys/devices/system/cpu/cpu1/cpuidle/state3/disable
echo 1 > /sys/devices/system/cpu/cpu2/cpuidle/state3/disable
echo 1 > /sys/devices/system/cpu/cpu3/cpuidle/state3/disable


Connecting and disconnecting a modem to get a new ip

You can do this using NetworkManager:

Deactivate : nmcli con down id "connection name"
Re-activate : nmcli con up id "connection name"


Permanently pin printer indicator to top toolbar?

There is supposed to be an indicator already but it doesn't work.

https://bugs.launchpad.net/ubuntu/+source/indicator-printers/+bug/1304434

In the meantime use System Settings → Printers → printer_name → View Print Queue.


glyrc is the CLI program you're looking for.  Once you've got it compiled and installed, this script will do what you want

#!/bin/ksh

if [[ $# -eq 0 ]]; then
  echo "Usage: $(basename $0) music_file.mp3"
  exit 1
fi

FILE="$1"

ALBUM="$( id3v2 --list "$FILE" |sed -n 's/TALB[^:]*: *//p' )"
ARTIST="$( id3v2 --list "$FILE" |sed -n 's/TPE1[^:]*: *//p' )"

glyrc cover --artist "$ARTIST" --album "$ALBUM"

To compile glyrc following the author's directions you must first

sudo apt-get install libsqlite3-dev libcurl3-dev cmake libglib2.0-dev


How can I log terminal output to a file but leave the terminal window active to allow answering of prompts?

While answering you are giving input via file descriptor 0 i.e. STDIN and the program is showing output on file descriptor 1 i.e. STDOUT. As you can see these two are wowking on different file descriptors and manipulating one should not hamper the operation of other.

Note that there is also file descriptor 2 i.e. STDERR normally used for showing error messages.

In you case run the script as:

./myscript.sh >~/script.out

Now you can provide input answers to the questions of the script via STDIN and the output of the program will be saved in ~/script.out.

You can save the error also e.g. in another file:

./myscript.sh >~/script.out 2>~/script.err

The STDOUT will be saved in ~/script.out and the STDERR will be saved in ~/script.err.

You can save the output and error both in the same file:

./myscript.sh >~/script.all 2>&1

Now ~/script.all will contain the outputs and error messages (if any) from myscript.sh.


SynPS/2 Synaptic Touchpad not working in Ubuntu 17.10

Run this command in terminal:

  sudo gedit /etc/default/grub

You will find a line like this:

GRUB_CMDLINE_LINUX_DEFAULT="quiet splash"

Now replace "quiet splash" with "acpi=force"

So the new line will be:

GRUB_CMDLINE_LINUX_DEFAULT="acpi=force"

Save the file.

Now run this command:

  sudo update-grub

This should solve your problem.


I have the same keyboard and this was driving me nuts for exactly the same reason.
Anyway, the fix in this Reddit thread solved it for me.

By editing /etc/systemd/logind.conf and setting HandleSuspendKey=ignore, I'm able to press the Fn+L combination without anything happening.


How to pass addional script to an already existing ssh script

In my opinion the entire approach could be improved:

First you can use Key-Based SSH Login to securely authenticate yourself without password - just leave the passphrase empty when generate the key.
Next you can create ~/.ssh/config file to ease the process of the creation of ssh connection.
Then the automation script could execute just these steps:

use scp (or rsync) to copy your script to the remote machine;
run the script remotely and then delete it.

Alternatively you can mount a folder to the remote machine using sshfs and then just run the script remotely.


Should I remove old Wifi adapter driver?

You should not need to uninstall the old driver unless it's causing issues.
If you want to uninstall the old driver to clean up your system, I would try this command

dkms status

You may see some results like this:

8812au, 4.2.2, 4.15.0-43-generic, x86_64: installed
nvidia, 390.77, 4.15.0-29-generic, x86_64: installed
nvidia, 390.77, 4.15.0-43-generic, x86_64: installed
rtl8812au, 4.2.2, 4.15.0-43-generic, x86_64: built
rtl8812au, 4.3.8.12175.20140902+dfsg, 4.15.0-43-generic, x86_64

From here you can see which drivers are installed, so remove them by typing
(Replace 4.2.2 with your versions)

sudo dkms remove 8812au/4.2.2 --all
sudo dkms remove rtl8812au/4.2.2 --all
sudo dkms remove rtl8812au/4.3.8.12175.20140902+dfsg --all

Here's an answer I found that may help you:
https://askubuntu.com/a/1104342/1029522


Strange question. Yes, of course, you can install 64-bit Ubuntu to 64-bit PC (if it meets other requirements, of course). And if you think it is old this does not mean that it is really old. The newer word in this case means that 64-bit architecture is slightly younger than 32-bit, that's all.

Other Requirements:

AMD64 CPU
1 GB RAM
5.4 GB Free Space on hard drive
(Recommended) Internet connection


Problems with internet access via modem . Ubuntu 15.10

I had similar issue, don't know how to solve it permanently, but what I do to connect to the internet is going to System Settings -> Network -> Mobile Network[or sth like that, I don't have english software], then in the select you choose to add new connection proceed normally. It should connect to the internet, and you should be able to ping 8.8.8.8


PPTPD failed after upgrading ubuntu server to 15

This wasn't a complete fix for me, but it got me past the error:
"pptpd-logwtmp.so is for pppd version 2.4.5, this is 2.4.6"

If you edit the conf file:

sudo nano /etc/pptpd.conf

you can disable the logwtmp option by adding a # before it.

The issue appears to have been logged as a bug here:

https://bugs.launchpad.net/ubuntu/+source/pptpd/+bug/1451419

The suggestion to disable logwtmp came from a similar, but older bug:

https://bugs.launchpad.net/ubuntu/+source/pptpd/+bug/352622

Having got past that problem, the other part of the issue (at least in my case), was that GRE packets were not making it through my UFW firewall. That appears to be the problem for the author of this question as well. For some reason GRE was working fine under 14.10, but after I upgraded to 15.04, this stopped working.  I found the solution in Dikei's answer to this question:
Can't connect to PPTP VPN with ufw enabled on Ubuntu 14.04 with kernel 3.18

I added this rule to the file /etc/ufw/before.rules before the line # drop INVALID packets ...

-A ufw-before-input -p 47 -j ACCEPT

I had to stop and restart UFW (I did this via the GUI) before the change took effect.


How to resolve 'gdk-pixbuf/gdk-pixbuf.h: No such file or directory'

There's a generic “teach a man to fish…” answer here, too:

Install the apt-file package, and use it to search for the package containing the file you need.  In this case, you get:

└─(14:36:%)── apt-file search gdk-pixbuf/gdk-pixbuf.h
libgdk-pixbuf2.0-dev: /usr/include/gdk-pixbuf-2.0/gdk-pixbuf/gdk-pixbuf.h
libgfcui-dev: /usr/include/gfc-2.0/gfc/gdk-pixbuf/gdk-pixbuf.hh
lsb-build-desktop3: /usr/include/lsb3/gtk-2.0/gdk-pixbuf/gdk-pixbuf.h

which has (surprisingly) returned more than one result.  libgdk-pixbuf2.0-dev is the package you're after.


What to do when I get an "attempt to read or write outside of disk 'hd0'" error and Boot Repair does not solve the problem?

Locate the partition in which linux is present with the help of following technique

grub rescue > ls
(hd0) (hd0, msdos9)
grub rescue > ls (hd0,msdos9)/
grub rescue > ls (hd0,msdos8)/
grub rescue > ls (hd0,msdos5)/ # suppose this is root and bootloader of linux
grub rescue > ls (hd0,msdos5)/
grub rescue > set root=(hd0,msdos5)
grub rescue > set prefix=(hd0,msdos5)/boot/grub
grub rescue > insmod normal
grub rescue > normal

Now, system's boot menu appears. Boot into linux.

sudo update-grub
sudo grub-install  /dev/sda # If the drive is hd0 the equivalent is sda, if it's hd1 then use sdb

This fixes boot loader.


There were 2 issues: conky permissions, and network interface (NIC) name.
The short summary is:

run this command to give Conky the needed permissions:

sudo setcap cap_net_raw,cap_net_admin=eip /usr/bin/conky

Rename your wireless NIC from eth1 to wlan0. Here is how.

Why?

Some people had suggested (in their websites) that the problem might be with the boradcom wireless adapter, which blocks conky request to get the adapter's info, but since the command-line tool iwlist was able to get the list of wireless networks in my neighborhood, I doubted that blocking requests would be the issue, though another command line tool iwspy was unable to get info.

You can get a detailed list of wireless networks in your neighborhood using the command-line tool iwlist:

iwlist eth1 scan

Indeed, one of the issues was this lack of having appropriate root user priviledges. Apparently, Conky needs to have root priviledges to access network libraries and functionalities. If you don't want to run conky with root priviledges, there is a way (since Linux kernel 2.2) to give programs the priviledges they need without running them under root priviledges. You can give any program (its executable binary file) partial root priviledges for performing specific functionalities (eg. network functionalities, filesystem functionalities, etc). This is fully explained in this man page, and partially here. So, we need to delegate (to Conky's binary file) the appropriate root priviledges to perform network-related tasks and to capture raw packets from wire/wireless adapter. In other words, tasks are categorized into different categories of priviledges. Two of these access categories (which conky needs them) are called cap_net_admin and cap_net_raw. We need to give conky these classes of permission. This is done by the following command (source: here):

sudo setcap cap_net_raw,cap_net_admin=eip /usr/bin/conky

In addition to this permission issue, a reply to a topic gave me a clue that the name of my network interface card (NIC) (in this case my wireless adapter) might be the source of the problem, since conky "assumes" that the interface names starting with "eth" (eth1, in my case) are ethernet (cable) network cards and thus, these cards are not supposed to represent signal strength. Although the clue was very precious, but no solution was offered there in the above-mentioned topic. I thought renaming the interface may resolve the problem, and indeed it did! I renamed wireless interface (which was named eth1 by default) to wlan0. Here, you can find how to rename a network interface card in Linux. Just note that in that article, they renamed the interface to "wan0", I renamed it to wlan0.

And here is the network part of my .conkyrc config file:

${if_existing /proc/net/route eth0}
${voffset -6}${font PizzaDude Bullets:size=14}O${font}   Up: ${upspeed eth0} kb/s
${alignr}${upspeedgraph eth0 8,60}
${voffset 4}${font PizzaDude Bullets:size=14}U${font}   Down: ${downspeed eth0} kb/s ${alignr}${downspeedgraph eth0 8,60}
${voffset 4}${font PizzaDude Bullets:size=14}N${font}   Upload: ${alignr}${totalup eth0}
${voffset 4}${font PizzaDude Bullets:size=14}T${font}   Download: ${alignr}${totaldown eth0}
${voffset 4}${font PizzaDude Bullets:size=14}Z${font}   Signal: ${wireless_link_qual eth0}% ${alignr}${wireless_link_bar 8,60 eth0}
${voffset 4}${font PizzaDude Bullets:size=14}a${font}   Local Ip: ${alignr}${addr eth0}
${voffset 4}${font PizzaDude Bullets:size=14}b${font}   Public Ip: ${alignr} ${execi 3600 wget -O - http://ip.tupeux.com | tail}
${else if_existing /proc/net/route wlan0} ${voffset 4}${font PizzaDude Bullets:size=14}Z${font}   Signal: ${wireless_link_qual wlan0}% ${alignr}${wireless_link_bar 8,60 wlan0}
${voffset 4}${font PizzaDude Bullets:size=14}O${font}   Up: ${upspeed wlan0} kb/s ${alignr}${upspeedgraph wlan0 8,60}
${voffset 4}${font PizzaDude Bullets:size=14}U${font}   Down: ${downspeed wlan0} kb/s ${alignr}${downspeedgraph wlan0 8,60}
${voffset 4}${font PizzaDude Bullets:size=14}N${font}   Upload: ${alignr}${totalup wlan0}
${voffset 4}${font PizzaDude Bullets:size=14}T${font}   Download: ${alignr}${totaldown wlan0}
${voffset 4}${font PizzaDude Bullets:size=14}a${font}   Local Ip: ${alignr}${addr wlan0}
${voffset 4}${font PizzaDude Bullets:size=14}b${font}   Public Ip: ${alignr} ${execi 3600 wget -O - http://ip.tupeux.com | tail}
${endif}

And finally here is some extra commands for displaying and removing capabilities (partial and categorized root priviledges) of (executable/binary) files:

You can find out the permissions that each file has by running the following command:

getcap filepath/filename

And remove all permissions (capabilities) of a file:

setcap -r filepath/filename


In Ubuntu, we don"t use RPM (RedHat) packages but DEB (Debian) packages.

If you have an ISO file, you have thus a CD-ROM image you can use to install the OS on a PC where the OS is not yet installed.
If you have packages (one package = one software, one OS is composed of a multitude of packages), you need at least to have an running installation of the OS to which these packages belong to proceed further.


How to properly partition my HDD for Ubuntu?

"Erase disk and install Ubuntu" is supposed to work and it would be probably then also crash if choose the other option. Maybe there is an issue with the bootstick, you could check the md5 sum of your downloaded .iso file and maybe create a new bootstick.


How to configure English keyboard for Brazilian users to have cedilha character

Based on my earlier answer to a similar question:-

Press whatever you have set as the compose key then a then e in sequence will produce æ

This solution is much simpler, as you don't have to know the unicode for the character you wish to type. So, for example, press compose key then  o  then e will produce œ. compose key then c then , (comma) will produce ç and so on.

I use the Right Windows key as the compose key as it isn't really used in the context of typing characters in Ubuntu.

If you don't already know, you can set the Compose Key by going to System Settings>Keyboard>Typing>Compose Key


to deploy custom images in MAAS you need to have a subscription from Canonical.
You can see here.
https://maas.io/docs/image-builder

And here:
https://ubuntu.com/pricing/infra


How Do I manually remove malformed Packages?

Try :

sudo vi /var/lib/dpkg/status

remove all entries about the package and save , then try again.

sudo apt-get update


Internal laptop screen stuck on Ubuntu loading screen, secondary monitor working just fine. (Ubuntu 18.04)

I did not have this issue myself, but here is an educated guess, informed by other cases of "stuck on the loading Ubuntu screen with the 5 dots":

The display manager (which should display the login screen) cannot start until the graphical "loading Ubuntu" screen has finished, which seems to not happen for your internal display. Since that graphical "loading Ubuntu" screen does not necessarily display on all available screens, that could be the reason why your external screen is unaffected.

A good indicator of this cause for the problem is when you have the following message in /var/log/boot.log:

A start job is running for Hold until boot process finishes up (Xmin Xs/no limit)

The graphical "loading Ubuntu" screen is called plymouth, and it is not essential at all. When it is not installed, a text-mode screen will show the five dots instead. So the following may already fix your issue:

sudo apt remove plymouth

And then reboot. For variants of this solution, some specifically from people with Nvidia driver issues, see this question.


Black Screen with Cursor after installing CUDA 7.5 on 14.04

Ok, after many more installs of ubuntu and re-configurations I found that the error was being caused by me installing both the current nvidia graphics driver as well as the accelerated graphics driver packaged with the cuda toolkit. They were conflicting and causing the system to never load into tty7.


Look at your /etc/passwd file
Find your user and look shell (example ttr:x:501:501::/home/ukraine/ttr:/sbin/nologin)
Add this shell (/bin/false or /sbin/nologin) to your /etc/shell or /etc/shells

After that, check your connection

  Status:  Retrieving directory listing... Command:    PWD Response:   257 "/home/ukraine/ttr" Status: Directory listing successful


Probably kernel logging is disabled in (r)syslog.
Add this in /etc/rsyslog.conf file:  kern.warn /var/log/firewall.log and reload syslog.

After, make some rule like, iptables -A -p tcp --dport 22 -j LOG --log-prefix " ALERT " --log-level=warning

And scan your SSH port.


Open365 will not install on Ubuntu 16.04

After some research we have concluded that this is a known issue that should be remedied in the next release for Ubuntu 16.04 updates:

Bug #1573206


Why is my default sources.list so short?

You seem to have chosen something like “only the main repository” during the OS installation or are affected by a known bug.

If it’s not what you like, you should edit the file with the contents you want. You should check What is the correct output of cat /etc/apt/sources.list and/or the Ubuntu Sources List Generator for what the file can contain.

  Any way to change it without manual edits after the fact?

You could use a GUI application to manage repositories in the Desktop edition. In the Server edition (without GUI), you can still use the contents from the generator or another Ubuntu machine. Anyway, manually editing configuration files is the default way in the Server edition.


Bash script not working as required with xbindkeys

Probably the easiest thing to do would be to specify to xbindkeys that your script should be launched with gnome-terminal (or equivalent), for example, and minimise the size of the terminal. You could replace your entry in ~/.xbindkeysrc with:

"gnome-terminal --geometry=1x1+1141+27 --hide-menubar -e /home/ranveer/capsnotify.sh"
 m:0x2 + c:66

We gained the geometry readout of the terminal by placing it at the top right hand corner of the screen and then running xwininfo and clicking on the window. By specifying such a small terminal (1x1) and its top right hand position (1141+27) and hiding the menubar, we can ensure that a thumbnail sized terminal actually opens momentarily underneath the caps lock notify messages at the top right of the screen. It should be possible to specify the geometry like this with other terminals such as well.

After any changes to ~/.xbindkeysrc, you must enter

killall xbindkeys

and then

xbindkeys

for the new changes to be read.

In the screenshot below, I pressed caps-lock twice very quickly so that the first notify-send message had not yet disappeared:

There may be other ways of solving the problem, but this is a quick reliable one that does not entail any rewriting of your script or installing other programs.


Intel graphic chipset and NVIDIA Geforce GTX560

finally i got it working, the main issue was the configuration of the BIOS where i need to force the Nvidia card to be the first one to initialize.

here is my xorg.conf with some comments :

# two X servers, one on nvidia GPU with 2x1920x1080 @ 60Hz video beamer and one with a full HD monitor on Intel GPU
Section "ServerLayout"
    Identifier     "Layout0"
    Screen      0  "Screen1" 0 0
    Screen  1  "Screen0" 1920 0
    InputDevice    "Keyboard0" "CoreKeyboard"
    InputDevice    "Mouse0" "CorePointer"
    Option         "Xinerama" "0"
EndSection

Section "Files"
EndSection

Section "InputDevice"
    # generated from default
    Identifier     "Mouse0"
    Driver         "mouse"
    Option         "Protocol" "auto"
    Option         "Device" "/dev/psaux"
    Option         "Emulate3Buttons" "no"
    Option         "ZAxisMapping" "4 5"
EndSection

Section "InputDevice"
    # generated from default
    Identifier     "Keyboard0"
    Driver         "kbd"
EndSection

Section "Monitor"
    # HorizSync source: edid, VertRefresh source: edid
    Identifier     "Monitor0"
    VendorName     "Unknown"
    ModelName      "Idek Iiyama PLE2607WS"
    HorizSync       29.0 - 81.0
    VertRefresh     55.0 - 76.0
    Option         "DPMS"
EndSection

Section "Device"
    Identifier     "Device0"
    Driver         "nvidia"
    VendorName     "NVIDIA Corporation"
    BoardName      "GeForce GTX 560"
    BusID      "PCI:1:0:0"
    Option     "CustomEDID" "CRT-0:/etc/X11/InFocus-IN5316.bin; CRT-1:/etc/X11/InFocus-IN5316.bin"
EndSection

Section "Device"
    Identifier     "Device1"
    Driver         "intel"
    BusID      "PCI:0:2:0"
EndSection

Section "Screen"
    Identifier     "Screen0"
    Device         "Device0"
    Monitor        "Monitor0"
    DefaultDepth    24
    Option         "TwinView" "1"
    Option         "TwinViewXineramaInfoOrder" "CRT-0"
    Option         "metamodes" "CRT-0: 1920x1080_60_0 +0+0, CRT-1: 1920x1080_60_0 +1920+0; nvidia-auto-select +0+0"
# here I'm using specific EDID file to force resolution/refresh rate because i got some EDID error with 20m VGA cables.
    Option     "CustomEDID" "CRT-0:/etc/X11/InFocus-IN5316.bin; CRT-1:/etc/X11/InFocus-IN5316.bin"
    SubSection     "Display"
        Depth       24
    EndSubSection
EndSection

Section "Screen"
    Identifier     "Screen1"
    Device         "Device1"
    Monitor        "Monitor0"
    DefaultDepth    24
    Option         "metamodes" "1920x1080_60_0 +0+0"
    SubSection     "Display"
        Depth       24
    EndSubSection
EndSection

with this configuration I'm able to use GPU acceleration on Nvidia's server but not on Intel's one, I don't know why yet.
GLX extension is not present on Intel's server.
For my configuration this is not a big issue because Intel server is just for monitoring video tracking information and control and setting up the video projection.
But if someone knows how to enable GLX both on Intel and Nvidia, I would appreciate some tips.
Notice that there is no error in the Xorg.0.log related to GLX or something else, so I'm guessing I'll need to force GLX to be loaded both on Nvidia and on Intel servers.

Moreover, i have a another small issue with this configuration.
As I have two computers with the same configuration, I'm using a KVM switch plugged to the monitor to control one and the other computer alternatively. But when computer starts, if the KVM is displaying the other one, the resolution drops down to 1024x768.
I need to force it to 1920x1080 even if there is no connected monitor. But I don't know how yet.

Hopes this helps.

A.


Thank you for this i was struggling mounths to find a solution

My Pc was shutting off every time it was so hot , and i was thinking it was the CPU fan not working well
But after installing lm-sensors i found :

ucefkh@01Tek:~$ sensors
atk0110-acpi-0
Adapter: ACPI interface
Vcore Voltage:      +1.26 V  (min =  +0.85 V, max =  +1.60 V)
 +3.3 Voltage:      +3.23 V  (min =  +2.97 V, max =  +3.63 V)
 +5 Voltage:        +5.02 V  (min =  +4.50 V, max =  +5.50 V)
 +12 Voltage:      +12.09 V  (min = +10.20 V, max = +13.80 V)
CPU FAN Speed:     675000 RPM  (min =  600 RPM)
CHASSIS FAN Speed: 2934 RPM  (min =  800 RPM)
CPU Temperature:    +20.0°C  (high = +60.0°C, crit = +95.0°C)

radeon-pci-0400
Adapter: PCI adapter
temp1:        +56.0°C

coretemp-isa-0000
Adapter: ISA adapter
Core 0:       +38.0°C  (high = +86.0°C, crit = +100.0°C)
Core 1:       +39.0°C  (high = +86.0°C, crit = +100.0°C)

Now i just applied the propriety driver and i think it is working well !


I didn't test this but the following should work:

rsync -av --include "*/" --include "*.html" --exclude "*" ~/.gvfs/. /path/to/destination


How do I install 18.04 using full disk encryption with two drives (SSD/HDD)

HOWTO Encrypt an Ubuntu 18.04 LTS Installation with TWO Drives: OS on the primary SSD, /home on your secondary HDD
This is a guide to FULL DISK ENCRYPTION of an Ubuntu 18.04 LTS install.  Not to be confused with the encryption of just the /home directory, which I believe has been removed as an option during install.  These instructions are for Ubuntu 18.04 LTS, but should work with 16.04 LTS.
This guide assumes that you are familiar with Ubuntu (Linux) and can install the OS from a USB key, or at least understand how to do this procedure – if you can’t, find someone who can and the both of you go through it.  This guide also assumes that you have backed up ALL your data prior to beginning this procedure as you will destroy all DATA on ALL drives during this procedure.
YOU HAVE BEEN WARNED!
This guide is largely a meld of the two procedures from here (David Yates’ blog post) (https://davidyat.es/2015/04/03/encrypting-a-second-hard-drive-on-ubuntu-14-10-post-install/) and the Ask Ubuntu post (Move home folder to second drive).
First things first, why do we wish to do this?  Because if you own a laptop, or other sensitive data on a computer and it gets stolen or lost, it is necessary to be able to protect the data.  You may be legally responsible to have protected the data.  Secondly, many (most) systems now come with a small SSD (fast) for the OS and larger HDD (slow) for the data.  Thirdly, encrypting just the /home directory is now recognised as a bad idea as it exposes you to the potential of /home being hacked (don't ask me how to do it, I couldn't), AND partial encryption slows down the system to a large degree.  FDE requires less overhead and therefore has minimal impact on the performance of the system.
PART I: Install Ubuntu 18.04 LTS on the primary drive (usually the SSD)
Install Ubuntu 18.04 LTS onto your smaller (usually the SSD) and check (i) erase the disk, (ii) encrypt the installation, and (iii) LVM management.

This will result in an encrypted SSD, but will not touch the second (usually HDD) drive.  I'm assuming that your second drive is a new, unformatted drive, but it doesn't really matter what's on the drive prior to this procedure. We are going to destroy all the data on this drive.  We are going to use a software package from within Ubuntu to prep the drive (not sure whether or not this preparation is strictly necessary, but it's what I've tested). To prepare this for your soon-to-be moved /home partition (folder), you should format it using the GUI tool called gParted.
sudo apt install gparted

Open gParted and navigate to your second HDD (carefully check the /dev/sd?X) and delete any & all existing partitions, then create a new PRIMARY PARTITION using the ext4 file system. You could also label it, but that’s not necessary.  Choose "Apply". One gParted is finished, close gParted and now you're ready to install the LUKS container on the second drive and then format it.  In the following commands, replace sd?X with the name of your SECONDARY drive (not your primary drive), for example sda1.
sudo cryptsetup -y -v luksFormat /dev/sd?X

Then you’ll need to decrypt the new partition so that you can format it with ext4, the modern Linux file system preferred by Ubuntu.
sudo cryptsetup luksOpen /dev/sd?X sd?X_crypt
sudo mkfs.ext4 /dev/mapper/sd?X_crypt

If you want to use your second HDD as a regular, frequently accessed hard drive (as in moving your /home partition to it, which is the point of Part II), there’s a way to automatically mount and decrypt your second drive on startup, when your computer prompts you for the primary hard drive decryption password. Aside: I use the same passphrase for BOTH my drives, as I'm superstitious and envision more issues with two different passphrases.
First you’ll need to create a keyfile, which acts as a password for your secondary drive, and so that you don’t have to type in every time you start up (like your primary hard drive encryption password).
sudo dd if=/dev/urandom of=/root/.keyfile bs=1024 count=4
sudo chmod 0400 /root/.keyfile
sudo cryptsetup luksAddKey /dev/sd?X /root/.keyfile

Once the keyfile has been created, add the following lines to /etc/crypttab using nano
sudo nano /etc/crypttab

Add this line, save & close the file (/etc/crypttab).
sd?X_crypt UUID=<device UUID> /root/.keyfile luks,discard

To get your parition’s UUID to enter into the /etc/crypttab file, use this command (you need to use sudo it so that all of your partitions show up):
sudo blkid

The value you want is the UUID of /dev/sd?X, not dev/mapper/sd?X_crypt. Also make sure to copy the UUID, not the PARTUUID.
Okay, at this point (closed & saved /etc/crypttab file), you should be able to login to your Ubuntu install (entering your primary drive decryption password) and it should decrypt BOTH your primary and secondary drives.  You should check to see if this happens otherwise STOP; and solve the issue(s).  If you don't have this working and you've move your /home, you will have a non-working system.
Reboot and check to see if this (daisy-chain decrypt) is in fact is the case.  If the secondary drive is automatically decrypted, when you choose “Other Locations” the second drive should show up in the list and have a lock icon on it, but the icon should be unlocked.
If the second drive automatically decrypts (as it should), then move on to Part II, designating the second drive as the the default location of your /home folder (with the larger amount of space).
Part II: Move your /home partition to your secondary drive (i.e. HDD)
We need to make a mount point for the secondary drive, temporarily mount the new partition (secondary HDD) and move /home to it:
sudo mkdir /mnt/tmp
sudo mount /dev/mapper/sd?X_crypt /mnt/tmp

assuming /sd?X is the new partition for /home (as per above)
Now we copy your /home folder to the new /home location from the primary drive (SSD) to the secondary drive (HDD).
sudo rsync -avx /home/ /mnt/tmp

We then may mount the new partition as /home with
sudo mount /dev/mapper/sd?X_crypt /home

to make sure all the folders (data) are present.
ls

Now, we want to make the new /home location on the secondary drive permanent, we need edit the fstab entry to automatically mount your moved /home on the secondary decrypted HDD.
sudo nano /etc/fstab

and add the following line at the end:
/dev/mapper/sd?X_crypt /home ext4 defaults 0 2

Save & close the file.
Reboot. After a reboot, your /home should reside on the new secondary drive and you should have plenty of space for your DATA.


lightm fail to start LXDE,but LXDE works with startx

I had a similar problem in Ubuntu 18.04 after installing lxde, I would get "failed to start session" when I put in the correct password. (Putting the incorrect password gave a different error.) I did apt-get install lubuntu-desktop and this solved it.


Logitech MX Master Wireless Mouse under Ubuntu 14.04

I can confirm that it works with Ubuntu 16.04LTS. If you use the unifying receiver that came with the mouse it will already be paired when you plug it in. If you wish to pair to a pre-existing unifying receiver you should install Solaar, which provides basic control over pairing, and limited configuration options for some Logitech peripherals.

I used a pre-existing unifying receiver, and paired my MX Master to it using Solaar.  It does detect battery strength, but does not provide configuration of gestures, dpi, scrolling, etc.  The mouse's standard configuration seems to be fine, except that it would really be nice if I could configure the hidden thumb button to switch workspaces for me. The hidden thumb button creates a key sequence, so I guess I could map that sequence within Linux to do workspace swaps.

Anyway, aside from minimal support for configurability, it works great.

I have also paired it using Bluetooth. Doing so required installing blueman and trusting the device.

As an update: The MX Master continues to work under Ubuntu 17.04 just as it did under Ubuntu 16.xx versions. I've also been using it under 18.xx and 19.xx.


If the output of lsusb and the mouse name contains the ID 04d9:a072 is it not currently supported in the kernel. That because the device like, a lot of other Holtek based devices, report a report descriptor that exceed HID_MAX_USAGES.

A workaround would be to increase HID_MAX_USAGES.
How to do so can be found in the similar problem linked. link to post.

The correct way of getting the mouse supported out of the box with no need to recompile the kernel is to provide more debug info to the already existing bug report. Bug report. The currently lsusb -v in the report is missing the report descriptor part cause the device is bound to a not working driver. How to bind\unbind devices.


ACPI Errors - Ubuntu 16.04/17.04 can not be installed

On my DELL XPS 9560 I had to:

sudo nano /etc/default/grub

Then add acpi_rev_override=5 to GRUB_CMDLINE_LINUX_DEFAULT:

GRUB_CMDLINE_LINUX_DEFAULT="quiet splash acpi_rev_override=5"

Run sudo update-grub.

Profit (hopefully it will work when you reboot, and rev override is better than turning off ACPI completely. Also I recommend you to update Kernel at least to 4.14.)


Alienware M14X R4 Eject Button Not Working, Please Help!

Open up a terminal and type eject followed by the enter/return key. If this works, then go to How can I set hotkeys? Where they are using gnome-system-monitor, use eject and instead of Ctrl+Shift+Esc, press your eject key.


Installing old kernel 3.4.69 in Linux 18.04 LTS

Probably not due to the requirements of some of the supporting libraries and utilities are distributed together and there are some dependencies.  Thus if you really really want to do this, you might but with a bit of effort and probably a lot of instability and problems.

How about trying to find an older version of Ubuntu containing the kernel release you want.  This would be more stable however it would not have any real support however.  But in doing what you are suggesting you would not have that anyway.


Can I remove KDE applications from Kubuntu?

Simulation - what will hapen if...

~$ sudo apt-get -s purge rekonq

Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages will be REMOVED:
  rekonq*
0 upgraded, 0 newly installed, 1 to remove and 1 not upgraded.
Purg rekonq [0.8.0-0ubuntu0.1]

:~$ sudo apt-get -s purge kmail

Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages will be REMOVED:
  kmail*
0 upgraded, 0 newly installed, 1 to remove and 1 not upgraded.
Purg kmail [4:4.7.2+git111007-0ubuntu1]

Man Pages

http://manpages.ubuntu.com

man apt-get

   purge
       purge is identical to remove except that packages are removed and purged
       (any configuration files are deleted too).

   -s, --simulate, --just-print, --dry-run, --recon, --no-act
       No action; perform a simulation of events that would occur but do not
       actually change the system.

Defaults

The Kubuntu desktop is wrapped up by the Kubuntu developers. The default applications are picked (mainly) from the KDE and the Qt applications.

The KDE-base (the nucleus of KDE, namely the minimal package set necessary to run KDE as a desktop environment.) /1/, /2/ is having the: dolphin, kde-baseapps-bin, kdepasswd, kfind, konqueror, plasma-widget-folderview as dependency.

Here is an older example of building a barebone KDE installation: http://kubuntuforums.net/forums/index.php?topic=3106858.0

Links:

https://help.ubuntu.com/community/MetaPackages
http://packages.ubuntu.com/oneiric/kde-baseapps


It should go into the install automatically once you boot, you shouldn't have to "try and open Ubuntu" in any way, it should just.... Go.

Sometimes Ubuntu USB install doesn't work very well.  Try reformatting the USB and setting it up again, either with the live cd again, or with the alternate installer if that doesn't work.


Is it possible to Enable Focus Stealing under Wayland? (Gnome Shell 3.26, Ubuntu 17.10)

Well, not sure if this bug is only taking place in my machine or if it's more widespread. I could be wrong but I'm guessing this is probably due to some wayland security restriction that prevents apps from focusing already open windows (as far as I know the window manager is supposed to handle these things now and not the display server like in X). I'm assuming this is a transitional issue and that gnome will eventually give gedit the ability to focus new tabs.

While waiting for this fix, I came up with a partial fix that will send a notification when a new tab is opened in gedit. This doesn't fix the autofocus issue but at least it gives you some kind of cue so that you don't have sit there for 2 or 3 seconds wondering why your window hasn't opened yet.

In a non-root terminal, enter:

gedit admin:///usr/bin/gedit-notify

In gedit-notify, paste the following script:

#!/bin/bash
# purpose of this script: gedit under gnome Wayland has pretty messed up focusing and activation problems. First document/tab opened will focus normally but all the following ones open in the background without the traditional notification: "Your window is now read, click to focus". Its very distracting behavior because for the first 2 seconds you're wondering if your click was registered or not, if the app opened or not, etc. This script sends a notification every time you open a text file in the background.

skip_list=true # you get notified but your notification list doesn't get spammed.

    gedit_inst=$(ps ax|grep " gedit "|wc -l)      #total number gedit windows + 1
    gedit_inst=$(expr $gedit_inst - 1)          #remove one from the count to account for the grep " gedit " process
    gedit_s=$(ps ax|grep " gedit -s"|wc -l)         # -s switch represents signle / independent instance for gedit.
                                                # gedit_s represents the number of gedit windows running as
                                                # independent instances + 1
    gedit_s=$(expr $gedit_s - 1)                # same logic as before
    gedit_inst=$(expr $gedit_inst - $gedit_s)   #substracts the # of windows running in independent instances
                                #from total cound - because they don't affect the focus behavior.
    if [ "$skip_list" = true ]; then
        n_arg0="--hint";n_arg1="int:transient:1"
    else
        n_arg0="-u";n_arg1="low"
    fi

    if [ "$gedit_inst" = 0 ]; then notify=false;fi

n=0
while true; do
    n=$(expr $n + 1)
    file=$(eval echo \$$n)
    if ! [ -z "$file" ]; then
        gedit "$file" &
        if [ -z "$err" -o "$err" = 0 ]; then
                err="$?"
        fi
    else
        count=$(expr $n - 1)
        if [ $count = 0 ]; then
            if [ "$notify" != false ]; then notify-send $n_arg0 $n_arg1 "TEXT EDITOR is ready. Activate it manually.";fi
            gedit
        fi
        break;
    fi
done

if [ "$err" = 0 -a "$notify" != false ]; then
    if [ $count -gt 1 ]; then
        notify-send $n_arg0 $n_arg1 "TEXT EDITOR is ready. Activate it manually." "$count files were opened."
    elif [ $count = 1 ]; then
        notify-send $n_arg0 $n_arg1 "TEXT EDITOR is ready. Activate it manually." "file: \"$1\""
    fi
elif [ "$err" != 0 ]; then
    notify-send -i error "TEXT EDITOR: I ran into some error(s) while opening your file(s)."
fi

save gedit-notify, and enter:

cd /usr/bin
sudo chmod +x gedit-notify; sudo touch gedit-notify
gedit admin:///usr/share/applications/gedit-notify.desktop

in gedit-notify.desktop, paste the following code:

[Desktop Entry]
Name=Text Editor (Notify)
Comment=Edit text files
Exec=gedit-notify %U
Terminal=false
Type=Application
StartupNotify=true
Icon=gedit
Categories=GNOME;GTK;Utility;TextEditor;
X-GNOME-DocPath=gedit/gedit.xml
X-GNOME-FullName=Text Editor
X-GNOME-Bugzilla-Bugzilla=GNOME
X-GNOME-Bugzilla-Product=gedit
X-GNOME-Bugzilla-Component=general
X-GNOME-Bugzilla-Version=3.22.1
X-GNOME-Bugzilla-ExtraInfoScript=/usr/share/gedit/gedit-bugreport.sh
Actions=new-window;new-document;
Keywords=Text;Editor;Plaintext;Write;
X-Ubuntu-Gettext-Domain=gedit

X-AppStream-Ignore=true

[Desktop Action new-window]
Name=New Window
Exec=gedit --new-window

[Desktop Action new-document]
Name=New Document
Exec=gedit --new-document

This will create a desktop shortcut that will show up as Text Editor (notify) in your dashboard and Open With menu. In nautilus, browse around, find a text file, right-click on it, select Properties, click on the Open With tab, select "Text Editor (Notify)", set as default. There will be 4 or 5 different types of text files that needs to have this process repeated. Rinse and repeat.


phpMyAdmin is not working in ubuntu 20.04 with php7.4 there is blank screen

I have found the issue, it is due because at some point during the update I have updated php and there were running both versions, so I had to disable 7.0 from apache and enable the new 7.4, and it has worked, I realized that some other programs that I have with PHP were not working either, but part of them were running fine. Once I applied the change it worked fine.
Thanks.


Navigate to init.py file and edit the file

Comment file from line 79 to 89

It worked for me!


To permanently disable ipv6, you can update your grub file. You'll need administrative rights.
Edit /etc/default/grub with your preferred text editor. Make sure ipv6.disable=1 is added to the GRUB_CMDLINE_LINUX lines as follows:
GRUB_CMDLINE_LINUX_DEFAULT="quiet splash ipv6.disable=1"
GRUB_CMDLINE_LINUX="ipv6.disable=1"

Then
sudo update-grub

And you should be good after a reboot.


How do I launch Ubuntu 16.04 LTS from the terminal?

I think somehow your upgrade went wrong. Try switching to Virtual Termnal 7 by Ctrl-Alt-F7 and there you'll see the login screen.

If you can't see that login screen, use startx (after going back to VT1 pressing Ctrl-Alt-F1) to start the graphical session. If the graphical session starts, install a display manager which should handle the login prompts automatically after each reboot now.

sudo apt install lightdm

If that too doesn't work, install lightdm from the VT1 (where you originally were) using the above command sudo apt-get install lightdm and reboot with sudo reboot.

It should solve the problem.


You should use GPT over MBR because as MBR was invented back in 1983, so it is old and has several limitations this is where GPT has advantage over MBR.

Limitations of MBR:

It doesn't work on the disk size over 2TB
It only supports up to 4 only 4 primary partitions
Boot data is stored in a single place if it is overwritten or deleted that means error in starting the OS

Pros of GPT:

It supports disk size greater than 2TB
It also gives you support for making numerous partial but the number varies with each OS. ex: It supports up to 128 partitions for Windows
It stores multiple copies of boot data across disk is data is corrupted anyhow it recovers it easily

In short, GPT is modern new and overcome the limitations of MBR.

As for as the second question is considered if you are not going to install heavy software on windows then you can partition SSD in 2 parts but I would not recommend it.

It better to figure out which OS you use most and install it on SSD and the other on HDD, it's totally up to you.


CIFS is Linux kernel based and knows nothing about smb.conf so making changes there will have no affect on a cifs mount.

I'm going to assume the NAS is running only SMB1 so you will need to specity that in your fstab declaration by adding vers=1.0 to your list of options:

//192.168.1.2/share /mnt/FileServer cifs username=guest,uid=1000,vers=1.0 0 0

You will probably need to add another option to change the defalt security mode that SMB1 had in those days: sec=ntlm So the line becomes:

//192.168.1.2/share /mnt/FileServer cifs username=guest,uid=1000,vers=1.0,sec=ntlm 0 0

EDIT: Reason for adding vers comes from man mount.cifs for the vers option:
The  default  since  v4.13.5  is  for the client and server to negotiate the highest possible version greater than or equal to 2.1. In kernels prior to v4.13, the default was 1.0. For kernels between v4.13 and v4.13.5  the  default  is 3.0.

The Linux kernel in Ubuntu 16.04 was accessing the NAS using vers=1.0. Now it's trying to access it between 2.1 and 3. Adding vers=1.0 overrides the default.


chown fails because the mounted file system is fuseblk. So you are trying to write meta data to a file system which the file system does not support (cannot store). You can only change permissions and ownership on a Unix filesystem like  ext3 or ext4.

If you want that mounted point with ownership applied to a specific user/group, specify at the mount time:

mount -o uid=username,gid=groupname /dev/sdb1 /path/to/mount

See also:

https://superuser.com/questions/57092/cant-change-permission-ownership-group-of-external-hard-drive-on-ubuntu
https://unix.stackexchange.com/questions/73955/unable-to-change-permissions-of-file-system-root


Install Windows 10 alongside Ubuntu 14.04

This is a FULL solution to the problem. I'll be outlining all my steps and possible alternatives for others. A lot of thanks go out to Zacharee1 and the Ubuntu community as whole.

Steps:

You'll need to download some tools.

UNetbootin will make your live USB's. It runs on Win, Mac, and Linux.
I used Ubuntu to split my partitions from a live USB.
Grub Boot Repair. This will allow you to recognize all the OS's on all your partitions. It installs Grub2.

Making a Live USB and Partitioning.

Run UNetbootin
You have two options on the main screen. We want to choose Disk Image, not distribution. Make sure it says .iso, then click the "..." button and find your Ubuntu .iso file we downloaded earlier and select it. Now make sure you're selecting USB on the main screen and the appropriate drive letter for your USB. You can ignore making extra space, as we won't be needing it for this. Then install that .iso file. It should only take a couple minutes.
Restart your PC as prompted. On restart you need to get into your Boot Menu. On my laptop this means hitting the F12 key during boot. Yours might be different. Once you're in your bios screen select your boot device (You should see your USB). It'll open Ubuntu and ask if you want to install or run from the USB in a trial version. Run the trial version.
Open Gparted from the desktop. You should see "blocks" of memory here. You want to Resize a partition (this makes room for a new one). So right click on the partition and select resize/move. You now see a min and max size. Don't set it directly to your minimum size, but leave room for expansion -- at least a few GB if possible. The numbers are in MB. You can google the conversion if you need to. Now click resize/move.
You are now back on the GParted main screen and a new partition labeled "Unallocated" has appeared. Right click on this partition and select NEW. Create it as a PRIMARY PARTITION with a files extension of NTFS. You can set the size as well; by default it'll use all the free space which is fine. You can add a label, but I find it easier to let the system name it. Now click add. You are back to the main screen. Click the Green checkmark to run both the resize operation and the NTFS formatting operation. If you are working on sizes with 100's of GB this is going to take a long time (took me 1.5 hours).

Installing Windows 10

Restart your PC and install the Windows 10 .iso to a USB using UNetbootin (same steps as in #2)
Restart your PC, hammer on your boot key (mine is F12) to enter your BIOS. Select the USB from the boot list.
Windows will walk you through installing itself. It will directly ask you to pick a partition. Select the new one you made in Step 2. When it's done it will have altered your boot settings and it will look like Ubuntu is missing (but it's not, don't panic).

Repairing Grub

Use UNetBootin to make a live USB for the grub boot repair .iso (see previous steps for instructions)
Restart your PC and hammer on your boot key (mine is F12) to enter the BIOS. Select your USB from the boot list.
You are now in a desktop designed simply to repair GRUB for you. You the "recommended settings" button that pops up on the desktop. You'll be prompted to connect to the internet during the repair process. They store your log file in a URL for you to access later, nothing crazy. Once you're done you should be good to go. Grub should load automatically allowing you to select your OS when you restart the computer. But if you are unlucky like me, and restarting just throws you into Windows, go to step 5.

Changing your UEFI boot order.

This should not be necessary for most people. My UEFI and BIOS just hated me. There are three methods to fixing this: Using Ubuntu, Using Windows, and Using your BIOS. Ubuntu and Windows failed for me, using the BIOS directly worked.

Ubuntu Method. (Copied mostly from Cleaning up and changing the EFI boot order permanently using eifbootmgr)

Open a terminal and type:

sudo efibootmgr -v

You'll see your boot order now. Here's my broken order, paraphrased. Yours will vary:

BootOrder: 0005,0000,2001
Boot0000* Ubuntu
Boot0002* UEFI Onboard LAN IPv4
Boot0003* UEFI Onboard LAN IPv6
Boot0005* Windows Boot Manager
Boot2001* EFI USB Device

The line BootOrder: 0005, 0000, 2001 is our problem. It means we're loading Windows and not Ubuntu (which holds Grub) first. We need to change this. Copy this line and change the numbers as needed for your own system:

sudo efibootmgr -o 0000,0005,2001

This will change the order to Ubuntu, then Windows, then a USB. This is specific to MY system. You need to use your own numbers, but in that exact same format. You can add more commas and numbers, but don't use any spaces and all numbers are 4 digits. Restart your PC and see if you load directly into GRUB for Ubuntu. Mine didn't stick, so I then tried the windows method below.
Windows Method.

If you boot into the Windows 10 OS, you can try configuring the UEFI Boot order manually. Unfortunately my system didn't detect my files properly. Here is how to do it though: Changing the Default Boot Entry These are the instructions I followed and they do a good job. I had to go to the next step though.
BIOS Method.

This method sucks because every BIOS interface is different.

Restart your PC. Hammer on your BIOS key (mine is F12) to enter the boot menu.
Find some sort of menu that talks about boot order. Mine was hidden in an "advanced" tab. You should see your list and Windows will be at the top.
Using +/- you can change the order. Place Ubuntu at the TOP. My system only uses -, but it still works.
SAVE AND EXIT that screen. Exit out of your bios.
You should now see the Grub Menu (since Ubuntu is the default UEFI Boot now).
Select the OS you want.
Restart your PC one more time. If Grub pops up, then you're done and good to go. Hope this helped.

Again, thanks to the community for all the support articles and friendly advice. If you wish to configure your Grub Menu, please refer to Ubuntu Wiki - Grub2/Setup - Configuring GRUB 2. It has a lot of fun options to tinker with, like your timeout for loading into a default OS.


Which applications offering search functions opens when pressing Ctrl+Space?

The application is called synapse. One can open a configuration dialog pressing the round symbol in the upper right corner and deactive the start or change the shortkey for displaying.


Installing WINE as a brand new Ubuntu User

Try this executing these commands step by step:

  sudo apt-get remove wine
  sudo apt-get install -f
  sudo add-apt-repository ppa:ubuntu-wine/ppa
  sudo apt-get update
  sudo apt-get install wine1.6
  sudo apt-get install -f
  sudo apt-get -o Dpkg::Options::="--force-overwrite" -f install


The easiest thing to do is probably use a Windows Reapir CD to "fix" the boot loader. This should kill grub and replace it with the windows default.


After resizing swap area, ubuntu is not starting

what @waltinator says is that you have to resize the partition correctly (see: http://www.microhowto.info/howto/reduce_the_size_of_an_ext2_ext3_or_ext4_filesystem.html) or use tools like gparted which will do that for you.
by the way I'm glad to hear you can boot again in to your system;
The system boot probably is slow down due the UUID of swap partition has change see this for fix it: Ubuntu is booting very slowly after dual boot with Kali It talk about get issue after installation in dual boot of kali, but that was the cause, issue was the UUID of swap change, and if you increase it you probably format and so the UUID has change.


Can't boot Ubuntu or Windows 8 after Ubuntu 64-bit install on Samsung series 7 Windows 8 laptop, error "All boot options are tried."

You installed Ubuntu in BIOS/CSM/Legacy mode using the protective MBR. You should be able to boot just Ubuntu from UEFI menu in CSM or BIOS mode. That would have UEFI off and with UEFI off, there is no secure boot option.

Some systems only boot Windows with secure boot on. Others boot with it off, but Windows is installed in UEFI mode. Since UEFI & BIOS write hardware info to system differently you cannot dual boot from grub menu but only by going into UEFI and turning it on for Windows or off for the BIOS install.

Better to install Ubuntu in UEFI mode and then you should be able to dual boot from grub menu. But some systems will only boot Windows with secure boot on and you have to boot the Boot-Repair program in secure boot mode to get to install the Ubuntu signed kernels that will work with secure boot.

It looks like Boot-Repair already converted your BIOS install to UEFI, but you do not have signed kernel so Ubuntu will only boot with secure boot off. A few system do not allow that or only allow the Windows efi file to boot. Then Boot-Repair has to do a work around and rename grub's shim to be the Windows file to may dual boot work.

Shows install with screen shots.

https://help.ubuntu.com/community/UEFI

Also shows Windows 8 screens

Installing Ubuntu Alongside a Pre-Installed Windows with UEFI

Boot Repair -Also handles LVM, GPT, separate /boot and UEFI dual boot. required for UEFI & grub bug fixes

https://help.ubuntu.com/community/Boot-Repair


The Software Center has some info that should help:

https://help.ubuntu.com/community/UbuntuSoftwareCenter#reinstalling-purchases


How to view the data from a .mysql file?

The data is visible in any text editor, albeit it is in mysql format, to put it in a database you can import it to one, if you want you can create a database with "create database" command, next if you want to assign a separate user create a separate user with "grant" command for that database, flush privileges and quit mysql prompt. Now you can import .sql file to database by: mysql - u "username" -p  'databasename' < filename.sql  I use an extra space inbetween -p and databasename so it will prompt for password and not log the mysql user password in the system command history. if you require the actual commands let me  know. If you are looking for an easier option to view install phpmyadmin and import the .sql file. this will give you a frontend to view the data.


My Gnome shell in Ubuntu is the old-style gnome 2.0 style

When you were asked to login, you clicked on the button that says you can choose

Gnome
Gnome Classic
Gnome Classic (No Effect)
Ubuntu
Ubuntu 2D

you should chose Gnome.

what version did you chose ?


Command "look" optimisation (virtual linebreaks)

I tried part of what you gave and it works for me

$ cat .alias
alias proxyon='
export FTP_PROXY=http://ftp-proxy.intern.me.de:1234;
export HTTPS_PROXY=http://https-proxy.intern.me.de:1234; '

and the result is

$ env | grep PROXY
FTP_PROXY=http://ftp-proxy.intern.me.de:1234
HTTPS_PROXY=http://https-proxy.intern.me.de:1234


Change screen brightness Acer Swift 3 Ubuntu 20.04

You probably run kernel version 5.4 (which was the case for me). With a newer kernel it should work. I have the 4700U processor, whose internal graphics is apparently not supported by the older kernel's driver, with the new one adjusting the screen brightness via the fn button works.
According to this article (https://www.phoronix.com/scan.php?page=news_item&px=Ryzen-7-4700U-Daily-Driver) Version 5.7 should work, I used 5.9, and since I'm a noob installed it using following instructions:
https://www.fosslinux.com/44138/linux-kernel-5-9-new-features-how-to-upgrade.htm


Twitter Client with multiple account support Ubuntu 14.04

Corebird supports multiple accounts -

Corebird 0.9 is developed in GTK+3.12 and the Ubuntu 14.04 is based on GTK+3.10.

Therefore, the GNOME 3 and GNOME 3 Staging PPAs need to be added in order to satisty all the Corebird dependencies.

To install -

sudo add-apt-repository ppa:gnome3-team/gnome3
sudo add-apt-repository ppa:gnome3-team/gnome3-staging
sudo add-apt-repository ppa:ubuntuhandbook1/corebird
sudo apt-get update
sudo apt-get install corebird

Alternatively, you can download the .deb file here and install it using dpkg -

sudo dpkg -i <filename>.deb


Command for changing virtual terminals is named chvt. In gnome-terminal:

$ sudo chvt 1

Here is an exmplanation why do you need sudo: https://superuser.com/questions/69807/why-does-chvt-work-fine-as-a-regular-user-on-a-virtual-terminal-but-not-under-x

In a virtual terminals 1-6 root privileges aren't needed.

To run a command on another virtual terminal you can use openvt:

$ sudo openvt -s pwd

More examples and explanation here: http://www.ae.iitm.ac.in/pipermail/ilugc/2008-December/045004.html


Installing Ubuntu on an SSD from a HDD on same box

Yes, it's possible to install fresh Ubuntu to SSD and then copy all of the data from old Ubuntu installation on HDD. Use rsync utility to copy system files from old to new installation. See my answer here.


Can't use window controls on maximized windows

This seems to be related to Steam and can be fixed by restarting (exiting then reopening) Steam.

The reason the old solution worked (posted below) was because of (what I believe to be) a bug which I have reported here, https://github.com/ValveSoftware/steam-for-linux/issues/2799, but I'm not sure when it'll be fixed. The bug caused Steam to exit when opening a 13.04 Unity logout or shutdown dialog.

I've reported the window controls bug here: https://github.com/ValveSoftware/steam-for-linux/issues/2919

Original solution:

  Fixed by opening a logout or shutdown dialog in Unity with Ubuntu 13.04. Opening a dialog and cancelling it will fix the problem.


How are Ubuntu-supplied drivers verified for production LTS updates

I can explain what really happened.
In October 2020 Ubuntu 20.10 was released with the 5.8 Linux kernel. All drivers were tested and there are no problems with them.
For those who installed Ubuntu 20.04 from the 20.04.1 image, linux-image-hwe-20.04 meta package was installed. It was pointing to the same kernel as linux-generic (5.4). That was an initial mistake IMHO. Before the HWE meta appeared only with xx.04.2 releases. And it didn't cause so much trouble.
People who wanted to test a new kernel could install HWE before but at their own risk. I did it many times. But this time all of a sudden...
Recently the linux-image-hwe-20.04 was switched to the 5.8.0-34 kernel, but drivers stayed the same in the repos. Some of them are incompatible with the 5.8 kernel. This is a second mistake.
Kernels got an update to 5.8, and a lot of people is having a lot of trouble.
This can be more or less easily fixed by installing drivers from 20.10 repos.
So this is not a matter of driver testing. It is disappointing that every time a HWE kernel is released some kind of trouble with drivers happens. This time it is worse than ever. But I wouldn't complain very much about it.


Can't Change the default python to 3.7 in ubuntu 19.10?

Changing the default Python interpreter is probably no good idea, as system tools could depend on the Python version.

As Python 2 support officially ends at the beginning of 2020, it is certainly a good idea to use Python 3 when you create new projects.

In order to use Python 3, just enter python3 in the terminal.

There is no need to change the default behavior.


My HDD used for backups it doesn't have the "Delete Option" and other options

You have mounted the HDD with read access only. You need to unmount it and remount it with read and write access.


Will GParted automatically format to ext3 when repartioning?

Yes and No!

When you create a new partition using GParted, it gives you an option to format to your choice of FSType. If you dont format, the partition become unusable.

TO install Ubuntu you need ext[n] type partition at least for system directories like /,/boot, /var. I am not sure if you can have /home on NTFS or FAT partition. If you are unsure or dont want separate partitions, then its better to create a single ext4 partition for /.


Ubuntu VPN Outside Network Connection Issue

I only can propose the script in witch you can add route or host to router traffic via ppp0 interface ...

Try maybe will work good.
Create file with some name and put in

nano name_of_script

script

 #!/bin/bash
function routeadd {
    route add -host xxx.xxx.xxx.xxx dev ppp0
    route add -net xxx.xxx.xxx.xxx/xx dev ppp0
}
function makepptp {
   echo pty \"pptp xxx.xxx.xxx.xxx --nolaunchpppd\" >> /etc/ppp/peers/vpn;
   echo remotename PPTP >> /etc/ppp/peers/vpn;
   echo require-mppe-128 >> /etc/ppp/peers/vpn;
   echo file /etc/ppp/options.pptp >> /etc/ppp/peers/vpn;
   echo ipparam vpn >> /etc/ppp/peers/vpn;
pppd call vpn &
}
if [ -a /etc/ppp/chap-secrets ];
        then
        rm /etc/ppp/chap-secrets
    echo $1 PPTP $2 '*' >> /etc/ppp/chap-secrets;
else
    echo $1 PPTP $2 '*' >> /etc/ppp/chap-secrets;
fi

if [ -e /etc/ppp/peers/vpn ];
    then
    rm /etc/ppp/peers/vpn;
    echo name $1 >> /etc/ppp/peers/vpn;
    makepptp;
    sleep 8;
    routeadd;
else
    echo name $1 >> /etc/ppp/peers/vpn;
    makepptp;
    sleep 8;
    routeadd;
fi

In script change you host ip and add network or/and host witch you wish to connect via vpn

Usage:

sudo /path_to_script/name_of_script username password

note: set execute permision to script

In this way you have control over traffic.

Edit 1

Your server witch you want to access via vpn is on 10.10.10.10
Your vpn server is on 172.16.16.16

You change script to look like this

#!/bin/bash
    function routeadd {
        route add -host 10.10.10.10 dev ppp0
    }
    function makepptp {
       echo pty \"pptp 172.16.16.16 --nolaunchpppd\" >> /etc/ppp/peers/vpn;
       echo remotename PPTP >> /etc/ppp/peers/vpn;
       echo require-mppe-128 >> /etc/ppp/peers/vpn;
       echo file /etc/ppp/options.pptp >> /etc/ppp/peers/vpn;
       echo ipparam vpn >> /etc/ppp/peers/vpn;
    pppd call vpn &
    }
    if [ -a /etc/ppp/chap-secrets ];
            then
            rm /etc/ppp/chap-secrets
        echo $1 PPTP $2 '*' >> /etc/ppp/chap-secrets;
    else
        echo $1 PPTP $2 '*' >> /etc/ppp/chap-secrets;
    fi

    if [ -e /etc/ppp/peers/vpn ];
        then
        rm /etc/ppp/peers/vpn;
        echo name $1 >> /etc/ppp/peers/vpn;
        makepptp;
        sleep 8;
        routeadd;
    else
        echo name $1 >> /etc/ppp/peers/vpn;
        makepptp;
        sleep 8;
        routeadd;
    fi


How to activate MySQL general log in version >= 5.6?

Here is how I managed to do it :

Edit your /etc/mysql/my.cnfand add the following at the end of the file :

[mysqld]
general_log_file = /var/log/mysql/mysql.log
general_log = 1

Connect through mysql (mysql -u <username> -p) and run :

SET GLOBAL general_log = 1;

Restart mysql :

sudo service mysql restart

Note :

If general log is still not working, try to manually create the log file :

touch /var/log/mysql/mysql.log
sudo chown mysql:mysql /var/log/mysql/mysql.log


My Ubuntu One account is empty but I'm still using 8.7 MB?

At the uttermost right, there is a label containing "More". If you click it, then the file will be expanded like a treeview, and you'll get options to publish, download or delete the file. Also, if you login to your Ubuntu One account on your desktop, then you can delete the file in Nautilus, because deletes are also synchronized.


Trying to script deleting files from wildcards in a text file

Pathname expansion happens after variable expansion, but only on unquoted parts of the command line.

rm -- $line  # <- no double quotes to expand wildcards

This wouldn't work for filenames containing spaces, as word splitting also happens after variable expansion.

You can use Perl to expand globs:

perl -lne 'unlink glob' -- list.txt

Normal glob needs whitespace backslashed, but you can switch to File::Glob for a different behaviour if it's more convenient to you:

perl -MFile::Glob=:bsd_glob -lne 'unlink glob' -- list.txt


How to force a proprietary driver to load on startup?

Since it is included with the kernel as a module, unless you blacklist the old module, it is loaded at the boot time because of having a device using that module. After installing an other driver, you need to blacklist the old one.

Blacklisting is the right way. But you should add the new module to /etc/modules file.


GRUB menu alternating between two fonts - where to configure?

I have found a solution. GRUB isn't supposed to be able to alternate fonts like this, and the fact that it does it is a bug - but, specifically, removing --append from the following line in /etc/grub.d/00_header:

terminal_output --append ${GRUB_TERMINAL_OUTPUT}

... so that it becomes ....

terminal_output ${GRUB_TERMINAL_OUTPUT}

... and then running:

sudo update-grub

Worked for me.

Here is the Source.


~/.profile is not only used by bash, it's also used by other posix shells. When you log in graphically in Ubuntu, ~/.profile gets sourced by sh, which does not have [[ or source.

EDIT

After a bit of googling about this rvm stuff, it appears it's a bash script, so switching to posix sh syntax won't work; the script simply does not belong in ~/.profile.

One way to get around it could be to source it from ~/.bashrc instead. The drawback of that is that whatever environment variables it sets, will only be available to bash shells. e.g. commands that rely on these enviornment variables can't be run directly from a launcher.


You should change the permissions of /import folder (as you mentioned 12.04 box) so that you can have write access.


Please open a terminal and do:

sudo -i
echo "options iwlwifi led_mode=1"  >>  /etc/modprobe.d/iwlwifi.conf
modprobe -r iwldvm
modprobe iwlwifi
exit

Any improvement? It may take a reboot.

If '=1' doesn't help, edit the file to try the other options that you can find here:

modinfo iwlwifi

  parm:           led_mode:0=system default, 1=On(RF On)/Off(RF Off),
  2=blinking, 3=Off (default: 0) (int)

Edit the file in question:

gksudo gedit /etc/modprobe.d/iwlwifi.conf

Use nano or kate or leafpad if you don't have the text editor gedit. Change the last line to try 2 or 3 as the parameter. Proofread carefully, save and close the text editor. Reboot.


Ubuntu 14.04LTS Icons and Theme not working

You could just run it at start up every time (clunky solution i know).

Search for 'Startup Applications', click add, place the command with a title and description.
It will auto run after startup.


Why UFW has to be (re)started at boot time if it's only iptables rule manager?

When system is booted, there is no firewall rules. Kernel is not saving those to anywhere.

If you don't start UFW (or some other firewall manager), your iptables is empty. Also, default rule for each chain (FORWARD, INPUT, OUTPUT) is ACCEPT, so everything is allowed.

So UFW is not just checking, it's actually putting those rules in place, and creating additional chains it uses for rule management.


Actually I don't have any idea about your fprint problem but you must mount the file system as rw on recovery mode to make some changes. After opening the system via recovery mode run this command first:

mount -o rw,remount /


It sounds like a bug: specifically, a window-manager crash.  You can check the .xsession-errors file in your home directory for any pertinent error messages.

On the other hand, gnome-session is supposed to restart the window manager should it crash, and I'm not sure why that's not happening here.

Do you use Desktop Effects?  Perhaps compiz is still running, and it was gtk-window-decorator that crashed?


dpkg warning about '/etc/lsb-release' version number not starting with a digit

This is a bug in dpkg which has been reported here: Bug #1597466


Can't Mount NTFS drive "The disk contains an unclean file system"

If you can't access the drive, execute the following command:

sudo ntfsfix /dev/sdXY

where XY is the partition

e.g sda2 or sdb1

Then, mount with:

sudo mount -o rw /dev/sdXY


Cannot execute just compiled binary file

To execute a binary file that is in the current directory (but not on your executable path) the correct syntax is

./iri

(note the /). The command you gave (with a space between the . and the filename) attempts to source the file as a script in the current shell - see help source

$ . hello
bash: .: hello: cannot execute binary file
$
$ ./hello
Hello world!
$


How to properly create a virtual machine for Windows?

I will suggest there are five stages of using both Ubuntu and Windows. Here is the list of the five stages in chronological order from the first stage to the last stage. As a new Ubuntu user you are still at stage 1 in the list.

New Ubuntu user runs Windows in a virtual machine so that he can pop back into Windows any time it's necessary. Oracle VirtualBox is a good choice for the virtual machine application.
Ubuntu user with more experience uses Windows less frequently and wants more RAM to be available in Windows, so he dual boots Ubuntu alongside Windows.
Experienced Ubuntu user learns that there are many alternatives to the applications that he used in Windows including running the same Windows applications in Ubuntu using Wine, but he saves his dual boot Windows OS for when he needs to run applications that can't be replaced or won't run in Ubuntu using Wine.
The user doesn't use Windows much anymore, so he removes Windows and installs it on another computer if possible.
User rarely boots the computer that has Windows on it, and the computer sits unused gathering dust.


Calculate time when commands are received at server

The simplest approach I can think of is

$ date; ssh user@server date
Fri May  2 13:45:28 EEST 2014
Fri May  2 13:45:30 EEST 2014

The first date will print out the current date/time of your system. The second will connect to your server over ssh (ssh user@server) and run the date command on the server. Assuming that both client and server are synchronized to the same NTP server and so have the same time, that will let you see the time difference. Note that this won't be 100% accurate since there will be a tiny delay caused by the launching of the ssh command but we're talking about milliseconds so I doubt it will make a difference.

If you need greater precision, use something like this which will show the nanoseconds:

$ date +%T:%N; ssh user@server date +%T:%N
13:47:21:739912080
13:47:23:774238647

You can also use the verbose flag for ssh (-v) which will report the transfer speed. This only takes into account the time after the connection has been established and not the overhead needed for connecting in the first place:

$ ssh -v user@server exit 2>&1 | grep second
Transferred: sent 3272, received 1920 bytes, in 0.5 seconds
Bytes per second: sent 6556.2, received 3847.1

The command above connects to the server and simply runs exit to quit the connection again. 2>&1 redirects standard error to standard output which allows us to grep for "second" and get the stats.


Which command are you using. Are you using localhost with curl? First check the output of the following:

curl -v localhost:5984

Most likely you would find an output similar to this:

Rebuilt URL to: localhost:5948/
Hostname was NOT found in DNS cache
Trying ::1...

Most likely, curl is not able to resolve localhost. It switches to an IPv6 address of localhost and your couchdb is not listening for an IPv6 address. Change from localhost to 127.0.0.1.

curl 127.0.0.1:5984


From @stroudmw's comments the following commands fixed the problem:

sudo apt-add-repository ppa:remmina-ppa-team/remmina-next
sudo apt-get update
sudo apt-get install remmina remmina-plugin-rdp libfreerdp-plugins-standard


How do I install Opera for Linux in Ubuntu?

I'd recommend installing Opera using the Opera repository.  That way it will install the version that is needed and run the updates automatically.

To add the Opera repository, run the following in the terminal:

sudo add-apt-repository "deb https://deb.opera.com/opera/ stable non-free"
wget -O - https://deb.opera.com/archive.key | sudo apt-key add -
sudo apt-get update
sudo apt-get install opera-stable

(if you prefer beta releases, use deb https://deb.opera.com/opera-beta/ stable non-free in the first line above).

For more details see the guide on manual setup of the Opera apt repository.


You'll want to set g+s on the directory in order to new files to inherit the permissions from the directory.


Does MSSQL interfere with MySQL on LAMP SERVER?

PHP packages has support for connecting to MSSQL server.  The support is included in php5-sybase package.  In PHP 5.6 you can still use the obsolete MSSQL functions, but I urge you to use pdo_dblib extension (it's compiled with freetds library, but it can be used to connect to MSSQL server) as the old extension has been dropped in PHP 7.

Here's the link to the documentation: http://php.net/manual/en/ref.pdo-dblib.php and don't forget to use dblib as your DSN prefix as the extension is compiled with FreeTDS on Ubuntu.

The additional modules won't affect existing modules.  If you install f.e. php5-pgsql it won't affect existing MySQL module, same goes with pdo-dblib.  It will just add more functions.


ls < text.txt (with files in subdir and resolution of files)

In general, the way one takes a 1-argument command (mediainfo foo) and applies it to a bunch of files, is with find and xargs. See man find;man xargs.

I'm using the NUL-terminated options (-print0 and -0) because you did not say no filename had spaces.

find . -type f -print0 | xargs -0 -n 1 mediainfo


Brightness Control inverted? ubuntu 20.04?

Your kernel looks like it has been manually installed, since this is not an officially supported kernel version for Ubuntu 20.04.2. I would suggest sticking to the supported kernel versions by Canonical (should be 5.8 for 20.04.2) - sudo apt-get install --install-recommends linux-generic-hwe-20.04


Can't install Code::Blocks plugin wxsmith

You need to install the same version of codeblocks-contrib and codeblocks-wxcontrib-dev. This would resolve your issue cleanly, because it looks like the package maintainers decided to move a file from one package to another in between the two versions, which created the conflict you're currently facing.

You appear to have installed those packages with APT, which doesn't resolve the package removal and installation sequence correctly (probably due to incorrect package conflict entries). Therefore you need to download manually and install those packages forcefully:

apt-get download codeblocks-contrib codeblocks-wxcontrib-dev
sudo dpkg -i --force-overwrite --force-overwrite-dir codeblocks-contrib_*.deb codeblocks-wxcontrib-dev_*.deb

Alternatively, remove both packages and re-install them:

sudo apt-get remove codeblocks-contrib codeblocks-wxcontrib-dev
sudo apt-get install codeblocks-contrib codeblocks-wxcontrib-dev


Some packages (like the kernel) can only be upgraded with sudo apt-get dist-upgrade.

For pinned packages, have a look at the /etc/apt/preferences file and the files in the /etc/apt/preferences.d directory. Usually the file and directory is empty unless you've manually set values. Removing a file will then remove the pin.


Yep, install the game:

$ sudo apt-get install assaultcube

Start the server

$ assaultcube-server

Run the client

$ assaultcube

And choice multiplayer, have fun!


In /etc/postfix/virtual remove or edit these lines:

domain.tld   domain.tld
domain.tld   [name of corrosponding unix user]

I am not sure what you want them to do, but it is not how it is done, the domain.tld should either start with @ or not be there at all, first line does not make sense, see http://www.postfix.org/VIRTUAL_README.html


Why installtion fails when preseeding the partitioning method?

Are you installing from a Legacy or UEFI/EFI USB entry? You need to make sure you select the one that matches the mode your BIOS is going to boot in.

I'm also using this to ensure the USB is unmounted properly before the installer tries to detect the device to install to.

d-i partman/early_command string \
USBDEV=$(list-devices usb-partition | sed "s/\(.*\)./\1/");\
BOOTDEV=$(list-devices disk | grep -v "$USBDEV" | head -1);\
debconf-set partman-auto/disk $BOOTDEV;\
debconf-set grub-installer/bootdev $BOOTDEV; \
umount /media;

From the linked article you already have additional preseed answers to remove existing lvm or md devices.

d-i partman-lvm/device_remove_lvm boolean true
d-i partman-md/device_remove_md boolean true

You can also specify lvm instead of regular if you want resizable partitions without requiring a reinstall.

# Alternatively, you may specify a disk to partition. If the system has only
# one disk the installer will default to using that, but otherwise the device
# name must be given in traditional, non-devfs format (so e.g. /dev/sda
# and not e.g. /dev/discs/disc0/disc).
# For example, to use the first SCSI/SATA hard disk:
#d-i partman-auto/disk string /dev/sda
# In addition, you'll need to specify the method to use.
# The presently available methods are:
# - regular: use the usual partition types for your architecture
# - lvm:     use LVM to partition the disk
# - crypto:  use LVM within an encrypted partition
d-i partman-auto/method string lvm

https://help.ubuntu.com/lts/installation-guide/amd64/apbs04.html


Open linux terminal and run multiple tasks using perl script

For simplicity sake, try:

./xbrecoverBoard.sh

If it crashes, try:

./xbrecoverBoard.sh &

This could be something as simple as a bogus line of code in the perl script.


I had a similar issue faced once.

Now you have two options as you have changed the permission of / and a lot of services depends upon it. (Ex: most probably your sudo su must not be working etc.)

The short way is to re-install your system again. This is the best way I would recommend take backup of your files and data and do a re-install.
The long way is to you will have to boot your system in recovery mode then mount the /  partition in rw mode using

mount -o remount,rw /

mount --all

and then you will have to set permissions of various services manually so yes it is possible to do that but for this you need to know what are the permissions of these services in a default ubuntu working OS.

Now in this case you may seem to change the permission of many of the services but there are chances that you may miss alot of special permissions which may cause problem in the near future.


Is there a easy way to test ubuntu on new notebooks before buying it?

Testing hardware compatibility is a long a tedious process, even if you have unrestricted access to the hardware. There is no easy way, I am afraid. Without proper vendor support and testing for Linux, it's down to the user to make sure the hardware works, and that is anything but easy.


How can I check my filesystem with the new Disks 3.4.1?

Note: Users of Ubuntu 12.04 Precise will not experience this issue because Disks 3.4.1 is only available via PPA or in the next Ubuntu release, 12.10 Quantal.

Disks 3.3+ is a complete rewrite of the old gnome-disk-utility (aka Palimpsest). It no longer appears to include an option to check filesystems:

Use GParted to check filesystems instead. Select the partition you want to check, click on Partition...Check in the menu:

The operation will be added to the list. Click on the Apply button to start the check:


You have to choose a different compositor. One that is compatible with the X11 config.

Then you have to point nvidia-config to xorg.conf


Installing ibus-qt4, then logging out and back in fixed it for me.
I also found this thread: https://bbs.archlinux.org/viewtopic.php?id=111087