How do I reduce the size of the menu bar?

I ran
mlocate unity.css

and saw there are two other css-files:

/usr/share/themes/Ambiance/gtk-3.0/apps/unity.css
/usr/share/themes/Radiance/gtk-3.0/apps/unity.css


Ubuntu installed on HDD does not see SSD with Windows

This answer was originally posted by the asker as an edit to the question and a comment.

Switch to AHCI, run boot-repair and switch back to RAID.


Diff between backups: see permissions, group and owner and sym link differences

My experiment

Setup

At first I created an Ext4 Partition on my PC using gparted.

Then I booted into a small Arch GNU/Linux installation in the hope that this would bring a better performance. Then I attached my Raspberry Pi with a only a bit modified Raspbian GNU/Linux Installation via Ethernet switch to the PC.

Then I mounted the Ext4 partition.

Copying

After this I copied the / partition of the Pi to my PC.

rsync -rlptgoDXvxzH --numeric-ids --exclude={"/dev/*","/proc/*","/sys/*","/tmp/*","/run/*","/mnt/*","/media/*","/lost+found"} root@raspberrypi:/ rsync_mount/

This took about 20 minutes. If you copy your server to your NAS you may need

a flatrate (or a lot of money;) )
a lot of time

bricking the Raspberry Pi

Then I bricked my Raspberry Pi using

ssh root@raspberrypi

rm -r /run /var /etc /usr

Then I had to unplug the power cable because nothing was working anymore.

repairing the Raspberry Pi

Finally I plugged the SD-Card of the Rpi into my computer, mounted it and repaired it using

cp -rpvxH  rsync_mount/* rpi_mount/

after unmounting the SD-Card and booting the Rpi everything worked fine again.

Fazit

The part with rsync worked fine, but I do not know if it will work with a complete new installation. Maybe then the kernel will not fit to what you copy back on the server.

I will make another try, where I install a newer kernel version after rsyncing.


How can I make Google Chrome tabs sharper?


Should I execute bash scripts from python with `bash` or `./`?

First, regarding the dot in ./script.sh, this indicates that script.sh can be found in the working directory, it means something like "look for script.sh here, in this directory". This is known as dot slash, and it is well explained here.

I see three options:

If you intend to restrict the file to only run if it is in the user's current working directory when he runs your Python script, then use the dot slash. However, this doesn't seem like the best idea: it will lead to exceptions most of the time.
If you intend to restrict your shell script to run only if it is in the same directory as your Python script, then you would need to find out your Python script's directory and prefix it to the name of your script.
If you intend to place your shell script elsewhere in your PATH, don't use the dot slash.

Now, sending "bash" as an argument to the Popen constructor seems more like a matter of preference. If you don't want to send it as an argument, then you will need to add a shebang to the shell script, e.g. #!/bin/bash, and you will need to add execute permissions to it. These are perfectly acceptable things to do.

One benefit of doing it this way is if later one changes the shell interpreter, it won't be necessary to modify every single call to that script in who knows how many Python scripts.

And one can just call the script like:

cmd = subprocess.call('script.sh')
# or
cmd = subprocess.call(sdir + 'script.sh')
# Where sdir stands for the script's directory,
# which you would need to find before, as in option #2.

Notes:

Even if your script runs without a shebang normally (in which case it almost certainly gets executed by dash and not by bash on Debian based distros), when calling it from python like this, it will fail and raise an OSError exception with errno 8 (errno.ENOEXEC).

If it's really necessary, use Popen.


Error on attempting to move and shrink an Ubuntu partition using GParted

Boot into windows and then use EASEUS PARTITION MASTER to add unallocated space to your NTFS partition.


How to cause an Ubuntu Touch device to vibrate?

The website says you can do it with an API call to cordova(html5 abstraction layer), so it has to be an exposed api somewhere https://developer.ubuntu.com/api/html5/sdk-14.04/org.apache.cordova.vibration/


The PulseAudio Volume Utility (pavucontrol) might give you what you're looking for ... to a point. I use this with my microphones:

If you do not already have it installed, you can do so like this:
sudo apt install pavucontrol

Once installed, you can open the application like any other.
Hope this gets you closer to what you're looking for.


How do I configure an Apple Magic Trackpad to use with Unity?

I have got the Apple Magic Trackpad too and of course, I have to admit that it works better on Mac OS X. Thanks to OMG!Ubuntu I discovered Touchegg a very nice app that gives us many options for increase usability. Give it a try!


You need to put the lsof command inside parentheses (command subsitution) instead of braces in order to kill every processes (files) that uses the port 3000.

kill $( lsof -t -i:3000 )


Difficulty installing a CNC pendant linuxcnc

'~' means your home directory, so ~/src means /home/your_username/src.
You are correct: That directory is not created by Ubuntu.
However, there is nothing magical about that directory. You can create it and destroy it as much as you wish without harming your system.
Create the directory using either your file manager or terminal (mkdir ~/src).


mount.cifs fails with mount error(2): No such file or directory

This is just a guess because I don't remember what the default settings were on Samba 3.6 but I think CIFS is trying to mount with an smb dialect that that version of samba didn't have yet.

Add the parameter vers=1.0 or maybe vers=2.0 to your list and see if you can connect:

mount -t cifs -o user=myuser,vers=1.0 //myserver/myshare /home/user/myserver/myshare/

EDIT: You may have to drop down the security level as well with another parameter: sec=ntlm


Lost lockscreen after uninstalling cinnamon from 13.04, how do I get it back?

I had a similar problem after upgrading to 13.10. I was able to resolve it by re-enabling the cinnamon-stable ppa and re-installing cinnamon. After that, all is well again. If you aren't using the cinnamon ppa, I recommend it:

https://launchpad.net/~gwendal-lebihan-dev/+archive/cinnamon-stable


It is telling you that the packages are already installed, but it has not installed all of the other packages it needs to work. You should be able to solve this by running this:

sudo apt-get -f install

(This command should automatically install the unmet dependencies.)

or this:

sudo apt-get install click curl dpkg-dev python-lzma python-requests imagemagick ubuntu-dev-tools

If some of those packages are not available, you can search for ways to install them here or here.


Container Partition does not start on physical boundary

This is typical and most users see this message. You can safely ignore it.

See the answer here Partition does not start on physical sector boundary?


Error installing Ubuntu touch on Galaxy Nexus

The package:

phablet-tools

depends on python which in turn depends on python-minimal

$ dpkg -S /usr/lib/python2.7/logging/__init__.py
libpython2.7-minimal:amd64: /usr/lib/python2.7/logging/__init__.py

which provides the logging module.


Restarting fixed the problem. Not sure why.

Edit
The problem occurred again. Using urgency critical caused the notification to appear. The command is:

 notify-send --urgency="critical" "asdf"


Ubuntu 18.04 on Acer Spin 5 with \EFI\BOOT\mmx64.efi not found

Solution:

Enter BIOS and ensure Secure Boot is disabled. I then performed the following actions:

Select Security
Select "Erase Secure Boot settings"
Select "Restore Secure Boot to factory default"
Press F10 (restart)
Enter BIOS
Select Security
Select "Select UEFI file as trusted for executing"
Select "HDD0", select "EFI", select "ubuntu", select "grubx64.efi", name it "grubx64efi", press Enter key twice
Disable Secure Boot (I did not adjust my load-order in any way before disabling Secure Boot)
Press F10

Everything booted up just fine.

Here are two resources for further references. Cheers to Niclas Borlin and jacobbrett for solving this problem.

[SOLVED] Unable to boot to ubuntu from an SSD
System fails to boot with \EFI\BOOT\mmx64.efi - Not Found - Linux Mint Forums


The easiest way to do this is to compile it yourself. Here's how I managed to get it working on Ubuntu 15.10 Wily.

~/$ sudo apt-get install pyqt4-dev-tools git
~/$ sudo apt-get install libusb-dev libjack-dev libbluetooth-dev pyqt4-dev-tools
~/$ cd Downloads
~/Downloads/$ git clone https://github.com/falkTX/qtsixa.git
~/Downloads/$ cd qtsixa
~/Downloads/qtsixa/$ make
~/Downloads/qtsixa/$ sudo make install

After that it should be installed, and you can use the qtsixa program to connect to your device via bluetooth. TO do so, first connect your six axis controller to your computer via usb, and then enter the command below

~/$ sudo sixpair

After that unplug the usb from the controller and run the next command to connect to your six axis controller via bluetooth.

~/$ sixad --start

You will be prompted to press the Playstation button on your controller, which you actually need to hold down for a few seconds. Finally if everything worked, your controller should rumble for a second and you should be good to go.


Upgrading Ubuntu 12.10 to 13.04 using bootable USB alongside Windows 7

I wrote this as a technical document on April 25th, 2008; I just used this exact method to install Ubuntu 13.04 on a WD external USB 2 TB harddrive and it worked flawlessly. I will give you this one piece of advice... **

  follow this to the letter and it will work for you and if you do not I
  am not responsible for the end result

**.

The topic of a bootable external USB Linux hard drive (without dual-boot) is an area that is not well documented. A simple Google search shows many articles, blogs and forum posts written on this topic, all of them discuss setting up dual-boot strategies. While I did not specifically test a USB Thumb Drive and did not intend to address this device in this article, I see no reason why this would not work for Thumb Drives as well. This article was written with the goal of defining an alternative to the traditional dual boot concept and keeping each operating system isolated from each other.

While the dual-boot scenario works, this can cause undesirable issues when grub installs its files on the external drive. Should Grub install its files to the external drive, the drive must be connected before booting the computer or you will receive a Grub 17or 21 error. Based on the testing I have done in an effort to achieve the desired results, I did not want a dual-boot on either the laptops operating system (internal hard drive) or on the external USB drive.

This document applies to all Linux distributions that I have tried since writing the original document in 2008. You will want to use laptop or desktop hardware in which the BIOS supports booting to a USB device.

Why would you want to do this?

Small foot print USB powered external drives are very obtainable and affordable. These drives come in various sizes with the most common and cost effective today being 250GB. This gives you the ability to:

Test new OS versions
Carry multiple working OS’s with you in the field
Lab issues in the field
Test patches
Perform demonstrations

All of the above and more without risking the OS installed in your laptop or desktop. While this solution may not be right for everyone; this will provide you with more options.

There are several ways to achieve the results described herein; I will describe two of these methods and you can choose which method works better for your scenario.

Method 1:

Insert the Linux OS Install CD/DVD
Reboot the computer
Enter the “Setup Menu”
Disable the internal hard drive
Save settings and exit
The computer will reboot so you can see the Post Screen
Push the appropriate key (F12 for Dell Laptops) to bring up the “One Time Boot Menu”
Select boot from CD/DVD
Install Linux OS (Follow your normal install procedure)
The only device that should appear is the external USB drive

Note: Since the internal hard drive is disabled the Linux OS will have no choice, it will install all of the required components for the external USB drive to become a bootable device.

When the install has completed:

Remove the Linux OS Install CD/DVD
Reboot the computer
Enter the “Setup Menu”
Enable the internal hard drive
Change the boot order to resemble
    USB Device
    Internal Hard drive
    CD/DVD
Save settings and exit
The computer will reboot so you can see the Post Screen (Let the system boot as normal)

The machine will boot into your newly installed Linux OS and will have no knowledge or connection to the OS that is installed on the computers internal hard drive.

Method 2:

Insert the Linux OS Install CD/DVD
Shout down the computer
Remove the internal hard drive
Start the computer
The computer will boot so you can see the Post Screen
Push the appropriate key (F12 for Dell Laptops) to bring up the “One Time Boot Menu”
Select boot from CD/DVD
Install Linux OS (Follow your normal install procedure)
The only device that should appear is the external USB drive

Note: Since the internal hard drive was physically removed the Linux OS will have no choice, it will install all of the required components for the external USB drive to become a bootable device.

When the install has completed:

Remove the Linux OS Install CD/DVD
Shut down the computer
Install internal hard drive
Enter the “Setup Menu”
Change the boot order to resemble
    USB Device
    Internal Hard drive
    CD/DVD
Save settings and exit
The computer will reboot so you can see the Post Screen (Let the system boot as normal)

The machine will boot into your newly installed Linux OS and will have no knowledge or connection to the OS that is installed on the computers internal hard drive.

Issue:

During one of my tests, after all of the above steps were completed Linux on the USB External Hard drive would not boot. The computer did not see the device as a bootable device therefore the machine booted to the OS installed on the internal hard drive.

Solution:

Plug the external USB device into the USB port on the computer
Place the Linux install CD/DVD in the CD/DVD drive on the computer
The computer will boot so you can see the Post Screen
Push the appropriate key (F12 for Dell Laptops) to bring up the “One Time Boot Menu”
Select boot from CD/DVD
The main install screen will give you the option to repair the Installed OS (during my tests this did not have any unwanted effects on the computers internal hard drive or the OS installed on it)
Once the repair is completed remove the CD/DVD from the CD/DVD drive
Reboot the computer

The computer should boot to the OS installed on the external USB drive without issue. However you need to understand the BIOS in your machine; I would suggest removing any USB devices except for the hard drive before booting the computer.


From looking over the instructions here it seems the install script install.sh should do everything for you.  So you don't need to do apt-get stuff.  In other words, from inside the directory, just type ./install.sh

That's it!


Can't use custom themes, Gnome Shell 3.2

I had to face this problem again, and found a solution:

Original blog post here

Istall the user-theme extension from ppa:

sudo add-apt-repository ppa:ferramroberto/gnome3
sudo apt-get update
sudo apt-get install gnome-shell-extensions-user-theme

Restart by logging out and back in or with ALT-F2 and r.

Open the gnome tweak tool, go to Shell Extensions, enable the User Themes Extension.

Close the tweak tool restart gnome-shell again.

Now open the gnome tweak tool again and, under theme, you should be able to select your shell theme.


¿Cómo puedo iniciar programas al arracar automaticamente en diferentes areas de trabajo?

English translation

How can I start programs by automatically booting into different work areas?

Currently I use the Startup Applications program to start my continuous use programs, however I want to open programs in different workspaces and I would like to know how I can do it. Cheers

Since you have to specify the full path in Startup Applications, the OS assumes that you are not in any specific directory.  Instead of using the executable, try using a bash script to start your application.  The bash script should cd to the correct location before running the application.


You can do it using the Perl-based rename I think, using a mix of non-greedy and greedy matches ex.

$ rename -n 's/^(.*?)_(.*)_(.*?)$/$2_$1_$3/' *
rename(firstName_de_lastName_date, de_lastName_firstName_date)
rename(firstName_lastName_date, lastName_firstName_date)
rename(firstName_von_lastName_date, von_lastName_firstName_date)

The non-greedy modifier on the last (date) group isn't really necessary - but I like the symmetry.

Alternatively, with the shell alone

$ for f in *; do
    m="${f#*_}"; m="${m%_*}"; echo mv -- "$f" "${m}_${f%%_*}_${f##*_}";
  done
mv -- firstName_de_lastName_date de_lastName_firstName_date
mv -- firstName_lastName_date lastName_firstName_date
mv -- firstName_von_lastName_date von_lastName_firstName_date


Here's a pretty good (if dated) description of display fonts in Ubuntu.

Quoting from that section:

  The Ubuntu GNOME desktop allows fonts to be specified for a number of different display categories:

  Application font - The font used to display text in application windows. This also changes the font used to display items such as the menus in the desktop panel.
  Document font - Specifies the font that is to be used when displaying document text in an application.
  Desktop font - The font used to display text under the icons on the desktop (such as folder names).
  Window title font - The font used on the text in window titles.
  Fixed width font - Specifies the font to be used when the system needs to display fixed width font. A prime example of this is the text that is rendered in a Terminal window.
  In terms of font selection options, fonts may be specified by type (Utopia, Serif, Monospace etc), style (Regular, Bold, Italic) and size (10pt, 11pt etc).


Can't install Filezilla, can't locate package

Had problem on home network, special thanks to comments for solution: sudo apt-get -o Acquire::ForceIPv4=true update

Forces IPv4 for apt-get.


looking for a clock widget that is unaffected by the mouse

I wish someone with plasma widget experience could tell me if this is possible for plasma widgets but for now I found a ... kind of hack/fix to get around the problem.

There is a screenlet called "digiclock"

If you run this screenlet,
turn off the gradient color,
make background completely transparent,
make the clock text semi transparent,

then the mouse will not be able to click on the widget...
For some reason the mouse can not click on screenlets which use transparency , and it will be able to click on buttons from windows that fall behind the widget.

This is wonderful but sometimes/rarely, If the mouse catches a non-transparent pixel then it will not be able to click behind the widget... strange behaviour.


Partitions created after installation is readonly

To have partitions mounted in read/write mode, you need to change the mount options in /etc/fstab and make sure your user has read/write access to the place where the partitions are mounted (the mount point).

Get the UUID of your partitions by running blkid in a terminal. The output will look something like this (this is on my system, your details will be different):

/dev/sda1: SEC_TYPE="msdos" LABEL="DellUtility" UUID="3030-3030" TYPE="vfat"
/dev/sda2: LABEL="RECOVERY" UUID="E208CFC008CF9249" TYPE="ntfs"
/dev/sda3: LABEL="OS" UUID="C0BCD19CBCD18D72" TYPE="ntfs"
/dev/sda5: LABEL="READER" UUID="4C2D-395C" TYPE="vfat"
/dev/sda8: UUID="7696fff5-139c-425f-b3c1-5a3e2ba1158d" TYPE="swap"
/dev/sda6: LABEL="Home" UUID="a180cec0-ecad-4944-8e29-7c9249ed23b0" TYPE="ext4"
/dev/sda7: UUID="d5cf136f-f344-4187-92c5-e29c6006c5c6" TYPE="ext4"

Note the UUID of your partition (eg. a180cec0-ecad-4944-8e29-7c9249ed23b0 and it's type, eg. ext4), you will need these to modify fstab.
Create the mount point for these partitions, the place where you want them to be accessible. For example, /media/data1 and /media/data2, and change their permissions to give everyone read/write access to your user:

sudo mkdir /media/data1 /media/data2
sudo chmod a+wrx  /media/data1 /media/data2

Let's say you want sda6 and sda7 to be mounted read/write. Open /etc/fstab as root:

sudo gedit /etc/fstab

Add these lines to the file:

## sda6
UUID=a180cec0-ecad-4944-8e29-7c9249ed23b0   /media/data1    ext4    defaults    0   0
## sda7
UUID=d5cf136f-f344-4187-92c5-e29c6006c5c6   /media/data2    ext4    defaults    0   0

IMPORTANT: make sure you change the UUID above to the one returned by blkid and the ext4 to whatever TYPE was for that partition.
Either reboot (they will now be mounted automatically) or run sudo mount -a. You should now have read write access to both partitions at /media/data1 and /media/data2.


Here are couple of suggestions, but by no means definitive answers:

Try different dhcp client

If you search with apt-cache search dhcp | less, you will see quite a few alternatives to dhcp that comes by default. For instance, I'd suggest getting dhcpcd. I'm not sure if NetworkManager changes it's settings automatically once you install dhcpcd, but I'd suggest opening the /etc/NetworkManager/NetworkManager.conf and under [main] section specify dhcp=dhcpcd, like so. At least according to man NetworkManager.conf :

  Presently dhclient and dhcpcd are sup‐ ported. The client configured
  here should be avail‐ able on your system too. If this key is missing,
  available DHCP clients are looked for in this order: dhclient, dhcpcd.

Disable dnsmasq plugin

dns=dnsmasq is another option that is specified in the NetworkManager.conf. The reason why I'd disable it, is because dnsmasq would fetch the dns server from the default gateway (aka your router), and that is also one of the elements in the "getting ip configuration" process. Simply comment out that plug in, like so # dns=dnsmasq. Small thing to keep in mind is that NetworkManager then won't resolve domain names. Thus, I suggest changing dns settings altogether. Also, think about deleting /etc/resolv.conf to let things reset or at least sudo dpkg-reconfigure resolvconf.

Delete connection configurations and reconnect

This can be done either through connections editor (Edit connections option in the drop-down menu ornm-connection-editor from terminal). Also, sudo rm -i /etc/NetworkManager/system-connections/* will do the trick.

Disable NetworkManager from creating a default wired connection

Again, it's in NetworkManager.conf, under [main], option should be no-auto-default=*

Try WICD network manager

I suppose that is self explanatory . . .

Examine /etc/dhcp/dhclient.conf file

You can compare with my configuration :

#send host-name "andare.fugue.com";
send host-name = gethostname();
#send dhcp-client-identifier 1:0:a0:24:ab:fb:9c;
#send dhcp-lease-time 3600;
supersede domain-name-servers 208.67.222.222,208.67.220.220,8.8.8.8;
# prepend domain-name-servers 208.67.222.222,208.67.220.220;
request subnet-mask, broadcast-address, time-offset, routers,
        domain-name, domain-name-servers, domain-search, host-name,
        dhcp6.name-servers, dhcp6.domain-search,
        netbios-name-servers, netbios-scope, interface-mtu,
        rfc3442-classless-static-routes, ntp-servers,
        dhcp6.fqdn, dhcp6.sntp-servers;

Among other things, I'd also suggest that you add information from ifconfig, what ethernet card you have, and output of dmesg to your questoin. Cheerios !


How to remap a single function key f1-f12, without any new program?

I figured it out. The reason why the org.gnome.desktop.wm.keybindings may not have been working is that I had no gnome.desktop. I used the dconf editor to browse the org entry and realised, it should have been org.<desktop_env_name>. and so forth. Anyways, use the dconf editor and it lets you bind any keys. Obviously now, be careful!


The easiest way would be to boot off a LiveDVD or LiveUSB (12.04 or 12.10) and plug the device in.  Next mount the drive in the computer (or another USB device) by opening it in Nautilus.  If you're not sure where the device is mounted open a terminal and issue the command:

mount | grep /dev/sd

Or have a look in 'disk utility'

Next, start deja dup and select the external device/pathname to restore from, and the drive of your choice to restore to.


Logitech C270 webcam reading from wrong position

Probably you have a /dev/video0 that's not connected to anything. sudo rm /dev/video0 and then reboot and you should see your device added in the /dev/video0 position; if not check dmesg for clues.

It's also possible that you've used udev to manually assign a video1 number.


Docker compose install error 'curl: (56) OpenSSL SSL_read: SSL_ERROR_SYSCALL, errno 104' in Ubuntu 18.04.2 LTS

Maybe not the solution you wanted, but if you only need to download the file, and placed them onto /usr/local/bin directory, then wget can do that.
sudo wget https://github.com/docker/compose/releases/download/1.24.1/docker-compose-$(uname -s)-$(uname -m) -O /usr/local/bin/docker-compose

This will download and specify the path of the file to /usr/local/bin/docker-compose— which is I assume what'd you want to achieve.
Failing cURL command
There has been bug reports that describe the problem that you occured on cURL's GitHub page, it is currently active and you may want to look at it → https://github.com/curl/curl/issues/4409


"inputattach" doesn't survive suspend / resume

You should try to create an UDEV rule in /etc/udev/rules.d/. I assume that you want to attach the Logitech mouse, so find the correct rule by entering:
sudo udevadm monitor --environment --udev

Plugin the mouse and analyze the data the command above will log to the console: (Yours will look different!)

UDEV  [43482.659634] bind     /devices/pci0000:00/0000:00:1a.0/usb1/1-1/1-1.5/1-1.5.6 (usb)
ACTION=bind
DEVPATH=/devices/pci0000:00/0000:00:1a.0/usb1/1-1/1-1.5/1-1.5.6
SUBSYSTEM=usb DEVNAME=/dev/bus/usb/001/007 DEVTYPE=usb_device
DRIVER=usb PRODUCT=93a/2521/100 TYPE=0/0/0 BUSNUM=001 DEVNUM=007
SEQNUM=3718 USEC_INITIALIZED=43481815203 ID_VENDOR=093a
ID_VENDOR_ENC=093a ID_VENDOR_ID=093a ID_MODEL=USB_OPTICAL_MOUSE
ID_MODEL_ENC=USB\x20OPTICAL\x20MOUSE ID_MODEL_ID=2521 ID_REVISION=0100
ID_SERIAL=093a_USB_OPTICAL_MOUSE ID_BUS=usb ID_USB_INTERFACES=:030102:
ID_VENDOR_FROM_DATABASE=Pixart Imaging, Inc.
ID_MODEL_FROM_DATABASE=Optical Mouse
ID_PATH=pci-0000:00:1a.0-usb-0:1.5.6
ID_PATH_TAG=pci-0000_00_1a_0-usb-0_1_5_6
ID_FOR_SEAT=usb-pci-0000_00_1a_0-usb-0_1_5_6 MAJOR=189 MINOR=6
TAGS=:seat: CURRENT_TAGS=:seat:

In this case you create a file it the folder mentioned above like 40-attach.rules and write the following rule:
ACTION=="bind", ATTR{idVendor}=="093a",RUN+="/usr/local/sbin/mybashfile.sh"

You have to to select the ATTR values according to your data (not mine).
Basic idea is that udev will execute the command after "RUN" if it detects the hardware.
Be reminded: This is an example that is based on a device that is plugged in. You will have a different values, but it should give you the gist. You could do the same with about any hardware that is connected to your PC/Laptop
UPDATE
This Arch Linux article describes how to attach a serial device to the kernel. It might help you to get around instead of using the UDEV route - which is not helpful in your case.
Another approach is listed here reawakening a touchscreen. In both cases systemd was used. Not as hook (as you tried) but as a service itself.
The most important part should be the unit definition:
[Unit]
 Description=restart your-inputattach service
 After=suspend.target

This precedes the "Service" Section, where you can define whatever your needs.


Ibus does not start automatically on kubuntu

Those variables should not be set in ~/.bashrc, since that won't make them available everywhere in the graphical environment.
To make IBus start automatically at login and set the appropriate variables correctly, open the Input Method tool and select "ibus".
Alternatively you can do it with this terminal command:
im-config -n ibus

(That also makes ibus-daemon in the startup application redundant.)


1080p External Monitor through a Dell XPS 15 L502X?

Actually, using a mini DisplayPort to DVI ou HDMI adapter and connecting the External Monitor through it, is working fine. and you get full 1080p resolution.

While HDMI port does not on DELL XPS 15, as it is optimus based.

Installing Bumblebee project or Ironhide enbales Optimus and the use of the Nvidia card but HDMI support is still in the laboratory.

One can enable the HDMI video output under a native resolution (supposing that one installed bumblebee), on terminal:

$ optirun nvidia-settings -c :8

$ DISPLAY=:8 firefox

Check this to enable the HDMI port with native resolution:
https://github.com/Bumblebee-Project/Bumblebee/issues/67

UPDATE: Check the new support for Optimus in Ubuntu 13.04, named REVERSE PRIME (Only Nouveau)


Skype screen-sharing doesn't work properly

Skype for Ubuntu is unfortunately outdated. It does not receive any more updates and has certain broken parts.

Here's a list of additional software you could use to accomplish the task at hand -->

1) Guacamole

2) appear.in

3) Chrome Remote Desktop

The other option is to use remote desktop over VNC. Its simple and does not require the installation of other third-party applications. Guide to setup VNC.

The most recommended option would be Jitsu video bridge. It is a video chat client that will also provide you with the option to share the desktop beside some other features. It could be the alternative for skype that you are looking and it works directly from within the browser.

Edit: Google Hangouts also support screen sharing.


Most likely it will not affect them at all. Kubuntu and Xubuntu are community efforts; there is very little direct contribution from Canonical to these projects. For instance, I believe that there is only one developer paid by Canonical working on Kubuntu. Xubuntu doesn't have any. Canonical's main contribution to these projects is infrastructure.

Each of these projects has been driven by the strong communities which have grown around them. The fact that Canonical has decided to push Unity will not change that. In fact, if any thing, I wouldn't be surprised if the community ends up creating a new "buntu." I imagine that there will be people interested in working on a stock GNOME derivative. Gubuntu perhaps?


findimagedupes is a common command-line application for finding similar or identical images. You can install it by executing the following:

sudo apt-get install findimagedupes

You could also set up an OpenCV script using Python, but that would take a bit of studying.


Why does print('\x9f') in the python3 REPL hang gnome-terminal?

python3's print('\x9f') prints the UTF-8 encoded version of the U+009F character (assuming that your locale is set to UTF-8, which is a pretty reasonable assumption). This is not the same as the single 0x9F byte printed by echo -e '\x9f', which is invalid UTF-8.
U+0080 .. U+009F are control characters, potentially causing subsequent data to be interpreted as parameters, rather than letters to be displayed. Some terminal emulators (e.g. gnome-terminal) support these control characters even in UTF-8, while some others (e.g. xterm) reject them in UTF-8 and only recognize their 7-bit-clean counterparts in this encoding. Which one is correct is probably debatable.
The bottom line is: Never print something to the terminal that isn't printable (according to iswprint() or its equivalent), unless you know exactly what you're doing (e.g. your explicit intent is to print an escape sequence). And stick to the 7-bit-clean C0 control codes rather than the problematic C1 ones.


I have found the solution which is working well for me till now -

posting it here -

I tried upgrading to

  40.0.2214.93

It does not help much. after a while the problem start again, as it is mentioned by other users above.

The one worked for me is this - disable the hardware acceleration settings. in google chrome. For disabling hardware acceleration -
go to the option "customize and control google chrome"
the gray area in upper right corner besides the option of Google input tools-

Then click on settings from the drop down menu.
click on the blue option

  Show advanced settings...

check for the 6th category -

  System

and see if the box for using hardware acceleration is checked

if it is checked please uncheck it.

This has solved my problem.


See if there's a proxy set in /etc/apt/apt.conf (or somewhere in /etc/apt/apt/apt.conf.d).

There'll be a file with a line something like:
Acquire::http::Proxy "http://155.238.4.87:8080";

Comment the line(s) by putting a # at the beginning of it and try again.


How to know where wget store it's data and which process started it

ps axjf shows which process started it. Also this will show its pid, process id.
Then use ls -l /proc/4043/cwd replacing 4043 with PID you are interesting it, this will show what is current directory of that wget. This is most likely place for saving downloaded data.
Otherwise examine what parameters were passed to that wget by cat /proc/4043/cmdline (again, your PID instead of 4043).


Broadcom Bluetooth device remains undetected (BCM2046, WIDCOMM )

I had the same problem on my dual boot machine, switching over to windows and enabling the bluetooth and then going back to Ubuntu 12.04 fixed the problem.


With the help of @GunnarHjalmarsson I solved the problem.

I don't know exactly why that happened, but perhaps Firefox looked for fonts there, found one, and used it. But those fonts don't have a typewriter variant, so maybe this is the cause.

The Solution

@GunnarHjalmarsson suggested to move the fonts to /usr/share/fonts/calibri.

Since these were TrueType fonts, I moved them to /usr/share/fonts/truetype/calibri

Actually, there are more fonts in the bundle, so I did this:

for i in calibri cambria candara consola constan corbel; do
    sudo mkdir /usr/share/fonts/truetype/$i # create the folder
    sudo mv ~/.fonts/$i* /usr/share/fonts/truetype/$i/ # move the font files
    sudo chmod 644 /usr/share/fonts/truetype/$i/* # change permission of the fonts to rw-r--r--
done

After that I removed the ~/.fonts and restarted Firefox and the problem was solved...

But then the fonts were no longer available (for XeTeX, at least). So I downloaded the script which installed the fonts in the first place:

wget -qO- http://plasmasturm.org/code/vistafonts-installer/vistafonts-installer

but didn't execute it. At the end of the script I found fc-cache -fv ~/.fonts. Reading the man fc-cache page I found out that this command creates sort of a mapping of the available fonts, so I used:

fc-cache -fvs

to regenerate these mappings.

After that I had my Firefox working fine and the fonts were available for XeTeX to use.

I must add that on another computer (both with Ubuntu 16.04 and Firefox 58) I did the same procedure described in the question (the font installation), but the problem didn't happen... I have no idea why :P


Grub2 doesn't recognize any new partitions?

hey there i too experienced with such problem once but instead of formatting free space you need to format complete hdd{so sorry to say that :( }

Because any hdd will have only 4 primary partitions on which any operting system can be installled to be seen in boot loader (grub or burg etc...)

so according to my knowledge and experience take backup and "clean" (windows command) it and reinstall all other operating systems that you have installed.

if there is another best way please let me know.


Status 503 is website unavailable.

Launchpad is currently down, I assume Ubuntu One uses the same servers.


Use visudo to edit the sudoers file (never try to change it any other way!):

sudo visudo

then paste the following line at the end;

user ALL=(ALL) NOPASSWD:ALL

at the end of /etc/sudoers. Replace user with the name of your current user.
so if your user is babek you enter

babek ALL=(ALL) NOPASSWD:ALL

at the end of /etc/sudoers.


I have a HP Envy dv7-7390eb laptop and in Ubuntu 14.04.1 (fresh install) what worked for me was:

gksudo gedit /etc/pulse/default.pa

and add the following line

load-module module-combine channels=6 channel_map=front-left,front-right,rear-left,rear-right,front-center,lfe

When you reboot and go into sound settings (click on volume control icon and choose "sound settings") an extra entry "Simultaneaous output to Built-in Analog Stereo" appears in the "Output" tab. Click on this, then click on the "Test sound" button to the right and you will now have 6 speakers to test. For me 5 out of 6 work now, only subwoofer remains silent. Which is a big step forward, albeit not a full solution...

(Everything I tried relating to changes in /etc/modprobe.d/alsa-base.conf, like adding the line options snd-hda-intel model=ref or variations on this, did not work. And I try to keep away from hda-jack-retask because it seems a bit dangerous to a noob like me).


This is not a problem. Any *-installer package downloads it's contents during install due to licensing restrictions. For your case, you may want to use package adobe-flashplugin instead of flashplugin-installer.

Anyway, if you want to use installer version, you have to check your network settings, and be sure that command wget <url> works proper.


Desktop icons label too dark in nemo file manager

not a solution, just +1 report

I got same issue here, but i did not poke gtk libs, grub or complex thing.. just plain update (and install some things by repository).  I try:

gsettings reset-recursively org.nemo
killall nemo
nemo &

He successful reset my nemo settings, but problem persist. I smell something is wrong in the packages, not in the settings :(


From the Virtualbox FAQ:

  Q: Does VB support 64 bit guests?

    A: Support for 64 bit guests was introduced at version 2.0.0. If you wish to create 64 bit guests then we recommend that you upgrade to the latest version. Note that VirtualBox also supports 64-bit guest operating systems, under the following conditions:
    You need a 64-bit processor with hardware virtualization support (see User Manual chapter 1.2, Software vs. hardware virtualization (VT-x and AMD-V), page 10) and a 64-bit host operating system.
    NOTE: Since version 2.1.0, you can run 64 bit Guests while running a 32 bit Host. The prior requirement for Operating System is only for version 2.0.x. You still need the proper hardware.
    You must enable hardware virtualization through your BIOS; software virtualization is not supported for 64-bit VMs.
    Note: some HP BIOSES have a glitch, When You ENABLE VT-X/AMD-V, You DISABLE it, so do try both ways.

So I would try downloading 32bit ubuntu here - http://www.ubuntu.com/download/desktop.


Add a stanza for your eth0 card in /etc/network/interfaces with the line, this will stop network manager doing its thing.

iface eth0 inet manual


Gitlab is not sending mails but postfix works, omnibus installation (16.04) how to troubleshoot?

You should be able to update your email address with the command git config.   Use the command man git-config for details.

Check the mail logs for details what is happening with your email.  This is likely /var/log/mail.log.  The command mailq should list any email messages that has been accepted for delivery, but not yet delivered.


Startx take me root@hostname prompt with high video but no gui

You don't need sudo for startx. Just run startx /path/to/your/desktop-environment. For example, I run startx /usr/bin/openbox or startx $(which openbox).

On Ubuntu by default you don't have .xinitrc file, but if you want to run a specific desktop environment, you'd have to create one. For instance, on my Arch Linux install in virtual box I have .xinitrc file, which has exec /usr/bin/blackbox, thus everytime I run startx command it automatically launches blackbox desktop.

A note of caution: if you start unity with startx unity it will be missing top panel indicators, hence I suggest you start lightdm login screen first, and then login into unity.


Mcrypt extension is missing in 14.04 server for mysql

Try just doing this:

sudo php5enmod mcrypt

And then:

sudo service apache2 restart

I have installed fresh Ubuntu 14.04 (desktop version) to my computer. This way works for enabling mcrypt that was already installed.


The balsa email client can be installed directly in Ubuntu.

First Enable the Universe repository then enter the folowing

sudo apt-get install balsa

In  Precise (12.04) the version is 2.4.11-1
and in Quantal (12.10) it's 2.4.12-1


Run e2fsck automatically to fix all errors during boot with Samsung SSD 850 EVO 500GB

From the comments...

I've found that Windows EXT2/3/4 drivers can cause corruption on Ubuntu partitions.

The user had Paragon Ext2Fsd 0.69.1035-09.14 installed, and has now uninstalled it.

I suspect that will take care of the problem.


Ubuntu 18.04 5.1 front speakers not working

Looks like your system tries to play in 3.1 surround mode.

Try to install PulseAudio control panel:

sudo apt install pavucontrol

It gives you more options. Maybe there is an option to choose 5.1 surround.


VT-x is enabled, but ubuntu 18.04 doesn't show it

I had this same exact problem. It happened after upgrading from ubuntu 16.06 to 18.04. Both virtualbox and vmware 15 started having issues where virtualization was not detected. I didn't change the BIOS and virtualization was enabled (I double checked). cpuinfo also showed that virtualization was enabled.

Here is how I fixed it. The idea was to force the bios to wipe its settings and then re-enable virtualization... maybe something got corrupted when ubuntu tried to install its key in the EFI partition.

Open the BIOS and restore to defaults. In my case, I had a choice
between two different defaults one for XP and Win 7 and one for new
OSes (aka Secure boot settings). I restored to the Win8 and above
settings
Reboot
Enter the BIOS again and enable Virtualization and Disable Secure
boot (vmware modules wont load with it on unless you sign them your
self).
Now vmware worked.

Good luck!


Actually, you are getting the right kernel name using %k and it is passed to the script.
However, your rule condition is blind SUBSYSTEM=="usb" , it filters other device nodes other than the ones you want (partition devices).

Take a look on UDEV manpage, like the difference SUBSYSTEM=.. vs SUBSYSTEMS=.. , use udevadm info -a .. to get more info for condition.
You may use this simple one

..,KERNEL="sd[a-z][0-9]*",SUBSYSTEMS=="usb",..


wubi boots into grub after 12.04 install

I'm not certain that this will work with WUBI but it works with regular installs.

Boot from your live CD or USB.  On the splash screen click try Ubuntu without installing.

Open the home folder with he launcher.  To the right of the window that opens you will see your hard disk listed as "(xx)GB Filesystem".  When you open that filesystem you will be able to see all the folders in the hard drive.  One of the folders will say "home" if you can see the Wubi files..  when you open that file you will see your username, open that file and all your personal files should be right there.

If this works just save the files to a usb then you can reboot into windows and use the "Add Remove Programs"  to uninstall Wubi.

Just make sure that when you do a full install you  select the option to "install alongside Windows"  if you select the other one it will wipe your Windows installation.

The complete directions form Ubuntu's website are here....Installing Ubuntu Desktop

I have to add here, if you boot Ubuntu from a USB you will need another USB to save your files to, the USB with Ubuntu installed on it will not be accessible while you are booting from it.

{edit} I just stumbled across this answer to a similar question, it tells you how to attempt repairs of you Wubi install if you want to try that.  https://askubuntu.com/a/130440/65969 {edit}


The line should read:
deb https://dl.winehq.org/wine-builds/ubuntu/ bionic main

That's in /etc/apt/sources.list unless you made a separate file in /etc/apt/sources.list.d/

SO after you get the sudo issue resolved, remove the "artful" reference.


Cannot set LC_ALL and LC_CTYPE Ubuntu 14.04 LTS

To set LC_CTYPE="el_GR.UTF-8", you need to install the language-pack-el-base package which contains the necessary translation (.mo) files for Greek language:

sudo apt-get install language-pack-el-base


Trying to fully reinstall new version of Ubuntu

So what you have probably done is you have encrypted your partition with LUKS (which is why it asks you for a password and cannot mount the partition on boot the "normal way" via grub).

If you don't need to access the old ubuntu system and you can simply overwrite everything.

run Ubuntu USB,
choose "try ubuntu without installing"
fire up GpartED application.
Once you open it, re-format the "old ubuntu" partition to ext4 again.

This way you'll be able to restart from USB drive and install fresh ubuntu on it.


Install Ubuntu 18.04 alongside Windows 10 from live USB in Lenovo IdeaPad 330

The BIOS is skipping the Ubuntu Disk option at the top and going down to the Windows 10 Boot Manager 2nd option instead. Some BIOSs have not one but two options for USB flash drives in the Boot priority menu of the BIOS. One option is for UEFI USB and the other option is for Legacy or non-UEFI USB. Try selecting the other USB option (if there is one) in the BIOS Boot priority menu. You can also switch from BIOS mode to UEFI mode after you installed Ubuntu: Unable to boot into Windows after installing Ubuntu, how to fix?. Comment if you need additional help for your specific situation with dual booting Ubuntu 18.04 and Windows 10 on a Lenovo laptop.

Adding the nomodeset parameter to the kernel boot options instructs the kernel to not load video drivers and use BIOS mode instead until X is loaded. This answer has instructions for how to enable the nomodeset kernel boot option.

When you get to the Welcome screen that is shown in your question, click the Install Ubuntu button to start installing Ubuntu 18.04. If you want to dual boot Ubuntu 18.04 and Windows 10, select the Install Ubuntu 18.04 alongside Windows 10 option when you get to the Installation type screen of the Ubuntu installer. If you want to erase Windows 10 and install Ubuntu 18.04 (single boot) select the Erase Windows 10 and install Ubuntu 18.04 option instead.


14.04 Ubuntu black borders, black terminal

I Fixed it by Re-installing the Nvidia Drivers,

Here the link.. Hope help you.. How to Install Nvidia Drivers.


ubuntu installation -ram allocation-i feel my os slow

manually allocated swap space of 21 GB

This is  a bit of an overkill. Swap's purpose is to assist RAM, and usually the same size of swap as ram is enough, especially in your case where you have 4GB of RAM. Big swap size is necessary on machines with low ram, not in your case.

  the system info after installation shows memory:3.8 GB and disk
  space:72 GB

Here's the thing about *nix type systems : since hard drives are divided into blocks of 512 bytes,, *nix system report size as calculated from number of those blocks. Humans think in power of 10, computers - in power of 2, so if you see your memory and hard drive space being reported somewhat different, don't be surprised. Here's an example: If I do df -h, where -h is human readable size (as calculated with powers of 2 ), I get 145G . With df -H (which is also human readable, but with powers of 10), I get 156G. The first one makes more sense from engineering / computer science point of view, because it's closer to actual, physical organization of hard drive memory. So the confusion about the size might come from the fact that installer looks at hard drive space differently than the actual installed system.

As for the ram 4 GB vs 3.8 GB, again, RAM will always be reported less, because computer science 101 tells us that there's always some reserved memory , for instance - for peripherals like keyboard, screen, etc. If the difference would be large, that's where you'd have to start worrying.

  I feel my os is slow. What should i do?

There's plenty of material on this site and others on how to improve the performance - you just need to use your googlefu a little, and as bodhi already pointed out, lag often comes from graphics. I suggest you switch from default Unity desktop to something lighter. For instance , Gnome or Cinnamon. My personal favorites are openbox, blackbox, and gnome. They're minimalistic, but they do justice to the performance.


How to save live log bash input to a file?

Use the built-in command history:

history -w hist.txt

will save the current history into file hist.txt.

If you have write permsiions to the appropriate directory you could do something like:

history -w /var/www/html/latest_history.txt

Then your students could access it in a browser: http://teachers.ip.address/latest_history.txt


For some reason I tried to reinstall it again some times and now it worked.
I think i forgot to purge the package the last time and it tried to reinstall the package that was already downloaded.
So I ran sudo apt purge python3-venv and sudo apt install python3-venv and it worked.


I have Ubuntu 10.10 and I am trying to upgrade to newest LTS

You can't jump from 10.10 to the last LTS version (16.04), not to mention you are running an outdated version which has no support at all.

Get a backup of your files, do a fresh install of 16.04.

And here is a guide to update Ubuntu.


I don't know how your specific provider is set up to work, but the VPN connection is normally set up to route all traffic through the VPN.

Check if your ISP modem is the default gateway.

$ ip route
default via 192.168.0.1 dev wlo1  proto static  metric 600

where 192.168.0.1 is my modem IP in this case. The VPN connection (tun0) should also be in this table if you've connected successfully.

Delete the default gateway, and if that fixes the IP issue (or if you can't connect at all), it means your traffic was being routed through your ISP.

$ sudo ip route del default via 192.168.0.1

You can add it again with

$ sudo ip route add default via 192.168.0.1


Detect interface promiscuous mode in my network

Pretty unclear question.

You can see if a PC is in promiscuous mode on a LAN, go here: How to find out that a NIC is in promiscuous mode on a LAN?

If you're trying to get in promiscuous mode using python on Linux try this:  Python Sockets: Enabling Promiscuous Mode in Linux

Other than that if you're trying to find an IP/MAC address, PC name, etc. through a LAN even if a user is in promiscuous mode, then I'd have to look more into it, otherwise trying asking or looking around on Stack Overflow.


"stop-timeout is not an integer" when generating snap package - why?

snappy build and the tool that reviews the resulting snap are provided in two different packages developed in separate source repositories but they need to be kept in sync, the most likely cause of this particular issue is that they are indeed not in sync. Getting the latest versions of these packages will most likely fix this.

If you've done a release upgrade the ppa where the tools are published probably got disabled, you can simply add it again by running

sudo add-apt-repository ppa:snappy-dev/tools

Then update and upgrade

sudo apt-get update
sudo apt-get dist-upgrade

Replace apt-get for apt if you prefer using it.


Solution?

I don't think Ubuntu Restricted Extras Won't Work.

I think the problem is 'Ubuntu Software [Center]'. Maybe the following link (within AskUbuntu) can help you solve that problem.

Ubuntu 16.04 software center not working

Workarounds

But there are work-arounds.

Continue to use the command line tools,

to keep Ubuntu up to date

sudo apt update
sudo apt full-upgrade

to keep Ubuntu clean (remove unnecessary program packages)

sudo apt autoremove
sudo apt autoclean
sudo apt clean

to install a new program package program-package

sudo apt install program-package

Use the Synaptic Package Manager

Install it

sudo apt install synaptic

and start it from 'Dash', after clicking on the Ubuntu icon at the top left corner and typing syn.

There is a learning curve, but Synaptic is reliable and powerful. Later on, when 'Ubuntu Software' starts working again, you might stay with Synaptic, because you know it and like it :-)


Try:

$ awk -F, '{sub(/T.*/,"",$3);print}' OFS=, file
5,test,2019-09-27,closed,harshavardhanc,2019-09-27T11:09:28Z,2,2
4,test,2019-09-26,closed,harshavardhanc,2019-09-26T16:57:02Z,1,1
3,test,2019-09-26,closed,harshavardhanc,2019-09-26T16:54:55Z,1,1
2,test,2019-09-26,closed,harshavardhanc,2019-09-26T16:55:19Z,1,1
1,test,2019-09-26,closed,harshavardhanc,2019-09-26T16:47:25Z,1,1

Notes:

Your file is comma separated.  Thus, you need to specify -F, so that, on input, each line is divided into fields based on commas.
Since you want a comma-separated file on output, we also need to specify OFS=,.
The first argument to sub (or gsub) should be a regular expression not a string.  In our case the regular expression should match T and everything after.  .* means everything after.
Since awk programmers often pride themselves on conciseness, you might want to remove print (too long-winded) and instead use:

awk -F, '{sub(/T.*/,"",$3)} 1' OFS=, file


Any way to change lightdm unity greeter background without changing current config files?

In Ubuntu 12.04, it is possible to do this programmatically via the dconf database for user lightdm e.g.

sudo -u lightdm dbus-launch --exit-with-session \
gsettings set com.canonical.unity-greeter background /usr/share/backgrounds/Tie_My_Boat_by_Ray_García.jpg

The change takes effect when lightdm is restarted.


Dependency error when installing gcc-multilib

I managed to install gcc-multilib but with a downgrade for some components. Don't know if it is a good solution but it worked.

My solution was to install gcc-5-multilib and press n when aptitude asked for the first time "Accept this solution?" and Y on the second time. Output:

sudo aptitude install gcc-5-multilib
...
The following actions will resolve these dependencies:

      Keep the following packages at their current version:
1)      gcc-5-multilib [Not Installed]
2)      gcc-multilib [Not Installed]
3)      lib32gcc-5-dev [Not Installed]
4)      libx32asan2 [Not Installed]
5)      libx32cilkrts5 [Not Installed]
6)      libx32gcc-5-dev [Not Installed]
7)      libx32gcc1 [Not Installed]
8)      libx32stdc++6 [Not Installed]
9)      libx32ubsan0 [Not Installed]

      Leave the following dependencies unresolved:
10)     libc6-dev-i386 recommends gcc-multilib

Accept this solution? [Y/n/q/?] n
The following actions will resolve these dependencies:

     Remove the following packages:
1)     gcc-6-base:i386

     Keep the following packages at their current version:
2)     gcc-multilib [Not Installed]

     Downgrade the following packages:
3)     gcc-6-base [6.3.0-18ubuntu2~16.04 (now) -> 6.0.1-0ubuntu1 (xenial)]

     Leave the following dependencies unresolved:
4)     libc6-dev-i386 recommends gcc-multilib

Accept this solution? [Y/n/q/?] Y
The following packages will be DOWNGRADED:
  gcc-6-base
The following NEW packages will be installed:
  gcc-5-multilib lib32asan2{a} lib32atomic1{a} lib32cilkrts5{a} lib32gcc-5-dev{a} lib32gomp1{a} lib32itm1{a} lib32mpx0{a} lib32quadmath0{a} lib32ubsan0{a} libc6-dev-i386{a} libc6-dev-x32{a}
  libc6-x32{a} libx32asan2{a} libx32atomic1{a} libx32cilkrts5{a} libx32gcc-5-dev{a} libx32gcc1{a} libx32gomp1{a} libx32itm1{a} libx32quadmath0{a} libx32stdc++6{a} libx32ubsan0{a}
The following packages will be REMOVED:
  gcc-6-base:i386{a}
The following packages are RECOMMENDED but will NOT be installed:
  gcc-multilib
0 packages upgraded, 23 newly installed, 1 downgraded, 1 to remove and 0 not upgraded.
Need to get 11,1 MB of archives. After unpacking 46,1 MB will be used.
Do you want to continue? [Y/n/?] Y
...

And afterwards I was able to install gcc-multilib:

sudo aptitude install gcc-multilib
The following NEW packages will be installed:
  gcc-multilib{b}
0 packages upgraded, 1 newly installed, 0 to remove and 0 not upgraded.
Need to get 1.212 B of archives. After unpacking 8.192 B will be used.
The following packages have unmet dependencies:
 gcc-5-aarch64-linux-gnu : Conflicts: gcc-multilib but 4:5.3.1-1ubuntu1 is to be installed.
 gcc-multilib : Conflicts: gcc-5-aarch64-linux-gnu but 5.4.0-6ubuntu1~16.04.9cross1 is installed.
                Conflicts: gcc-5-aarch64-linux-gnu:i386 but it is not going to be installed.
The following actions will resolve these dependencies:

     Remove the following packages:
1)     gcc-5-aarch64-linux-gnu
2)     gcc-aarch64-linux-gnu

Accept this solution? [Y/n/q/?] Y
The following NEW packages will be installed:
  gcc-multilib
The following packages will be REMOVED:
  binutils-aarch64-linux-gnu{u} cpp-5-aarch64-linux-gnu{u} cpp-aarch64-linux-gnu{u} gcc-5-aarch64-linux-gnu{a} gcc-5-aarch64-linux-gnu-base{u} gcc-5-cross-base{u} gcc-aarch64-linux-gnu{a}
  libasan2-arm64-cross{u} libatomic1-arm64-cross{u} libc6-arm64-cross{u} libc6-dev-arm64-cross{u} libgcc-5-dev-arm64-cross{u} libgcc1-arm64-cross{u} libgomp1-arm64-cross{u} libitm1-arm64-cross{u}
  libstdc++6-arm64-cross{u} libubsan0-arm64-cross{u} linux-libc-dev-arm64-cross{u}
0 packages upgraded, 1 newly installed, 18 to remove and 0 not upgraded.
Need to get 1.212 B of archives. After unpacking 60,8 MB will be freed.
Do you want to continue? [Y/n/?] Y


Ubuntu 12.04.2 Dual boot UEFI Windows 8 Preinstalled CX21903W Ultrabook

The link on UEFI boot is pretty good, but most do not discuss the additional issues that Ultrabooks have. You have Intel SRT which (somehow) uses RAID to access the SSD. You have to turn off Intel SRT, and  remove the RAID meta-data from both drives to get Ubuntu to install in UEFI mode.

Some computers just will not install in UEFI mode. They have (not per UEFI standard) modified UEFI to only boot Windows efi file. But there are work arounds for that. Boot-Repair can convert a BIOS install to UEFI and if needed rename files as a work around.

Ultrabooks also have dual video and if in nVidia mode you need nomodeset. Some allow you to set it to Intel video only but many are just automatic. Then you need to install bumblebee to use dual video.

Intel Smart Response Technology

http://www.intel.com/p/en_US/support/highlights/chpsts/imsm

sudo dmraid -E -r /dev/sda
sudo dmraid -E -r /dev/sdb

When you reimplement Intel SRT it will work again.

Bumblebee:

https://wiki.ubuntu.com/Bumblebee

http://www.webupd8.org/2013/04/set-up-bumblebee-with-bumblebee.html

More info here:

http://ubuntuforums.org/showthread.php?t=2147295


If there is a SMTP server running on your system, first look up its process id:
sudo fuser -4uv -n tcp 25 (assuming it is listening to port 25) If this remains blank, there is no SMTP server. If there is, use ps -ef | grep <PID> to find its command line. Replace <PID> with the process id you found with the fuser command.


I figured out the solution for this problem.
It has nothing to do with the program configuration, but the way I was saving the markdown files.
Given that it is an Rmarkdown file, I need the .Rmd extension.
I was just using the .md extension which didn't allow me to knit the file before.


To open the folder as root in the grapical file manager, run the following command:

gksu nautilus /etc/apt/

If you wish to do your operations from the command line, the following command enters the intended directory and makes you root. However, you would be better off using the first method above.

cd /etc/apt; sudo -i


Performance issues on Lenovo T460s (seems like graphics problem under metacity)

My T460s shipped with the graphics memory turned down to 256MB in the BIOS setup. Go in there and crank it up to 512. When I did that, the UI sluggishness I experienced went away.


Meaning of directory redirection using dot operator

2 directories up ,  / is part of the path, so just as

/home/your_username

.. = one directory up

../.. = two directories up

../../.. three - etc

See also relative vs absolute path

If you start from / , it is an absolute path, /home/your_user for example

If you start from your current directory, without a / in front, the path is relative to your current directory. So , in your home directory, Desktop == /home-your_user/Desktop.

See http://www.linuxnix.com/2012/07/abslute-path-vs-relative-path-in-linuxunix.html or similar


How do I find the information I need to diagnose a slow wireless problem?

Usually if you go to your computer manufacturer's web site and search for the model number that you have, there's a page of hardware specifications that would have this info.

For example, if you scroll down to Wireless, this page says that a Dell Inspiron 14R has an Intel® Centrino® Wireless 2230, 2x2 bgn + Bluetooth:

http://www.dell.com/us/p/inspiron-14r-5421/pd?oc=fncwy78s&model_id=inspiron-14r-5421#TechSpec

If that doesn't work, it also might be in the BIOS.


Question 1

It's pretty likely that all the files are in /home/USERNAME since it's the default save location for all those. Although an app (or you) may have chosen to save some files elsewhere.

Question 2

Sure, it's installed at /dev/sda1 - you can figure that out by looking at the partition setup image you gave, since / (the root of the filesystem, where Ubuntu installs to) is mounted at /dev/sda1.


How to recover after unsuccessful upgrade to 18.04 from 17.10?

It may not help you here, but it looks like you'll have to restore from a backup. Next time, I'd recommend you utilise the inbuilt backup program in ubuntu for your personal files, and timeshift (or similar) for system files.

You can find timeshift here: http://www.teejeetech.in/p/timeshift.html

That way, if you system fails to boot, you can boot from a live CD and restore from a backup.


I finally found a solution.

for anyone who faces a similar problem, this is what I did in the end (and what I think was what solved it :)):

sudo apt-get install build-essential linux-source
sudo apt-get install linux-headers-`uname -r`
sudo apt-get install nvidia-current
sudo depmod -a
sudo modprobe nvidia_current
sudo gdm restart

now the system works like a charm.


Trouble creating a default desktop for new users 18.4.03

Ok, so I was able to solve the problem. It was very simple but want to post here. My confusion with the /etc/skel was that I thought that putting files in there would only put the files in the new users Home directory.

The solution: Create a Desktop dir in /etc/skel and name it Desktop. Then simply copy all of the directories you want on the new users desktop into that directory


I want to install Ubuntu 13 on the last drive, along side Windows 7 via USB stick

I have solved this problem myself ,it was not a problem  actually ,  jus not understanding SDA drives and all . So mentioning here to what I did to make it simple-

In windows I deleted the last drive in which I supposed to install ubuntu 13.04.

Then changes the Boot Priorities to USBand reboot.

Then started installation normally till it asks for Where to install like shown below -

4.Then after clicking the option Something Else , it was showing all my partitions along with Free Space
5.I used Free Space where I wanted to install it without afecting others and Entered the values for making SWAP Area as 4gigs as I am having 4gigs of ram ,and rest all for root directory(/) where everything is about to be installed.
6.After everything completes , I got what I want as shown below-

7.Remember in my question I was asking to do so with 17 gigs of partition , and in the picture its 47gigs , because i have changes the partition size for that, Its better now.


Ubuntu 20.04 LTS Screen Flickering Lenovo Yoga S740 Geforce MX250

It looks like I solved the problem. I figured out that the screen flickering only appears when on battery. Uninstalling tlp solved my problem. It might have been just a tlp settings problem and I tried a couple of settings but none helped, so I uninstalled it.

Uninstall tlp:

sudo apt-get purge tlp

Cheers
Kait


To run a dialog box as a result of clicking a button in quickly using python

In addition to defining the functions to be called, you must connect the signal of the button.
The easiest way to do this is to define a dict with a mapping from the names to the handlers and then pass it to the Gtk.Builder.connect_signals() method. Read here for more help.


How to update Flash? (version numbers don't match)

Edit: Flash version numbers don't match

I just noticed that the plugin page in Firefox told me that the version I had installed was vulnerable though I had the latest version of the of flashplugin-installer installed and it matched with the version number of the plugin for Linux on Adobe's site.

However what I must have ignored: the version number for Flash in Firefox was lower!

After running sudo apt-get install --reinstall flashplugin-installer it re-downloaded Adobe Flash and all version numbers matched up without restarting Firefox.

You should be able to find an entry in your USC history or the apt log when the package was updated the last time. Just run the update-manager from the dash to search for new packages and install them.

Alternatively you could remove the package and reinstall it, here is the corresponding page for the package: https://apps.ubuntu.com/cat/applications/flashplugin-installer/

It should have been updated a while ago unless there is an issue with the repository that your installation uses. Here is a description to test and change the repository server.


how to copy file or directory to remote machine using sftp

This command

put l1/l2/file.tar.gz  /rl1

copies file to the remote root directory (/), which is probably not what you want (and as a normal user, you certainly don't have access for this). You probably want to copy the file to your home directory (~) like this:

put l1/l2/file.tar.gz  ~/rl1

or current directory

put l1/l2/file.tar.gz  ./rl1

or

put l1/l2/file.tar.gz  rl1

This should work for you.


libpng16.so.16 not found - how to get it?

Try installing the libpng-libary Version 16:

sudo apt-get install libpng16-16


Depending on how you created the USB boot drive, it will be read-write or read-only.

Cloned drive

A cloned drive created with the 'Startup Disk Creator' in Ubuntu 16.04 LTS or newer versions, has a hybrid iso9660 file system, which works both in DVDs and USB pendrives (and memory cards), but it is read-only by design, so you cannot edit anything in it. Also 'Disks' alias gnome-disks, and 'mkusb' (when cloning and creating live-only drives) make USB drives with a hybrid iso9660 file system.

Extracted drive

An extracted drive, for example

a persistent live drive created with mkusb or
a live-only drive created with Rufus,

can be edited. You can add nomodeset and other boot options to the boot configuration file, so that they will persist (survive to be used in the future). Edit boot/grub/grub.cfg in partition #3, 'usbboot' for mkusb. You may need to boot from another drive in order to mount the FAT32 file system read-write for Rufus.

New tips to make your USB boot drive with Ubuntu 19.10+

You can edit your binary iso file and replace the cosmetic boot options quiet splash with the boot option 'persistent  ' or 'nopersistent' (the strings contain 12 characters, so the replacement can be done without any offset in the following part(s) of the iso file. You can do it with sed

sed 's/quiet splash/persistent  /' standard.iso > persistent.iso
sed 's/quiet splash/nopersistent/' standard.iso > nopersistent.iso

and clone the modified iso file, or flash directly with

sed 's/quiet splash/persistent  /' standard.iso > /dev/sdx
sed 's/quiet splash/nopersistent/' standard.iso > /dev/sdx

where x is the device letter for the USB pendrive.
You can do it with a safety belt using mkusb-minp
It is more convenient and also safer to use mkusb-plug for the whole process including the sed commands, and there is a graphical user interface.
You can do it yourself with an extracting method and get whatever combinations of boot options, that you like, according to this link


Smallest ubuntu install : ubuntu-minimal, ubuntu-server..etc

Don't think there is something that small. Ubuntu Core is probably the smallest of the images available, and still you get python and APT framework, and more stuff deemed essential. Here is an installation example.

PS:There is no Ubuntu Core for 14.10.


How can I update KDE Plasma to 5.13 on Kubuntu 18.04?

https://community.kde.org/Neon/BionicUpgrades isn't meant for users of Kubuntu. It's meant for users of KDE neon which isn't supported at Ask Ubuntu.

If you're on Kubuntu 18.04, please note that Plasma 5.12 is regarded as LTS which means you'll get updates only to 5.12 and you won't get updated to Plasma 5.13 or higher during the life of Kubuntu 18.04.

Please monitor https://kubuntu.org/news/ or  https://www.kubuntuforums.net/forumdisplay.php/30-Kubuntu-Announcements for news on availability of Plasma updates for Kubuntu 18.04..


16.04 Desktop hangs after period of inactivity

My issue was with a PC running Ubuntu 16.04.1 LTS that after leaving it for several minutes, screen would go dark (a little different from  your case), but the PC is not turned off, not suspend or hibernate, but I could not wake it up with the mouse or keyboard.  I needed to turn off / turn on the PC to solve this issue.  It seems that this issue has always been there since the PC was upgraded to 16.04.

I tried changing power settings, and updating kernel.  But these did not work.

What worked for me is I changed the System Settings->Brightness & Lock, and set the Turn screen off when inactive for Never.  Then I changed lock to OFF.  So now I do not see this issue, and do not need to reboot the machine every time I step away.


Samba Client and Windows 10 Home - "NT_STATUS_LOGON_FAILURE"/"Access denied"

THE REAL PROBLEM:

As you can see in this image...

...my user "eduardo" is actually "alldocube"... As seen in the print above the way the user "eduardo" ("alldocube") is in the system caused a huge confusion! Actually I couldn't understand how it happened...

SOLUTION:

So the only thing that needs to be done is to share (Properties > Sharing) drive "D" for the user "alldocube" (in my case) and give permissions (Properties > Security) on drive "D" for the user "alldocube".

To access the sharing using Linux open the file browser (Dolphin in my case) and in the path field enter smb://WORKGROUP\<YOUR_USER>@<SERVER_IP>/<SHARE_NAME> (smb://WORKGROUP\alldocube@192.168.0.5/D in my case).

[Ref.: https://answers.microsoft.com/en-us/windows/forum/windows_10-networking/samba-client-and-windows-10-home/a7502032-240a-4fc8-a756-132d46831adf?tm=1568998388625&auth=1&page=2 ]

Thanks! =D


Launcher Icons Revert to Default Upon Login

Try installing the libdconf0 package. Installing it seems to have done the trick for the filer of this bug report. You can do this through the Software Center. If it doesn't show up, click the "Show technical items" link at the bottom.


"nvidia-304-updates" vs "nvidia-304" (and similar)?

You can research which Nvidia driver you need at: Unix Drivers | NVIDIA

If you click on the 304 link, you find information about the driver and the Supported Products tab lists the cards that need this driver. Find your card and you will know which driver you need.

If you look up the package names in Software Center or Synaptic, you will find the url to that same Nvidia page in the package description and you will see the driver version that the Ubuntu package is providing.

The difference between nvidia-304 and nvidia-304-updates is the Nvidia version (and perhaps the version of Ubuntu patch of that number) that it points to.

In general, the updates package will point to the newest revision by Nvidia and the package without updates in the name will point to the previous stable version. The exact relationship, however, may vary by Ubuntu release.

For example, at the Nvidia driver page, you can see that 304.108 is called "the Latest Legacy GPU version". It was released August 8, 2013. A link to the archived drivers shows that the previous version was 304.88, released on April 2, 2013.

So, in 13.10, 304-updates currently refers to 304.108 and 304 currently refers to 304.88

In general, you will want the updates version since it will point to the newest driver. But exactly what you need depends on the exact model of your card since the newest features in the driver may not work with your card.

In addition to the Nvidia number, the Ubuntu developers patch the driver, so the actual binary version to install contains the Nvidia number followed by the Ubuntu version number.

In 13.04 and 12.04 both packages refer to 304.88, but to different Ubuntu-patched versions. For example, in 13.04, 304 is 304.88-0ubuntu1 and 304-updates is 304.88-0ubuntu2. Information about the Ubuntu version can be found in Launchpad.

So you see that the actual binary file that the nvidia-304 and nvidia-304-updates packages will provide to your system will change over time. You can see this easily by viewing the changelog. 304 now points to 88, before that to 84, before that 64, etc.

A little research or experimentation may be needed to determine which each driver you need and it may change over time. On my laptop with an older Nvidia card, as the version numbers changed I had to go from 304-updates to 304 because 304-updates began to point to a newer version of the driver that caused problems for my card.

A note based on comments:

These version numbers assume that you are using the versions of 304 and 304-updates provided by the standard Ubuntu repositories. It is possible to replace the standard repository for these packages with PPA's (Personal Package Archives). One commonly used PPA is xorg-edgers, which provides bleeding edge versions of the drivers. Someone may choose to use this PPA if they need or want a version of the driver that is newer than the one offered by the Ubuntu release they are using.

Here's the important point for the meaning of the 304 and 304-update packages (and others) after a PPA like that has been installed: they no longer have the same meaning. If you install 304 from xorg-edgers, 304 will now point to the newest driver provided by xorg-edgers and the relationship built into the package name structure will no longer hold. Additional Drivers will still report the the package name as 304 (because the package name hasn't changed). Nvidia-settings will report the actual version of the binary that it sees, in this case a non-standard 108. It doesn't know (or care) that the binary came from a PPA, not the standard repository.


No. You should never just edit sources.list. Use the update-manager, or if you use command line, use do-release-upgrade. You can upgrade safely from LTS editions to other LTS editions, or otherwise, you need to step via each release. Only those pathways are supported, and prevent some issues that can otherwise occur with improper upgrades.


No compatible screen mode found, blurry screen

If you can still log into a graphical desktop session, open a terminal window (CtrlAltT), else change to a tty (CtrlAltF1) and login. In the terminal, enter xrandr -q

The output should look something like this:

Screen 0: minimum 320 x 200, current 1366 x 768, maximum 32767 x 32767
CRTC connected primary 1366x768+0+0 (normal left inverted right x axis y axis) 344mm x 194mm
   1366x768       60.0*+   39.9
   1360x768       59.8     60.0
   1024x768       60.0
   800x600        60.3     56.2
   640x480        59.9

where in this case, CRTC is the output which your monitor is connected to.

Now enter xrandr --output CRTC --mode 1440x900 (replace CRTC with the correct output if necessary). The output should now have the correct resolution.

To make the changes permanent, you need to put the above command into your .xprofile file.
To do this, type nano ~/.xprofile in a terminal. Enter the line xrandr --output CRTC --mode 1440x900 (remember to use the correct output name) and save (CtrlO, Enter, CtrlX).


You might want to check out http://cloud-images.ubuntu.com/server/trusty/current/

Vagrant pulls some of its images from that site and runs them with VirtualBox by default.
http://cloud-images.ubuntu.com/vagrant/trusty/current/


Ubuntu 20.04 keyboard media keys dont not work

I have found a solution to my media keys problem on Ubuntu 20.04.1
By default the Media Play button is not set on 20.04 out of the box.
Go to Settings → Keyboard Shortcuts and move down the list to the Sound and Media section and navigate down the list to Play (or play/Pause) which will open the set key dialogue box

Once there, press the Home Page (WWW) button to set it and finish off by selecting Set


Why can't I interact with my ssh-agent? (e.g. ssh-add -D doesn't work)

NOTE: is not an answer solving the root issue. Please provide a new answer if you think you can solve the root cause. You really have to read on why my solution is just an ugly hack.

Here's an explanation on what happens at boot time, identifying the culprit.

Using KDM (or LightDM) as log in manager, an X session is spawned for you upon logging in. The log in manager allows you to select an X session (e.g. GNOME, KDE Plasma, etc.) based on those available in your system. The directory /usr/share/xsessions contains the files for each of those desktop environment installed and your user specific choice is saved in ~/.dmrc.

While the desktop environment loads after logging in, it loads all scripts in /etc/X11/Xsession.d/. On a Kubuntu 14.04 system I see /etc/X11/Xsession.d/90x11-common_ssh-agent there by default, initialising an SSH agent. As expected. Great!

In practice however we see different things. Where does gnome-keyring-daemon come from then and why is the regular ssh-agent not started? Well, the GNOME keyring is started in two ways:

XDG autostart, in /etc/xdg/autostart/gnome-keyring-ssh.desktop
As an Upstart session job in /usr/share/upstart/sessions/gnome-keyring.conf

All scripts are first checking the environment values whether they will proceed. E.g.

[ -z "$SSH_AUTH_SOCK" ] || [ -z "$GPG_AGENT_INFO" ] || { stop; exit 0; }

This makes it a sort of race condition which SSH agent is actually started. First one wins. Brace for more nasty bits.

How come it works at one machine reliably and it doesn't reliably at another? The X session upstart jobs are only started when the DESKTOP_SESSION environment variable is whitelisted for it in /etc/upstart-xsessions, handled by /etc/X11/Xsession.d/00upstart. KDM allows one to set a Desktop environment 'Default' (default in ~/.dmrc), effectively kde-plasma, but not appearing kde-plasma.

With Session=kde-plasma:

⟫ echo $DESKTOP_SESSION
kde-plasma

With Session=default in a KDE Plasma desktop:

⟫ echo $DESKTOP_SESSION
default

This is plain wrong. And you can guess now why it fails the whitelist check against /etc/upstart-xsessions.

Quick fix for running terminal session

killall gnome-keyring-daemon && eval `ssh-agent`

Conclusion

It appears that one can hit a bug with all Upstart session jobs not being started at all. Another bug prevents proper interfacing with the GNOME keyring SSH agent (or ssh-add should complain and fail). Oh I hate you, bugs.

Once I find time to do some research on what is exactly supposed to do what, I'll file the bug reports.

For now I decided to just 'use' the Upstart bug and prevent Upstart session jobs from running by setting Session=default. I'm not sure how much this breaks, but so far I haven't seen anything falling apart.

The root cause is the appearance of GNOME keyring in the first place and which should not lie to me and keep offering wrong keys.


Scripting Language That Sends GUI Events To Any GUI App

In the world of old programmers, script and GUI are two words that live in totally different worlds. That looks like a myth very well established for many reasons.
Any way, the world of web applications is throwing this tine line away, and more and more people are looking for this, and some of them point this as a new tendence.
Why not simple scripts, with simple gui's? First one to start this kind of project, BUMM...
Well, I did my shots at Bashscript, as I am a big beginner in programming. You can take a look at

xdotool

glade

gtk
and the obvius phyton advanced scripting language, which I know nothing about it. (google about this itens, they will be very helpfull whatever language you choose it)

The dialog command in bash is very nice to do some simple Gui's, I guess this is the best beggining I can point you. xdotool is a interactive mouse/keyboard tool, glade is a full program to make Gui for many languages, and gtk is a lybrary/toolkit u can use with C++ or Pỳthon I guess... Good research wait for you.


When you're ready to create the archive, do this: press ALT-F2 and type gksu file-roller. Then, enter your password.
Now, use Nautilus to connect to the FTP server.

After you've connected, go back to the Archive Manager and click the "new" button. Tell it to save the file to where you need it (in the FTP directory.)
Now, open it and add the files!

If this method didn't work for you because you couldn't access the FTP directory from within the Archive Manager, then try this alternate approach:

Press ALT-F2 and type gksu nautilus.
Making sure that the newly-created window is selected, choose "connect to FTP server" from within that window. Try what you originally were trying, but, this time, do it from within that window.

The key to both of these is to run the program as Root, incase the problem was a system permission limitation on your end. If the FTP server is rejecting write access, then there's nothing you can really do.


How can I apply a LADSPA plugin to a PulseAudio stream?

Adding a LADSPA plugin to pulseaudio is done with module-ladspa-sink.
We install this module as an output sink where we can define the processing module and are able to send the processed signal to this newly created sink.
Load the LADSPA module:
This module can be loaded at runtime with:
pacmd load-module module-ladspa-sink sink_name=<yourname> master=<sinkname> plugin=<plugin> label=<label> control=<option1>,<option2>,[...]

The name of the master sink can be read with the following command:
 pacmd list-sinks

Give a name for the processed sink as it will appear in the output list in sink_name. All further options depend on the plugin we use (see example below).
To apply the LADSPA processor we choose the output sink from "Sound Settings..." and can now listen to the processed stream. Control options can not be altered at runtime.
Unload the LADSPA module:
We  will have to unload the module and load it again for different options. To find the module index for unloading we may issue:
 pacmd list-modules

To unload a module we either restart the sound server with pulseaudio -k or we unload the module with it's index number #:
pacmd unload-module <#>

See also the reference wiki from pulseaudio.
Load LADSPA module at startup:
After having found the appropriate options we may want to run it per default. This can be done by including it to the /etc/pulse/default.pa configuration file to be loaded by the daemon on startup:
.ifexists module-ladspa-sink.so
.nofail
load-module module-ladspa-sink <options>
.fail
.endif

Example:
This is an example of one special case to give you an idea on how to do it. In this example we want to apply a pitch shift to our sound output using the TAP-plugin tap_pitch (tap-plugins ). For this plugin the additional options needed for loading to Pulse Audio are the following:
plugin=tap_pitch # as from /usr/lib/ladspa/ without .so
label=tap_pitch  # defines which label of a plugin to use

To find the appropriate control options we browse to the plugin documentation (here TAP plugin pitch shifter). There we find a nice table of four relevant controls we have to apply in the control= command:
control=<semitone>,<rate>,<dry>,<wet>

Leaving an option empty will use the default in this case.
Thus the following command will apply a pitch shift of one octave downward from my master sink alsa_output.pci-0000_00_14.2.analog-stereo (replace with your sink) to the output sink ladspa_out with a semitone shift of -12, that is a rate shift of -50%, and with a dry (unprocessed) mixer level of -90dB, and a wet (processed) level of 0dB.
pacmd load-module module-ladspa-sink sink_name=ladspa_out master=alsa_output.pci-0000_00_14.2.analog-stereo plugin=tap_pitch label=tap_pitch control=-12,-50,-90,0

For some plugins the documentation may be not be complete, or appropriate setting will need quite some experimenting until they are right.


Make sure to partition the drive before you install Ubuntu. I unfortunately made the mistake once and wiped my entire hard drive. I highly recommend from personal experience that you get gparted or use the built in partitioner in the Ubuntu install usb to partition at least 15GB for Ubuntu. Do a Google search for "Dual boot Ubuntu alongside Windows" to find explanations more in-depth than I could tell you.
Here is a good guide on how to dual boot Ubuntu alongside Windows.
http://www.everydaylinuxuser.com/2013/09/install-ubuntu-linux-alongside-windows.html
Hope it helps!


file=$1 assigns variable file the first paramter of your script.

If you run you script like  this:

script.sh blablabla

Then blablabla will be the file name that the script will check if it exists.

The last line seems wrong to me. It should be

touch $1

if I understand the script.


You can just enter the port number in the port number input rather than the server box. Make sure you close Evolution after entering the new port number and restart it to take effect.


You need to update Wine to 1.7.

Run this 3 commands to do so:

sudo add-apt-repository ppa:ubuntu-wine/ppa
sudo apt-get update
sudo apt-get install wine1.7 winetricks

You don't need to reinstall PokerStars, just install wine 1.7 and run PokerStars again.

Good Luck!


The tr archive server for ubuntu is throwing the error
Change the http://tr.archive.ubuntu.com/ubuntu in /etc/apt/sources.list to http://archive.ubuntu.com/ubuntu.
Do an
apt-get update

and then try to install
apt install nasm

Hope this helps.


PhpStorm theme installation folder not found

ls -a ~

There should be ".WebIde70" directory in there. You should next download some-theme.xml from http://www.phpstorm-themes.com/ to your Downloads folder.

cp ~/Downloads/some-theme.xml ~/.WebIde70/config/colors

When you open PhpStorm next time you should go to File->Settings->IDE Settings-> Editor->Colors & Fonts and change the theme from the drop down menu.

If you have PhpStorm8:

cp ~/Downloads/some-theme.xml ~/.WebIde80/config/colors


Do Ubuntu PC programs work on Ubuntu tablet?

Yes and no.

I don't know what you mean by tablet but probably your Tablet would have an Arm processor so its repository will likely be the same of Ubuntu Arm (https://wiki.ubuntu.com/ARM).

As you can see on their page they say "Much of the application porting is complete" so probably you can expect to run a lot of the software you love and use on your Intel (or AMD) desktop.

Of course if your program hasn't been ported for ARM it won't be so easy to see it running on your tablet.

From Ubuntu's site:

Ubuntu on ARM
Ubuntu on ARM provides a platform for the best collection of open-source applications and proprietary applications available on ARM. Core applications include Firefox 3.5, Chromium, Evolution email client, the Rhythmbox media player and OpenOffice.org. Highlights of the ARM distribution include DeviceTree support and ARM v7 Thumb2 optimisations and removal of unused packages, creating an optimised desktop. Ubuntu on ARM is available to OEMs with the Ubuntu Desktop or Ubuntu Netbook user experience, providing OEMs flexibility to choose the user experience that best meets the needs of their target markets.

Here's a document too


What is the least information that the default keyring can hold?

The keyring has more than just WIFI passwords, any program can store passwords there.
Some programs that store passwords in the keyring by default:

chromium
vlc (network streams)
nextcloud client
nautilus for network connections (e.g. smb passwords)
gpg
ssh-agent
Ubuntu online accounts
...

By default, the keyring gets unlocked when you login but it won't grant any program sudo access.
Run seahorse (GUI tool) to see what is saved there.

To disable automatic unlock when you login, remove these lines from files in /etc/pam.d/:
auth    optional        pam_gnome_keyring.so
session optional        pam_gnome_keyring.so auto_start

But I would suggest not to do that, rather tell your programs not to use the keyring.


Add a multi-line text with one variable to multiple files using bash

You should be able to do that with a simple shell loop over a here-document. For example, given files 001.txt to 005.txt of the form

$ cat 003.txt
=== START OF ORIGINAL FILE 003 ===
stuff
more stuff
even more stuff

then

for i in {001..005}; do cat - "$i.txt" <<EOF >tmpfile
+++ HEADER $i +++
new stuff
more new stuff

EOF
mv tmpfile "$i.txt"
done

results in files of the form

$ cat 003.txt
+++ HEADER 003 +++
new stuff
more new stuff

=== START OF ORIGINAL FILE 003 ===
stuff
more stuff
even more stuff

and so on.


Problem with cluster installation with cloudera manager

The configuration in /etc/hosts that removed the warning for me was

#127.0.0.1       localhost
192.168.13.27  cloudera2

localhost is commented and I only use the machine ip
the machine hostname is also cloudera2

if you don't want to expose your machine, then use only

127.0.0.1  cloudera2


Packard Bell Easynote NJ65 not saving gamma Setup

Boot into recovery root console thingy. Run:

X -configure
cp /root/xorg.conf.new /etc/X11/xorg.conf

reboot and you should now have an xorg.conf to configure :)


setup.py is the file that will handle the installation of your packages. you execute it by prefixing it with the python command and by passing install as a parameter, hence, the "python setup.py install".
.pyc are the compiled bytecode of your python code (for faster execution). So if yoou are moving your code, I suggest you take the .py files and remove the old .pyc from the old folder as they will be regenerated after.


How to download a portion of a video with youtube-dl OR something else?

There is indeed a plethora of techniques available online to accomplish this. One fairly basic technique is the following one liner which works well enough on my system with a YouTube clip:
ffmpeg -i $(youtube-dl -f 18 --get-url https://www.youtube.com/watch?v=ZbZSe6N_BXs) \
-ss 00:00:10 -t 00:00:30 -c:v copy -c:a copy \
happy.mp4

The 2 sections which govern the clip start and end in this example are:

-ss 00:00:10: Placed after the input file this encodes and discards samples up until the 10 second mark. This is slower and less efficient than placing the seek options before the input file (input seeking) but works better in this example (in particular when copying audio and video streams)
-t 00:00:30: This specifies the duration of the encode, in this case 30 seconds only

I have tested this extensively with YouTube and all works well on my own system...
References:

youtube-dl Download Range: Great discussion of the possibilities, some a little misguided :)
FFmpeg: Seeking A solid outline of seeking, cutting and the correct time unit syntax


In the chromium window open :

Click on the wench icon on the right of your toolbar. Click Settings -> On Basics Section, in the option under On startup heading, Choose the radio button with Reopen the pages that were open last.

Now, Your session will be always be saved.

See the image below:


How to restore update settings after accidentally changing it with dist-upgrade and pantheon desktop environment

In theory APT installs latest version of the package available. When I add ppa:elementary-os/os-patches in my 20.04.1 system, I'd be getting "updates" for following packages:
base-files/focal 11ubuntu5.2+elementary9~ubuntu20.04.1 amd64 [upgradable from: 11ubuntu5.2]
gir1.2-gtksource-4/focal 4.6.0-1+elementary2~ubuntu6.0.1 amd64 [upgradable from: 4.6.0-1]
libgtksourceview-4-0/focal 4.6.0-1+elementary2~ubuntu6.0.1 amd64 [upgradable from: 4.6.0-1]
libgtksourceview-4-common/focal,focal 4.6.0-1+elementary2~ubuntu6.0.1 all [upgradable from: 4.6.0-1]
lsb-base/focal,focal 11.1.0ubuntu2+elementary2~ubuntu6.0.1 all [upgradable from: 11.1.0ubuntu2]
lsb-release/focal,focal 11.1.0ubuntu2+elementary2~ubuntu6.0.1 all [upgradable from: 11.1.0ubuntu2]

This packages are essential for elementaryOS and the repository's description itself states:

elementary OS specific patches
This PPA is essentially required by elementary OS

Though not mentioned or warned, this repository may mix up packages on Ubuntu.
A similar mess and mixup can also be caused if you use Pop!_OS' PPA. So, whenever you add PPA/repository, look out for the packages they offer. See if those packages are distro specific and would replace the official packages, don't use it and if you use, don't upgrade or dist-upgrade the system. Your system may report other distribution (for example, Updated Ubuntu 16.04, now I'm running Kali?) and even break the system horribly and would land in dependency hell (for example, if you use Kali or Debian repository).
Now coming to your questions:

What exactly caused my mess (I guess sudo apt dist-upgrade is to blame) and what has been changed (like /etc/lsb-release)?

Yes. dist-upgrade alone shouldn't be blamed. The combination with that PPA should be held responsible.
I don't know what has been changed but I can say above packages would have been surely replaced.

Is there a way (beside reinstalling) to cleanup the issues completely? (I just saw that files like /etc/issue and /etc/issue.net are also changed)

ppa-purge is the best way if you don't want to clean install the system. If it fails, you've to do work, a lot of work, i.e., manually check all packages the replace with the official ones. You can always check which package provide "that" file using
dpkg -S file

and check if you can install (or "downgrade") the official packages without breaking other packages.


Links and installation of codelite dependencies

I needed to add trusty repository instead of utopic one.
To install codelite follow instructions on codelite official installation page
except for:
sudo apt-add-repository 'deb http://repos.codelite.org/ubuntu/ trusty universe'

run this instead:
sudo apt-add-repository 'deb http://repos.codelite.org/ubuntu/ utopic universe'


It is possible that bits of code may get dragged around from kernel to kernel - during the unpacking/install - It is also possible to go back to an older kernel. At the grub boot menu choose the Kernel you want to boot to - Once you have chosen the Kernel you want to keep and you have booted into it

uname -r

will tell you what kernel you are currently running on

dpkg -l | grep linux-image
dpkg -l | grep linux-headers

will tell you what kernels/headers are saved on your system - I will also delete the headers - though they dont take up too much space i still purge them, why have them if I am deleting the kernel?

Be advised that it is important to NOT delete the Kernel you are running i.e uname -r- Deleting these kernel and header entries will make your system unusable

then just delete the ones you dont want:

sudo apt-get purge

an example of what the full command will look like:

sudo apt-get purge linux-image-3.16.0-41-generic linux-image-3.16.0-41-lowlatency linux-image-extra-3.16.0-41-generic

sudo apt-get purge linux-headers-3.16.0-41 linux-headers-3.16.0-41-generic linux-headers-3.16.0-41-lowlatency

an example of what the output of dpkg -l | grep linux-headers will look like:

jason@casa-wesella:~$ dpkg -l | grep linux-headers
ii  linux-headers-3.16.0-41                     3.16.0-41.57~14.04.1                    all          Header files related to Linux kernel version 3.16.0
ii  linux-headers-3.16.0-41-generic             3.16.0-41.57~14.04.1                    i386         Linux kernel headers for version 3.16.0 on 32 bit x86 SMP
ii  linux-headers-3.16.0-41-lowlatency          3.16.0-41.57~14.04.1                    i386         Linux kernel headers for version 3.16.0 on 32 bit x86 SMP
ii  linux-headers-3.16.0-43                     3.16.0-43.58~14.04.1                    all          Header files related to Linux kernel version 3.16.0
ii  linux-headers-3.16.0-43-generic             3.16.0-43.58~14.04.1                    i386         Linux kernel headers for version 3.16.0 on 32 bit x86 SMP
ii  linux-headers-3.16.0-43-lowlatency          3.16.0-43.58~14.04.1                    i386         Linux kernel headers for version 3.16.0 on 32 bit x86 SMP
ii  linux-headers-generic-lts-utopic            3.16.0.43.34                            i386         Generic Linux kernel headers
ii  linux-headers-lowlatency-lts-utopic         3.16.0.43.34                            i386         lowlatency Linux kernel headers


The results of running: lspci -nn | grep 0280 were:

02:02.0 Network controller [0280]: Broadcom Corporation BCM4306 802.11b/g wireless LAN  Controller [14e4:4320] (rev 02)

  The driver needed was b43legacy. Performed the following:

sudo apt-get update

  Then:

sudo apt-get install firmware-b43legacy-installer

  The install completed successfully, but the wireless isn't seeing my
  wireless signal. More investigation indicated that Dell used a utility
  name a Quickset utility to turn on / off the radio on the card. I
  received a comment to my question that took me to:

  https://help.ubuntu.com/community/WifiDocs/Driver/bcm43xx#b43%20-%20Internet%20access

  I then went to the FAQ from that page and there was a question:

  Q: The radio-enable-button on my laptop does not work.

  A: You have to enable RF-kill support in the kernel configuration. The
  config options you have to enable are: CONFIG_RFKILL,
  CONFIG_RFKILL_INPUT, CONFIG_INPUT_POLLDEV.

  Before proceeding I would like to do as the answer indicates, but I do
  not know what the command string would look like.

Answering my own question. After researching the comment on my question, I was lead to this being a possible solution from the developer page regarding my wifi card. I am new at this. What do I type in the terminal to satisfy the items below. I have loaded the b43legacy drivers. The wireless is enabled and ON in the BIOS. The wireless does not seem to see any signals. I am guessing, the RF is off and needs to be turned on.

You have to enable RF-kill support in the kernel configuration. The config options you have to enable are: CONFIG_RFKILL, CONFIG_RFKILL_INPUT, CONFIG_INPUT_POLLDEV