Openvpn server on ubuntu and clients on Windows

Ubuntu Server 14.04.1 How To setup OpenVPN server on a seperate machine than the LAN gateway (with access to other machines on server LAN)

Make sure your openvpn LAN is not the usual 192.168.1.1 or 10.0.0.1. If it is, log in to your router and change the third number ie. 192.168.(this number).1

Make sure to forward port 1194 on your router to the OpenVPN server IP

Example Network:

Gateway IP:            192.168.5.1
OpenVPN Server IP:     192.168.5.20

OpenVPN Config:

 port 1194
 proto udp
 dev tun0
 ca ca.crt
 cert server.crt
 key server.key
 dh dh2048.pem
 server 10.8.0.0 255.255.255.0
 ifconfig-pool-persist ipp.txt
 push "route 192.168.5.0 255.255.255.0"
 push "route 10.8.0.0 255.255.255.0"
 push "redirect-gateway def1 bypass-dhcp"
 push "dhcp-option DNS 8.8.8.8"
 push "dhcp-option DNS 8.8.4.4"
 client-to-client
 duplicate-cn
 keepalive 10 120
 tls-auth ta.key 0
 comp-lzo
 user nobody
 group nogroup
 persist-key
 persist-tun
 status openvpn-status.log
 verb 3

Edit /etc/network/interfaces:

 auto lo
 iface lo inet loopback

 auto eth0
 iface eth0 inet static
      address 192.168.5.20
      netmask 255.255.255.0
      broadcast 192.168.5.255
      network 192.168.5.0
      gateway 192.168.5.1
      dns-nameservers 8.8.8.8
      dns-nameservers 8.8.4.4

 post-up iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -j SNAT --to 192.168.5.20

Make sure to comment out ipv6 setting

Edit /etc/sysctl.conf:

Change:

 #net.ipv4.ip_forward=1

to:

 net.ipv4.ip_forward=1

Assuming your keys and client configs are all squared away; Reboot your server and you should be good to go!

Once connected, ping from client:

 Ping 10.8.0.1
 Ping 192.168.5.20


The update manager has the upgrade button you are looking for.

start the update manager with typing update-manager in a terminal. The upgrade button will be shown there.

Or you can search for it in dash by typing update manager.


What can I do to help make Ubuntu better for iMac users?

Technically, it works but with a very low performance. Some tweaks are usually needed.
You can contribute to the Mactel community in the official Ubuntu wiki, most of their documents are outdated and need people like you to improve them.
The matter of post-installation, there is a great answer to solve your doubts
From the Ubuntu documentation:

If you want to program brand-new features specifically for Ubuntu or redesign and develop current ones, there are several ways to get you started:
Look through the list of Ubuntu specifications on Launchpad. Pick one that interests you, and hopefully there should be enough information to begin with an implementation.
Write and package brand new software for Ubuntu. Contact the MOTUs to get new software into the Ubuntu Universe so that people can try it out and give you feedback. In time it may become part of the Ubuntu Main portfolio of applications that are available to all Ubuntu users by default.


Minidlna server only appearing after restart

The notify_interval option in /etc/minidlna.conf should be changed to a lower value as the default is 900 seconds, so that every 15 minutes minidlna sends a multicast advertisement.

That is too long time to wait for the TV to start seeing your files, so I set a 30 seconds interval instead:

sudo nano /etc/minidlna.conf
notify_interval=30


Make Windows the default boot option in an UEFI enabled system

You're lucky as you have UEFI. (I seriously never thought I'd ever say that lol). Ubuntu supports SecureBoot/UEFI.

Install Ubuntu as normal. It should detect the UEFI configuration.

Once it's done, boot into your BIOS configuration and change the boot order. Move Windows further up and move Ubuntu down. The UEFI system will automatically boot into Windows instead of using GRUB2.

For you to boot into Ubuntu, simply enter the BIOS settings again and use the Boot Override menu. It can also be called Select boot device... or similar.

This works because UEFI uses boot files instead of a MBR. There can be multiple bootloaders on a single drive.

A standard EFI boot partition has the following (simplified) file scheme:

EFI
|
|--> UBUNTU
|     |
|     |--> grub2.efi
|
|
|--> Windows
      |
      |--> win32.efi

The EFI bootloader is (by default) trying to do this:

 1. Check for the UBUNTU folder, and try to boot from the `grub2.efi` file.
 2. Check for the Windows folder, and try to boot from the `win32.efi` file.

You can change the order so it looks for Windows first. Once the boot succeeds, it will not continue trying to use bootable EFI files. If you set Windows first (and it works), Windows will boot without GRUB ever being seen. You can then manually override this by using the Select Boot File... option/key/decoder ring/sacrifice/UEFI setting.

Consult the documentation that came with your computer for the proper settings, keycombination, and/or the right mixture of blood. I do not know these off-hand.


How do I backup grub files / configuration on a new installation of Ubuntu 16.04?

First, you can always chroot into your broken Ubuntu and reinstall the GRUB, read here.

! These commands are dangerous, be aware of what you are doing !

However here is what I do:

Get a backup from MBR:

sudo dd if=/dev/sda of=/home/user/mbr bs=512 count=1

Get a backup from files within the /boot directory.

It's not really necessary, you can only get a copy of /boot/grub/grub.cfg it's the file containing the menu entries

Note that /dev/sda is my first hard disk where my grub has been installed on for you it might be /dev/sdb or something else.

When ever I broke my system's GRUB (Most of the times its a broken MBR), I can easily boot into a Live system and restore my MBR using:

sudo dd if=/home/usr/mbr of=/dev/sda

And my MBR with a working grub is back, you can also use your backup from /boot to restore anything else that might be corrupted.


error while importing tensorflow version 1.0 gpu

Can be found here.
sudo apt install libcuda1-384

Just for completeness the file should be located at /usr/lib/x86_64-linux-gnu/libcuda.so.1.

https://github.com/tensorflow/tensorflow/issues/4267


I have the same problem with Xubuntu 14.04, too. Solution above didn't work for me. The only workaround I found was to play wmv files using mplayer from terminal (since skinned version fails to load).

Like mplayer [filename]

Hope it helps.

EDIT: found out, that XBMC can play wmv files as well.


Kerberos - Active Directory Domain Failure (Ubuntu)

After i google this past week, lucky i found this site http://edoceo.com/howto/samba4

Happens to be i need to edit my dnsmasq (/etc/dnsmasq.conf)
add this line :

  srv-host=_kerberos._tcp.test.sg,4ecapsvsg6.test.sg,88
  srv-host=_kerberos._tcp.dc._msdcs.test.sg,4ecapsvsg6.test.sg,88
  srv-host=_kerberos._udp.test.sg,4ecapsvsg6.test.sg,88

  srv-host=_kpasswd._tcp.test.sg,4ecapsvsg6.test.sg,464
  srv-host=_kpasswd._udp.test.sg,4ecapsvsg6.test.sg,464

and disable Bind9 (which installed along with Samba4 by default)

Now the problems gone :)

Only one problems remains, how to connect to AD (which i'll open another thread for that)


“Enable Wireless” option is disabled in network settings

Your WiFi is disabled in hardware: on Page 2-4 of the manual of your computer: press the Fn+F12 to turn the WiFi on or off.  If that fails, maybe the BIOS setting is set to not use the Fn key.  In that case: press F12 all on its own.

LQ queue reviewers: That's it!  :-/


Why am I getting ubuntu option in boot menu(Image included ) even after I have deleted the Ubuntu partition?

You need to delete grub from the EFI System partition.

In the EFI partition, find the folder /efi/ubuntu/ and delete it.


Alt key caught by ubuntu, can't use intellij keybindings (and want to key the bindings I know)

Well I have managed to do most of what I want with some help from this (answer) [What is dconf, what is its function, and how do I use it?
the TL;DR is use

gsettings list-recursively | egrep "*Alt*"

to find the where the keybindings are used and then the dconf-editor to change those settings.
If there is a more systematic way to do this, that would be great.


I have/had the same problem (Acer 3820TG laptop) with 2 video chipsets. Ubuntu 14.04.

Main problems were:

Cursor flickers or disappears completely.
I would launch programs and the window was on the other screen (I thought it hadn't launched correctly, urrgh!) so I couldn't see it.

As a workaround I selected Mirror Displays in System Settings/Screen Display.(Both screens reported identical attributes so no resolution conflict expected)

It gave me a problem warning but has fixed these problems. SO far its working but I don't know why it detects two in-built displays. Like you, I suspect the 2 graphics cards to one monitor are confusing it.


Where is the application to reverse the color of the screen?

Compiz method

Its a Compiz plugin,
Firstly install ccsm if you havent already

sudo aptitude install compizconfig-settings-manager

Then go to

System > Preferences > CompizConfig Settings Manager

Tick the plugin Negative. If it is not listed, then install the compiz-plugins package, and reopen CCSM:

sudo apt-get install compiz-plugins

Now it should work
But in Natty, You will face a problem, Pressing Ctrl+M Brings up the messaging menu
So the key association of the Negative Plugin should be reassigned to another combination

To do that:
Click the Name of the negative plugin
You should encounter such a page

Click the key combinations and change them to something else

Now it will work

Non Compiz method

Either you can use

magnifier -z 1 -fi

or
sudo apt-get install xcalib
 /usr/bin/xcalib -invert -alter;


Microphone not working on Ubuntu 14.04 on MacBookPro10,2

Well I finally found it. Amazing how quickly that happens after you ask a question.

I added the following line to /etc/modprobe.d/alsa-base.conf

options snd-hda-intel model=mbp101

Credit goes to fooblahblah https://bbs.archlinux.org/viewtopic.php?id=144255&p=4

So happy right now.


If I run lspci on a LiveCD booted in VirtualBox I see a couple of devices which give it away:

00:02.0 VGA compatible controller: InnoTek Systemberatung GmbH VirtualBox Graphics Adapter
00:04.0 System peripheral: InnoTek Systemberatung GmbH VirtualBox Guest Service

I haven't installed the Guest additions.

If this is scripted, you could do something as simple as:

if [[ lspci | grep VirtualBox >/dev/null ]]; then
   ...
fi


You could try using the bind mount method, in order to have your secondary hard drive mounted into two location.

mount --bind /mnt/... /media/...

In order to make it persistent, modify your fstab.

/mnt/...     /media/...    none      bind

Don't forget to add this line after all other mounts.


Bash - putting the first word of every line into an array

Unless you have to do it in pure bash (for pedantic reasons?), use cut to produce the list of "first words", either in a for wrd in $(cut "-d " -f1 $file_name ) ; do loop, or if your word list is larger than xargs --no-run-if-empty --show-limits </dev/null, use cut and xargs.

In your existing code, you seem to be trying to slurp up all the data, and using only bash "Parameter Expansion", process it in content (a misuse of bash variables), then use it as a filename (cat $content), to flatten the data out and process 1 line at a time.

Of course, read man cut, man xargs, and man bash.


How can I map repeated key presses to specific?

Either turn on Sticky Keys (included in Ubuntu) or take a look at USB foot petals (more) which explicitly support Linux and imitate the Shift key of your keyboard.


I don't know how to do it using your .img file, but your goal is readily do-able using Clonezilla. Just take a Clonezilla backup of the partition, then boot your virtual machine using Clonezilla and restore the backup into it.

I actually just did this yesterday to test an 18.04 upgrade in a vm before doing it on the real machine.


There are two kinds of Ubuntu Live systems- with Persistence and without persistence. If you make a persistent USB drive, the data you create during the session are saved in a casper-rw file. This changes are stored and reflected even after you reboot. A Live system without persistence is reset to the defaults each time it is shutdown.

To used  a casper-rw file that is larger than 4GB, you'll need to partition the pendrive.

The HDD remains unaltered as long as you do not explicitly modify a file from the hard drive itself.

The speed and performance of such live systems depends largely on the performance of the USB drive. I would say it isn't painfully slow and can be managed.


Step 2 of Windows liveUSB instructions are not clear to me

As far as step 1, you guessed correctly. (To be more exact, "Linux Distribution" is a category, and "Ubuntu Desktop Edition" falls into that category.)

"Ubuntu 13.10 Desktop i386" should work fine with your computer, but you might consider picking "Ubuntu 13.10 Desktop amd64" if you gives the option. The browse button is for if you already had a copy of Ubuntu. In your case, you want to instead check the box that says "Download the ISO (optional)". This should automatically retrieve Ubuntu from the internet for you.


How do I get keyboard shortcut working for maximise in gnome-shell?

"In Unity 12.04 Super+Up is for maximizing windows." - Thanks to Jakob for this answer (in comments), this does work and so unless you really think it must be Alt+F10, stick with this.


VirtualBox cannot be started, removed or reinstalled

Update Virtualbox like so...

In terminal...

dpkg -l *virtualbox* | grep ii # show installed VB software

ii  virtualbox                     5.1.38-dfsg-0ubuntu1.16.04.3 amd64        x86 virtualization solution - base binaries
ii  virtualbox-dkms                5.1.38-dfsg-0ubuntu1.16.04.3 all          x86 virtualization solution - kernel module sources for dkms
ii  virtualbox-qt                  5.1.38-dfsg-0ubuntu1.16.04.3 amd64        x86 virtualization solution - Qt based user interface

sudo apt-get remove virtualbox # uninstall VB 5.1

dkms status # note the name of the virtualbox software

Note: with the next command, you may need to change "virtualbox-dkms" to the name found with the dkms status command... let me know if you have any problem...

sudo dkms remove virtualbox-dkms/5.1.38-dfsg-0ubuntu1.16.04.3 --all # remove dkms driver

sudo apt-get remove virtualbox-dkms # uninstall other VB softwares

sudo apt-get remove virtualbox-qt # uninstall other VB softwares

sudo apt-get update # update software database

sudo apt-get install virtualbox-6.0 # install newer version


Acer laptop, Intel 2200BG, wireless "disabled by hardware switch" irrespective of switch position

I decided to answer my own question with the solution I found at least, not least because, while there are many similar questions (and answers) around for the Intel 2200BG chip, none concerned the acerhk module and Acer hardware.

The way I solved this is by installing the acerhk module. This Hotkeys module also controls the function of the wireless hardware switch.
This module was removed in a previous release (9.10?) which is probably why the hardware switch stopped working in the first place. Even the source package was removed from the standard repositories a while back. Luckily, I found a recent version on Launchpad, including a PPA.

1) Install acerhk-source:

sudo add-apt-repository ppa:cogito-16/ppa

sudo apt-get update

sudo apt-get install acerhk-source

2) Like the README.Debian in usr/share/doc/acerhk-source says, do

sudo module-assistant auto-install acerhk

3) Load the module according to your model in this rfswitch.SF model matrix. For me, this was

sudo modprobe acerhk force_series=290 usedritek=1 verbose=1

sudo echo 1 > /proc/driver/acerhk/wirelessled

This will to everything you need. Your wireless hardware switch should work now.

4) To make this change permanent after reboot, you have to do as explained here:

Create the config file
echo 'options acerhk force_series=290 usedritek=1 verbose=1' | sudo tee /etc/modprobe.d/acerhk.conf

Edit /etc/rc.local

echo 1 > /proc/driver/acerhk/wirelessled
exit0

and /etc/modules as root an add an entry for the module

acerhk

When I think this has stumped me for >1 year (I don't use this laptop very often anymore), and I probably wasted 2+ solid days searching for a solution, it was pretty simple in the end. I hope this will help you, too.

NB: You can also get acerhk source from its homepage, but this didn't compile for me with the current kernel - make just sat there and did nothing, probably the reason why it got kicked out of the standard repos.


Edit the /etc/default/grub file

GRUB_CMDLINE_GRUB=" "

add rootdelay=30 nomodeset between quotes

then save the changes, exit and reboot.


All of the folder it is in owned by root, but you should be able to delete with sudo:

sudo rm -rf /media/user/DATA/Personal/Program/Java

To create a new folder, you can use:

mkdir /media/user/DATA/Personal/Program/Java

if you run into a permissions error, and want it to be owned by your user:

sudo mkdir /media/user/DATA/Personal/Program/Java
sudo chown -R YOUR-USERNAME:YOUR-USERNAME /media/user/DATA/Personal/Program/Java

and if you want the entire folder owned by your user:

sudo chown -R YOUR-USERNAME:YOUR-USERNAME /media/user/DATA/Personal/Program/

Hope this helps


You may have two separate issues. File system corruption and secure boot...

To check the file system on your Ubuntu partition...

boot to the GRUB menu
choose Advanced Options
choose Recovery mode
choose Root access
at the # prompt, type sudo fsck -f /
repeat the fsck command if there were errors
type reboot

Stop the reboot at the BIOS and check to make sure that secure boot is disabled.


Apache is not starting automatically after reboot

Have you tried sudo systemctl enable apache2? It could be it got disabled somehow. If it's starting without problems using the start command, I can't imagine why this wouldn't fix it not starting on its own.

If this fixes it, it means there's no errors; it just wasn't being told to start.


What's the difference between the 'ubuntu-gnome-desktop' and 'gnome' packages?

The package gnome is closer to the pure GNOME and the ubuntu-gnome-desktop is more Ubuntu specific.

The package gnome

Full GNOME Desktop Environment, with extra components

This is the GNOME Desktop environment, an intuitive and attractive
desktop, with extra components.

This meta-package depends on the standard distribution of the GNOME
desktop environment, plus a complete range of plugins and other
applications integrating with GNOME and Debian, providing the best
possible environment to date.
The package ubuntu-gnome-desktop

The Ubuntu GNOME metapackage

Ubuntu GNOME is an Ubuntu flavor that offers a mostly pure GNOME
experience. This package depends on all of the core Ubuntu
GNOME packages.

It is also used to help ensure proper upgrades, so it is recommended that
it not be removed.


discover if other users are executing the watch command on the machine in which MyOwnCommand is beeing executed

To see what processes are running on a machine, you can use ps. This is a command with a huge number of options, so you might want to take a look at man ps to learn a little about it.

To check whether anyone is running watch, you would do:

 $ ps aux | grep -w watch
terdon   15915  0.0  0.0  15912  2676 pts/4    S+   15:58   0:00 watch ls
terdon   16123  0.0  0.0  13948  2264 pts/5    S+   15:58   0:00 grep --color -w watch

The -w tells grep to only match whole words. Otherwise, processes like watchdog would also be listed. However, that also returns the grep process itself. To avoid that, you can use pgrep:

$ pgrep -xl watch
15915 watch

The -x makes it look for exact matches only and the -l makes it also list the process name and not just its PID.

Now, if you want to check for both  MyOwnCommand and watch, you could do:

$ pgrep MyOwnCommand >/dev/null  && pgrep -xl watch
15915 watch

The && means that the second pgrep will only be run if the first was successful, if MyOwnCommand is running. The >/dev/null discards the output of the first pgrep.


Installed new kernel on Ubuntu 12.04. How do I start it?

Do you see your new image in the /boot directory?

$ ls /boot

It may be as simple as doing:

$ sudo update-grub


Installing Ubuntu 18.04 alongside Windows 10 from USB

Beore proceeding, do you make sure that you are installing Ubuntu with the same boot options as Windows. This way you will be able to choose which one to boot from in the same boot menu and not worry if one will work or not.


The manpage of ufw in the RULE SYNTAX section explains the port range part of your question quite well I guess. Hard to get an excerpt with only relevant information from it, so to summarize by example:

/tcp just makes the rule only match TCP. Removing that will match all traffic, including UDP and possibly other future protocols with port numbers.
Ranges are indeed specified as you described. 6667:7000 matches all ports from 6667 up to and including 7000.
Multiple ranges or individual ones can be separated by commas, e.g. 6667,6669:7000 will be the same as above, but excluding 6668.

Wikipedia on IRC mentions this as the protocol/ports required to use it:

  IRC was originally a plain text protocol (although later extended),
  which on request was assigned port 194/TCP by IANA. However, the
  de facto standard has always been to run IRC on 6667/TCP and
  nearby port numbers (for example TCP ports 6660–6669, 7000) to
  avoid having to run the IRCd software with root privileges.

So, this should do the trick for most common outgoing IRC connections:

sudo ufw allow out 6660:7000/tcp

And look for documentation on the IRC server you're connecting to if available. For example FreeNode:

  All freenode servers listen on ports 6665, 6666, 6667, 6697 (SSL only), 7000 (SSL only), 7070 (SSL only), 8000, 8001 and 8002.


How can I install Java from the command line only?

A better solution is to install default java:

sudo apt-get install default-jdk

This will install all of the latest packages for the default jdk product.


Will I lose my applications and desktop customizations when I upgrade to a new release?

A release upgrade will remove some packages from your system, but in general most of the packages being used currently will be updated to new versions and your system and most of the applications you use at the moment will remain the same.

About customizations we are talking about a different story:

If you are talking about simple customizations, eg: wallpaper and the size of your launcher icons, then nothing will probably change;
Other more in depth system changes can be eventually reversed by the upgrade and the customization effects will need to be re applied with updated versions of the tools you used to customize your desktop.

14.04 is the next LTS, once you upgrade you will probably be happy with it and enjoy 5 long years of support and stability. I would say that its better to upgrade and test than to worry now. If you need to re-install and least do it only if necessary and if you are worried about stability then do it for a LTS version as 14.04.


Ok, I just tried installing it, an it worked OK.  Here what I did: To install, just press Ctrl+Alt+T on your keyboard to open Terminal. When it opens, run the command(s) below:

sudo apt-get install scilab

After the installation was done, I searched for scilab in dash, and clicked on it

After I clicked on it, it opened, and I checked the version, and it was 5.4.1

Hope that helps.


You have to revert libc6 library to the normal version using command below:
sudo apt-get install libc6=2.31-0ubuntu9.2 libc6:i386=2.31-0ubuntu9.2


nvramtool, but it seems that some settings are unaffected even when changing their value in nvram from ubuntu (SystemAudioVolume might be one).


poor 2d performance with nvidia 375.66 and 378.13 (when scrolling, moving windows, watching movies etc.)

This solve the issue:
You could benefit from enabling Prime Synchronization, I've outlined how to do in this post. https://ubuntuforums.org/showthread.php?t=2365449&p=13663158#post13663158 If you don't know how to use nano ask first. (pretty easy – doug 8 hours ago

Ty Doug


How can I disable the multitouch gestures in Ubuntu?

I have solved this issue by setting the following configuration values (initial values were 0):

synclient ClickFinger3=2
synclient TapButton3=2


Input the filename in the commandline as an argument in Python

I would use sys.argv.

import sys
filename = sys.argv[1]

sys.argv will be a list of elements in your call.


You can try with -f flag with the command as

sudo chattr -f +i /etc/resolv.conf


Error installing software through terminal

Assuming you installed a Java package called "oracle-java8-installer" (as an example) you should be able to force-remove it with:

sudo dpkg --purge oracle-java8-installer

And then you should be able to continue updating the rest of your system with apt-get as normal.


Resize partition without affecting other OSes in dual-boot

You can resize a Windows (NTFS) partition from Ubuntu using GParted. You'll need to shrink the partition to free up some unallocated space on the drive. Then you will be able to create a new Linux partition in that space.

GParted is not installed by default, look for it in the Software Center or install it in therminal by doing

sudo apt-get install gparted

It won't be possible to modify your Ubuntu root partition (or, more precisely, any partition which is in use) while booted in Ubuntu. To do this, boot from Ubuntu Live CD and run GParted from there.

Make sure you have a backup of your important data before proceeding because it's a potentially dangerous operation.

You can find more documentation on GParted here: http://gparted.sourceforge.net/


How can I troubleshoot `apt-get update` giving Hash Sum mismatch

I have encountered the same situation.

W: Failed to fetch http://security.ubuntu.com/ubuntu/dists/vivid-security/main/binary-amd64/Packages  Hash Sum mismatch

W: Failed to fetch http://security.ubuntu.com/ubuntu/dists/vivid-security/main/binary-i386/Packages  Hash Sum mismatch

W: Failed to fetch http://archive.ubuntu.com/ubuntu/dists/vivid-updates/main/binary-amd64/Packages  Hash Sum mismatch

W: Failed to fetch http://archive.ubuntu.com/ubuntu/dists/vivid-updates/universe/binary-amd64/Packages  Hash Sum mismatch

W: Failed to fetch http://archive.ubuntu.com/ubuntu/dists/vivid-updates/universe/binary-i386/Packages  Hash Sum mismatch

E: Some index files failed to download. They have been ignored, or old ones used instead.

First，I edited apt.conf

Debug::Acquire::http true;
Debug::pkgAcquire::Auth true;
Debug::Hashs true;

then，searched http://security.ubuntu.com/ubuntu/dists/vivid-security/main/binary-amd64/Packages in the apt-get update command output, and found this:

Get:1 http://security.ubuntu.com vivid-security/main amd64 Packages [115 kB]
100% [1 Packages 115 kB/115 kB 100%] [Waiting for headers] [Connecting to security.ubuntu.com (91.189.91.15)]201 URI Done: http://security.ubuntu.com/ubuntu/dists/vivid-security/main/binary-amd64/Packages.bz2
RecivedHash: SHA256:0460b45fe9ace5ddb1e2080df5f75a6ee5d950fa451733991ec1b2b303bd16f6
ExpectedHash: SHA256:9daf23b84605ff833d1d280f837bd87fcbc3c7e0ca9403590985f970ee561f61

100% [1 Packages bzip2 0 B] [Waiting for headers] [Connecting to security.ubuntu.com (91.189.91.15)]201 URI Done: bzip2:/var/lib/apt/lists/partial/security.ubuntu.com_ubuntu_dists_vivid-security_main_binary-amd64_Packages.bz2
RecivedHash: SHA256:f10f6ef0486182bc9369e7912ddb9cf536c3049813ffd169b84f34dcda540ace
ExpectedHash: SHA256:9daf23b84605ff833d1d280f837bd87fcbc3c7e0ca9403590985f970ee561f61

http://security.ubuntu.com/ubuntu/dists/vivid-security/main/binary-amd64/Packages: Computed Hash: SHA256:f10f6ef0486182bc9369e7912ddb9cf536c3049813ffd169b84f34dcda540ace  Expected Hash: SHA256:9daf23b84605ff833d1d280f837bd87fcbc3c7e0ca9403590985f970ee561f61
100% [Waiting for headers] [Connecting to security.ubuntu.com (91.189.91.15)]GET /ubuntu/dists/vivid-security/multiverse/binary-amd64/Packages.bz2 HTTP/1.1
Host: security.ubuntu.com
Cache-Control: max-age=0
Range: bytes=5195-
If-Range: Mon, 28 Sep 2015 14:33:00 GMT
User-Agent: Debian APT-HTTP/1.3 (1.0.9.7ubuntu4)

Obviously，the downloaded Packages file was not right. So I downloaded http://security.ubuntu.com/ubuntu/dists/vivid-security/main/binary-amd64/Packages.bz2 and http://security.ubuntu.com/ubuntu/dists/vivid-security/main/binary-amd64/Packages.gz, unzipped them and checked hash sum manually：

$ wget http://security.ubuntu.com/ubuntu/dists/vivid-security/main/binary-amd64/Packages.bz2
$ wget http://security.ubuntu.com/ubuntu/dists/vivid-security/main/binary-amd64/Packages.gz
$ sha256sum Packages*
0460b45fe9ace5ddb1e2080df5f75a6ee5d950fa451733991ec1b2b303bd16f6  Packages.bz2
f10f6ef0486182bc9369e7912ddb9cf536c3049813ffd169b84f34dcda540ace  Packages.from.bz2
9daf23b84605ff833d1d280f837bd87fcbc3c7e0ca9403590985f970ee561f61  Packages.from.gz
b6b70b8f7838d742104904d461677652cf5120f9b8302841cb017c0c5c9dea40  Packages.gz

It turned out that http://security.ubuntu.com/ubuntu/dists/vivid-security/main/binary-amd64/Packages.bz2 contains a wrong Packages file, but the http://security.ubuntu.com/ubuntu/dists/vivid-security/main/binary-amd64/Packages.gz contains the right one which is not downloaded by default.

So edit apt.conf:

Acquire::CompressionTypes::Order:: "gz";

It worked for me. Good luck!


unable to boot win7 after installing ubuntu

Install Boot-Repair to reinstall GRUB and fix boot problems.

In a new terminal, type the following commands:

sudo add-apt-repository ppa:yannubuntu/boot-repair
sudo apt-get update
sudo apt-get install -y boot-repair && (boot-repair &)

Launch Boot-Repair and click on Recommended repair.

With Boot-Repair, you can also create a Bootinfo summary to make a report of your boot problems before reinstalling GRUB. This report need to be posted here for further analysis.

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


Upgrade hardware enablement stack but retain kernel

If you are looking to update the x-org display drivers, why not look into installing the oibaf PPA or xorg edgers PPA.  I know for sure the oibaf ppa doesn't work with the hardware enablement stack it is meant to work with your existing kernel and just update the x-org video drivers.

I use oibaf with 14.04. Just add the PPA in Software and Updates  or run

sudo add-apt-repository ppa:oibaf/graphics-drivers

then, in either case, do:

sudo apt-get update

followed by:

sudo apt-get dist-upgrade


As steeldriver properly pointed out, all you have to do is to put commas after each item in the command, like so:

sudo ir-keyable -p NEC,RC-5,RC-6,JVC,SONY,SANYO,LIRC,RC-5,SZ,SHARP,XMP

But of course, we as Linux users love our command-line and scripting solutions, so one possible solution that you could use is tr:

$ echo NEC RC-5 RC-6 JVC SONY SANYO LIRC RC-5 SZ SHARP XMP | tr ' ' ','
NEC,RC-5,RC-6,JVC,SONY,SANYO,LIRC,RC-5,SZ,SHARP,XMP

Or maybe you like awk:

echo NEC RC-5 RC-6 JVC SONY SANYO LIRC RC-5 SZ SHARP XMP | awk '{for(i=1;i<=NF;i++){printf $i;if(i<NF)printf ","}}'

But surely python can do the job too:

python -c 'import sys;stuff=sys.stdin.read();print ",".join(stuff.split())' <<< "NEC RC-5 RC-6 JVC SONY SANYO LIRC RC-5 SZ SHARP XMP"


U16.04- DNS messed up, must edit /run/resolvconf/resolv.conf after booting

First, as it is badly malformed, return your /etc/network/interfaces file to default:

# interfaces(5) file used by ifup(8) and ifdown(8)
auto lo
iface lo inet loopback

Second, you can easily set your own DNS nameservers in Network Manager like this: https://farm4.staticflickr.com/3898/14334590042_3c72168038_o.jpg

After making these changes, reboot and let us hear your report.


You should choose the session "XMonad" from the login manager (LightDM by default).

Some useful keys:

Mod-Shift-Enter open a terminal
Mod-Shift-p launch gmrun
Mod-Shift-q quit xmonad

where Mod is the Win key.


Opera & Pepper flash

Opera Forums: http://forums.opera.com/discussion/1850996/pepper-flash-on-linux/p1

  ruario    December 2014

  If you use Ubuntu or Debian install the pepperflashplugin-nonfree
  package.

Ubuntu package: http://packages.ubuntu.com/search?keywords=pepperflashplugin-nonfree&searchon=names&suite=all&section=all

More can be found:

https://wiki.debian.org/PepperFlashPlayer
https://wiki.debian.org/PepperFlashPlayer/Installing


Upstart virsh commands fail on startup even with libvirt-bin running

The easiest would be to add a static sleep of a few seconds to your script startup. This may not be ideal for many reasons, especially if you use this script more generally, since the sleep is not directly linked to libvirt being up.

It might be better to have the script check if libvirt is indeed started. You may be able to do this using the exit status of virsh connect or checking if libvirtd has bound to the socket (lsof).


How can I install GNOME 3.12 on saucy (13.10)?

You can find a live image in gnome's website:

Getting GNOME | GNOME

Try the latest release

GNOME 3.12 is the latest version and will be available in distributions in the future. In the mean time, you can try our live demo image.

Instructions for installing the image on to a USB stick with GNU/Linux:

  Insert the drive (any data it contains will be erased!)
  Run dmesg in a terminal: this will give you the location of the stick in square brackets, such as sdb
  To write the image, run sudo dd if=gnome-3.12.iso of=/dev/DRIVE bs=8M conv=fsync, replacing DRIVE with the location (e.g., /dev/sdb but not e.g., /dev/sdb1)
  Once the write operation has finished, you can reboot with the USB drive inserted (you may have to specify the boot device on startup)


If your mobile is rooted and have a terminal emulator installed then you can check the host name using command

getprop net.hostname

To change host name type:

setprop net.hostname new_name


Why is Grub menu not shown when starting my computer?

Hold down the shift key during the boot process this will give you the menu on a one off basis.
You can also modify /etc/default/grub comment out the line by adding a # to the start like:
# GRUB_HIDDEN_TIMEOUT=0

This will cause the grub menu to be displayed for the number of seconds in GRUB_TIMEOUT before selecting the default and booting that.
If you have modified this file then you need to run update-grub for it to take effect. This will automatically be run each time a new kernel is installed by sudo apt full-upgrade
sudo update-grub

Edit-Oct-14-2020: In ubuntu 20.04.1 you have to enable console mode. Open /etc/default/grub with your preferred editor (sudo required) and uncomment the line GRUB_TERMINAL=console. Don't forget to sudo update-grub


PC can't find my HDD after lubuntu 13.10 Crash

The simple solution to this would be to boot from your live CD or Flash Drive and check to see if the hard-drive in question can be accessed from there, if so then thankfully your partitions are ok and you could perform a new install of Lubuntu to fix everything once more without adding zram, leave that for Lubuntu 14.04 in April...


Installing latest version of wine on Ubuntu 17.10

First, as I'm new to linux also, check the date and version used on any write up you find. A write up from 2010 more than likely won't directly apply, as with a write up from ubuntu version 10.... Not everything changes but most things do to some degree. Look for ubuntu 17 instructions not general linux instructions.

There are three gui's for software on my xubuntu 16 install. Software, software updater, and software and updates. Software is where you can find a wine package and other apps/software, software updater helps with updates, it will do the same as "sudo apt update" to some degree, and the software and updates allows you to add ppa's and configure your auto update stuffs.

You don't need to add a ppa to find wine in the software gui. If you try to download it from there, and can't get it to work, look here:   https://wiki.winehq.org/Ubuntu

They list a different ppa than you did,
"sudo apt-add-repository https://dl.winehq.org/wine-builds/ubuntu/," along with a bunch of other crap, so I'd try the software manager version first. I did see some reviews there saying it wasn't working, so you might have to check out the winehq website, or wait for a patch.

I'm not entirely sure but I don't think, "Enter ppa:ubuntu-wine/ppa," will add a ppa. The computer doesn't know how to get there. Notice the one I posted from winehq is a web address, the computer knows how to get there. What does it do with the ppa they listed? Nothing as far as I know. Even where you said you added the ppa it lists a format for adding them, "The APT line includes the type, location and components of a repository, for example  'deb http://archive.ubuntu.com/ubuntu xenial main'."

Try the software gui, from there go to wine hq. What I read there is far more complex than I want to try, without having to, If your running 64bit you have to enable 32bit arc, etc.


Exception on Desktop[sic!] sun.awt.X11GraphicsEnvironment

I didn't remember that I had OpenJDK activated on this computer, and switched to it recently.

After steaberts comment, I found the solution real quick:

update-java-alternatives -l
java-1.5.0-sun 53 /usr/lib/jvm/java-1.5.0-sun
java-6-openjdk 1061 /usr/lib/jvm/java-6-openjdk
java-6-sun 63 /usr/lib/jvm/java-6-sun

^ This are the installations

sudo update-java-alternatives -s java-6-sun

^ switched to suns java (formerly known as oracle :) )

and: Bingo: No more error-message, program runs.

If somebody has a solution for OpenJDK: You're welcome. But I'm not that much interested anymore and wouldn't spend hours of tests on this. :)

However: you rock!


WINEDEBUG is an environment variable that is set for only for the invocation of wine.

What you need to do is make the environment variable permanent, which you can do in your ~/.bashrc.

Open it in your favourite editor and add to the bottom:

export WINEDEBUG=-all

The next new Terminal you open will trigger that setting and wine ./program.exe should inherit it.

Since .bashrc is just a series of shell commands that are run when a Terminal is started, you can just type the same thing into a Terminal as well; but then it will be lost when you close that Terminal.


Multiarch issue with packages marked as supporting "all" architectures

So as I suspected there is a hacky solution for now, which I don't like but at least it allows me to continue working. In case someone is interested in a temp solution:

I downloaded proj-data: apt-get download proj-data
I used fpm to change the control file of the .deb: fpm -e -s deb -t deb ../proj-data_4.9.2-2_all.deb
In the control file I change this line: Architecture: all to Architecture: arm64.

  Update: Based on documentation using actually Architecture: any should be the way (but I haven't tested).

I installed the new .deb: dpkg -i <deb_file>

And now libproj9:arm64 is not complaining finding proj-data:arm64 any more.


How To Fix Nvidia Driver 384.90 From Causing fsck from running On 17.10 Boot

this is not an issue with the nvidia drivers. it is possibly because of kernel update or fsck update or plymouth update. It used to do the scan without report to the GUI splash screen. now when fsck starts it flashes a message on the GUI even if the drives are set to not be scanned.

The fix to prevent fsck from starting is to edit your /etc/fstab file.
The fstab entries should look something like:

UUID=<uuid>  /  ext4 errors=remount-ro 0 1

the last digit tells fsck which pass to scan the partition. Possible values are 0,1,2.
Setting it to zero for all mounts will keep fsck from launching and passing any messages.

Note: this also means that you will have to manually check your file system periodically.


My computer shows 6 boot options instead of 2

The other ones are recovery and memory test options. These are useful if something breaks. However, you can modify the GRUB config to not display those options, I don't recommend this though.


You can convert it to iso via  nrg2iso

sudo apt-get install nrg2iso
nrg2iso source.nrg desitination.iso

or you can try nero for linux


WiFi doesn't work with Compaq CQ58 (RALINK RT5390R)

I've maybe the same problem. I have:

02:00.0 Network controller: Ralink corp. RT5390 [802.11 b/g/n 1T1R G-band PCI Express Single Chip]
    Subsystem: Hewlett-Packard Company Pavilion DM1Z-3000 PCIe wireless card
    Flags: bus master, fast devsel, latency 0, IRQ 17
    Memory at d0100000 (32-bit, non-prefetchable) [size=64K]
    Capabilities: [40] Power Management version 3
    Capabilities: [50] MSI: Enable- Count=1/32 Maskable- 64bit+
    Capabilities: [70] Express Endpoint, MSI 00
    Capabilities: [100] Advanced Error Reporting
    Capabilities: [140] Device Serial Number 00-00-9e-c4-b7-f9-55-ec
    Kernel driver in use: rt2800pci
    Kernel modules: rt2800pci

With linux-image-5.3.0-51-generic it don't work. It disconnect all the time.
With linux-image-5.3.0-28-generic it works fine.
Also works with all ubuntu kernels I've tested back to ubuntu 11.04 kernels.

Get this in syslog:

May 12 22:49:41 pluttis wpa_supplicant[1004]: wlan0: CTRL-EVENT-SIGNAL-CHANGE above=0 signal=-83 noise=9999 txrate=6500
May 12 22:49:45 pluttis wpa_supplicant[1004]: wlan0: SME: Trying to authenticate with 38:43:7d:60:f1:4e (SSID='JACn2G' freq=2412 MHz)
May 12 22:49:45 pluttis kernel: [  167.140512] wlan0: disconnect from AP 38:d5:47:1f:04:e0 for new auth to 38:43:7d:60:f1:4e
May 12 22:49:45 pluttis kernel: [  167.265794] wlan0: authenticate with 38:43:7d:60:f1:4e
May 12 22:49:45 pluttis kernel: [  167.268995] wlan0: send auth to 38:43:7d:60:f1:4e (try 1/3)
May 12 22:49:45 pluttis wpa_supplicant[1004]: wlan0: CTRL-EVENT-REGDOM-CHANGE init=CORE type=WORLD
May 12 22:49:45 pluttis NetworkManager[953]: <info>  [1589316585.2040] device (wlan0): supplicant interface state: completed -> authenticating
May 12 22:49:45 pluttis kernel: [  167.973741] wlan0: send auth to 38:43:7d:60:f1:4e (try 2/3)
May 12 22:49:46 pluttis kernel: [  168.956007] wlan0: send auth to 38:43:7d:60:f1:4e (try 3/3)
May 12 22:49:47 pluttis kernel: [  169.356777] wlan0: authentication with 38:43:7d:60:f1:4e timed out
May 12 22:49:47 pluttis NetworkManager[953]: <info>  [1589316587.3694] device (wlan0): supplicant interface state: authenticating -> disconnected
May 12 22:49:47 pluttis NetworkManager[953]: <info>  [1589316587.4700] device (wlan0): supplicant interface state: disconnected -> scanning
May 12 22:49:47 pluttis wpa_supplicant[1004]: wlan0: SME: Trying to authenticate with 38:d5:47:1f:04:e0 (SSID='JACn2G' freq=2462 MHz)
May 12 22:49:47 pluttis kernel: [  169.601817] wlan0: authenticate with 38:d5:47:1f:04:e0
May 12 22:49:47 pluttis kernel: [  169.724194] wlan0: send auth to 38:d5:47:1f:04:e0 (try 1/3)
May 12 22:49:47 pluttis NetworkManager[953]: <info>  [1589316587.6547] device (wlan0): supplicant interface state: scanning -> authenticating
May 12 22:49:48 pluttis kernel: [  170.981842] wlan0: send auth to 38:d5:47:1f:04:e0 (try 2/3)
May 12 22:49:49 pluttis kernel: [  171.783215] wlan0: send auth to 38:d5:47:1f:04:e0 (try 3/3)
May 12 22:49:50 pluttis kernel: [  172.965891] wlan0: authentication with 38:d5:47:1f:04:e0 timed out


How to make Fingerprint reader of Dell latitude e6510 work on ubuntu 16.04

The device is not supported on linux. Below is link to the bug on launchpad.

https://bugs.launchpad.net/ubuntu/+source/libfprint/+bug/602071?comments=all


Install dependencies.
Ubuntu 16.04:
sudo apt install autoconf automake bison build-essential curl flex \
  libtool libssl-dev libcurl4-openssl-dev libxml2-dev libreadline7 \
  libreadline-dev libsqlite3-dev libzip-dev libzip4 nginx openssl \
  pkg-config re2c sqlite3 zlib1g-dev libonig2 libonig-dev

Ubuntu 18.04
sudo apt install autoconf automake bison build-essential curl flex \
  libtool libssl-dev libcurl4-openssl-dev libxml2-dev libreadline7 \
  libreadline-dev libsqlite3-dev libzip-dev libzip4 nginx openssl \
  pkg-config re2c sqlite3 zlib1g-dev libonig4 libonig-dev

Ubuntu 20.04
sudo apt install autoconf automake bison build-essential curl flex \
  libtool libssl-dev libcurl4-openssl-dev libxml2-dev libreadline8 \
  libreadline-dev libsqlite3-dev libzip-dev libzip5 nginx openssl \
  pkg-config re2c sqlite3 zlib1g-dev libonig5 libonig-dev

So you don't overwrite any existing PHP installs on your system, install PHP in your home directory. Create a directory for the PHP binaries.
 mkdir -p ~/bin/php7-latest/

Download the PHP 7.3 from GitHub, decompress it, then change directories using cd to the new directory. You can also download PHP 7.3 from php.net/downloads.php and the installation instructions are exactly the same. Ordinarily this would be the preferred way of downloading PHP 7.3, but I'm using PHP 7.3 from https://github.com/php/ in this answer instead in order to match the PHP 7.3 archive that is asked about in the question.

Configure PHP. Remove any options you don't need (like MySQL or Postgres (--with-pdo-pgsql))
 ./configure --prefix=$HOME/bin/php-latest \
     --enable-mysqlnd \
     --with-pdo-mysql \
     --with-pdo-mysql=mysqlnd \
     --with-pdo-pgsql=/usr/bin/pg_config \
     --enable-bcmath \
     --enable-fpm \
     --with-fpm-user=www-data \
     --with-fpm-group=www-data \
     --enable-mbstring \
     --enable-phpdbg \
     --enable-shmop \
     --enable-sockets \
     --enable-sysvmsg \
     --enable-sysvsem \
     --enable-sysvshm \
     --enable-zip \
     --with-libzip=/usr/lib/x86_64-linux-gnu \
     --with-zlib \
     --with-curl \
     --with-pear \
     --with-openssl \
     --enable-pcntl \
     --with-readline

Probably you won't need to remove any of the options except for --with-pdo-pgsql=/usr/bin/pg_config if PostgreSQL isn't installed. If you don't remove an option that is specific to a package that isn't installed, then this command will return an error message that tells you what option must be removed so that the command will run successfully.

Compile the binaries:
make # wait until make is finished

When make is finished you will see the following message:
Build complete.
Don't forget to run 'make test'.

Warning: make test takes a long time to finish, so don't run it when the computer is busy.
make install

Copy the PHP.ini file to the install directory
cp php.ini-development ~/bin/php-latest/lib/

Rename two files.
cd ~/bin/php-latest/etc/
mv php-fpm.conf.default php-fpm.conf
mv php-fpm.d/www.conf.default php-fpm.d/www.conf

Create symbolic links for your for your binary file.
cd ~/bin
ln -s php-latest/bin/php php
ln -s php-latest/bin/php-cgi php-cgi
ln -s php-latest/bin/php-config php-config
ln -s php-latest/bin/phpize phpize
ln -s php-latest/bin/phar.phar phar
ln -s php-latest/bin/pear pear
ln -s php-latest/bin/phpdbg phpdbg
ln -s php-latest/sbin/php-fpm php-fpm

Link your local PHP to the php command. You will need to logout then log back in for php to switch to the local version instead of the installed version from the default Ubuntu repositories.
# add this to .bashrc
if [ -d "$HOME/bin" ] ; then
  PATH="$HOME/bin:$PATH"
fi

Start PHP-FPM
sudo ~/bin/php-latest/sbin/php-fpm

If you run the above command as normal user without sudo, it will show the following notices:
NOTICE: [pool www] 'user' directive is ignored when FPM is not running as root.
NOTICE: [pool www] 'group' directive is ignored when FPM is not running as root.

Source: The Install file in php-src-master directory from https://github.com/php/php-src.git contains a link to https://php.net/install from which source these instructions were revised. In addition to several small revisions I added information about how to install PHP 7.3 locally in your home directory without requiring root permissions.


How to fix error report upon boot-up and after sleep mode, Ubuntu 18.04

For the Wayland crashes, try this...

In the terminal app, edit /etc/gdm3/custom.conf...

sudo -H gedit /etc/gdm3/custom.conf

Find this:

#WaylandEnable=false

Change it to this:

WaylandEnable=false

Save the file and quit gedit

reboot


Link proxy settings to particular wifi network

You might want to check out transparent proxying. Its very convenient.

Transparent proxying


multiple domains on one sever using nginx

This is one of my nginx virtual host configs..  This one works so really I think its down to those arcane fastcgi params.`
server {
    listen 80;
    server_name collect.local;
    index index.php index.html index.htm;
    root /var/www/html/collectd-html;

    location / {
       try_files $uri $uri/ =404;
    }

    location ~ \.php$ {
        try_files $uri =404;
        fastcgi_pass unix:/var/run/php/php-fpm.sock;
        fastcgi_index index.php;
        fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
        include fastcgi_params;
    }
}

I would suspect these..
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
include fastcgi_params;


Is it safe to `zfs snapshot` my entire boot drive from root down?

Short answer: Yes, you can.

Long answer: There is one caveat - the consistency of the snapshots will be "crash level" consistency. This is usually not a problem because modern operating systems and file systems go to great lengths to ensure that an unexpected power failure won't corrupt the file system, and the worst that might happen is that the most recent few seconds worth of transactions might go missions.

I have sanoid taking snapshots of my various file systems, including my VM backing zvols, and have never had any kind of a corruption issue arise from a rollback of a VM.

There may be a handful of edge cases (e.g. with databases when you have your database data directory split up over several ZFS file systems), but even that just means that you have to take a consistent snapshot of everything (i.e. zfs snapshot -r, as you propose above), to make sure that the data and the logs don't get out of sync with each other.


As an exercise, can you try install ubuntu 14.04 first? Anyway, AFAIK it is not possible to upgrade directly to 14.04 or 16.04 directly, no matters what. You have to jump want step at a time, first to 12.04, 14.04 and then 16.04.

Regarding 16.04, if you do not have much experience with Linux and Ubuntu, I would suggest not to try it. It is still not official and may have bugs here and there. You will not know what the problems really are.

Last but not least, I did not have succeed with any of the bootable USB creator recommended by Canonical. The one I find every easy to use is Yumi (the Windows version). I haven't tried the Linux version http://www.pendrivelinux.com/downloads/YUMI/ubuntu/yumi_0.0.1-1_all.deb


Where in the filesystem should I store shared data?

This question does seem to have a clear answer in the Filesystem Hierarchy Standard, which specifies /srv as "contain[ing] site-specific data which is served by this system
". (3.16.1)

  This main purpose of specifying this is so that users may find the location of the data files for particular
  service, and so that services which require a single tree for readonly data, writable data and scripts

(my emphasis)

Note: 'Served by the system' doesn't necessarily refer to the Internet. It needn't even mean a network. It's applicable to even a shared system. Further, the words site and service should be understood in their pre-internet meanings. Your site can be "the physics department" or "the finances office".

It goes on to say:

  On large systems it can be useful to structure /srv by administrative context, such as
  /srv/physics/www, /srv/compsci/cvs, etc. This setup will differ from host to host. Therefore, no program
  should rely on a specific subdirectory structure of /srv existing or data necessarily being stored in /srv.
  However /srv should always exist on FHS compliant systems and should be used as the default location for
  such data.

You should therefore further structure your data in directories such as /srv/nfs, /srv/backup and so on.

I should also mention that few people do this anymore. But there is no good reason why they don't. The standard is by no means out of date.

/var is traditionally used for things like print-spools and log-files, but it's also used by the Apache web server (on Debian systems anyway - SUSE use /srv); There doesn't seem to be consensus on whether /var is a proper directory for shared data. But if you decide to use it instead, you will have no regrets I'm sure.

Note also: Karthick's answer is by no means wrong. The FHS says /srv " should be used as the default location for
such data", but the standard leaves some room for your own preference, depending on how you interpret the terms.


Quickest method to display image dimensions for files in Nautilus in List View?

There is a package called nautilus-columns. I currently find it only in a PPA, which is documented here. With this little script its easy to add columns for various meta data for PDF, images, sound files etc. To sum all things up:

sudo add-apt-repository ppa:nilarimogard/webupd8
sudo apt-get update
sudo apt-get install nautilus-columns
nautilus -q

Finally go to Edit > Preferences > List Columns and enable all you need. Please note, its only working for the List-View.

Current versions of nautilus-columns can also be found here.


Unable to connect to visible wireless network

Network Manager often has trouble working with Broadcom.

I like to use WICD because it is a simple and easy to use network manager. Its a very good alternative to network manager in Ubuntu and it seems to always work when Network Manager doesn't. To install it just open up the terminal.

To download and install WICD

sudo apt-get install wicd-gtk

And now you need to uninstall NetworkManager:

sudo apt-get remove --purge network-manager-gnome network-manager

Now you can find WICD in your menu Start WICD, find the network you want to use and enter the information needed, password, encryption, etcetera and choose Automatically Connect to this network. You should be good to go!

WICD may also be available in Ubuntu Update Manager so you can look there first but it is important to uninstall Network Manager completely to prevent conflicts!!


Instead of pulse audio use ALSA as audio input backend. Then reduce your ubuntu mic volume to 50%.
It worked for me on Ubuntu 18 LTS.


indicator-multiload (System Load Indicator) don't show cpu usage correctly

I hope this is what you need:

from system load indicator:

CPU: $(percent(cpu.inuse)), iowait $(percent(cpu.io))


Assuming that you run UFW, do the following:

sudo ufw enable
sudo ufw allow from YOURIP to any port 443
sudo ufw deny 443

Please make sure that you don't lock yourself out of the machine while doing this. As your admin interface is running on a different port, you might need to replace the 443 above with your port number.


howto copy folder "test" to another folder with icreased number test1, test2 test3

Assuming you have a folder named test, write a shell script copytest with the following contents:

#!/bin/bash

i=1
while true
do
    if [ -d test$i ]
    then
        i=$((i+1))
    else
        cp -r test test$i
        break
    fi
    if [ $i -eq 11 ]
    then
        rm -r test{1..10}
        cp -r test test1
        break
    fi
done

Now make it executable with chmod u+x copytest and each time you call ./copytest you'll get a new copy named test<n>.

Explanation:

[ -d test$i ] checks whether there is already a folder test$i
break exits the otherwise infinite loop initiated by while true.
The eleventh call will delete all copies and begin again with test1.

This does what you asked for in your question (create more and more copies of test). If you want the copies to "move on" at each call (i.e. test10 is discarded, test9 becomes test10, etc.) then you should take a look at the logrotate command as suggested by @Jean-Marie in the first comment.


Why can I no longer access wifi networks?

Try going to system settings and select Network then wireless, make sure that Airplane mode is OFF and that Wireless is ON


change ctrrl+a keyboard shortcut (select all)

One way is by using dconf-editor
sudo apt-get install dconf-editor

Under the /org/gnome/terminal/legacy/keybindings, you will find one to select all.
Or you can use xbindkeys.


How can open-source programs make money?

Ubuntu, being a free and open source OS, does not limit you to the usage of free (as in freedom, not as in free beer, to quote Richard Stallman) software only. If you take a look into the Ubuntu Software Center, you'll find a bunch of proprietary software, some of which you have to pay money for. Another example is Steam, which allows users to sell games for Linux.

So you can make and deploy proprietary and paid software for Linux. There is no contradiction in that.

If you want to make your software free as in freedom, you could charge for it too, but it wouldn't make the most sense, as anyone who has the software and its code may remove any copy protection and redistribute it legally. Another way would be to raise donations.

There are, however, some successful business models which are based on free software, but I can't think of any example where the customer pays for the software. Most of the times, you pay for exclusive support, such as in the example of Canonical, who offers paid support for business customers. Some companies may offer other services, but I think I've made my point.


(K)ubuntu 18.04 - PulseAudio - Set Bluetooth Headphones As Default

I had the same problem with my bluetooth headphones. In my case the problem started many months after the installation of Kubuntu 18.04 so I think an update was the cause.

No matter how many times I set the bluetooth device as default in the audio control it didn't matter.

The solution for me came when I changed the settings in
System Settings > Multimedia > Audio and Video > Device Preference (Tab)
for Audio Playback I set the headphones as the most preferred.

I hope it helps


Try to remove old kernels with this:

dpkg -l linux-{image,headers}-* | awk '/^ii/{print $2}' | egrep '[0-9]+\.[0-9]+\.[0-9]+' | grep -v $(uname -r) | xargs sudo apt-get -y purge

see: Don't know which kernel to remove to free up disk space

The other errors you get (couldn't lock....) is because you have several applications running who are already created the lock.


There isn’t a software package called `adobe-flashplugin` in your current software sources

If you want to install Flash, you can install it using the command -

sudo apt-get install flashplugin-installer

Alternatively, to install Adobe flash from canonical partner repository -

Software & Updates -> Tab 'Other Software' -> Tick 'Canonical Partners'

sudo apt-get update

sudo apt-get install adobe-flashplugin


Universal USB installer installs Ubuntu as Live image on any USB storage device.
So in order to install ubuntu on your external hard disk you need to install Ubuntu using Universal USB installer on a pen drive first.  Then boot your pen drive and install ubuntu on your external hard disk from that live boot.


From the sound of the incorrect names bit, I would venture:

There’s a typo in Linux kernels earlier than 5.8 that may result in the system requesting the wrong .hcd file. If you are using the BCM4356A2 chipset, you will need to rename (or copy) the correct .hcd file.

Given the size of the file, and given that more recent kernels will request a different file name, it might make sense to have two copies to cover both names.

Copy BCM4356A2-13d3-3485.hcd to /lib/firmware/brcm
Copy the file again:
sudo cp /lib/firmware/brcm/BCM4356A2-13d3-3485.hcd /lib/firmware/brcm/BCM4354A2-13d3-3485.hcd

Hopefully this will result in a working device …


http://people.adams.edu/~cdmiller/posts/Ubuntu-dpkg-recovery/

This might help point you in the right direction. It looks like you'll have to re-install apt and then force the system to re-install the apps that it thinks it can.


How do I change colors in Zim (wiki editor) running on Kubuntu 18.10?

I'm still on Kubuntu 18.04 but it appears that the version of Zim is the same in 18.10.

Zim seems to be a gtk2 application
Kubuntu allows users to choose different gtk2 and gtk3 (and qt) themes.
Open System Settings > Application Style > GNOME Application Style and make your selections there. However, certain aspects of Zim's appearance are not governed by the gtk2 theme.
Zim's Help > FAQ mentions that a user can

  … change the colors used for links, underline etc. ?

  Copy "/usr/share/zim/style.conf" to "~/.config/zim/" and edit as you
  see fit. See the Config Files page for the syntax of this file.

That allows users to modify several aspects of Zim's appearance, including links.

To get the image below, I edited my ~/.config/zim/style.conf to change the link color from blue to aquamarine.


Can gpsd change the firmware of a gps receiver?

Prior to setting the -b flag in /etc/defauls/gpsd

# Default settings for gpsd.
# Please do not edit this file directly - use `dpkg-reconfigure gpsd' to
# change the options.
START_DAEMON="true"
GPSD_OPTIONS="-n -G -b"
DEVICES=""
USBAUTO="true"
GPSD_SOCKET="/var/run/gpsd.sock"

The -b flag is:

  Broken-device-safety mode, otherwise known as read-only mode. A few bluetooth and USB receivers lock up or become totally inaccessible when probed or reconfigured

We found this true for the occasional gps unit that would be returned to a Windows system.

We weren't sure how to fix the non-responsive units.  It appeared something had latched (one source said it latched into SiRF binary), so they were pried apart and the battery was removed to clear its memory.  The battery was re-inserted and the plastic shell glued back together.  Tedious.

Subsequently we encountered this procedure:

  In order to switch your device back to NMEA protocol, you must follow these instructions on Windows:

Download and install this software:
http://www.usglobalsat.com/store/downloads/SiRFDemo387.zip
Run the SiRf Demo software.
Connect your device, choose the correct COM port, and select the 4800 baud rate.
Go to Action > Open Data Source.
Next, go to Action > Synchronize Protocol & baud rate.
Then, go to Action > Switch to NMEA Protocol.
In the pop-up window, select the 4800 baud rate under the Baud Rate and click Send.
Close the SiRf Demo software.

The instructions continued:

  Now, try your GPS Receiver with the GPSInfo Utility
  (http://www.usglobalsat.com/store/downloads/GPSInfo.zip) to see if the
  problem persists.

  Note: Be sure and not to click on anything else in this software, as
  you can render your device unusable.

However, since adding the -b flag we have had no more gps units stop working when no longer being handled by gpsd in a Linux system and have never tested them.


How do I lower the critical temperature?

You can try Computer Temp at Computer Temperature Monitor

  Computer Temperature Monitor is a little applet for the GNOME desktop
  that shows the temperature of your computer CPU and disks on screen.

  It also allows you to log temperatures to a file. You can set alarms
  to notify you when a tempertature is reached. Several monitors can be
  added to the panel to monitor different sensors. It is designed to
  look like CPU Frequency Gnome applet, so they match each other on
  panel.

Other way around it is to cool your CPU temperature frequency throttling:

Sepero Hacker: Linux: Cool your CPU temperature with frequency throttling


This thread posted on the Ubuntu Forum sounds similar to your problem, this might help you
"Unable to locate package" errors for all software

When in doubt during installation, always try running...

sudo apt-get clean
sudo apt-get update
sudo apt-get upgrade

Btw, I don't think ckan is included among the official packages, have a look at this link for how to install ckan
http://docs.ckan.org/en/latest/install-from-package.html


Tried to update Kernel, broke Ubuntu Software Center

Well, You have tried to update your kernel to the latest mainline kernel which is not a good idea (ref). But still if you need (for some reason like hardware compatibility or anything else) to do so this is the way:

In the link you shared as your workflow you have removed the the deb file related to new kernel right after installation. That is why you get the error The package linux-image-4.11.0-041100rc5-generic needs to be reinstalled, but I can't find an archive for it. Logically everything should go fine and you shouldn't get this error if the installation was done well. But it seems there has been some problem and there was a need for reinstallation.

Now, go through the same procedure and download and install the kernel but this time don't remove the deb file.

Reboot your system. If you don't get the error, now you can remove the deb file.


Well, if this was a Juju config option for the charm, I think the charm should restart it automatically. If not, it probably should be added to the config (but the README says "This charm doesn't offer any configuration as Alice doesn't have any command line configuration tools, everything is done through the browser.")


Yes you can fix it from the shell that you obtained via CTRL+ALT+F3. You will just need to set a new PATH, or use the full path to commands until it is fixed.
For example, you can open a command line editor like nano:
/bin/nano ~/.profile

and correct your mistake from there.


I removed nvidia driver and lshw -c video still shows nvidia

Since then I've tried to play with jockey-text and I found out that jockey-text -l displayed that xorg:nvidia_current_updates was in use even though I couldn't install it in the 1st place.

So I disabled it but then xorg:nvidia_experimental_304 was in use and when I repeated the former process it showed that experimental_310 too was in use.

So all of the 4 drivers were in use "simultaneously" which was not ok obviously.
Now that there is only one working, I have a GUI again.

I posted this because it's scary that you lose your GUI so easily, that kind of bug is way to easy to make happen since the additional drivers panel showed that NONE were in use...


Most up to date Ipython and Matplotlib in Ubuntu 13.10

The way to fix it is using pip.

The way to set up pip is described here: http://docs.python-guide.org/en/latest/starting/install/linux/#install-linux and it sums up to:

(I think python-distribute comes pre-installed in 13.10, but it doesn't hurt to check)

sudo apt-get install python-distribute

Then we set up the python environment properly:

sudo easy_install pip
sudo pip install virtualenv

After that, do:

sudo pip install ipython[all]

This will let pip take care of the dependencies listed by ipython. At this point, IPython is already working properly.

OPTIONAL, installing matplotlib and numpy:

These take care of the dependencies for matplotlib and numpy (and assuming you already have LaTeX properly installed):

apt-get install libfreetype6-dev libpng-dev libpython-all-dev gcc gfortran dvipdf

partial ref: https://stackoverflow.com/questions/8359383/error-while-installing-matplotlib

I'm aiming for something like this:

    ============================================================================
Edit setup.cfg to change the build options

BUILDING MATPLOTLIB
            matplotlib: yes [1.3.1]
                python: yes [2.7.5+ (default, Sep 19 2013, 13:49:51)  [GCC
                        4.8.1]]
              platform: yes [linux2]

REQUIRED DEPENDENCIES AND EXTENSIONS
                 numpy: yes [version 1.7.1]
              dateutil: yes [using dateutil version 2.1]
               tornado: yes [using tornado version 3.1.1]
             pyparsing: yes [using pyparsing version 2.0.1]
                 pycxx: yes [Couldn't import.  Using local copy.]
                libagg: yes [pkg-config information for 'libagg' could not
                        be found. Using local copy.]
              freetype: yes [version 16.1.10]
                   png: yes [version 1.2.49]

OPTIONAL SUBPACKAGES
           sample_data: yes [installing]
              toolkits: yes [installing]
                 tests: yes [using nose version 1.3.0]

    OPTIONAL BACKEND EXTENSIONS
                macosx: no  [Mac OS-X only]
                qt4agg: yes [installing, Qt: 4.8.4, PyQt4: 4.10.3]
               gtk3agg: yes [installing, version 3.4.8]
             gtk3cairo: yes [installing, version 3.4.8]
                gtkagg: no  [The C/C++ header for gtk (gtk/gtk.h) could not
                        be found.  You may need to install the development
                        package.]
                 tkagg: no  [The C/C++ header for Tk (tk.h) could not be
                        found.  You may need to install the development
                        package.]
                 wxagg: no  [requires wxPython]
                   gtk: no  [The C/C++ header for gtk (gtk/gtk.h) could not
                        be found.  You may need to install the development
                        package.]
                   agg: yes [installing]
                 cairo: yes [installing, version 1.8.8]
             windowing: no  [Microsoft Windows only]

OPTIONAL LATEX DEPENDENCIES
                dvipng: yes [version 1.14]
           ghostscript: yes [version 9.10]
                 latex: yes [version 3.1415926]
               pdftops: yes [version 0.24.1]

So, if I just missed any dependencies, just comment below ;)

Then, using pip:

sudo pip install matplotlib[all]

It compiles, and done. Ipython, numpy and matplotlib ready for science in Ubuntu 13.10.


From what I know, you cannot edit any config file to do so, but rather have to change the background image of the panel to something that is transparent (i.e. an SVG file that is transparent)


Is the template used when creating a new crontab stored centrally, or embedded into the cron package?

It's hard-coded into the crontab.c file in the cron package's source code:
        if (add_help_text) {
                fprintf(NewCrontab,
"# Edit this file to introduce tasks to be run by cron.\n"
"# \n"
"# Each task to run has to be defined through a single line\n"
"# indicating with different fields when the task will be run\n"
"# and what command to run for the task\n"
"# \n"
"# To define the time you can provide concrete values for\n"
"# minute (m), hour (h), day of month (dom), month (mon),\n"
"# and day of week (dow) or use '*' in these fields (for 'any')."
"# \n"
"# Notice that tasks will be started based on the cron's system\n"
"# daemon's notion of time and timezones.\n"
"# \n"
"# Output of the crontab jobs (including errors) is sent through\n"
"# email to the user the crontab file belongs to (unless redirected).\n"
"# \n"
"# For example, you can run a backup of all your user accounts\n"
"# at 5 a.m every week with:\n"
"# 0 5 * * 1 tar -zcf /var/backups/home.tgz /home/\n"
"# \n"
"# For more information see the manual pages of crontab(5) and cron(8)\n"
"# \n"
"# m h  dom mon dow   command\n" );
        }


Creating a custom installation CD with LAMP stack and some other packages preinstalled

There's a manual on the help sites on how to customize the Ubuntu Install CD. Try to follow that guide, it says it applies to the server version as well as the client version (alternative CD).

Good luck :)


I experienced the same problem and solved it with sudo dpkg-reconfigure libapt-pkg4.12

source: http://www.schakko.de/2013/08/11/fixing-segmentation-fault-in-libapt-pkg/


Try using Wink to record your screen actions.

  Wink is a Tutorial and Presentation creation software, primarily aimed
  at creating tutorials on how to use software (like a tutor for
  MS-Word/Excel etc). Using Wink you can capture screenshots, add
  explanations boxes, buttons, titles etc and generate a highly
  effective tutorial for your users.

To download and install visit the website.

Source:Wink


FireFox massive slowdown on upgrade to 13.10

I tried disabling all my add-ons, and the problem went away. Re-enabling them one at a time, I found that Ubuntu FireFox Modifications 2.8 was causing the performance issues. That add-on wasn't installed by me, but must have been added automatically with the upgrade.

If anyone else runs into the issue, go to the Tools menu and click Add-ons. Scroll down in the list until you find Ubuntu FireFox Modifications, and click the Disable button (may require a restart to take effect).


DNS not resolving in Ubuntu 11.10 LiveUSB

I fixed the problem by getting a new copy of Ubuntu 11.10. The internet works fine now.


Ubuntu 13.04 doesn't automount razr d1 mtp

This did it for me and my nexus7 and nexus4 : http://forum.xda-developers.com/showthread.php?t=1773598

But I personally do like AirDroid : https://play.google.com/store/apps/details?id=com.sand.airdroid&hl=en

no need for any drivers, just have your laptop talk to the phone through the browser.


How install Truecrypt on Ubuntu 14.04 LTS 32 bit

Since the truecrypt website no longer contains version 7.1a, I'm posting this.

I recommend the truecrypt PPA I created. It contains a patch I created that adds an appindicator to it, since the old systray is no longer supported in Ubuntu. https://launchpad.net/~stefansundin/+archive/truecrypt

sudo add-apt-repository ppa:stefansundin/truecrypt
sudo apt-get update
sudo apt-get install truecrypt

The version is 7.1a, and I do not intend to update to 7.2 because it has less functionality.


Awhile back, I found I had to use the ruby-pg gem instead of the pg gem, which was unneeded.  Also, avoid the old postgres gem.


1) First, try to correct your apt-get error with this command :

sudo apt-get -f install

2) Optional step : it might be useful to upgrade your system :

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

3) Then remove the package :

sudo apt-get remove --purge acroread*

4) And finally, remove all dependencies that might have to be uninstalled :

sudo apt-get autoremove


How can we disable mouse Pointstick in Ubuntu 18.04?

Run:

xinput list

It will give you a list of devices, look after your device name under "Virtual core pointer", for example mine is:

"TPPS/2 IBM TrackPoint"

Then run:

xinput set-prop "TPPS/2 IBM TrackPoint" "Device Enabled" 0

Replace "TPPS/2 IBM TrackPoint" with your device name.

Don't forget that this is only temporary, to make it permanent you can put the command somewhere which gets automatically executed, for example in ~/.profile.


In simple terms, how do ext4 journaling file systems work?

PC World: Ubuntu Linux, Day 16: EXT4 vs. NTFS

http://www.pcworld.com/businesscenter/article/230527/ubuntu_linux_day_16_ext4_vs_ntfs.html

Any discussion around 'why/why not' and 'defrag' needs to include Diskeeper (formerly Executive Software). Offering to license your product to Redmond, and having your company and/or product still be viable in two years, is a Herculean adventure at best ..


Yes there is. Go to ubuntuforums. Specifically, that link will take you to the 'Natty Narwhal Testing and Discussion' sub-forum. People are always very happy to hear what you think about betas etc. in that sub-forum.

For ideas on how it could be improved, go to Ubuntu Brainstorm.


Video issues where screen freezes with columned blocks of pixels appearing on screen followed by computer shutting down

Installing a 12V fan blowing over the CPU has helped and computer is running as expected. No crashes anymore. Just had to make sure the fan is pointed directly where the CPU core is.


20.04 Server Install not booting on low memory VM

Glad to see I'm not the only one with this issue. I'm creating a template with a low-memory VM (512M) and now it's not enough (it was with Ubuntu 18.04 and Ubuntu 16.04).

The issue is linked to the version of the image you are using. For Ubuntu 20.04 (and I don't understand why/how), the only version available is the "live" (using more memory).

You can download images from two endpoints.

http://cdimage.ubuntu.com/ubuntu/releases/20.04/release/
http://releases.ubuntu.com/20.04/

For Ubuntu 20.04, it seems that the difference is that "releases" is hosting amd64 versions (desktop, server live BUT no server non-live version) and "cdimage" is hosting everything else.

However, previously this was not the case

http://cdimage.ubuntu.com/ubuntu/releases/18.04/release/
http://releases.ubuntu.com/18.04/

"Non-live" versions are deprecated but sill available under the "ubuntu-server-legacy" section.

More official information can be found at https://discourse.ubuntu.com/t/server-installer-plans-for-20-04-lts/13631.

Wait & see.


Ubuntu 12.04 System crashes right after login - Boot-Repair log included

Ok, got back into my system and it is running.

To help others, here is the simple fix:

All I had to do is boot into an older kernel! :) (here is an explanation on how to do it https://askubuntu.com/questions/97731...keeps-crashing )

Note though, that I had to go back to a kernel as low as 2.6.x. I won't reinstall for now - there are too many issues reported with 12.04. or 12.10. - but if I notice unusual behavior I will. Now, is a good time to run another backup on /home.


You should go to /usr/share/doc/openvpn/examples/ , where are located some example config files. You can copy client.conf for example to your /etc/openvpn/ dir. Also , you should edit your /etc/default/openvpn and set AUTOSTART=client. This will bring your openvpn server up with config file /etc/openvpn/client.conf . Now you can go to your tutorials to configure it.

I hope this can help you.

Regards


See: http://www.digital-experts.de/doc/mbr/README

  The boot process ~~~~~~~~~~~~~

  When the MBR is first loaded it waits for a configurable length of
  time (1 second by default), monitoring the keyboard, for key presses.
  If the MBR detects a key press, it will interrupt the boot process,
  and display it's prompt.  Otherwise, it will load the first sector of
  the default partition, and execute it.  If a disk error occours, the
  MBR will display it's prompt.

  4.1 The boot prompt ~~~~~~~~~~~~~~~~~~~

  The boot prompt looks something like this:

  14FA:

  This is the list of valid keys which may be pressed.  This means that
  partitions 1, and 4 can be booted, also the first floppy drive (F).
  The 'A' means that 'advanced' mode may be entered, in which any
  partition may be booted.  The prompt for this mode looks like this:

  1234F:

  The only other valid key which may be pressed is RETURN, which
  continues booting with the default partition.

Your MBR is busted.
Boot Repair is probably the best tool to fix it: https://help.ubuntu.com/community/Boot-Repair


xUbuntu 16.04 no bass and poor sound quality

PulseAudio and ALSA are configured for 44.1KHz 16-bit audio by default which is not bad but not really great.

You can check the current configuration with:

$ pacmd list-sinks | grep sample

It will show something like this:

$ pacmd list-sinks | grep sample
sample spec: s16le 2ch 41000Hz
sample spec: s16le 2ch 41000Hz

To change it, we need to edit the PulseAudio's configuration file:

$ nano /etc/pulse/daemon.conf

Find these in the file:

; resample-method = speex-float-1
; default-sample-format = s16le
; default-sample-rate = 44100

Remove the semicolon and change the values to:

resample-method = src-sinc-medium-quality
default-sample-format = s24le
default-sample-rate = 96000

Save the file by pressing Ctrl+O (to save) and Ctrl+X (to exit).

Restart PulseAudio:

$ pulseaudio -k
$ pulseaudio --start

Check the settings again:

$ pacmd list-sinks | grep sample

It should something like this:

$ pacmd list-sinks | grep sample
sample spec: s32le 2ch 96000Hz
sample spec: s32le 2ch 96000Hz

and we are done!

For more info:
https://r3dux.org/2013/12/how-to-enable-high-quality-audio-in-linux/


Is there documentation for chown that is easier to understand?

Actually there is such documentation. Open a command line terminal - CtrlAltT  and enter:

info chown

you will find this document uses less technical terms and phrasing, and explains the command in a more "conversational" manner. It is therefore easier to read and understand for beginner users.

After reading the info page I recommend familiarizing yourself with the man page for chown, because the man pages tend to be more succinct and complete.


Install: TeX Live: metapackage pulling in all components of TeX Live

sudo apt-get install texlive-full

Caution: These are a few hundred megabytes.


How to run autorun script without prompt when inserting USB stick on Ubuntu

For general usage - No. Only with modifications on Host system.


Some useful line editing key bindings provided by the Readline library:

Ctrl + A: go to the beginning of line
Ctrl + E: go to the end of line
Alt + B: skip one word backward
Alt + F: skip one word forward
Ctrl + U: delete to the beginning of line
Ctrl + K: delete to the end of line
Alt + D: delete to the end of word


Try fdisk sudo update-grub and sudo reboot. Ubuntu 12.04 is still buggy. Hope, you can find more necessary information here


At a terminal prompt...

sudo apt-get install vlc
sudo apt-get -f install


This is pretty straightforward, potential BIOS complexities aside.

 Backup your user files
 Insert Windows 10 Install Media
 Install to main HDD
 Resize and re-partition from within Windows 10 if needed (it probably isn't)

Discussion: Since you want to "uninstall Kubuntu" you don't have to re-partition anything, you are just going to overwrite everything; Furthermore, Windows has sensitive partition schemes which are best changed with Windows utilities. It is possible you might have to change some BIOS settings, so if you run into trouble with the installation, come back here and we can work it out.


How to I get mcomix to remember my rotation settings?

I found the solution. After hitting r to rotate the page, I hit k, which is the keyboard shortcut for "keep transformation". Once I did this, the rotation was saved throughout the rest of the comic book.

In version 1.00-1, this option is not found in the Preferences menu. I think it was found in the Preferences menu in earlier versions of mcomix.

I found this option by going through ~/.config/mcomix/keybindings-gtk.rc


Touchscreen driver for Shuttle X50V4 AIO computer

This eGalaxTouch page offers drivers to download for these devices, including for Linux: https://www.eeti.com/drivers_Linux.html


Is there a real name policy in the Ubuntu community?

this answer has now been merged into the community accepted answer

None of the wider community stuff requires you to use your real name. Launchpad and Membership both allow aliases and handles (for example, I'm Oli here, Oli on IRC, Oli on Launchpad and Oli as an Ubuntu member).

The only instance where I've seen a real name policy is a reference to the Launchpad Beta Testers team requiring real names, in a discussion on the Ubuntu Women mailing list in 2007.

In reality though, this policy seems to have changed because the current members list shows plenty of people who are either using contracted forms of their names or handles. Edit: I've found that they officially retracted this policy in 2008:

  For a while now, we've required that Launchpad beta team members use
  their real names. As of today, you can join the beta team whether or
  not you use your real name as your Launchpad display name.

  Instead, we'd like to encourage you to use your real name but it's up to you.

  Although most people joining the beta team have been happy to use
  their real name, you'll probably have seen discussions on this list
  where people have given good reasons for not wanting to use their real
  names. The last thing we want to do is discourage you from helping us
  beta test new features!

  I'd like to explain, though, why we prefer people to use real names.
  We really value the feedback you give us when you beta test a new
  feature. One reason for preferring real names is that we feel a real
  name shows a greater readiness to take the beta team seriously.
  However, we know that this doesn't hold for everyone: for example,
  many people have a strong reputation built around a pseudonym.

  So, if you've held off joining the beta team because you didn't want
  to use your real name, please go ahead and join!

However for legal documents (like the Canonical Contributor License Agreement) a real name is probably demanded. Contracts are usually still binding regardless of the given name (if you can link it to a person with enough proof) but it makes the whole thing a lot more floppy for both sides.

But if you're just talking about the CCLA and you're afraid that giving your real name is an issue, talk to Canonical and they'll let you know what they require and what they do with that information. As far as I know there is no public list of people who have agreed to the CCLA (and there's no clause for this in Canonical's privacy policy) so if your name is leaked online from signing the document, Canonical have done something bad.

But I'm not a lawyer so if this really matters talk to Canonical and if that doesn't help, talk to a lawyer.

--- information about GPG ---

Adding an OpenPGP key to Launchpad.
Signing the Ubuntu Code of Conduct.
Becoming an Ubuntu member.

The above items require the use of a GPG Key currently, but there is no requirement that your GPG Key be signed. If you want to have your GPG Key signed you will have to use your real name because without that there is no proper way to identify you using official government photo identification as required.


How to move files from home/user.backup back to home/user?

You probably did more harm trying to move the files back. If you have not done anything to the two directories, you could simply renaming them back to what they was before. I.e.,

sudo mv /home/user /home/mygame
sudo mv /home/user.backup /home/user

It is unclear what you have done when you says trying to move the files back. May be you can describe all the steps you did already so we can find a way to reverse those operations. If the software you try to use hasn't done anything harmful yet, the above commands should do the trick.


install Compiz Config Settings Manager
run ccsm
go to Ubuntu Unity Plugin and click on it
in the reveal mode section change it to never
sit back
??????????
Profit!


Installing Ubuntu Desktop environment onto ubuntu gnome

Sorry - I just entered:

sudo apt-get install ubuntu-desktop

And it worked


Media shortcuts no longer work after installing a different version of Spotify and I can't find its .desktop file

the desktop file should stand in this folder

/var/lib/snapd/desktop/applications

You can create a new one if needed

sudo tee -a /var/lib/snapd/desktop/applications/spotify.desktop << ENDsd
[Desktop Entry]
Type=Application
Name=Spotify
GenericName=Music Player
Icon=/usr/share/spotify/icons/spotify-linux-128.png
TryExec=spotify
Exec=spotify %U
Terminal=false
MimeType=x-scheme-handler/spotify;
Categories=Audio;Music;Player;AudioVideo;
StartupWMClass=spotify
ENDsd

Or copy/paste those lines in  /var/lib/snapd/desktop/applications/spotify.desktop

[Desktop Entry]
Type=Application
Name=Spotify
GenericName=Music Player
Icon=/usr/share/spotify/icons/spotify-linux-128.png
TryExec=spotify
Exec=spotify %U
Terminal=false
MimeType=x-scheme-handler/spotify;
Categories=Audio;Music;Player;AudioVideo;
StartupWMClass=spotify


I found a solution : install CompizConfig, section window manager, and check grid box.


Problem with second display on 18.04 with RX560 (HDMI/DisplayPort converter)

It says that DisplayPort-0... ... has no modesthis means that nothing has been reported to the OS and it as such can't determine for example the resolution.

A solution to this would be to add a resolution to your output. ArchWiki always has great guides on these things and are compatible with Ubuntu generally.

And this chapter of the wiki show how to do it permanently because xrandr changes are temporary.

I personally currently have three monitors connected to my RX580 (one with a active DP to VGA adapter) without any problems. If you have the components you could try to switch your adapter (active/passive) or even port to see if it is correctly detected so we could further find out what the underlying problem might be.


I have the same laptop, and I fixed it in this way:

When starting on the computer, in the operative system selector, instead of choosing Ubuntu, choose the advanced options and then press e.

That will let you edit the grub before loading Ubuntu. So after something written about "splash" type acpi=off and then press Ctrl+x

(That will let you start Ubuntu)

Although, those changes are not permanent. So you need to do this too:

After Ubuntu started, open the terminal and write sudo nautilus (that will open the files explorer in root mode)
Go to, Computer > /etc/default and open the file grub. There you should replace

GRUB_CMDLINE_LINUX_DEFAULT="quiet splash"

for

GRUB_CMDLINE_LINUX_DEFAULT="quiet splash acpi=off".

That will make those changes permanent.

BTW, I have some issues that I can't resolve:

I can't shutdown the computer, and I've tried everything that I found on this forum.
There is no battery icon that shows how much battery do I have left, and I have also tried everything.

Any help?


Switch from Dual Monitor Display to Single Display Permanently

Partial Workable Solution:
Original: https://askubuntu.com/a/1048966/930126

1. sudo cp ~/.config/monitors.xml /var/lib/gdm3/.config
2. in the /etc/gdm3/custom.conf uncomment WaylandEnable=false

This does bring login screen to he external display.

The only (minor) issue that remains is that the initial startup screen with live logs (don't know what it is called) is still on the in-built display.

If anyone knows a better solution, that would be amazing. Otherwise this is sufficient for me, at the moment.


./script.sh a.txt

and your script will have a.txt in the variable $1 ($0 holds the name of the script).

Example:

~$ more script
#!/bin/bash
echo $1
~$ ./script a.txt
a.txt
./script "a a".txt
a a.txt


Am i missing packages ? - After removing Wine 1.9.5 - removed packages - help

Many packages have other packages they depend on to work, (aptly) called "dependencies." These are installed automatically, the only reaction from the user being to confirm the install for the base package. The packages you see marked for removal are these dependencies.

The ppa-purge command deletes the specified repository (WINE's in this case), any installed packages available from it and any dependencies for these packages.

Run sudo apt-get install -f and sudo dpkg --configure -a before running the ppa-purge command again. Then run sudo apt-get install -f to make sure everything's OK.

EDIT: I just noticed there are a few system packages that you have already removed. The PPA Purge option may not be a good one. Instead, try running sudo apt-get install -f and then sudo apt-get remove wine-*.


There're multiple conflicting packages, e.g. flashplayer-mozilla, flashplugin-installer, adobe-flashplugin…

The specific one you need for Opera browser is adobe-flashplugin, i.e.

sudo apt-get install adobe-flashplugin

Update per comments: if you get a has no installation candidate error, run software-properties-gtk, and set all checkboxes on the Ubuntu Software tab. Next update packages list with, e.g., sudo apt-get update, and try installing again.


How can I make Palatino look good in Firefox?

As far as I know this is a hinting issue. Try putting this into a new file in ~/.config/fontconfig/conf.d, like 20-autohint.conf:

<?xml version='1.0'?>
<!DOCTYPE fontconfig SYSTEM 'fonts.dtd'>
<fontconfig>
    <match target="pattern">
        <test name="family">
            <string>URW Bookman L</string>
        </test>
        <edit name="autohint" mode="assign">
            <bool>true</bool>
        </edit>
    </match>
    <match target="pattern">
        <test name="family">
            <string>URW Chancery L</string>
        </test>
        <edit name="autohint" mode="assign">
            <bool>true</bool>
        </edit>
    </match>
    <match target="pattern">
        <test name="family">
            <string>URW Gothic L</string>
        </test>
        <edit name="autohint" mode="assign">
            <bool>true</bool>
        </edit>
    </match>
    <match target="pattern">
        <test name="family">
            <string>URW Palladio L</string>
        </test>
        <edit name="autohint" mode="assign">
            <bool>true</bool>
        </edit>
    </match>
</fontconfig>

If you have an older system and this doesn't work try putting it into the file ~/.fonts.conf.


If you want to remove the Windows 7 (loader) (on /dev/sda1) entry: delete (or rename) the /bootmgr file and /Boot folder which are in the sda1 partition, then run sudo update-grub from within Ubuntu.
If you want to remove the Windows 7 (loader) (on /dev/sda2) entry: delete (or rename) the /bootmgr file and /Boot folder which are in the sda2 partition, then run sudo update-grub from within Ubuntu.


Is there a way to change the screen resolution?

There is no fix AFAIK. But you can usually drag the window keeping ALT pressed, clicking on any place of the window and dragging the mouse. That way you can reach the part of the screen that are hidden. Not exactly a great solution, but useful for occasional use.


windows 7 drivers compatible with ubuntu in lenovo ideapad s100?

Will my windows 7 drivers work in ubuntu?

No

  Do I also need drivers for ubuntu?

Yes, but they come WITH the installation of Ubuntu. Most of them that is since there is a bit of hardware that is not compatible with Ubuntu. To check if your system works out of the box with Ubuntu you can use the Live CD part of the installation media.

Your system has been used before by others so you are good to go from what I can tell. I did see some issues with the network card (Realtek) but that was with older versions of Ubuntu. If these still exist you might need to change the software that is used to connect to the internet (network manager) to WICD.


Unable to connect to the internet in 13.04 but fine in 12.04

We need more information:

Open a terminal and show us the output of the following:

Show us the output of ifconfig -a
Can you ping your router ping -C 10 192.168.0.1
Show us the output of dmesg
Show us the output of lspci, lsusb

Is the connection WIRED? ie, plugged in.
Is the connection wireless? ie, no ethernet cable

Right now, all you've told us is that "it's not working".


There are two versions of iso files with Ubuntu Server 18.04 LTS,

The new style iso file with the live installer, size 806 MiB,

releases.ubuntu.com/bionic/
The old style iso file with the debian installer, size 704 MiB,

cdimages.ubuntu.com/ubuntu/releases/bionic/release/

You can try both and use the one that works best for you.


What does the automatic login option do?

"Automatic Login" Inside of each User's options on the User Accounts dialog (remember that you can have several users in the same computer), just means that the user won't be prompted for his/her user password in order to start his/her session.

You can have only one "Automatic Login" even if this seems to appear in each user. But even if you allow a user to boot without authenticating (signing in), the user may need to unlock his/her keyring for administrative purposes and will always be in need to authenticate each time he/she's in need to run a command with sudo or gksudo from a terminal.

If you need further information don't hesitate to drop a comment in order to continue the support and edit this answer if needed.

As mentioned by @Eliah Kagan in a comment to this answer:

  If you log out to get to the login screen, and want to log back in,
  you still need to enter a password, even if automatic login is
  enabled. This is the case on every Ubuntu system on which I've ever
  used automatic login (which includes 13.04).


How do I remove the unnecessary part of this file?

Many ways:

grep with PCRE (-P):

grep -Po '^[^\s]+\s+\K.*' file.txt

^[^\s]+\s+ matches the first field along with trailing whitespace, \K discards the match, and then .* matches the rest of the line and gets printed

sed:

sed -E 's/^[^[:blank:]]+[[:blank:]]+//' file.txt

^[^[:blank:]]+[[:blank:]]+ matches the first field, again with the trailing whitespace(s) and is replaced with empty string

awk:

awk -F "[[:blank:]]+" '{$1=""; print substr($0, 2)}' file.txt

-F "[[:blank:]]+" sets field separator as one or more whitespaces, $1="" sets first field as empty string, this introduces a whitespace in front, so we need to do string slicing with substr($0, 2)` to get characters starting from second

cut:

cut -d" " -f2- file.txt

-d" " sets the delimiter as space, and -f2- prints the fields starting from second

bash:

while read -r _ desired; do echo "$desired"; done <file.txt

Reading each line and sets the first field as giveaway variable _, desired contains the remaining portion, and gets printed by echo "$desired"

perl:

perl -pe 's/^[^\s]+\s+//' file.txt

Similar logic to the sed one

python:

#!/usr/bin/env python
with open('file.txt') as f:
    for line in f:
        print line.split(' ', 1)[1]

Reading each line, and line.split(' ', 1) will split on space with a maximum of 1 splitting operation, so the index 0 will contain first word, and index 1 will have the desired portion (i.e. from second word till end)


Some nvidia driver package always asks for upgrade after updated to 450

The issue with the metadata in the CUDA repository has been resolved.
Run apt-get update and try again.
Also, keep in mind you can file a bug: https://developer.nvidia.com/nvidia_bug/add
You will need to sign-in/sign-up for a NVIDIA developer account.
Then choose

Relevant Area

Other

CUDA Installer


Wifi connection deauthenticated by router

Not your exact setup (laptop brand/modem) but a lot of the logs seem to match yours. Same issue, deauthenticating, reason 3

This is the post.

The solution for this person was

 sudo apt-get update && sudo apt-get install wicd

Then restart.

Like I said, different equipment, but simular logs. Might want to read through them first before you try my answer to be sure I'm not missing something.

But it solved this persons problems.


I use Oomox to create custom themes.  you can fully customize and export themes.  You should be able to change all the colors to what you want.  If this doesn't work it sounds like you have some problems with Unity Tweak Tool.  Try reinstalling it.  Make sure you purge to remove config files.  Hope this helps.


How can wget download a webpage with php as plain html?

Alternatively, you can force wget to rename every extension to HTML on download with the --adjust-extension/-E flag:

wget --convert-links --mirror --trust-server-names --adjust-extension the_website.com


Unhandled exception can't connect to mysql server on '127.0.0.1' (111) (code 2003)

I had the same problem. Here's how I resolved the issue:

sudo apt install mysql-server
sudo netstat -tap | grep mysql
sudo systemctl restart mysql.service

Now everything is working fine.  The following guide was of great help: https://help.ubuntu.com/lts/serverguide/mysql.html