Apache2: Forbidden You don't have permission to access /dir/ on this server

Let's make the vhost clear:

<VirtualHost *:80>
    ServerAdmin webmaster@localhost

    DocumentRoot /var/www
    <Directory />
        Options FollowSymLinks
        AllowOverride None
    </Directory>
    <Directory /var/www/>
        Options Indexes FollowSymLinks MultiViews
        AllowOverride None
        Order allow,deny
        allow from all
    </Directory>

    ScriptAlias /cgi-bin/ /usr/lib/cgi-bin/
    <Directory "/usr/lib/cgi-bin">
        AllowOverride None
        Options +ExecCGI -MultiViews +SymLinksIfOwnerMatch
        Order allow,deny
        Allow from all
    </Directory>

    ErrorLog ${APACHE_LOG_DIR}/error.log

    # Possible values include: debug, info, notice, warn, error, crit,
    # alert, emerg.
    LogLevel warn

    CustomLog ${APACHE_LOG_DIR}/access.log combined
</VirtualHost>

Then make sure you set the right permission like this:

sudo adduser <username> www-data
sudo chown -R www-data:www-data /var/www
sudo chmod -R g+rw /var/www


Cannot communicate with server: Post http://localhost/v2/apps: dial unix /run/snapd.socket: connect: no such file or directory

Unmask the snapd.service:
sudo systemctl unmask snapd.service

Enable it:
sudo systemctl enable snapd.service

Start it:
sudo systemctl start snapd.service

Then try installing your desired app.


Command to list systemd services that run on startup in the order in which they run?

Yes,

Run in the terminal:

systemd-analyze dump > ~/SystemdAnalyzeDump.txt

and to view it, run in the terminal:

gedit ~/SystemdAnalyzeDump.txt

or if you prefer a graphical representation, run in the terminal:

systemd-analyze plot > ~/SystemdAnalyzePlot.svg

and to view it, run in the terminal:

eog ~/SystemdAnalyzePlot.svg


Google Chrome cursor and text selection issues after upgrading to google-chrome-stable_41.0.2272.76-1_amd64

Have you tried the workaround?

sudo cp /usr/share/applications/google-chrome.desktop ~/google-chrome.desktop.bak~
sudo sed -i 's/\/usr\/bin\/google\-chrome\-stable/\/usr\/bin\/google\-chrome\-stable \-\-touch\-devices=123/g' /usr/share/applications/google-chrome.desktop

If this workaround causes problems, use this command to uninstall:

sudo cp ~/google-chrome.desktop.bak~ /usr/share/applications/google-chrome.desktop

Source: https://code.google.com/p/chromium/issues/detail?id=456222#c175


You can create mode resolution using xrandr and gtf

First use gtf to create a mode line

gtf 2560 1080 60

this will generate something like this

# 2560x1080 @ 60.00 Hz (GTF) hsync: 67.08 kHz; pclk: 230.76 MHz
  Modeline "2560x1080_60.00"  230.76  2560 2728 3000 3440  1080 1081 1084 1118  -HSync +Vsync

then create a new mode using xrandr and parameters from previous command

 xrandr --newmode "2560x1080_60" 230.76  2560 2728 3000 3440  1080 1081 1084 1118  -HSync +Vsync

Now you need to add the mode to the desired output, in your case it seems to be HDMI-0

xrandr --addmode HDMI-0 2560x1080_60

Finally apply the new mode

xrandr --output HDMI-0 --mode 2560x1080_60

Cheers


Why [machine_name].local works when remote login is enabled?

Ubuntu uses the Avahi service, which uses the .local domain as a multicast DNS zone.

See /etc/avahi/avahi-daemon.conf There will be a domain-name=.local under the "server" section where you can change it. .local is the default if you did not change it.


Problems installing Wget for firefox un Ubuntu 14.04 (along with fireget extension)

Install a current version of intltool. My Ubuntu 14.04.3 system has

||/ Name           Version      Architecture Description
+++-==============-============-============-=================================
ii  intltool       0.50.2-2     all          Utility scripts for international

This:

sudo apt-get install intltool

should do it.

The other error message, which Google translate says is:

No target specified and no makefile found. Off.

is caused by the earlier failure of the ./configure script, which was supposed to create a [Mm]akefile, but did not. Fix the first problem, and this one will go away.


Ubuntu 14.04 fresh install disabled toshiba satellite fans

Try Toshiba hardware interface package - toshset

sudo apt-get install toshset


The disk drive for /media/My_Passport is not ready yet or not present

You should add nobootwait to your /etc/fstab. So that it looks like the following:

UUID=4E1AEA7B1AEA6007 /media/My_Passport ntfs defaults,nobootwait,nls=utf8,umask$

Below is from the fstab man page:

The  mountall(8) program that mounts filesystem during boot also recognises additional options that the ordinary  mount(8) tool does not. These are:  bootwait which can be applied to remote filesystems mounted outside of /usr or /var, without which mountall(8) would not hold up the boot for these; nobootwait which can be applied to non-remote filesystems to explicitly instruct mountall(8) not to hold up the boot for them;


Strange GPG error. apt-get doesn't work anymore

Try re-adding the PPA to your system, and checking for updates: sudo add-apt-repository ppa:libreoffice/libreoffice-4-0 && sudo apt-get update. This should hopefully cause your system to re-download the pgp key, thus hopefully fixing the issue.


Installed lubuntu 14.04 on an Acer Aspire 5517 and can't connect to wireless

I have seen some users with the same card having the same problem (Installing Broadcom Wireless Drivers)

A known issue is that jockey; also known as Additional Drivers, suggests the wrong driver for a few Broadcom cards.

Please open a terminal and run and post:

sudo apt-get install --reinstall bcmwl-kernel-source

After it's done, do:

sudo modprobe wl

If there is no error or warning, your wireless should be working.

OP indicates that an additional step was required to get this solution working.  See below

After following all of the steps here, I had to additionally install the b43 firmware package like so:

sudo apt-get install firmware-b43-installer

Then it worked after a reboot.


defunct processes and their parent processes

Simply -- the script db.service.sh that is the parent of your ruby process started an executable (with the PID 11958). When you start a program from a script it is a new process, with the parent being the script that called it. Consider this script:

#!/bin/bash

cat

When you start it as test.sh, you will see that the bash is the parent, and the cat is the child:

xxx   4087 10976  0 08:29 pts/2    00:00:00 /bin/bash ./test.sh
xxx   4088  4087  0 08:29 pts/2    00:00:00 cat


How to upgrade from xserver-xorg-lts-saucy to xserver-xorg-lts-trusty

You'll have to upgrade the named packages together:

sudo apt-get install xserver-xorg-lts-trusty \
    xserver-xorg-core-lts-trusty \
    xserver-xorg-video-all-lts-trusty \
    xorg-driver-video \
    xserver-xorg-input-all-lts-trusty \
    xorg-driver-input \
    xserver-xorg-input-evdev-lts-trusty

If you get any errors about other packages with trusty in the name, add them to the list too.


How can I have sound output before logging in?

Well, I found the answer when I attempted to run alsamixer et al. under sudo (in which case, they run). I had to add the remotely-connecting user to group audio (which had only user pulse from the previous pulseaudio installation).

It really would be more helpful if the various ALSA tools reported something EPERM/EACCES related instead of ENODEV/ENOENT.


Yes it is possible. However, the error "operation not permitted" is indicative of the file itself not having executable privileges.

It appears you are already in the directory with the file, if not cd into the directory first and then run the following before you try to run the file again.

sudo chmod +x NvidiaTvOut.run

You may now use

./NvidiaTvOut.run

to execute the file.

If you need root privileges, You will see "permission denied" instead of "operation not permitted".

The output of ls -l will show the file permissions for the files in the current directory and an x at the end of the permissions indicates the file is executable.

Please post any errors.


Grub boot menu does not properly reflect default selection using Start-up Manager

Grub2 Customizer:

I have always had issues configuring Grub2 with Startup-Manager; Grub Customizer developed by Daniel Richter is a very intuitive GUI to properly configure GRUB2.  With it you can add a background image to Grub as long as the picture is also residing with /boot folder; you can edit both menu entries and the menu timeout length; my favorite feature is the ability to boot into the previously selected operating system (i.e. If I manually select to boot into Windows7 than the next time this same entry will be the default entry in Grub).


Installing Ubuntu 12.04 along Windows XP and Windows 7

Kevin provides a good explanation of the different options. For your scenario I would make the following suggestion:

This isn't always required for installing Ubuntu but because you have a busy setup going on, we wanna fine tune our partitions before starting the setup. Just so we can be sure of what's gonna happen with our data and drives and partitions etc.

Boot your Live USB/CD into "Try Ubuntu" mode:

Open a program called GParted
Select your G: Drive in the top right corner, in this case it will be named according to Linux methodology. Something like /dev/sde
Resize until you have the 15GB free space Unallocated
Create a 2GB partition as Swap. Learn more here
Create a partition in the remaining space as ext4
Remember to Apply the changes!

During the Installation process (called Ubiquity), at the partitioning step:

Select Something Else and click next.
Then double-click the prepared ext4 partition on your intended drive for mounting "/". We call this the root structure, the entire file system falls under this. Just like a C: drive in Windows. You can tick the format box if you want even though we just did it.
The swap partition should automatically be detected, you can double click to check if it's "used as swap area".
The bootloader can also go on the 'G: drive' so we don't have to bugger up the windows bootloaders. Underneath the partitions, in the dropdown, select /dev/sde or whatever this one may be.
Continue installation.
IMPORTANT: When restarting, open your BIOS and select your G: drive as the primary boot drive so that it loads the linux bootloader (Called GRUB) before the Windows ones. Grub allows you to select which operating system you want to boot (Dual/Triple boot) and will use Ubuntu as default, you can always change this using grub-customizer

Now we should have installed Ubuntu alongside the rest without messing with the other drives or their operating systems.

Let us know if this worked for you! Good Luck!


Not able to 'unset' environmental variable permanently - UBUNTU

The environment variable is always going to be set if it's present in your configuration files for your system's environment variables or your own login profiles.
Open each of these files and search for a line that has export CATALINA_HOME, and remove the line (or comment it out) where present:

/etc/environment
/etc/profile
~/.profile
~/.bashrc

Once removing the line from the file, log out, and log back in (if in a terminal, just close the terminal and reopen it).  If it was in /etc/environment then consider rebooting the system first.
With the export line gone, the variable will be 'permanently unset' until the line is readded to one of those files.


nVidia on Ubuntu 14.04 black login screen (not freeze)

I know from bitter experience that at any given time there are several nvidia drivers available and each one has its own pros and cons.  I learned that after I "upgraded" to a later version only to spend hours putting it back the way I had it the first time.

I admit I'm not clear about your wishing to switch it off.  I think what you need is the nvidia control panel so you can turn it on and off on the fly.

I used to have that on one of my computers.  To get it I would advise you to go into the "Synaptic Package Manager" and there type, "nvidia control".  You will get several results most of which I suspect you'll be interested in.

PS:  If you don't already have the "Synaptic Package Manager" installed you can install it from the the Ubuntu Software Center"


install ubuntu alongside windows 7 without cd drive

You can create live USB pen using Live USB Creator Download it after, run it from windows, plug your USB Drive and, select already u have downloaded Ubuntu ISO file and then create Live USD, after everything, in CMOUS setting select boot device property to USB drive and login into live user, after you can install it


I solved my problem. While the computer was still using the emacs shortcuts, I tried to add a custom ctrl+c shortcut - it hadn't worked. When I switched away from emacs shortcuts, my non-operational custom ctrl+c shortcut was still in place! How annoying of me!

Thank you @Zacharee1, @mchid, @Hitechcomputergeek, @KGIII, and @chaskes!


How can I get an nfs mount in fstab to use the bg option to mount a server when it eventually comes up

I think what you really want to use is auto mounting.  Auto mounts only mount when they are needed and dismount when inactive.  They also "solve" the problem you are seeing as long as you don't try to access the remote mount until the server is up.

See the Ubuntu Community Docs on Autofs for more information on setting it up.


qBittorrent seed files I've already downloaded

Yes. If you open/load the .torrent file in qBittorrent (or any client, for that matter), and set the save path to the directory containing the file you already downloaded, then qBittorrent will see that a file of the same name exists and that all pieces of the file have already been downloaded. It will then proceed to seed the file.

This feature is also beneficial if you have a partially-downloaded file and want to download the remainder of the file through bittorrent, but don't want to start from the beginning.


Updated from Ubuntu 12.04 LTS Wubi to 13.10, won't boot now

What I always do in a problem is to reinstall whatever version of Ubuntu I am using. That usually fixes the problem (Do not get into any partitioning or any complicated stuff while installing. That may cause problems while booting). Cheers! :)


Problem was solved with a fresh install

  I would love to provide, however the problem went away after a fresh install. Something I was meaning to do anyway, not because of the sound issues. You can't close questions right?


I need BASIC, HAND HOLDING type help booting Ubuntu now that I've installed it on my Windows 7 machine

Seems like Windows is still there. Here's what you can do:

Boot from the Ubuntu installation media (the same way you've done when you installed Ubuntu) and run the installer. When it asks about the disk partitioning, select  the "Erase disk and install" and proceed with the installation. When it finishes, you'll be prompted to reboot. Windows should be gone and Ubuntu should boot up.


How to remove the window border for gnome-terminal?

Turns out this can be easily done using the Compiz window decoration plugin. In the 'Decoration windows' field enter:

!(class=Gnome-terminal)

To further customize this you can hide a specific set of terminals by entering in the 'Decoration windows' field:

!(title=tmux_terminal)

Then, borders will only be disabled for terminals that are started as follows:

gnome-terminal --title=tmux_terminal


after install of 15.10 - no desktop just wall paper

It sounds like the ISO you downloaded was corrupted. Did you verify the checksum?

Also, are you using 15.10 for any specific reason? It is the bleeding-edge. I recommend using 14.0.4 as it is the most stable.


Which Ubuntu version has the 4.0.6 kernel which supports L2TP VPN?

There is no stable Ubuntu release with kernel 4.x yet.

There are l2tp modules in current Ubuntu kernels for a long time.

It looks like you misunderstood something regarding l2tp. You will need a user space application (xl2tpd or openl2tpd) to use l2tp protocol.

These application use kernel modules. I am now writing this connected with l2tp to ISP.


To disable it system-wide, comment the Exec= line in /usr/share/thumbnailers/evince.thumbnailer:

sudo sed -i 's/^Exec=/# &/' /usr/share/thumbnailers/evince.thumbnailer

user@user-X550CL ~/tmp % sudo sed -i 's/^Exec=/# &/' /usr/share/thumbnailers/evince.thumbnailer
user@user-X550CL ~/tmp % cat /usr/share/thumbnailers/evince.thumbnailer
[Thumbnailer Entry]
TryExec=evince-thumbnailer
# Exec=evince-thumbnailer -s %s %u %o
MimeType=application/pdf;application/x-bzpdf;application/x-gzpdf;application/x-xzpdf;application/x-ext-pdf;application/postscript;application/x-bzpostscript;application/x-gzpostscript;image/x-eps;image/x-bzeps;image/x-gzeps;application/x-ext-ps;application/x-ext-eps;application/x-dvi;application/x-bzdvi;application/x-gzdvi;application/x-ext-dvi;image/vnd.djvu;application/x-ext-djv;application/x-ext-djvu;image/tiff;application/x-cbr;application/x-cbz;application/x-cb7;application/x-cbt;application/x-ext-cbr;application/x-ext-cbz;application/x-ext-cb7;application/x-ext-cbt;application/oxps;application/vnd.ms-xpsdocument

To re-enable it, uncomment it again:

sudo sed -i 's/^# \(Exec=\)/\1/' /usr/share/thumbnailers/evince.thumbnailer

user@user-X550CL ~/tmp % sudo sed -i 's/^# \(Exec=\)/\1/' /usr/share/thumbnailers/evince.thumbnailer
user@user-X550CL ~/tmp % cat /usr/share/thumbnailers/evince.thumbnailer
[Thumbnailer Entry]
TryExec=evince-thumbnailer
Exec=evince-thumbnailer -s %s %u %o
MimeType=application/pdf;application/x-bzpdf;application/x-gzpdf;application/x-xzpdf;application/x-ext-pdf;application/postscript;application/x-bzpostscript;application/x-gzpostscript;image/x-eps;image/x-bzeps;image/x-gzeps;application/x-ext-ps;application/x-ext-eps;application/x-dvi;application/x-bzdvi;application/x-gzdvi;application/x-ext-dvi;image/vnd.djvu;application/x-ext-djv;application/x-ext-djvu;image/tiff;application/x-cbr;application/x-cbz;application/x-cb7;application/x-cbt;application/x-ext-cbr;application/x-ext-cbz;application/x-ext-cb7;application/x-ext-cbt;application/oxps;application/vnd.ms-xpsdocument


I cannot get wifi with my toshiba satellite c55-a

Let's re-run the backports install and see if we can find out what went wrong. Please open a terminal and do:

cd ~/Desktop/backports-3.11-rc3-1
make clean
make defconfig-rtlwifi
make
sudo make install

Assuming every step goes without error, reboot and confirm the version of the driver:

modinfo rtl8188ee

Under 'version,' it ought to report that it is from backports-3.11-whatever. Next, see if it loaded:

lsmod | grep rtl

If not, load it and see if there is an error message:

sudo modprobe rtl8188ee

Check for error messages here:

dmesg | grep rtl

If you have lengthy errors or warnings to show us, paste them here and give us the link in your reply: http://paste.ubuntu.com/


On Ubuntu 12.04.2, what happens if I disable dnsmasq?

Extract from http://www.ubuntugeek.com/how-to-disable-dnsmasq-in-ubuntu-12-04precise.html

  The big advantage is that if you connect to a VPN, instead of having
  all your DNS traffic be routed through the VPN like in the past,
  you’ll instead only send DNS queries related to the subnet and domains
  announced by that VPN. This is especially interesting for high latency
  VPN links where everything would be slowed down in the past.

  As for dealing with DNS failures, dnsmasq often sends the DNS queries
  to more than one DNS servers (if you received multiple when
  establishing your connection) and will detect bogus/dead ones and
  simply ignore them until they start returning sensible information
  again. This is to compare against the libc’s way of doing DNS
  resolving where the state of the DNS servers can’t be saved (as it’s
  just a library) and so every single application has to go through the
  same, trying the first DNS, waiting for it to timeout, using the next
  one.

So it will not disable it as such, it will be less "safe" and efficient under certain circumstances. Like VPN


How can I extract text between a pair of the same character?

You can use a cut command.

To extract the second pattern:

echo "blah@foobar1@blah" | cut -f2 -d"@"

To extract the second and third patterns:

echo "blah@foobar1@blah" | cut -f2,3 -d"@"

To extract from the second pattern onwards

echo "blah@foobar1@blah" | cut -f2- -d"@"

EDIT: Since the question was tagged with awk. Here is an awk solution.

echo "blah@foobar1@blah" | awk -F'@' {'print $2'}


Passing luks passphrase to unlock encrypted rootfs with script instead of passing from the terminal

Not sure why you'd want to have a LUKS root and then store the passphrase and script its usage... Doing that essentially overrides the reasons for using a LUKS root.

You'd need to do a lot of work on:
/usr/share/initramfs-tools/scripts/local-top/cryptroot
Replace any code that sets up the variables holding the commands that prompt for the passphrase... Quite a bit of work.

It makes sense to use a scripted manner on other file-systems and removable media, but not root/initramfs/etc... Scripting it just seems to make a LUKS root unnecessary.

Good Luck!


When I start the Ubuntu ISO, initramfs says "unable to find a medium containing a live file system"

Using Ubuntu 17.04 ISO on a SanDisk 32GB USB stick. My m/board is ASROCK B250M. None of the suggestions I read online worked for me. I noticed, though, that the USB stick was mounted when I pulled it out and plugged it back in, so when the installation was showing the Ubuntu 'wait' screen with flashing dots, I figured it was looking for the installation media, so I pulled out the USB stick and pushed it back in. Hey presto! - the installation media was found and I managed to install Ubuntu.


First thing I'd try is to connect to port 22 when on WAN, the router might not be redirecting port 130 on WAN.

I'd also try to do telnet the-pi's-local-ip 130 then telnet the-pi's-local-ip 22 to see if you get anything. That might help debug the issue.


Want to change the direction that my mouse exits the screen on dual monitors

Change the relative locations of the two monitors
Open Settings > Devices > Displays and use your mouse to move the second monitor where you want it:

Finally click the green Apply on the top right edge of the window. If the two displays are of different sizes, you can also align the smaller display to the middle (as I have) or with the top or the bottom of the bigger display. If everything looks okay, click on "Keep Change" or else "Revert Settings" as prompted.
Once you move the second monitor to the left of the first monitor as shown above, you may want to move the The dock and the top bar to the left most screen as well. You can do this by making the screen 2 the primary display, as shown in the figure above.
If you want the dock to appear on both the screens go to appearances tab on the left panel of the settings window and change it there as shown in the answer by Dan Dascalescu.
Hope this helps


Why do the Nouveau drivers work better than the Nvidia ones?

There are three possible reasons I can think of

Less bugs, better compatibility: The source is open — with the nouveau drivers, you probably have a lot more people looking at the code, and it is also easier to deal with changes on the X Windows System and linux kernel sides that break the driver code, and bugs are easier to track.
Issues with 3D acceleration part of the video card, or some feature that is only supported by the proprietary drivers. It is possible that your card is actually damaged, and that you don't get random crashes because nouveau does not use the affected components.
Bad memory. I don't know to which extent are the drivers so different that their different memory usage patterns explain this, but you may have some bad main memory or video card memory (random crashes are a common effect of bad memory). The former is easier to test, using memtest86+, the latter may be supported by tools like memtest86+, but I've never played with video card memory stress testing...


Cannot install build-essential on ubuntu 16.04

Turkish repo have some problems.
You can change /etc/apt/sources.list file.

replace all lines
http://tr.archive.ubuntu.com/ubuntu
to
http://archive.ubuntu.com/ubuntu

and execute sudo apt-get update; sudo apt-get upgrade


How to fix error in pdf2djvu: "Bogus memory allocation size"

You have to install python-djvu package  and it should work. Worked for me

Good luck

John


sudo Virtualbox returns "Qt WARNING: libpng warning: iCCP: known incorrect sRGB profile" error 17.04

Graphical applications should not be launched using sudo. This is the cause of the first warning. Not sure why you would need to launch virtualbox using sudo, but if you do you should use gksudo:

gksudo virtualbox

A search of the second warning suggests it isn't anything to worry about. It apparently means that one or more of the png files used has an old sRGB profile. Everything should still work correctly.


Kubuntu 12.10 Shortcut to Restart X Server?

The old way

KDE System Settings > Input Devices > Keyboard;Advanced tab "Key sequence to kill the X server"


How are snap applications being protected?

snapd developer here.

The word protections seems to imply that snapd contains some sort of DRM system to protect binaries. There's no such thing. Snapd protects your system from possibly untrusted software and various software packages from affecting each other.

Differences from Virtual Machines are simple, there are no virtual machines involved. Running a program in a virtual machine really runs a program, operating system and a hardware emulator as one big process on your system. Snaps don't use anything like that, they instead executed directly on top of the hardware and the kernel provided by the host system.

Differences from ordinary processes are just a few but they make all the difference and magic possible. Snapd uses multiple features of the Linux kernel to give snap processes (processes of started snap applications) different view of the file-system, so that they can run on top of virtually any modern distribution. In addition the interaction of such processes with the kernel and other userspace programs is controlled by a sandbox managed by snapd. The exact behaviour of the sandbox depends on the system used and the set of snap interface connections made between the snaps in the system.

The term container means pretty much nothing today, it is just a marketing buzzword. The linux kernel offers a wide range of tools that allows to segregate various parts of the system and make some of them appear unaffected by changes made by other processes elsewhere. This may range from "it looks like another machine" to "it looks like this machine" and is constantly evolving and expanding in scope of what can be done.

Differences from other "containers" like docker is the set of those primitives used. Specifically snapd uses the device cgroup, the freezer cgroup, the seccomp BPF filter to constrain system calls and a large set of apparmor profiles to constrain access to IPC mechanisms, networking mechanisms, signals, capabilities, read, write and other access to files on the system. Docker or other "containers" typically use different set of such kernel features and configure them differently.

From a purely perception difference snapd is designed to integrate with the host. If you snap install a service it will be directly visible to your machine's service manager (systemd). If you snap install a CLI application you will be able to run it mostly like any other application on your host. If you snap install a graphical application it will integrate with you launcher, panels and other typical controls. This is not the case for docker which is designed to allow you to run, typically, headless network payloads and leave the integration to the user.

As for data protection snapd manages and retains application data between revisions to allow users to revert to a prior working revision as well as contains default permissions that limit access to potentially sensitive access to certain files in the home directory. Still most of the home directory is currently allowed as the mechanisms to mediate access are incomplete or immature. Over time that access will be restricted and only granted through fine-grained mediation.

There's a sophisticated white paper about snapd security model that I could recommend for far more details than those that I presented here: https://developer.ubuntu.com/static/resources/ubuntu-core-16-security-whitepaper.pdf


This can be done in two different ways, depending on whether access is from the keyboard or via the menu.

From the keyboard:

One has to edit ~/.config/openbox/lubuntu-rc.xml.

  note: it's always a good thing to save a copy of lubuntu-rc.xml
  first (lubuntu-rc.xml.old)

Use a text editor to open ~/.config/openbox/lubuntu-rc.xml.  This file has several sections; in the section devoted to keybindings, add this:

<keybind key="C-A-T">
<action name="Execute">
<command>lxterminal --geometry=140x40</command>
</action>
</keybind>

Save the file and exit the text editor. Open a terminal and run openbox --reconfigure to refresh lubuntu-rc.xml. After this, any time you access lxterminal from the keyboard using Ctrl+Alt+T, lxterminal will open with a size of 140 columns by 40 rows.

From the menu:
This requires editing of a .desktop file. By default, .desktop files are located in /usr/share/applications and could be edited there (using sudo).
However, it may be preferable to make a copy of the .desktop file in ~/.local/share/applications because editing this file only affects the specific user (and doesn't need sudo).

So, copy /usr/share/applications/lxterminal.desktop to ~/.local/share/applications. Then open the copied file with a text editor. Search for a line that starts with Exec= and change Exec=lxterminal to Exec=lxterminal --geometry=140x40. Save the file. Done.


How can I correct logical bad sectors in HDD in Ubuntu?

For each bad block number, first use dd to verify that it is bad ( and you didn't make some mistake somewhere ):

sudo dd if=/dev/sda1 skip=##### count=1 of=/dev/null iflag=direct bs=1024

If that comes back with an error, then you are looking in the right spot.. now it's time to correct it:

sudo dd if=/dev/zero of=/dev/sda1 seek=###### count=1 oflag=direct bs=1024

If the second comes back without an error, you should be able to retry the first command and it should also now not error.  Repeat for each bad block number listed in the file.

Make sure to type the commands exactly as shown ( substituting the block number for the #### ) or you can destroy your data

You also might want to run sudo smartctl -a /dev/sda to read the SMART status of the drive.  Of note are the raw values for the reallocated count and pending.  If you fixed all of the bad sectors, the pending count will have returned to zero.  If they were remapped, the reallocated count will have gone up.  If this is more than a handful you probably want to replace the drive as it is likely to get worse.  If the reallocated count didn't go up, then there is nothing physically wrong with the drive.

At this point you also should boot into rescue mode and run a full fsck on the volume to make sure that checks out.


For your general question take a look at "What are Unity's keyboard and mouse shortcuts?"

For your special question I suggest Easystroke:

Easystroke is a gesture-recognition application for X11. Gestures or strokes are movements that you make with you mouse (or your pen, finger etc.) while holding down a specific mouse button. Easystroke will execute certain actions if it recognizes the stroke; currently easystroke can emulate key presses, execute shell commands, hold down modifiers and emulate a scroll wheel. The program was designed with Tablet PCs in mind and can be used effectively even without access to a keyboard. Easystroke tries to provide an intuitive and efficient user interface, while at the same time being highly configurable and offering many advanced features. (source)

To minimize all windows except the active one I refer to the script in this answer (minimise.py).
To manage Easystroke easily you should make it visible in the panel. For that install dconf-tools , then open dconf Editor and switch to desktop → unity → panel and to "systray-whitelist" add , 'easystroke' at the end.
Then start Easystroke. To add a new action click the panel icon and in the Actions tab click Add Action. Use these parameters:

Name: minimize except active
Type: command
Details: bash -c 'python ~/minimise.py'

To set a mouse gesture click Record Stroke and then while pressing mouse button 2 move the mouse the way you like for this action in future. Ready.
(You can change the preferred mouse button in Preferences tab with a click on Gesture Button.)

To minimize all windows except the active one now just press mouse button 2 and do the action you chose before.
If you like it add Easystroke to Startup Applications by marking as checked "Autostart easystroke" in the Preferences tab.

How to configure Easystroke you can find out in its Documentation as well as in this Tips & Tricks section.


Ubuntu Server Setup help: sda sdb have changed? How to know I'm making shared folders on the right drive?

You cannot rely on sdX to remain the same (it probably will, but no guarantees). You should use either labels or UUIDs. See the devices in /dev/disks/by-label and /dev/disk/by-UUID. You can check which drives have been used as currently by using the mount command (which will use sdX in the output). To fix your cryptswap, edit the file /etc/crypttab to use UUIDs.

The Ubuntu installer uses UUIDs by default in fstab and crypttab, so you shouldn't have to manually edit them. Applications like parted cannot identify encrypted swap, since the partition appears to be filled with garbage to them. (If they ever identify them successfully, there's something very wrong going on.) You can check usage of swap using the swapon -s command.

That a partition doesn't start on a physical boundary doesn't mean much these days. Today's disks don't really expose the real physical state.


Error occured when "sudo apt-get update"

Open the file and search for the line with the problem with:

gksu gedit /etc/apt/sources.list

In my case, the file contains this in the first seven lines (compare it):

# deb cdrom:[Ubuntu 13.04 _Raring Ringtail_ - Release amd64 (20130424)]/ raring main restricted
deb-src http://archive.ubuntu.com/ubuntu raring main restricted #Added by software-properties

# See http://help.ubuntu.com/community/UpgradeNotes for how to upgrade to
# newer versions of the distribution.
deb http://ubuntu.grn.cat/ubuntu/ raring main restricted
deb-src http://ubuntu.grn.cat/ubuntu/ raring universe main restricted multiverse #Added by software-properties

Check if there's a difference. Sometimes due to a corrupted connections I've got errors due to incomplete lines.
Good luck!


How do I submit a new package to universe?

The workflow for submitting your package is here:

http://developer.ubuntu.com/packaging/html/udd-sponsorship.html

and then keep an eye on the sponsorship queue:

http://reqorts.qa.ubuntu.com/reports/sponsoring/

I also recommend getting ahold of a MOTU to see if your package is appropriate for Debian as usually submitting to Debian and syncing back into Ubuntu might be a better way to work.


GRUB menu lost in win 8 dual boot configuration after hard drive swap

I've had this problem before and I always follow this site: https://help.ubuntu.com/community/RecoveringUbuntuAfterInstallingWindows

But here's a copy-paste of what you need to do:

Short story:

Boot Ubuntu using Live CD or USB and run sudo grub-install /dev/XXX replacing XXX with the device you installed Ubuntu on, for example sudo grub-install /dev/sda

Long story:

Boot up Ubuntu using a Live CD or USB.

Open a terminal. As of Ubuntu 11.10 and 11.04, this can be done by opening the Unity Dash (you can click the Ubuntu logo in the top panel or use the Windows key on your keyboard) and typing in "Terminal", and clicking what comes up. On earlier versions, you can achieve this by going to Applications→Accessories→Terminal. Alternately use the Keyboard Shortcut: Ctrl+Alt+T.

For full details on using terminal to fix grub on hard drive from Live Installer DVD or Flash: https://help.ubuntu.com/community/Grub2/Installing#via_the_LiveCD_terminal

You are then presented with a standard bash prompt, type - this only works to reinstall to MBR of a working system:

sudo grub-install /dev/XXX

where XXX is the device of your Ubuntu install. (E.g.: grub-install /dev/sdb). Hint: You can also use /dev/disk/by-label/ if the partition you installed on has a label. You can determine the /dev node for such a device by running:

ls -l /dev/disk/by-label/

This will give the output of something like:

lrwxrwxrwx 1 root root 10 Oct 16 10:27 data -> ../../sdb2
lrwxrwxrwx 1 root root 10 Oct 16 10:27 data2 -> ../../sda2
lrwxrwxrwx 1 root root 10 Oct 16 10:27 fat -> ../../sda6
lrwxrwxrwx 1 root root 10 Oct 16 10:27 home -> ../../sda7
lrwxrwxrwx 1 root root 10 Oct 16 10:27 root -> ../../sda1
lrwxrwxrwx 1 root root 10 Oct 16 10:27 swap -> ../../sda5
lrwxrwxrwx 1 root root 10 Oct 16 10:27 windows -> ../../sdb1

You can also use gparted --list if you do not see the /dev/disk/by-label:

$ sudo parted --list

Model: ATA WDC WD10TPVT-00U (scsi)
Disk /dev/sda: 1000GB
Sector size (logical/physical): 512B/4096B
Partition Table: msdos

Number  Start   End     Size    Type     File system  Flags
 3      1049kB  1000GB  1000GB  primary  ext4

From here, find only the drive name, ignore the partition number, that is, for partitions labelled root, data2, fat, home and swap it's all still just sda. This is due to the fact that GRUB is installed in the MBR of the drive, and not on a partition.

Trouble? If other things are messed up, e.g. if you have deleted the partition from where Grub was previously installed, grub-install may return an error message such as cannot find a device for /... (is /dev mounted?). You may have to do grub-install a bit differently. Refer to the handy guide on fixing a broken system

Now reboot your system. The usual GRUB boot menu should appear. If it does not, hold Left Shift while booting. You will be able to choose between Ubuntu and Windows.


Using:

start on startup

instead of

start on filesystem

worked for me (I geuss the filesystem variable not supported by our environment). I also recommend adding pre/post-script logging so that you can see to what point the script was successful.


I uninstalled the version that came from the "Ubuntu Software" app and downloaded the .deb directly from skype.com. Although it's the same version number, this does not have the link problem.


How to get flash working in Ubuntu 15.10 Wily Werewolf

In order to do that, we'll utilize the command line to do the following:

Install flashplugin dependencies
Install flashplugin-installer
Install flashplugin-downloader
Rename the flash plugin
Install nspluginviewer
Install nspluginwrapper
Activate nspluginwrapper

In turn, doing this will:

Install the flash plugin we need, for obvious reasons.
Rename the flash plugin to make it work.
Install NetScape Plugin Viewer (don't worry about netscape in the name, it's what we need), that the wrapper needs to function
Install NetScape Plugin Wrapper (don't worry about netscape in the name, it's what we need), so we can make the flash plugin compatible.
Activate the wrapper to get the plugin working for most popular browsers

Step 1: Install flashplugin dependencies

This is the easiest part, simply issue this command:

apt-get install libpango1.0-0 libnss3 libnspr4 libcurl3 libcurl3-gnutls

If it fails and gives you a message about dependencies, issue this command:

apt-get -f install

Steps 2 & 3: Install the flashplugin downloader/installer

You'll need to get these yourself, I couldn't find them in the apt-get packages at time of this writing. In order to get them yourself, use launchpad.net. These commands will probably still work, but if significant time had passed since this writing and your reading of it, you may want to get the latest packages instead.

Another reason to get the latest yourself instead, is that these deb packages are for i386, if you have 64bit/PowerPC/etc you'll need the packages for them instead.

wget https://launchpad.net/ubuntu/+source/flashplugin-nonfree/11.2.202.540ubuntu2/+build/8136297/+files/flashplugin-installer_11.2.202.540ubuntu2_i386.deb

wget https://launchpad.net/ubuntu/+source/flashplugin-nonfree/11.2.202.540ubuntu2/+build/8136297/+files/flashplugin-downloader_11.2.202.540ubuntu2_i386.deb

Now do:

dpkg -i flashplugin-installer_11.2.202.540ubuntu2_i386.deb

dpkg -i flashplugin-downloader_11.2.202.540ubuntu2_i386.deb

If it fails and gives you a message about dependencies, issue this command: apt-get -f install

Step 4: Rename flash plugin

We need to do this, because it is written...

sudo mv /usr/lib/mozilla/plugins/flashplugin-alternative.so /usr/lib/mozilla/plugins/libflashplayer.so

Steps 5 and 6: Install nspluginviewer and nspluginwrapper

This is nice and easy, again though, these commands will probably still work, but if significant time had passed since this writing and your reading of it, you may want to get the latest packages instead.

Another reason to get the latest yourself instead, is that these deb packages are for i386, if you have 64bit/PowerPC/etc you'll need the packages for them instead.

wget http://launchpadlibrarian.net/136801009/nspluginviewer_1.4.4-0ubuntu5_i386.deb

wget http://launchpadlibrarian.net/136801008/nspluginwrapper_1.4.4-0ubuntu5_i386.deb

dpkg -i nspluginviewer_1.4.4-0ubuntu5_i386.deb

dpkg -i nspluginwrapper_1.4.4-0ubuntu5_i386.deb

Step 7: Activate nspluginwrapper

The final command:

nspluginwrapper -a -v -n -i

You need to repeat Step 7 (and ONLY step 7) on each user's account you want to have access to flash. This only needs done 1 time on each account.

A cheap way to do this from an account with sudo power is:

sudo -u <username> nspluginwrapper -a -v -n -i

Of course replace  with the user you want to have flash.


Songs & instrument Game Alternative (Stepmania & Guitar Hero)

I can recommend Performous, it is a all-in-one music game.
It can import songs from Frets On Fire (like Guitar Hero/Rock Band)
and songs from UltraStar Deluxe (Like SingStar/karaoke)

Offtopic:
You can use real Guitar Hero Guitars from the Wii in the game.
Connect the wiimote using wminput and map the guitar-keys to the keyboard-keys you use in the game.

Have Fun !


Ubuntu 12.10 Modem Connected but no internet

I was (and am) having a similar problem while connecting to the Internet using my MTS MBlaze (India) dongle which is a ZTE device. I am using Kubuntu 12.10.

A while back I was only able to connect to the device from Network Manager applet, but a ping to any address including 8.8.8.8 resulted in "Network is unreachable". I figured out this could primarily be because of my host not being able to connect to MTS gateway.

'ifconfig' shows something similar to the following:

ppp0      Link encap:Point-to-Point Protocol
          inet addr:180.215.149.123  P-t-P:10.228.10.5  Mask:255.255.255.25

I used the 'route' command to manually add the gateway address (P-t-P in above ifconfig output) as follows:

sudo route add default gw 10.228.10.5

And voila, I was able to ping again, even to google.com (as dongle devices auto configure DNS servers as well); there is no need to change /etc/resolv.conf at all.

Now I need to figure out how to automate this. Any help most welcome.


Wireless Access Point Won't Delete and Automatically Connects

in /etc/NetworkManager/system-connections check your "Wireless connection XX" items - you may have created a connection to an access point manually and are not seeing that it's actually connecting to one of those - happened to me.


Intel Wireless Card (9260) speed limited in ubuntu 18.04

It appears Ubuntu thinks the card can only do up to 54mb/s.

Not Ubuntu. It is the driver; the support for your card is fairly new (it was added to debian july 2018) so it might just be lacking support for this.

2 things to try:

On ubuntuforums there is a suggestion ...

you need this patch.
try the option 11n_disable=1 or 11n_disable=8in /etc/modprobe.d/iwlwifi.conf

I would file a bug report on this against linux-firmware iwlwifi.


Switching between windows with scroll wheel on Ubuntu Dock

Open Terminal and run

gsettings set org.gnome.shell.extensions.dash-to-dock scroll-action 'cycle-windows'


It seems like you do not have Ubuntu installed on your machine, you only have the ISO file downloaded to your computer. The dash is a part of Unity, and is only accessible once you install Ubuntu. If you want the flash drive without the mess of having another operating system installed, I suggest you use a VirtualBox guest and create a startup disk that way.


software updater failed to download repository information

Another solution is, sometimes it couldn't find the packages from the selected server. You should change it to the best matched server.

Go to Software & Updates, Ubuntu Software tab,
Then on Download from click Other
Select Best Server and it will auto update the sources.
Now install it from Software Updater or do sudo apt-get upgrade


What is the Minimum Setup Needed for Setting-up XDG Directories ($XDG_RUNTIME_DIR etc.)?

Seems my problem was actually related to a failure during boot of some systemd units that didn't show any other side-effects and wasn't picked up due to the nature this container was deployed. As such this has now resolved itself and so I assume that the libpam-systemd package is in fact all that is required.


Why is /usr/src/linux-aws-headers* growing?

This is probably due to the automatic updates.

You can disable the automatic updates and even remove the unused kernel images and headers running sudo apt autoremove --purge (as you are already doing)

More info here: https://help.ubuntu.com/lts/serverguide/automatic-updates.html


Where are the proprietary NVIDIA drivers in 16.04?

All these drivers, except X.Org are proprietary Nvidia drivers.

The open source is a bug of the user interface.

In your case the proprietary driver is already installed.


Javafx is not on the default classpath even with Oracle JDK 1.8

You need to set up CLASSPATH in /etc/environment. Execute the following command in a terminal (Ctrl+Alt+T)

sudo gedit /etc/environment

Add the following lines (all four lines at the end of /etc/environment)

JAVA_HOME="/usr/lib/jvm/oracle_jdk8"
export JAVA_HOME
CLASSPATH="/usr/lib/jvm/oracle_jdk8/lib"
export CLASSPATH

Alternatively you can add CLASSPATH to /etc/profile.d/oraclejdk.sh if you have used this guide.

export CLASSPATH="/usr/lib/jvm/oracle_jdk8/lib"


Cannot print pages in random order using lp/lpr

lp can't seek in a PDF, but pdftk can.  Try something like this:

pdftk test.pdf cat 320 289 321 300 output - | lp


resolv.conf permissions/ownership change after VPN disconnect

I have the same issue. Maybe it is a bug.
But I use NetworkManager. This solution does not work with it. The script does not run. I add my solution for it.

The NetworkManager has similar solution.
The script must be added to the directory:

/etc/NetworkManager/dispatcher.d

I have added this file: "02-fix-resolv.conf.sh":

#!/bin/sh
if [ "$1" = "ppp0" -a "$2" = "vpn-up" ]; then
  echo "bleeeeeee je dole" > /tmp/testjenahore.txt
  chmod a+r /run/systemd/resolve/stub-resolv.conf.pppd-backup.ppp0
  chown systemd-resolve:systemd-resolve /run/systemd/resolve/stub-resolv.conf.pppd-backup.ppp0
fi

It works for me.
And I finded out, that the file "/run/systemd/resolve/stub-resolv.conf.pppd-backup.ppp0" has permission and owner badly.
And my script fix permission and awner, when the VPN goes UP.
Then it works too if the VPN goes DOWN.


Error Installing Grails - Unmet Dependencies

Do you have a particular reason to have the Sun JDK installed instead of the default? If not, remove it and go with the default, as apt-get suggests.

After uninstalling the 'Sun JDK', the command apt-get install grails-ppa should pull in the default JDK automatically. If it doesn't, install it explicitly using apt-get install default-jre-headless grails-ppa.


Answering my own question after 3 weeks of despaired search and a fruitless complete 18.04 reinstall including all packages I had before.
Finally diagnosed and repaired by an expert family member inspired by question 1021748.

The ondemand CPU governor switched to "powersave" mode after booting up. This lowered the CPU frequency to even below the minimum set frequency of 400MHz, and stayed there hovering around 380Mhz (inspected via lscpu).

This happened when the governor switched the CPU to powersave mode:

cat /sys/devices/system/cpu/cpufreq/policy*/scaling_governor

Switching the CPU governor to performance mode solved the problem (for policy0-3):

 echo performance | sudo tee /sys/devices/system/cpu/cpufreq/policy0/scaling_governor

Permanently removing the ondemand governor, made this survive reboot, keeping the governor set to performance:

systemctl disable ondemand

No idea why the powersave mode turns out so bad and what went wrong where in the April 26 18.04 update and is still present in the reinstalled version.  Some posts hint that the ondemand governor doesn't play well with the Intel pstate scaling driver...  Anyhow, my question wrongly asked about gnome (I took it out).  It was the CPU control affecting everything.


Bash only stores history of the commands you ran (which you can retrieve by typing history). Unless you already have set the scroll-back to a very high number, there is no way to see the outputs that are older than the set value of scroll-back. Also setting this value to a very high number will make your scrolling sluggish since the lines are stored in the memory.

To store your future commands and their outputs, there are few options:

Using screen

Start a screen session by entering screen. Once you are inside screen, press Ctrl-a, then :, then enter log. All the I/O will be captured in screenlog files in the directory where you started the screen command.

Using script

You can start by typing script. A script session will start that will capture all the I/O to a file named typescript. You can exit the script session by Ctrl-d  and view the logs in the typescript file.

Using tee

tee is a handy tool. You can do something like this:

$ bash | tee log.txt

This will open a new bash shell inside the one you are already running. When you exit out of this, you can see the outputs in the file called log.txt

Other ways

As Dustin Kirkland suggested in this post, you can also use byobu. Although, I have never used, terminal screencasting tools such as Shelr also sounds like an option.


How to cryptsetup newly installed Ubuntu Server 18.10

Of course, you can't do it on the running system.

You need to configure your LUKS container (with cryptsetup) from the LiveCD/USB and then proceed to the installation by feeding those containers to the installer.

May be, it is better that you use a LVM install from the installer. It will automatically use LUKS/cryptsetup.


(1) Please check version of pip.

>pip list
BeautifulSoup (3.2.1)
oauthlib (1.0.3)
pip (7.1.2)         # <-- this is mine, today.
tweepy (3.5.0)
....

(2) If yours is not so, try this.

>pip install --upgrade pip # <-- to upgrade pip by pip
>pip install tweepy

(3.Foot-Note)
'cause I use on Windows8, I don't use 'sudo'.
Please try AT YOUR OWN RISK, Good Luck.


Is synapse application launcher available?

A bug has been filed on launchpad about that.

It seems, though, that the program's testing PPA now supports 14.04:
Synapse Bleeding edge

EDIT:

To install from the PPA above, do the following in a terminal - [Ctrl+Alt+t]

sudo apt-add-repository ppa:synapse-core/testing

(press Enter-key when prompted to continue)

sudo apt-get update
sudo apt-get install synapse

Synapse should now be installed.

NOTE: It is not recommended that you use a bleeding edge version of a software application as they may (and often do) contain game breaking bugs. My advice is that you keep checking Ubuntu's software repository and revert to a stable version as soon as one is made available.


How do I make Xmipp (Image processing software) work on Ubuntu 16.04.01?

The last version of Xmipp has been released under a more general framework, Scipion (www.scipion.cnb.csic.es), which allows you to combine several EM packages (such as Xmipp, Spider, Relion, Eman2, etc) in your project.
So we strongly recommend you to install the lastest version of Xmipp 3 through Scipion. In the following link you can find detailed instructions for the installation process:

https://github.com/I2PC/scipion/wiki/How-to-Install

Some tutorials can be found at:

https://github.com/I2PC/scipion/wiki

Hope this helps,
Jose Miguel


Install qt5ct:

sudo apt install qt5ct

Run:

qt5ct --platformtheme qt5ct

and set the icon-theme to breeze. (You may do other modifications as you wish)

Set the appropriate evironment variable:

sudo nano /etc/environment

and add this line:

QT_QPA_PLATFORMTHEME="qt5ct"

Reboot.

If this doesn't work continue with the following:
Then copy the okular .desktop file to your home folder:

cp /usr/share/applications/org.kde.okular.desktop ~/.local/share/applications

Modify the copied .desktop file by changing the line:

Exec=okular %U

to

Exec=okular --platformtheme qt5ct %U

Open the ~/.local/share/applications folder in Files and run Okular. It will ask you to trust the application the first time.

Done.


I need help with my intel wifi 7260. Ubuntu 16.04

I know this will sound completely ridiculous but....

What I Tried

Updating all the Linux Firmware drivers

Tried to boot using a backup Kernel (4.2.x).
Tried using two Mainline, upstream Kernels (4.6.x-wily and 4.4.10-Xenial).
Tried blacklisting acer-wmi.
Tried setting /etc/modprobe.d/iwlwifi.conf to add options iwlwifi 11n_disable=1.
Tried also adding options iwlwifi 11n_disable=8 to /etc/modprobe.d/iwlwifi.conf.

Nothing worked.

What worked for me?

Disable your Wireless Settings by Clicking that Wirless button off (I'm using Cinnamon, same principle for Unity)

From the same Menu, click "Network Connections"
Delete everything.
Reboot
Renable Wireless
Reconnect to your wireless network

Results

Haven't had a connection issue in nearly an hour. I'll update it if I have any further issues. Seriously, I never thought in a million years this would do anything but as desperate enough to try the obvious. It worked.

Tried from this suggestion here:
Source


Choosing ubuntu version for 10 year old pc

For a system with 512 MB of RAM I can only recommend distros with lightweight desktop environment (DE), such as Lubuntu, that sports LXDE (where L stands for Lightweight). It's preferable to install rather newer versions of OS as it usually supports more hardware. So I would recommend Lubuntu 14.04 LTS (Long Term Support = till 2019, but you can upgrade every two years) or something similar like PeppermintOS 5/6 (both based on 14.04). There is also WattOS with LXDE based on 14.04 and they have even some "Microwatt" edition for even slower, older PCs.

Other lightweight DE choices include fluxbox, various tiling like xmonad, ratpoison, awesome etc. But if you want something more familiar LXDE is probably the best first choice.

Lastly I'd like to mention that elementaryOS Luna is quite lightweight actually although it's build on older Ubuntu base (12.04). Too bad this is not true for their new version Freya, which didn't run properly even on Atom netbook with 1 GB RAM. Still Luna is supported till April 2017 so you might give it a try too.


Add gtk-update-icon-cache /usr/share/icons/hicolor to your debian/postinst file:

#!/bin/sh

gtk-update-icon-cache /usr/share/icons/hicolor

exit 0


Basically the latest version of svn packaged for 14.04 Trusty Tahr is 1.8.8, so that is the latest version in the Trusty repositories (see here), and therefore the latest version you are able to access.

By far the best solution to this in most cases is just to update Ubuntu, this will give you a more up to date set of repositories, with a much more up to date version of all your packages, including svn. The latest version of Ubuntu is 16.10 Yakkety Yak, which has svn version 1.9.4. If you need LTS, then 16.04LTS Xenial Xerus has svn version 1.9.3.

An alternative solution is to use what's called "apt-pinning" or simply "pinning", to install the Yakkety/Xenial version of svn, without having to update the whole of Ubuntu. This however often results in updating an awful lot of your system anyway, because the newer version of svn, relies on newer versions of other packages which rely on other packages, etc, etc. See these instructions for doing this if you really don't want to update all of Ubuntu.

A final (not recommended) solution, is that you could download the newer Yakkety or Xenial packages manually from those pages, and wrestle through installing the dependencies, and then svn, yourself.

EDIT: You may also be able to get access to an external package repository for svn from elsewhere, as Lv1z explains, but this can often leave your system as a bit of a tangled web, pulling different parts of your system from different sources. Whereas an Ubuntu version update would keep your system relatively clean, and with a guaranteed maintenance cycle from Ubuntu.


Ubuntuphone Acquaris E4.5 not recognized

OK, as weird as it sounds, I am able to mount my phone after I rebooted the phone. I spent the whole day trying everything that I could think of, but all it took was a simple restart of the phone.


Unable to use laptop after I close and open the lid

Install gnome tweaks from:

sudo apt install gnome-tweak-tool

Launch it, head to power section and set the "suspend when laptop lid is closed" button off.


Outdated package version error even though manually updated it


Ubuntu stuck at blackscreen after installation on a laptop with damaged discrete Radeon GPU

The correct way is blocking AMD Radeon device from Grub by adding "radeon.modeset=0" in /etc/default/grub then run update-grub


Your apt-cache policy python output told me that you could not install the correct python version (2.7.x) from the repositories. As Python is located in the main repository, we should first try to activate that repository (again) and update the package lists:

sudo add-apt-repository main
sudo apt-get update

As you got an invalid signature (BADSIG) error, we completely remove all package lists and re-download them. Also in case the error prevented it from working, we try to enable the main repository again.

sudo rm -rf /var/lib/apt/lists/*
sudo add-apt-repository main
sudo apt-get update

Now the new apt-cache policy python output shows the correct version available from the server, so we can now force the downgrade of our package python to the required version:

sudo apt-get install python=2.7.5-5ubuntu3

We then need to clean the locally cached wrong 3.5 version and just empty the entire package cache therefore:

sudo apt-get clean

Then we let it try to upgrade all remaining packages and hope for the best:

sudo apt-get upgrade


I have the same problem with a Radeon HD variant. There is no way around it while keeping your system at like-stock, don't even attempt. Go for any NVidia card or certified approved AMD Radeon card and you'll be good. NVidia has the best driver support out of any of the big two in graphics, Intel also has AMAZING support, but their graphics chips usually only on-motherboard or inside the CPU/APU.


Why does DVD playback still not work after installing libdvdcss2?

The instructions on the Ubuntu Documentation site were quite right. As david6 pointed out, I simply needed to read further down the page and set the region code.

The process:

1. Install libdvdcss

sudo /usr/share/doc/libdvdread4/install-css.sh

(libdvdread4 came installed with the laptop.)

2. Set my region code

After making sure the universe repositories were enabled:

sudo apt-get install regionset

Before setting my region code, I read the regionset documentation at /usr/share/doc/regionset/README.

sudo regionset

I set my region to 0, North America.

3. Fix poor playback

After setting my region code, playback was possible, but the video was very distorted. So I read further down the DVD playback page. Deleting ~/.dvdcss/ did the trick.

rm -R ~/.dvdcss/

Playback still isn't perfect... In Totem media player, the menu is slightly distorted, and in VLC I have to disable menus entirely. But once the video is rolling, everything works fine. Thank you January and david6 for your help!


Belgian formats when choosing US language - regional & language settings issue

The locale used for regional formats is determined (aka guessed) by the installer based on the time zone location. Normally that leads to the right thing.
In case of Belgium with multiple important languages there is an ambiguity. I think it picks German simply because it comes first when sorted alphabetically:
$ cat /usr/share/i18n/SUPPORTED | grep _BE | grep UTF-8
de_BE.UTF-8 UTF-8
fr_BE.UTF-8 UTF-8
li_BE UTF-8
nl_BE.UTF-8 UTF-8
wa_BE.UTF-8 UTF-8

To make the installer pick some other language, it would be possible, at least technically, to add BE to this list.
The reason why it's not there already may be political. If you would pick nl as the default language, the French speaking folks might be unhappy and vice versa.
Anyway, to have it considered by the developers, you may want to file a ubiquity bug report:
ubuntu-bug ubiquity


Remove "computer" and "network" categories from Nautilus sidebar (ubuntu 12.04 running Cinnamon 1.4)

Probably not even an issue for you anymore after all this time but I was having a very similar problem and this was one of the first few posts to come up on Google so hopefully this can help others.

In Nautilus click view > Show Hidden Files then from your home directory go to /.config/ in there you will find a file called user-dirs.dirs this contains the entries under 'Computer'.

MAKE SURE TO BACK UP ANYTHING YOU CHANGE

If you change, for example, XDG_DOWNLOAD_DIR="$HOME/Downloads to just XDG_DOWNLOAD_DIR="$HOME/" the downloads folder will no longer show up under 'Computer' in the sidebar.

You can also just comment out every line, in which case it will only show 'Home', 'File System' and 'Trash'. It will keep those other directories as bookmarks though so you can do what you like with them.

This will not remove the 'Computer' entry entirely, just remove its entries, but it will make it look considerably cleaner. Sorry I can't help on the 'Network' Entry.

Sources: Personal experience trying to restore missing entries under 'Computer'.


Cant acces files on my HDD to upload , download : '/media': Permission denied with Chromium

Try running the following command:

sudo usermod -a -G plugdev,cdrom passe

Restart and see if it works now.


Hindi display of words such as "pra" "gra"

Step 1 is for Ubuntu 16.04 and above
Step 1: Install Language Support
Go to System Settings...> Language Support > Install Languages and  install Hindi (or any other Indian language).
Step 2: Install Keyboard Layout
Go to System Settings... > Keyboard > Text Entry (at the very bottom left) > The + sign at the bottom left and add the keyboard layout of your choice, such as Hindi (Wx).
Step 3: Enable Complex Text Layout in LibreOffice
Go to Tools menu> Language > All Text > More.
Look for Complex Text Layout (CTL) and choose your language (Hindi). It should look something like this:

You may want to un-check the box "for current document only" at the bottom.
I have Hindi (Wx) working in gedit and LibreOffice but on in the Ask Ubuntu Answer text box.
Hope this helps


Ubuntu 16.10 rc.local file does not exist

Because Ubuntu is now (since 15.04) using systemd, and rc.local is now considered a service, it is turned off by default. You can turn rc.local "on" by entering the following command and rebooting:

sudo systemctl enable rc-local.service


Where to find the latest Kubuntu (13.04) with autoinstaller?

Although I always do "something else", I'm 100% positive kubuntu will install along with anything. Are you trying to install with the regular desktop version?


Ubuntu's equivalent for MacOS any app Help search

If the app developer makes that functionality available, you will find it with F1.


It sounds like you have come across the BIOS vs UEFI issue. Newer machines that come with Windows 8 use EFI and not BIOS. You may need to install Ubuntu in EFI mode. I would refer you to read the Ubuntu UEFI page. The UEFIBooting page is also most informative. A brief excerpt is below:

  Installing Ubuntu Quickly and Easily via Trial and Error

  If you have a computer that is more recent than 2010 and you do not
  know whether or not you need to install Ubuntu in EFI mode, you should
  be able to get Ubuntu installed quickly and correctly using the
  following steps:

  Create a LiveDVD or LiveUSB of Ubuntu (>=12.04.2) 64bit.
  In your BIOS, disable QuickBoot/FastBoot and Intel Smart Response
  Technology (SRT). If you have Windows8, also disable FastStartup.
  Boot your PC using the LiveDVD or LiveUSB and choose "Try Ubuntu".
  If you get a Secure boot or signature error, you may wish to disable
  SecureBoot as described here, then retry to boot the disk.
  Install Ubuntu from the Live CD/DVD or Live USB in the usual manner,
  then reboot the PC.
  If the PC does not load Ubuntu (but instead loads Windows, for
  example, as in Bug #1050940), or if the Windows entry in the GRUB 2
  menu does not boot Windows (see Bug #1024383), boot your PC using
  the Live CD/DVD or Live USB and choose "Try Ubuntu" once again. When
  the live session has loaded, run Boot-Repair (see link for details).
  When Boot-Repair loads, click on the "Recommended repair" button,
  and write on a paper the URL (paste.ubuntu.com/XXXXXX/) that will
  appear. Then reboot the pc. Do not run Boot-Repair unless you have
  problems booting the computer; the expression "if it ain't broke,
  don't fix it" applies to this tool.
  This should fix most boot problems. If this does not fix your boot
  problems, please create a new thread in this forum, describing your
  problem and indicating the URL you wrote in the previous step.

If your laptop is running SecureBoot also, as described in step 3, then other steps may be required.

  New Windows PCs come with UEFI firmware and Secure Boot enabled.
  Secure Boot prevents operating systems from booting unless they’re
  signed by a key loaded into UEFI — out of the box, only
  Microsoft-signed software can boot.

  Microsoft mandates that PC vendors allow users to disable Secure Boot,
  so you can disable Secure Boot or add your own custom key to get
  around this limitation.

I came across this issue myself a couple of weeks ago, trying to dual boot Windows and Ubuntu, and the links above proved most useful. However, as you aren't trying to dual boot, and only want Ubuntu, it should be relatively straightforward, once you've got your head around, how it differs from the older, more straightforward, BIOS setup.

I hope this helps.


I was googling around and found this,  by clicking on the little icon in password field it seems to keep password.  Do not know yet if it will automatically login to VPN. Here is the link and am using second answer.   Can't save VPN passwords in Network manager (Xubuntu 16.04)
Have tried connecting to VPN, and it is logging automatically now without having to type password.  Use the 'store for all users' option.


Cannot connect to internet on wired connection

To see if your DNS configuration is fine, ry to type:

dig canonical.com

If you don't have a reply (giving canonical name servers addresses), check your configuration:

To enter (and verify) your network settings, go to the system settings/Network panel. Select the wired interface and click the Options button.

Then in the IPv4 tab you should be able to type a DNS server address, at least if your interface is not configured with DHCP. If so, try to set up an IP address manually. Maybe your router don't dispatch DNS server address.

HTH


If you don't mind sorting the files you could use join (although it might not be practical for your case, it's fun to see how it might be done)

First sort File 2 on the common number field

sort -k2 "File 2" > file2clean

Then you can join the two files

sort -k5 "File 1" | join -a 1 -o 1.1 1.2 1.3 1.4 0 2.1 -1 5 -2 2 - file2clean | tee "File 3"

Notes

-a 1 print the lines in File 1 that can't be paired (since this file has more lines, I assume that's what you want)
-o 1.1 1.2 1.3 1.4 0 2.1 field order for the output line - the field we join on is 0, and 1.1 is the first field of the first file and so on
-1 5 -2 2 join on the 5th field of the first file and the 2nd field of the second file
- file2clean here - represents standard input passed along the pipeline, ie the sorted version of File 1

When done you can delete the intermediate file2clean.


Fan control for newer Thinkpad Lenovo (T460 series and above)

The speed of the fan is adjusted by the bios automatically based on the temperatures in your Thinkpad. But if you really want to control the fan, there is a old program called ThinkPad-Fan-Control

BUT, before you do anything, please read the README. This program is quite old and discontinued.

I also recommend you read this article on the thinkwiki: http://www.thinkwiki.org/wiki/How_to_control_fan_speed


Disable CPU frequency scaling and halts in Lenovo G50-80

If you are using intel-pstate, the default for Ubuntu, there are a bunch of settings for the cpupower program:

cpupower frequency-set -u 3.10GHz -d 3.10 GHz -g performance
cpupower set -b 0

Modify the -u and -l options to suit your processor.

To prevent C1 state, add the following options to your kernel boot parameters

intel_idle.max_cstate=0 processor.max_cstate=1

This is done by editing /etc/default/grub and adding these parameters to the line beginning with GRUB_CMDLINE_LINUX_DEFAULT


Where exactly to put string `fsck.mode=skip` on Lubuntu persistent USB to disabke disk checkup?

Location of fsck.mode=skip

Location in grub.cfg, (mkusb, UNetbootin and Rufus)

menuentry "Ubuntu" {
    set gfxpayload=keep
    linux   /casper/vmlinuz  file=/cdrom/preseed/ubuntu.seed maybe-ubiquity fsck.mode=skip quiet splash ---
    initrd  /casper/initrd
}

Location in syslinux.cfg, (UNetbootin)

label unetbootindefault
menu label Default
kernel /ubnkern
append initrd=/ubninit file=/cdrom/preseed/ubuntu.seed fsck.mode=skip quiet splash ---

Location in txt.cfg, (Rufus)

label live
  menu label ^Try Ubuntu without installing
  kernel /casper/vmlinuz
  append  file=/cdrom/preseed/ubuntu.seed initrd=/casper/initrd fsck.mode=skip quiet splash ---

Exact location in the linux line is not important, it can even go one space after ---.

Edit 20200524:
The above workaround is no longer needed.

This bug was fixed in the package casper - 1.447, as announced in:  https://bugs.launchpad.net/ubuntu/+source/casper/+bug/1875548

Run:

sudo apt-get update
sudo apt-get install -y casper

(I am still testing the fix, It does not seem to be working yet).


Script to list passwords for wifi connections

However I imagine you cannot rely on the file name always being exactly equal to the SSID (correct me if I'm wrong).

Correct.

If you look inside the files you will see that there is an ID:

[connection]
id=Schijfwereld

This is what the file identifies and matches the SSID inside the file:

[802-11-wireless]
ssid=Schijfwereld
mode=infrastructure

  The passwords seem to be located in files that are named after the SSID in files like this:

The system-connections directory holds all your WIFI networks that are ticked available to all users, with the PSK in cleartext. The lines will have psk= and the password behind it. If "available to all users" is NOT set the password is not saved in the system-connections directory.


I wouldn't recommend such an upgrade on a productive system, as it can cause some big troubles with the drivers. Once I've tried such an upgrade and it really messed up with my graphic drivers. and as ubuntu 13.04 is just a few weeks away it isn't worth it. you should wait for the new ubuntu and play it save.


Install Ubuntu without formatting the HDD on a laptop with SSD where Windows is installed+HDD

Install an Ubuntu guest OS in VirtualBox in Windows. You need to boot Windows first in order to run the Ubuntu guest OS, because the Ubuntu guest OS runs inside VirtualBox which is installed in Windows.

In order to install Ubuntu on the HDD open VirtualBox and select File -> Preferences -> General.
Create a new folder on the HDD and name it anything you like, e.g. VirtualBox.
Click the dropdown menu arrow to the right of where it says Default Machine Folder and choose Other…. Here you can choose the new folder for VirtualBox to store data.

Click the OK button in the lower right corner of the Preferences window.


how to shift applications from workspace 1 to 2 using command

If you are using a compliant window manager like Metacity (Unity 2-d) you can use wmctrl to switch a window to another desktop. The syntax is wmctrl -r :ACTIVE: -t <DESKTOP>. You can also change your current desktop using wmctrl -s <DESKTOP>. Desktop numbers start at 0. On one line, this would be:

wmctrl -r :ACTIVE: -t 1; wmctrl -s 1

If you want to switch a window other than the active one to another desktop, use text from the title as the argument to -r. For example:

wmctrl -r "Chromium" -t 1

Alternatively you can use wmctrl -l to list the available windows and pass the id number to -r instead of the special string :ACTIVE:. When passing an id, you also need to add -i. For example:

$ wmctrl -l
0x03e00189  0 hostname Ask Ubuntu - Chromium
$ wmctrl -i -r 0x03e00189 -t 2

(wmctrl can be installed on Ubuntu with sudo apt-get install wmctrl.) At present, this doesn't seem to work with standard Unity, unfortunately.


How large of a swap partition is needed to hibernate?

It's hard to predict: your swap needs to accommodate

what's already in the swap when you hibernate
what's in RAM when you hibernate, but only the part that's not disk cache or buffers; the RAM image is compressed if you use uswsusp
a few kernel data structures

So you can fail to hibernate even if your swap is bigger than your RAM, because most of your swap is already in use. And convertly you can successfully hibernate with a swap that's smaller than RAM, if you're not using much of either at the time.

If you want to avoid a fixed-size swap partition because your disk is very small, you can go for a swap file instead. It's easier to resize, and hibernation to a swap file is supposed to be supported (not sure if it currrently works out of the box, that's come and gone between Ubuntu releases; IIRC it did in 9.10 but it had to be set up in 10.10).


delete skype history from windows account does not delete history from ubuntu account

This is due to the Ubuntu client already having logs saved to your disk. If you want to manually view the logs, then open your file browser to the home directory, then press Ctrl+H to show hidden folders. You should now see a folder named .Skype. From there, navigate to .Skype/<username>/chatsync. Now, you can manually clear the folder or whatever you had planned.

If you'd like to disable the client-side chat logs on Ubuntu, then open up Skype and select Skype > Options > Privacy > Keep chat history for... > Disable History


Which aggregator scopes exist in ubuntu scope?

For security reasons, arbitrary third party scopes in the store cannot be aggregator scopes. As aggregators can see the data returned by the results of any child scopes, it would be a privacy leak to allow arbitrary third party scopes to see that data, as they could do anything with it, and there could be private data returned.

Your scope can provide appropriate keywords, and it may be included by an aggregator scope. That is what the list of keywords is for.


I want to create my own Ubuntu Phone Preinstalled touch image

Just posting this as an answer now instead of a comment.

If you want to port Ubuntu Touch to a new phone, you can do that with a little bit of work porting to any phone which has CyanogenMod 10.1 already built for it.

There is a guide on porting Ubuntu Touch here:
https://wiki.ubuntu.com/Touch/Porting

There is a list of devices which already have ports here:
https://wiki.ubuntu.com/Touch/Devices

If the device does not already have CyanogenMod 10.1, then porting Ubuntu Touch will be a lot harder, as you will have to port CyanogenMod as well. You will probably want to stick to devices which already have CM on them unless you have advanced knowledge in kernels.


Open system settings and under the hardware section go to input devices and select touchpad, then enable tap to click and apply setting
Visual aid


Dual Boot not recognizing new hard drive

Don't worry, there is nothing wrong with your installation. It is exactly the way Nautilus is supposed to display your file system.

The 320 GB drive represents another drive in addition to your Ubuntu drive. This drive can be mounted by clicking on it (but it may not be mounted by default). In addition to this drive only the mounted filesystem on your 2nd hard drive is shown (represented as folders).

To view all drives (/sda /sdb /sdc ...) and partitions (/sda1 /sda2 ... /sdb1 /sdb2 ...) in your system you may issue the following command in a terminal:

sudo fdisk -l

This is how Nautilus displays my system of 4 drives:


Why isn't my computer sending input to my monitor?

My suggestion would be to check for alternative outputs on your videocard (such as HDMI / S-Video) and try hooking up something to them to see if anything gets displayed.


How to align twinview monitors with different resolutions and prevent mouse disappearing into dead areas?

The mouse moving into those dead areas is a known X bug however there is a workaround using XCreateMouseVoid that I have detailed in this question:

How to easily open the Launcher with a secondary monitor to the left

If you wish to just align the monitors along the top or bottom edges then modify the Absolute Position from +1920+90 to +1920+0 or +1920+56


How to remove manually installed libraries?

If you installed the latest library by compiling manually:
Go to the build directory and run:

sudo make uninstall

If that does not work, run:

sudo checkinstall

Then a debian package will be generated. Open it (from Software Center) and press Remove.
If you installed the latest library though APT/Software Center:
Run this to remove it:

sudo apt-get remove libsfml


I eventually found a solution. As almost always someone smarter than me had the same problem, and also a solution :) github.com/gokmen/Sentelic.

Sentelic Mouse (Asus UX31) disable daemon while typing.

First install Xlib and Udev Python bindings. (Udev Python bindings are optional though)
You need root privileges to run the daemon.

$ sudo ./sentelic.py

Default timeout is 0.9 sec.  You can define the timeout in /etc/sentelic.conf:

timeout=1.5


How to fix missing characters from font after awakening from suspend?

This might be symptom of a kernel bug since 4.4.6, see here which reportedly got fixed in Linux kernel 4.8.x, and the fix will be in Ubuntu 17.04 (which will likely have 4.10 kernel).

On Fedora bug tracker, someone reported that changing / adding this in /etc/X11/xorg.conf.d/20-intel.conf helps:

Section "Device"
   Identifier  "Intel Graphics"
   Driver      "intel"
   Option      "AccelMethod"  "blt"
   Option      "TearFree"     "true"
EndSection

Didn't try, I am going to wait for 17.04.

To me, this happens also after switching to another user account and back.


Is the Launcher Icon Size set to an odd number? Try setting it to an even one; it worked for me. It's a confirmed bug.


Install button in the software center is grayed out when trying to install .debs without an internet connection

Try installing from the command line:

gdebi-gtk /full/path/to/deb/file


Where can I download the latest release of Ubuntu?

You can download it from any of the following:

Ubuntu Download page,
releases.ubuntu.com (precise, trusty, xenial)
Official CD Mirrors


Ubuntu server 10.04 usb wifi modem (D-Link DWA-137). Can't set it up

Maybe try the basics first. In the top right corner you would see the network icon. Make sure "Enable networking" is selected. Then either edit or create your wireless connection.

Hoping your router has DHCP on you would want ipv4 and ipv6 on automatic. That would leave ethernet. Assuming your hardware is functional and detected you would have the option to select a mac address for it (eth0 if there are no other network devices).

Then if that doesn't do it i would validate the router and the firewall. Assuming you have a network cable i would plug the computer directly to the modem. Repeat the directives above for a cabled connection. Then validate your firewall is not causing trouble by disabling it shortly and just testing a random google search.

The log you posted leads me to think your wi-fi device is detected and working but needs to be configured correctly.


How to access apache log file via php (Not parsing Log file)

I would be careful with trying to access the Apache log from anywhere other than local or SSH.  Accessing the log files for Apache via PHP or a nonsecure method is not safe, as those logs can contain connection related information in them which if leaked puts users at risk.

I would, if I were you, just download the log file via SFTP or rsync or scp via SSH to your system, and then analyze the logs, rather than try and have PHP serve the log file to you.


Missing icons with Xfce on Ubuntu 18.04.2

Most of the packages are missing. probably from using the server version instead of the desktop

I've got the same problem.

I ended up installing gnome first time, xfce was still there after.

sudo tasksel

pick a package, I went with xubuntu minimal, didn't get come with browser it seems, so going with the full xubuntu desktop.  You think that should do what I need, still messing with it.

Also needed fonts, not sure if this is the same as the font package in tasksel

sudo apt-get install xfonts-base and sudo apt-get install xfonts-100dpi and sudo apt-get install xfonts-75dpi fixes font issues. – gies0r Dec 10 '19 at 19:22

Couldn't start Xtightvnc trying default font path - VNCServer


How to bind keyboard layout in opengl game?

There is no way to bind directly to the xinput keys, unless I misunderstand your question. Is there a situation where binding to the quake 3 keys is insufficient?

Can you provide a concrete example of what you want to do, step by step?


GUI or simple Bash script to throttle the CPU?

cpuf - Simple Bash GUI to set CPU Min/Max Frequency

Demonstration
In this demo cpuf window is on left and conky system information is on right side. This is how the demo progresses:

Demo starts whilst youtube video is already running
Default CPU min/max frequencies are 800 / 3500
Override CPU min/max to 800 / 800 and CPU usage jumps to 20%
Override CPU min/max to 3500 / 3500 and CPU usage drops to 10%
Demo loops back and starts again

With three monitors cpuf can appear 10 feet away, so use parameter 1 --geometry option to put it close to conky:
sudo cpuf --geometry="450x450+4720+80" /home/rick/Pictures/icons/cpu-intel-128.svg

Parameter 1 --geometry is Window Width x Height + Width Offset + Height Offset
Parameter 2 can be your own icon (in this case Intel CPU image) otherwise it defaults to computer icon

cpuf Bash script
This section requires you to open a terminal with Ctrl+Alt+T.
How to setup
In order to function, cpuf bash script requires:
sudo apt install yad         # from the repository universe
sudo apt install coreutils   # installed by default in most distros

It's easiest when you place cpuf script into a root-owned directory within your search path. For example: /usr/local/bin.
To create cpuf script open the editor with sudo -H gedit /usr/local/bin/cpuf.

Highlight the lines in section below
Right click and select "Copy"
Toggle back to your editor
Right click and select "Paste"
From the editor menu select "Save" and then "Exit"

Make the script executable with sudo chmod a+x /usr/local/bin/cpuf.
cpuf code to copy to your editor
#!/bin/bash

# NAME: cpuf (Pronounced SEA-PUFF)
# CALL: sudo cpuf
# PARM: $1 = --geometry=WidthxHeight+VertOffset+HorizOffset
#       $2 = Optional image icon

# DESC: Simple GUI script to set CPU Min and Max Frequency.
#       For Ask Ubuntu Question: https://askubuntu.com/q/1141605/307523
# DATE: May 12, 2019.
# UPDT: No updates yet.
# NOTE: No notes yet.

### Dependancies ###

command -v yad >/dev/null 2>&1 || { echo >&2 \
        "yad package required but it is not installed.  Aborting."; \
        exit 1; }

command -v nproc >/dev/null 2>&1 || { echo >&2 \
        "coreutils package required but it is not installed.  Aborting."; \
        exit 2; }

if [[ $(id -u) != 0 ]]; then # root powers needed to call this script
    echo >&2 Must be called with sudo powers
    exit 3
fi

# $TERM variable may be missing when called via desktop shortcut
CurrentTERM=$(env | grep TERM)
if [[ $CurrentTERM == "" ]] ; then
    notify-send --urgency=critical \
    "$0 cannot be run from GUI without TERM environment variable."
    exit 4
fi

### Program constants ###

## Yad Window parameters
# Hard code Height & Width to suit your screen resolution and scaling factor
GEOMETRY="--width 400 --height 500"
# Pass Parameter 1 with ---geometry="WidxHgt+WidOff+HgtOff" to override
[[ "$1" == --geometry=* ]] && GEOMETRY="$1"

TITLE="cpuf"
TEXT="Set CPU Min/Max Frequencies"
ICON="/usr/share/icons/Adwaita/48x48/devices/computer.png"
# Pass Parameter 2 with icon for window image
# Intel CPU comes from: https://www.gnome-look.org/p/1107932/
[[ ! -z "$2" ]] && ICON="$2"

## Virtual File System directories
      CPU0_DIR=/sys/devices/system/cpu/cpu0/cpufreq
    PSTATE_DIR=/sys/devices/system/cpu/intel_pstate
 CURR_MIN_FREQ="$CPU0_DIR/scaling_min_freq"
 CURR_MAX_FREQ="$CPU0_DIR/scaling_max_freq"
ALLOW_MIN_FREQ="$CPU0_DIR/cpuinfo_min_freq"
ALLOW_MAX_FREQ="$CPU0_DIR/cpuinfo_max_freq"

OLD_IFS=$IFS            # Save current Input File Separtor (IFS)
declare -a Arr          # Array for YAD Window input
NumCPU=$(nproc --all)   # Number of CPUs (nproc from coreutils)

### Error Message Functions ###

Abend () {
    # Abnormal Ending - Parameter 1 = message to display, Parameter 2=exit code

    yad --image "dialog-error" --image-on-top --title "$TITLE - Fatal Error" \
        "$GEOMETRY" --button=gtk-ok:0 --text "$1" 2>/dev/null
    exit "$2"

} # Abend

ErrMsg () {
    # Parmater 1 = message to display

    yad --image "dialog-error" --title "$TITLE - Logical Error" \
        "$GEOMETRY" --button=gtk-ok:0 --text "$1" 2>/dev/null

    fErrMsgForceContinue=true

} # ErrMsg

### Initialize Variables ###

InitVars () {

    [[ ! -e "$ALLOW_MIN_FREQ" ]] && Abend "$ALLOW_MIN_FREQ not found" 11
    AllowMinFreq=$(cat "$ALLOW_MIN_FREQ")
    AllowMinFreq="${AllowMinFreq::-3}"  # Chop off three decimals at end

    [[ ! -e "$ALLOW_MAX_FREQ" ]] && Abend "$ALLOW_MAX_FREQ not found" 12
    AllowMaxFreq=$(cat "$ALLOW_MAX_FREQ")
    AllowMaxFreq="${AllowMaxFreq::-3}"

    [[ ! -e "$CURR_MIN_FREQ" ]] && Abend "$CURR_MIN_FREQ not found" 13
    CurrMinFreq=$(cat "$CURR_MIN_FREQ")
    CurrMinFreq="${CurrMinFreq::-3}"
    NewMinFreq="$CurrMinFreq"

    [[ ! -e "$CURR_MAX_FREQ" ]] && Abend "$CURR_MAX_FREQ not found" 14
    CurrMaxFreq=$(cat "$CURR_MAX_FREQ")
    CurrMaxFreq="${CurrMaxFreq::-3}"
    NewMaxFreq="$CurrMaxFreq"

    if [[ -e "$PSTATE_DIR" ]] ; then
        NumPstates=$(cat "$PSTATE_DIR/num_pstates")
        if [[ $(cat "$PSTATE_DIR/no_turbo") -eq 0 ]] ; then
            TurboBoost="Enabled"
        else
            TurboBoost="Disabled"
        fi
    else
        NumPstates="Not found"
        TurboBoost="Not found"
    fi

    if [[ -e "$CPU0_DIR/scaling_governor" ]] ; then
        Governor=$(cat "$CPU0_DIR/scaling_governor")
    else
        Governor="Not found"
    fi

    if [[ -e "$CPU0_DIR/scaling_cur_freq" ]] ; then
        CurrFreq=$(cat "$CPU0_DIR/scaling_cur_freq")
        # Chop off three decimals at end
        CurrFreq="${CurrFreq::-3}"
    else
        CurrFreq="Not found"
    fi

} # InitVars

### Paint / repaint window and get new frequencies ###

GetParameters () {

    # +------------------------------------------+
    # |  cpuf - Set CPU Min/Max Frequencies      |
    # +------------------------------------------+
    # |                                          |
    # |  Turbo Boost:            Enabled         |
    # |                                          |
    # |  Number of pstates:      99              |
    # |  Speed Governor Used:    powersave       |
    # |  Current CPU0 frequency: 9999 Mhz        |
    # |                                          |
    # |  Current Minimum Freq.:  9999 Mhz        |
    # |  Current Maximum Freq.:  9999 Mhz        |
    # |                                          |
    # |  New Minimum Frequency   9999            |
    # |  New Maximum Frequency   9999            |
    # |                                          |
    # +------------------------------------------+

    IFS="|"
    Arr=($(yad "$GEOMETRY" --form \
        --title "$TITLE" --text "$TEXT" \
        --window-icon="$ICON" --image="$ICON" \
        --field="Turbo Boost:":RO "$TurboBoost" \
        --field="Number of pstates:":RO "$NumPstates" \
        --field="Speed Governor:":RO "$Governor" \
        --field="Current Frequency:":RO "$CurrFreq MHz" \
        --field="Allowable Minimum Frequency:":RO "$AllowMinFreq MHz" \
        --field="Allowable Maximum Frequency:":RO "$AllowMaxFreq MHz" \
        --field="Current Minimum Frequency:":RO "$CurrMinFreq MHz" \
        --field="Current Maximum Frequency:":RO "$CurrMaxFreq MHz" \
        --field="New Minimum Frequency" "$NewMinFreq" \
        --field="New Maximum Frequency" "$NewMaxFreq" 2>/dev/null))

    Return="$?"
    NewMinFreq="${Arr[8]}"
    NewMaxFreq="${Arr[9]}"

} # GetParameters

###################################
#            MAINLINE             #
###################################

ALL_PREFIX="/sys/devices/system/cpu/cpu"
MIN_SUFFIX="/cpufreq/scaling_min_freq"
MAX_SUFFIX="/cpufreq/scaling_max_freq"

while true ; do

    InitVars
    GetParameters
    [[ ! "$Return" -eq 0 ]] && break ; # Exit on Cancel=1 or Close Window=252

    # Sanity checks
    fErrMsgForceContinue=false
    [[ $NewMinFreq -lt $AllowMinFreq ]] && ErrMsg "Minimum frequency too low"
    [[ $NewMaxFreq -gt $AllowMaxFreq ]] && ErrMsg "Maximum frequency too high"
    [[ $NewMinFreq -gt $NewMaxFreq ]]   && ErrMsg "Minimum frequency greater than Maximum Frequency"
    [[ $fErrMsgForceContinue == true ]] && continue

    # Set new Min/Max frequencies
    for (( i=0 ; i<NumCPU ; i++ )) ; do
        # If New Min > Curr Max, set Max first then Min
        if [[ $NewMinFreq -gt $CurrMaxFreq ]] ; then
            echo "$NewMaxFreq""000" > "$ALL_PREFIX$i$MAX_SUFFIX"
            echo "$NewMinFreq""000" > "$ALL_PREFIX$i$MIN_SUFFIX"
        else
            echo "$NewMinFreq""000" > "$ALL_PREFIX$i$MIN_SUFFIX"
            echo "$NewMaxFreq""000" > "$ALL_PREFIX$i$MAX_SUFFIX"
        fi
    done

done

IFS="$OLD_IFS"
exit 0


Could you try to

open Gnome-tweaks (You may need to sudo apt-get install gnome-tweaks)
Open the Workspaces Tab
Select Workspaces span display

Is it the behaviour you wanted?
(sorry I don't have my second monitor here)


The backup device has an incompatible file system, such as Windows FAT. FS doesn't have owners or permissions.
 USB and external drives are supplied like that for convenience, but it is bad for Linux users. You may need to delete the partition, create new of proper type, then run mkfs. I am staying conservative on file systems, only ext4.

Because drive tech and connection methods have changed, I cannot guess which way will suit you. In old days, "/sbin/fdisk /dev/sdXXX" (XXX might be b or c for you) would be the way to start. Now if your eternal is SSD, different way needed. There is good chance GNU parted can work to remove old partition and create new, but I worry about device types.


Why my ubuntu 19.10 took too long to boot [more than 10 minutes]?

You can use systemd-analyze to get an overview of your boot times.
Example: Startup finished in 12.749s (firmware) + 6.025s (loader) + 4.668s (kernel) + 9.488s (userspace) = 32.932s  graphical.target reached after 9.474s in userspace
With systemd-analyze blame, you can see what the main offenders are in terms of boot time.
For me, these are the ones that take longer than one second:
6.535s NetworkManager-wait-online.service
1.094s dev-sda5.device
1.067s udisks2.service
1.029s smartmontools.service
...


How can I make window titlebars black like the GNOME Shell top panel?

As indicated by Uri, gnome-tweak-tool  is extremely helpful for themeing gnome. You can adjust several settings including themes and icons.

sudo apt-get install gnome-tweak-tool


Installing postgres on 13.04: no valid OpenPGP data found

I ran into a similar issue following those instructions - try downloading the key separately  and then add it:

sudo wget http://apt.postgresql.org/pub/repos/apt/ACCC4CF8.asc

then:

sudo apt-key add ACCC4CF8.asc

This worked for me.


Instead of a Wikipedia-Lens I use the DuckDuckGo-Lens.
Works pretty much the same..
First results are always Wikipedia Results and in case there are no Wikipedia Results use the DuckDuckGo !Bang:

  wiki! or !wiki


Ubuntu partition unknown, cannot mount or update grub

According to the rescue log and your comment the header of the file system on sda5, your Linux partition, is seriously broken. You may be able to recover from the backup superblock as described in the output of fsck (from a live system as described by kyodake):

sudo e2fsck -b 32768 /dev/sda5

If that doesn't work, the file system is likely beyond repair. If you have important data on it, you can try to salvage it with data recovery tools, e. g. as described in the community help.


It's likely because you need to make it executable, which you can do with chmod +x jdk-8u60-nb-8_0_2-linux-x64.sh.


I recently had a similar problem. I'm on Ubuntu 14.04 so the problem may have been completely different from yours, but I was able to fix it by re-installing Unity (Ubuntu's default desktop environment).

To be honest I don't remember exactly which commands I used, but here are a few  threads that were useful to me while troubleshooting this problem:

How do I reinstall Unity?

Reinstall `ubuntu-desktop` after removing Gnome

The first answer here is useful as well:

How to reinstall unity desktop on Ubuntu 14.04

I remember using apt to check for missing dependencies and that there were few related to Unity.


Sound stopped and I must reboot to make it work again

I had the problem resolved by following most of these steps.
I hope this help as much as it help me.
Ubuntu help


Check out (type as url): about:support
This should give you info on supported features (like hardware rendering)

You can try to disable/uncheck hardware acceleration in Firefox. It may feel counter intuitive but has often worked for me. You can find it here:

Tools > Options > Advanced > General > Browsing: "Use hardware acceleration when available"

Another good thing to try is to install Chrome (or Chromium) and check that browser has the same problem. From experience I have had lagging in Firefox but Chrome worked fine.

If you do want to install the ati binary drivers you can go to

Ubunti Settings > Software & Updates > Tab: Additional drivers

Good luck!


This is more of a guess than an actual answer.

If you update the package-lists do you get any warning or errors?

 sudo apt-get update
 -- go through and check for warnings

And are the sources good?

 cat /etc/apt/sources.list
 -- check if something important is out-commented.


How could I change the scrollbars colors on Plasma(5.16) on Kubuntu 19.10?

DK Bose comment was the solution I wanted.

The approach I took was:

I tried the Oxygen application style in Plasma's System Settings application. I found I could change scrollbar width but not color.
Then I decided to give QTCurve a try. This involved building from source on my machine. Beware: if you are not a developer or user with a tinkerer spirit this could be difficult for you. This step involved cloning QTCurve Github repo from https://github.com/KDE/qtcurve, compiling and then installing on my machine. The compiling process needs some development packages from KDE (for libraries and such) which I already had because I'm compiling KDE apps from source. Once I did all of that I went to System Settings application and in there I found the new QTCurve I just built. QTCurve has a lot of options, and the scrollbars have the width and color customization I wanted!


Moving the menu bar to top bar ubuntu 20.10

There is a trend, adhered to by the Gnome Shell developers, to move away from traditional pull down menu bars in favor for extensive context menus and a "Hamburger" button. In that context, Gnome Shell developers do not bother implementing a global menu, because it should be gone in the first place.
A Gnome Shell extension, Gnome Global Application Menu (HUD for Gnome) by sathwik, implemented a global menu. It is not anymore developed, but apparently another project is maintained on Github. It will not necessarily work or work well for all apps. Firefox and Thunderbird, and Gnome apps are listed as a few where it does not work (yet?).


Is my local area network accesible to others when sharing my Internet connection?

It can depend on many things.

Best way is to try it out by yourself, as there is not much point in theory when it's easier to try it out and see.


Copy particular files (whose names are saved in a list) from one folder to another

the command you are looking is as follow,

cd /path/to/model
$ xargs -d '\n' -a /path/to/id.txt cp -t /path/to/selected_ids

this will read the files name saved in id.txt and copy to selected_ids directory.


Cannot read filenames that are in utf8 encoding (Greek characters)

This happens because default Ubuntu archive manager file-roller uses p7zip to unzip zip archives, if p7zip-full is installed. P7zip-full does not treat non-English file names correctly.

I made a PPA with file-roller using unzip program instead of p7zip.
Patched file-roller can be installed by

sudo add-apt-repository ppa:hanipouspilot/file-roller
sudo apt-get update
sudo apt-get install file-roller