You set proxy of firefox 127.0.0.1:8000 on [X]?
Try to set proxy 192.168.5.110 and port 8000 because that ip is on [S] witch is proxy.


Yeah it's a little bit hacky though. Let's start by installing two packages:

sudo apt-get install python-excelerator w3m

From there, we use a script that comes bundled with python-excelerator to convert the document into a HTML file. We then pipe that into a command line browser (w3m) and display it.

py_xls2html spreadsheet.xls 2>/dev/null | sed 's/"//g' | w3m -dump -T 'text/html'

You can create a bash function or alias with that if you don't want to keep typing it. It should give you output like this:

Sheet = Sheet1
┏━━━━┯━━━┯━━━━━┯━━━━━━━━━━━━┓
┃this│is │a    │spreadsheet ┃
┠────┼───┼─────┼────────────┨
┃it  │is │very │nice        ┃
┠────┼───┼─────┼────────────┨
┃this│has│three│rows        ┃
┗━━━━┷━━━┷━━━━━┷━━━━━━━━━━━━┛
Sheet = Sheet2 Sheet = Sheet3

Very pretteh. Obviously this isn't going to support any sort of macro, editing or any interactivity. This is purely a viewer. You could also work at stripping out the quotation marks that wrap things. I'm not particularly bothered by them at this point.

If you don't need it to be as tabular you could simply have something like this:

py_xls2csv spreadsheet.xls 2>&1 | less

You can go one further than that and display it in a slightly nicer way:

py_xls2csv spreadsheet.xls 2>&1 | grep '^"' | sed 's/"//g' | column -s, -t | less -#2 -N -S

That gives you the following:

  1 this   is    a       spreadsheet
  2 it     is    very    nice
  3 this   has   three   rows


Accessibility: Use high offscreen resolution to get better zoom quality? (compiz, gnome-shell)

Thank you user.dz.
With your pointer I managed to improve things by doing:
output=$(xrandr | grep " connected" | cut -d ' ' -f 1)
xrandr --output $output --scale 2.0x2.0 --dpi 200

This gives me a bigger (2k->4k) offscreen resolution that any composer (gnome-shell/mutter, compiz, ...) will use to get a far better looking zoom. In the case of text, this makes it a lot easier to read.
For this to work properly you also need to make everything 2x bigger to use all the new available pixels. To compensate for the 2x bigger screen you have to set the scale factor to 200% in the gnome settings: Displays
So, everything drawn on the bigger (off)screen has the same apparent size on your monitor but is made of 4 times more pixels (doubled for x and y axis)
Unfortunately, the 200% display scale won't work for all UI elements, so some things will look too small (known issues relatied to High DPI). eg: thunderbird does not scale the font when editing a new mail (be prepared to do quite a lot of Ctrl-+ or Ctrl-mousewheel)
After two weeks in this mode I'm happy and will continue using it. The better overall zoom quality/readability is worth a couple remaining issues.
Hope it helps if you are struggling with accessibility and readability of zoomed text.
Would be great if Ubuntu could support this "trick" as an official accessibility option.


Ubuntu Server 14.04 eth0 loads not load after 1st updates

Had the same problem. Fresh install on a HP microserver gen8. Works like a charm, network was called em1. In the log it showed that udev had renamed eth0 to em1.

Afther update with aptitude, the rename was gone from the log files, and I had an eth0 interface.

Sollution one:
 sudo vim /etc/udev/rules.d/70-persistent-net.rules

change the line:
SUBSYSTEM=="net", ACTION=="add",  ...... KERNEL=="eth*", NAME="eth0"

into
SUBSYSTEM=="net", ACTION=="add",  ...... KERNEL=="eth*", NAME="em1"

Sollution two
You can also change /etc/network/interfaces.

Modify the two lines that read em1 into eth0.

Don't know what is best. I was used to eth0 from my previus Slackware server so I sticked to eth0.

Do think it is bad that a LTS build changes network names on a update!! Using the ILO evaluation license I can now access the console, but otherwise I would have had to attach a keyboard an screen to fix this.


How to reset Notification Area settings?

Just reinstall the Xubuntu icons from the repositories and that will get your icons back.

sudo apt-get install --reinstall xubuntu-icon-theme

I found this out by querying each of the icon folders with dpkg -S; for example:

dpkg -S /usr/share/icons/elementary-xfce

which returned the name of the package they came from:

xubuntu-icon-theme: /usr/share/icons/elementary-xfce

If you have any other problems regarding settings you can purge the xfce4-indicator-plugin and then reinstall it with

sudo apt-get install --reinstall xfce4-indicator-plugin

If you have also removed the indicator from the Xfce panel, add it back again by right clicking the panel and clicking panel > add new items (see screenshot). Importantly, you will probably have to logout and login for the changes to take effect after reinstalling the icons.


EFI GRUB: Grub not shown after windows 10 boot

Set the windows entry inactive. Make sure windows is complete and remove faststart from windows.

sudo efibootmgr --bootnum 0000 --inactive

and try again.


Laptop boots straight up to windows 8 without asking me to start Ubuntu or anything using a live usb stick

It's probably a problem with your boot device order in the bios / efi.
Either try setting the order in your bios / efi or use the boot device selection, depending on your make and model this might be triggert by pressing F12 during bootup. If that doesn't work look at your manual or try googling which key to press for your make and model.


Photoshop in Ubuntu - what are my options?

Check the HP from Wine:
Wine Adobe Photoshop

Many People tried to use CS2 because there is a official free download version on the hp from adobe. (Tricky to find) The only acceptable Version that works is 7.0


Can I prevent an IDENTIFY PACKET DEVICE command to a specific device at boot?

Turns out these are libata messages from the kernel resulting from ATAPI commands being sent to the DVD drive. The problem is, the ASM1061 to which the DVD is attached doesn't support ATAPI.

The solution is to edit /lib/udev/rules.d/60-persistent-storage.rules, find the line containing the word "ATAPI" and comment out the next line.

Thanks to Olli Helin for his answer to my previous post for this answer!


How to use 'screen' to compile a project and give a notification when compilation is done?

If the screen is running on the same machine as your desktop, you can do

 make 2> make.errors ; notify-osd "Compilation done" "`tail -3 make.errors`"

or

(make && notify-send "Compilation finished" "Success") || notify-send "Compilation finished" "Failure"

If it is running on another system to which you connect over ssh, however, you will have to install a mailer that sends you an e-mail.


The sshfs package has been relocated to the universe repository:

# apt-add-repository universe

And re-attempting installation fixes the issue.


Flashplayer support needed for starsports videos

I guess the site you want to visit requires a current version of Flash to work.

As Adobe officially stopped support for the NPAPI (plug-in interface in Firefox-like browsers) Flash version on Linux at version 11, that's the latest version you can get normally for Firefox.

However, there's a trick starting with Ubuntu 15.10. The Linux PPAPI (plug-in interface for Chrome-like browsers) Flash version is still getting upgraded and currently runs at version 19.

You can install the package browser-plugin-freshplayer-pepperflash to temporarily download the Google Chrome browser in the background, automatically extract the latest PPAPI Flash plug-in from it and installing that. It also installs a PPAPI to NPAPI wrapper which makes this latest Flash version available for Firefox-like browsers as well.

Here's a list of all commands you need to run for the mentioned trick:

Purge the current Flash package:

sudo apt-get purge flashplugin-installer

Install the described PPAPI-to-NPAPI wrapper and the new Pepperflash plug-in extracted from Chrome:

sudo apt-get install browser-plugin-freshplayer-pepperflash

Then restart possibly running Firefox instances and visit https://www.adobe.com/software/flash/about/ again to verify that you're now running a Flash version 19 or higher.

Or simply install Google Chrome browser...
or Chromium browser plus pepperflashplugin-nonfree (available since 14.04)


Can you run Linux Mint in a virtual box on Linux Mint?

Yes you can run the same Linux Mint version (or any other OS for that matter) inside a VBox just fine.  The two are basically running independent of each other, just sharing the hardware at the direction of the hypervisor (which determines who gets the hardware at what point).

It sounds like you don't have the .iso file for Mint set as the bootable medium properly.  Try this:

With the VM shut down completely, Right-click on the VM in the list in VBox, and select "Settings..."
Click "Storage" in the left hand menu
Under "Controller: IDE" select the CD/DVD icon
On the very right there is another CD/DVD icon with a small down arrow.  Click that and select "Choose a virtual CD/DVD file"
Select the Mint .iso file (or whatever OS you're installing)
Check the box next to "Live CD/DVD"
Reboot the VM and it should launch into the install for Mint.  Run the installer.
After the install, shut down the VM
Go back to the drop down menu with the small down arrow next to the CD/DVD icon
Select "Remove disk from virtual drive"
You should now be able to boot into Mint (or whatever you installed)

Let me know if you're still having problems.


HP 255 G6 freezing at random times with Ubuntu

I'm writing this post to clarify to other Linux users that HP 255 G6 Laptop is incompatible with Ubuntu -and probably any other Linux distribution.

I searched the error message above, found out that it's related to BIOS errors, but that freeze won't occur with Windows OS, as Windows provides its own "ACPI tables" -as I read somewhere-, and since the majority of end users use Windows, companies care about testing for bugs with Windows not other OSes.

I tried both CSM and UEFI modes.
I tried to update the BIOS to latest version.
I tried flags acpi=off, nomodeset, but also in vain, actually it became worse, I heard weird sounds from the laptop.

Resources:

https://access.redhat.com/articles/65378 - shows the meaning of ACPI error message.


try to run this command in your terminal "nm-applet"  with out the quotes. This will launch the network manage interface. So you can check what is going on in your network configuration.


You have a typo error, change:

 sudo apt-get instal alien libaio1 unixodbc

to:

 sudo apt-get install alien libaio1 unixodbc


Ubuntu 14.04 LTS 64bit guest OS kernel panic on start up

I ended up using DiskInternals Linux Reader to mount and read the vmdk file.


Boot delay: Ignoring bad onboard SSD via libata: disable does not work

An additional "no reset" would work:

libata.force=2:disable,2:norst

I've had the same problem with my broken DVD drive.


Can I install Java on a live persistence Ubuntu?

If you are getting the message that the Drive is read only then you probably dont have required permissions to install Java. I think you have made a live USB of Ubuntu instead of a persistant live USB


apt-get install firefox-3.6 installs 5.0

Firefox 3.6 is only available in Lucid and Maverick repositories. If you are using Ubuntu 11.04 Natty Narwhal, then Firefox 5 is what you get.

You could download Firefox 3.6 from Mozilla and run it from you home or /opt, but if you provide more info about why you want to downgrade, then maybe we can help. Firefox 3.6 support won't last long. Besides, it is much slower than Firefox 5.


Why is the HID_MAX_USAGES value so low in kernel?

Well, I don't have an aswer yet, but kernel 3.11.0 (stable) works great with gaming mices, altough the HID_MAX_USAGES is still on ~13k. So, it's solved, and possessors of gaming mices will no longer need to rebuild the kernel with modified hid.h.


No, these are just warnings that should be fixed in update-manager code.

These warnings are just asking the Python code to specify a version during the library importing. But they're not errors and the program will work normally.


I need a little guidance on creating a snap package

The documentation for snapping a python application can be found in the snapcraft docs python language guide. This should get you started. If you get stuck, ask further questions here, or join us on #snappy irc or the snapcraft forums. I'm keen to hear your feedback on how you get on with that guide!


Have you tried the usual " do-release-upgrade " - checkout this article  for the many ways to upgrade ubuntu.

Upgrading using the command line:

Run do-release-upgrade in a terminal

sudo do-release-upgrade

If fails edit /etc/update-manager/release-upgrades and set Prompt=lts:

nano /etc/update-manager/release-upgrades

Then run again the above command:

sudo do-release-upgrade


How to install wireless drivers Ubuntu 16.04.1 LTS

Here are some commands that may help. There is also a link for the video!

~$ lspci -vvnn | grep 14e4

Driver - Card/Model

*STA - BCM4311, BCM4312, BCM4313, BCM4321, BCM4322, BCM43224, BCM43225, BCM43227, **BCM43228
  sudo apt-get update
  sudo apt-get install bcmwl-kernel-source

b43 - BCM4306/3, BCM4311, BCM4312, BCM4318, BCM4320
sudo apt-get install b43-fwcutter
sudo apt-get install firmware-b43legacy-installer
sudo modprobe -r b43 ssb wl
sudo modprobe b43

b43legacy - BCM4301, BCM4306, BCM4306/2

https://www.youtube.com/watch?v=nlLS8d4Z09c

Good luck with it.


Problem sourcing variables inside Upstart

This line:

if [[ ${NODE_ENV} = 'production' ]]; then

is not valid in a POSIX-compliant shell, but does seem to be valid bash. I don't see the shell that upstart uses by default in script stanzas documented anywhere, but it's reasonable to assume that it uses /bin/sh, which is not bash on Debian/Ubuntu systems.

Try:

if [ "${NODE_ENV}" = 'production' ]; then

instead.


How to add a custom alert sound in Unity

Personally I would use aplay /path/to/file as notification when a command is done with command && aplay /path/to/file, but there are multiple other options to do so. Check out these

https://superuser.com/q/276596/418028
https://askubuntu.com/a/316048/295286
http://www.unixmen.com/how-to-play-music-from-command-line-terminal/


JAR files are not executable in the same way as shell scripts and programs are. Rather, you need java to run them.

Check to see if you have Java Installed

Run the following:

java -version

If you get something like this, you have it installed and you can skip the Installation step. If not, continue with the Installation Step.

Installation (If you don't have Java Installed)

sudo apt-get update
sudo apt-get install openjdk-8-jre

The Fun Part :)

Now, after all that hard work, now you can run it! :)

Run:

java -jar filename

where filename is the name of the JAR file.

If you have any questions / comments, please comment on this answer. :)
Thanks!


How to add user to separate filesystem (Armel)

I found this page which explains exactly what I was trying to do to chroot into the target filesystem:

http://www.omappedia.com/wiki/OMAP_Ubuntu_Core#Chroot.27ing_into_the_Ubuntu_Core_Filesystem

It's then a simple case of running adduser ubuntu or similar.

Copied in case it goes dead:

Chroot'ing into the Ubuntu Core Filesystem

One solution to customize your Ubuntu Core Filesystem is to do it from the Linux PC. Using a 'chroot' is sometimes quite convinient as you can run commands as you normally do on the ARM target. Here are some quick steps to get running:

Chroot configuration on the Linux PC

Verify that on your Linux PC you have the 'qemu-user-static' Ubuntu package installed. This can be done with the following command line (on your Linux PC):

dpkg -l qemu-user-static

Have your SD Card mounted on your Linux PC and go to your rootfs Ubuntu Core folder, generally:

cd /media/rootfs

Copy the qemu for arm file:

cp /usr/bin/qemu-arm-static usr/bin/

If not done yet, have your network settings properly configured:

mv etc/resolv.conf etc/resolv.conf.saved
cp /etc/resolv.conf etc/resolv.conf

Then, mount sys, proc and dev:

for m in `echo 'sys dev proc'`; do sudo mount /$m ./$m -o bind; done

Finally, chroot into your target filesystem:

sudo LC_ALL=C chroot . /bin/bash

You are now in your 'chroot' which means you can run commands like if you were on your target ARM device.

Using the 'chroot'

The first step is to verify the network connection is fine. You can run:

apt-get update

You are now ready to install any new package in your Ubuntu Core Filesystem using APT tools.

Getting out of the 'chroot'

Un-mount the target filesystem:
Make sure your at the / target FS and run the following commands:

for m in `echo 'sys dev proc'`; do sudo umount ./$m; done

Go back to your original network settings:

mv etc/resolv.conf.saved etc/resolv.conf


How can I fix dual boot with Ubuntu after installing Manjaro alongside it?

Thanks to two of you.  I found that if I hold c during startup the menu will appear.  There's an edit to the grub file to make it happen automatically.

For permanent change edit:

/etc/default/grub

place a # symbol at the start of line GRUB_HIDDEN_TIMEOUT=0.

Save changes and run:

sudo update-grub


Is formatting my partitions the same thing as wiping my hard drive?

Wiping generally means to overwrite a partition/drive with other data (nulls, zeros, random) to completely destroy all data and prevent recovery. Formatting is to put a new filesystem on a partition, possibly on top of an old partition leaving the old data still recoverable but normally unseen.

The Ubuntu installer should let you pick a partition to format & install to, and probably partitions for /tmp, home, etc...

I don't know what "messing" you did with your drive so I couldn't guess if it's bad or not, but if you do a fresh install of Ubuntu you'll probably want to format it's partition to a ubuntu-friendly filesystem (fat32 or ntfs aren't optimal for linux) it should be as stable as completely wiping your drive, the rest of the drive is just data (as long as there's nothing running before Ubuntu)

If you want, you can run a Ubuntu live usb/cd/dvd (the same one you'll use to install Ubuntu) and run gparted (can install it with sudo apt-get install gparted if it's not already there) and resize or delete or move/make new partitions. There isn't really a merge. But backup any data you want to keep first. Actually it's safest to backup data before installing Ubuntu too.


Turning laptop into WAP using netgear WNA1100? (stuck at hostapd)

I just had a review of the ath9k_htc deb installer you've pointed to, it's not a supported driver. Worse the installer is all over the place with debian errors, inconsistencies and a couple of security issues. It worries me that users and being recommended to install this package at all.

Check what kernel driver is currently loaded by using lsmod, if you can find ath9k or ath9k_htc in the list, then that's what it's called. Use that exactly name. If that still doesn't work, then it's very likely that because the htc is a non-standard driver, the hostapd just don't know how to deal with it.

But I think it's probably more likely that the driver is really the ath9k driver with new firmware.


How to disable the "roll up" / "shade" keyboard shortcut in Gnome 3 (after upgrading to 12.04)?

The trick is to set up a new shortcut for the toggle-shade feature, using dconf-editor. Follow these steps:

Install dconf-editor: sudo apt-get install dconf-tools
Open dconf-editor (Alt+F2, enter dconf-editor)
Expand until the element: org → gnome → desktop → wm → keybindings.
Change the value for the key toggle-shaded to something less intrusive: ['<Control><Super>s']

UPDATE: There is an easier way to do it that does not require dconf-editor:

gsettings set org.gnome.desktop.wm.keybindings toggle-shaded "['<Control><Super>s']"

Edit from Michael Fischer:
T
o disable the keybinding with gsettings, just use the value ['disabled']

Example:

gsettings set org.gnome.desktop.wm.keybindings toggle-shaded "['disabled']"


The chipset is unknown for airmon-ng, but as you can see this is not a problem, the monitor mode is enabled. So, airmon-ng works well with your network device.


Is there a way for grub to automatically reboot into Windows from Windows?

Easiest way is with Grub

It is cumbersome controlling grub from Windows. A third party application to access Ubuntu from Windows and some hacking is required. However from the top part of this post: How to change the order on my dual booting distros, you can setup grub to automatically reboot to the last menu option. So when you initially boot with windows, and it wakes up at 2 am to run updates, grub will reload Windows so it can gracefully finish updates.

When you manually reboot and pick Ubuntu from grub all your next reboots automatically load Ubuntu. This feature works equally well if you have bugs in the current kernel and want grub to automatically reboot into an older kernel version you selected.

How to get Grub to repeat last boot selection

This is fairly straight forward. Using sudo powers edit /etc/default/grub and change the following:

#GRUB_DEFAULT=0 # Rather than option #1, we'll always default to last boot choice.
GRUB_DEFAULT=saved
GRUB_SAVEDEFAULT=true

The first line you will be commenting out and right below that insert the next two lines.

Save the file and type in the terminal:

sudo update-grub

Ubuntu command line to reboot into Windows

Currently you use something like this:

sudo grub-reboot x # Where x is Windows zero-based grub menu number
sudo reboot now

From this modified Stack Exchange answer you can use the grub default to reboot into Windows. Copy this code into your ~/.bashrc file:

function reboot-to-windows {
    WINDOWS_TITLE=`grep -i "^menuentry 'Windows" /boot/grub/grub.cfg|head -n 1|cut -d"'" -f2`
    sudo grub-set-default "$WINDOWS_TITLE"
    sudo reboot
}

Save the ~/.bashrc file with new reboot-to-windows function.
Close your current terminal session.
Open a new terminal session for changed ~/.bashrc to be loaded.
You could type : ~/.bashrc to reload it into the existing terminal session but some people recommend against do this.

To reboot into Windows from the command line use:

reboot-to-windows

If Windows automatically restarts when you aren't looking, Windows is rebooted. This allows Windows automatic updates to be processed normally over multiple-reboot cycles Windows sometimes uses.


Backspace key clicks rapidly when held on empty terminal

What you refer to as "empty terminal" is a terminal with your default shell (probably bash) running inside. It is bash (more precisely, the readline library underneath) that handles keypresses and decides to ring the bell on certain conditions, such as on a backspace when there's no character to remove.

In order to silence your shell, based on the manual page bash(1), you should place this line in your ~/.inputrc file:

set bell-style none


How to use gnome_settings_daemon and volume_step?

Doesnt work in 11.10. See https://bugs.launchpad.net/ubuntu/+source/gnome-settings-daemon/+bug/871133


There is not an straight forward way to do it, as far as I know. This answer can probaly help you a bit: https://superuser.com/questions/132891/how-to-reset-folder-permissions-to-their-default-in-ubuntu-9-10


How can I select an output and set my configuration for pulse audio volume control from the terminal?

Basicaly you have to move your audio stream from one output to another.

List available outputs

$ pactl list short sinks

0   alsa_output.pci-0000_00_1f.3.analog-stereo  module-alsa-card.c  s16le 2ch 44100Hz   RUNNING
1   alsa_output.pci-0000_67_00.1.hdmi-stereo-extra1 module-alsa-card.c  s16le 2ch 48000Hz   SUSPENDED

List all running audio stream

$ pactl list short sink-inputs

1716    0   915 protocol-native.c   s16le 1ch 44100Hz
1717    0   916 protocol-native.c   s16le 1ch 44100Hz
1719    0   918 protocol-native.c   s16le 1ch 44100Hz
2059    0   14  protocol-native.c   float32le 2ch 48000Hz
2067    0   1152    protocol-native.c   s16le 2ch 44100Hz
2078    0   14  protocol-native.c   float32le 2ch 48000Hz

Move each stream to new output using :

$ pactl move-sink-input <stream_id> <output_id>

Enjoy :)


Make sure that your application name is set in the program to be "com.ubuntu.developer.flscogna.ubuntu-netwalk", as it is in the manifest file.  In a QML app, set the applicationName attribute of the MainView to this value.  In a C++ application, call

QCoreApplication::setOrganizationName("");
QCoreApplication::setApplicationName("com.ubuntu.developer.flscogna.ubuntu-netwalk");

When it's running, the program uses this value to figure out which directory is writable, but apparmor uses the value in the manifest file to decide where to allow file system access.  If these aren't the same, you run into problems.  (Why the program can't get its application name directly from the manifest file, I don't know.)


Ubuntu 14.04 is not recognizing my Wacom cintiq 13HD anymore after latest update

Did you try installing the latest driver via Sourceforge?

http://linuxwacom.sourceforge.net/wiki/index.php/Input-wacom


Can not change display resolution on a Sony VGN-FZ21M

you have Nvidia Settings Manager, maybe you should try with that

go to DASH HOME in the search type NVIDIA to find the NVIDIA X Server settings manager.
Then open it and go to server settings.

In there you can tweak your settings


Keep boot tidy - Script to remove kernel +2

It isn't possible to set APT to do this.

This is part design choice, part limitation.

Ubuntu designates each new kernel as a different package name (the package name contains the kernel version) so APT treats them as separate packages.  When they want you to download and install a new package, they create the new kernel package, and then point the generic kernel package (eg linux-kernel-generic) to depend on that new package.  This is what causes the new kernel package to be installed.

Now, it is (or at least, traditional wisdom says it is) generally a good idea to keep your previous kernel installed when installing a new one, in case there is any incompatibility or bug in the new one.  This allows you to switch kernels from the boot loader.  So Ubuntu do not mark the new kernel packages as "replacements" of the old ones, which means APT will simply leave the old ones installed.

There is no mechanism in APT or the Ubuntu repositories to specify "keep the last two kernel packages".  There could be something like this hacked in, but it may not play very well with all situations, such as when people skip a kernel version.

Now, while I said this isn't possible to do in APT, there may exist third party software tools that can help you with this, if not on an automatic basis.

There is a tool called Ubuntu-tweak which is not available in Ubuntu, but can be installed from a PPA.  This tool has a "computer janitor" feature that, among other things, helps you uninstall old kernels.

Or, you can simply use Synaptic.  Synaptic makes it pretty easy to list installed kernels (search for packages containing linux-image) and from there you can uninstall them easily.


Can I write a python script that will automatically load a terminal as sudo?

You should read this question, because running ANYTHING as root within a script or other piece of software that COULD be run without the administrator's knowledge is a very very dangerous and bad thing.

As well, running your system in a root terminal just to run a script is also equally dangerous.

(whether you know the security implications or not, question poster, others probably won't, hence this answer)


Failed to start Login service after upgrade to 17.10

So in fact I must have broken the installation process.

From within a chroot, I run dpkg --configure -a as asked by apt and I was finally able to boot after a reboot.

Everything seems fine at first sight but I think I am good for a complete reinstall nonetheless.

So this leads to the originial problem. Why couldn't I login after I started the upgrade process ??? This is why I rebooted inthe first place.


Where desktop icon positions are saved in MATE?

Quick greping in home folder gives the following file name with needed information:
~/.local/share/gvfs-metadata/home

It is special file to be operated by gio info or gio set.

Every icon has its own metadata attribute. So one can:

read it by
gio info -a "metadata::caja-icon-position" ~/Desktop/file1.txt

to get something like

attributes:
  metadata::caja-icon-position: 922,382

where 922 and 382 are horizontal and vertical pixel positions for file1.txt icon.

write it by
gio set -t string ~/Desktop/file1.txt metadata::caja-icon-position 300,400

to move file1.txt icon to the location specified by 300 and 400 coordinates in pixels.
Then one needs to ask Caja to refresh the desktop by calling caja -q.


This doesn't seem like a software issue. It could very well be a problem with your display. I would suggest connecting another computer to the same display. If the problem persists, there's something wrong with the display.

If the display does work fine with another computer you should try booting a completely different OS to determine if the problem is in software or hardware.


The problem was solved with the help from @steeldriver
Solution:
If you can run man command with the following prefix:

MAN_DISABLE_SECCOMP=1 man man

Then you should add this flag to your .bashrc file

export MAN_DISABLE_SECCOMP=1

The same problem was mentioned here https://unix.stackexchange.com/questions/339132/reinstall-man-pages-fix-man/426204
However the question was created two years ago and still it doesn't work properly


Use unetbootin, dd command or the built-in Disks utility instead.
Using dd command
First unmount the usb device
sudo umount /media/milenko/sdb1

Then run the following command, replacing /dev/sdX with your drive. Do not append a partition number, so do not use something like /dev/sdb1
sudo dd if=/path/to/ubuntu.iso of=/dev/sdb bs=4M; sync

Wait for it to write to the device.
Using Disks Tool
Choose your device from the left pane and choose the option called Restore partition image..
UNetbootin
sudo apt-get install unetbootin


Is there an app which I can check the temperature of my PCI network card?

Many modern computer components contain thermal sensors, including but not limited to the CPU, hard drive, and even motherboards, although to be fair, motherboards did it first.  Display cards may or may not include them but they should as they are usually the first to die from overheating.

That said, it has never been my experience that commonplace network cards monitor their temperature, nor have I known them to overheat.  They do die however, a behavior I assume is caused by power surges over the ethernet cabling, and sometimes by poor chipset quality.

If your ethernet card appears to be flakey, it could well be the card itself.  Still more likely is that your router needs to be reset, is dying, or is of poor quality.  I see failing routers with some frequency.  Some routers with big reputations caused by heavy advertising are terribly unreliable.  D-Link and Linksys come to mind first. Most Netgear routers are bulletproof, and Ironically they often cost half as much retail, and can cost a quarter the store price if you order refurbished netgear routers online, which is something I do quite frequently for my friends.

To get back to your original question, if your goal is to monitor any temperature inside your pc, your best bet is to go in search of a self-illuminated front panel temperature monitor and attach the wired thermistor included with the kit to whatever components inside your pc.  Many of these are configured to monitor four components such as your display card and some of them even offer outputs for variable speed cooling fans.  I probably don't have to tell you these devices are aimed primarily at overclockers obsessed with gaming, but they can just as well be applied to sensible people concerned to reliability and system longevity.

I apologize if I seem to issue TMI, but I beg of you to please understand I do not do this to brag, but rather to give you all information which will help ensure your success.


Ubuntu 15.04 doesn't boot on Dell XPS 13 2015

It is possible that GRUB is not installed or corrupted. Try installing grub again if you can login through coomand line (CTRL + ALT + F1).


Whether or not your home folder is encrypted shouldn't affect your data loss one way or another. However, having an encrypted home directory makes it a lot harder to recover data from a Live CD. If you lose the password that you got after installing Ubuntu that allows you to unencrypt the directory, then your chances of getting data out of the folder are slim to none. So, therefore, it is good to always backup frequently. Ubuntu 11.10 comes with a nice built in backup utility, supporting backup to an Ftp server, external hard drive, Ubuntu One, etc. EcryptFs writes the data directly to disc, and there shouldn't be any data loss problems.


How to recover the background, or wallpaper, folder?

If you want to add back the defualt wallpapers from 15.04 or a previous lubuntu release you can install the lubuntu artwork 15-04 wallpapers Then set this wallpaper set back an acceptable wallpaper from this. OR you could even choose other wallpapers of a previous flavor or release. You can select prefrences desktop settings and choose the file in the filesystem. If you do not know where this is stored you can run dpkg -L in a termnial to list the files and look for something ending in .png.


I have more or less solved the problem. It's not ideal but it works. In CompizConfig Settings, General Options -> Key Bindings, there are two settings for "Raise Window", mouse and keyboard controls. I set the mouse control to Super+Button1, which does not conflict with Alt+Button1 in the "Move Window" options. I also set "Lower Window" to Super+Button2, for orthogonal operating with clicking the title bar.

Although this does not combine raise+lower like I am used to, it allows me to access raise/lower while using the mouse, so it's good enough for my purposes.


It will search the desktop. By the way: no need to press the super key for that ;)

If you type characters all the files on the desktop that start with those characters will get highlighted.

Example:


The standard way to hide files on Linux/Unix is to add a leading dot into the filename. Typically it's done in command line but you can do it through nautilus as well

Click on the file
Click F2
Add a leading dot in the filename. For example , rename myStory.txt to .myStory.txt
Refresh with F5 key; your file will be hiddne now.


How to set a single file on the desktop to be opened with a program other than the default?

What you should do is make a .desktop file. A .desktop file is a text file describing some action, for example, open a certain file with VLC. See the Desktop entry specification. You can specify the program to run and its arguments, the icon, and the name to display (and a non-breaking space   is a valid name).

[Desktop Entry]
Name=Name of Radio Station
Exec=/full/path/to/vlc /full/path/to/file.xspf
Terminal=false
Type=Application
Icon=/full/path/to/icon.png

Place the .desktop file in your ~/Desktop folder and make it executable (chmod +x file.desktop).


Internal microphone not detected on Ubuntu 20.04 LTS with sound card Intel ALC3204

I had the same problem with my audio and discovered that third-party drivers were responsible to this behave. Check if it didn't mess with your microphone too.

Anyway, this command bellow resolved for me:

alsactl restore


Date and time not showing up in Ubuntu 14.04 even though the option is ticked in settings

This will make the date and time indicator appear in the menu bar now.

Reinstall indicator-datetime. It should be installed by default, but just in case you have removed it unknowingly, it is best to run the install command again.

sudo apt-get install indicator-datetime

Next, we are going to reconfigure the date time:

sudo dpkg-reconfigure --frontend noninteractive tzdata

Lastly, restart unity.

sudo killall unity-panel-service

Source


12.04 byobu now defaults to tmux as a backend instead of screen.

So to get the byobu you are used to back, just type:

byobu-select-backend

and select the "screen" option instead of "tmux".


can't encrypt files with cinnamon nemo file manager

See issue howto to build nemo extension nemo-seahorse version 4.4.0 without libgnome-keyring-dev
When you follow the steps in the link to install the latest cinnamon desktop and install the nemo-seahorse package you can encrypt and decrypt files from nemo filemanager.
The problem is now solved.


Well, honestly I like to put here a great answer to you, but I cannot. Still I can't find an equal program to Total Commander on ubuntu. I'm thinking same way like you about on nautilus and krusader.

Additionally I had needed a good FTP client like on Total Commander.

So I have ended with 2 programs.

Double Commander http://doublecmd.sourceforge.net/

(+) similar interface
(+) easy to use
(-) horrible ftp client

BS Commander http://www.beesoft.org/index.php?id=bsc

(+) similar interface
(-) low functionality and configuration

P.S : Even I'm thinking about starting a open source project for making something total commander.


How to use & in mkdir when creating a new folder?

Try this,

mkdir "tests&results"

OR

mkdir tests\&results


How to disable built-in wifi and use only USB wifi card?

Add the following line to /etc/network/interfaces:

iface wlan0 inet manual

NetworManager doesn't manage interfaces configured in the interfaces file. Replace wlan0 with the interface you want to disable, if it's not the name of the built-in interface.

Then restart network manager

sudo service network-manager restart


The fan should work at full speed from time to time. When your machine gets hot, the fan will run at top speed to cool it down again. This is a Good Thing® and you should not try to change it.

If you feel that it is happening too often, that it occurs even when the machine is not hot, you might need to tweak the default temperature thresholds. There is a nice little program, ThinkPad Fan Control that lets you do that for ThinkPads.

You should also read the How to control fan speed page on http://thinkwiki.org which is the site for Linux on ThinkPads.


Use the commands below

ifconfig virbr0 down
brctl delbr virbr0

(most of the time virbr0 is a bridge created by Virtualbox or Xen like hypervisors)


Why did ubuntu overwrite windows when I installed it from a USB stick?

It is really too bad that this happened. I'm glad that you have recovery USB sticks.

I think (but am not sure) that Window was hibernated or semi-hibernated (alias fast startup), which means that linux cannot read the file systems, and should not read the file systems. But it also means that the installer does not discover Windows.

It is very important to identify the target for the installation, so that you are 99.9% sure, that you will install to the correct drive.

The good thing is that you know 'forever', that installing an operating system is risky. And you have those recovery sticks, so it could be worse. It is good to 'Try Ubuntu' for a considerable time before you decide to install.

And before installing, remember to always backup everything that you cannot afford to lose (or make a complete backup, for example a compressed image with Clonezilla).

-o-

Are there any personal files, that you want to recover? In that case, do not use the [internal] drive except for recovery, because you might overwrite what you want to restore. There is a tool, PhotoRec, that can recover files from the data stored in the drive's memory without a file system. It is hard work, because the file names and directory structure are lost (except if the file name is stored among the file data). Boot from another drive, for example your USB pendrive, install PhotoRec, and recover the important files before doing anything else with the internal drive.


What happens when a program is installed?

/bin contains commands that may be used by both the system administrator and by users, but which are required when no other filesystems are mounted (e.g. in single user mode). It may also contain commands which are used indirectly by scripts.  /usr/bin/ is the primary directory of executable commands on the system.  Source: https://unix.stackexchange.com/questions/5915/difference-between-bin-and-usr-bin
The executable needs to have the execute permission set properly and it needs to be located within a directory listed in the $PATH environment variable for the shell in which you are trying to execute it.  For example, if your PATH contains /usr/local/bin , any executable in that folder can be run by simply typing the name of the command at the prompt.
This is quite variable depending on the application, but one can count on at least some information under /etc for system-wide programs that have settings files, files within your home folder for user-specific settings, man files under /usr/local/share somewhere.  There could be files under /var, /opt, or pretty much anywhere else too.
For a program installed from a .deb file, you can see what files it has created using deb -L packageName .


iptables string match does not work whe the --to option is < 52

Keep in kind that the offset is not relative to the start of the payload portion of the packet, but includes the header portion of the packet. Here is a tcpdump capture of one of the example packets, i.e.:

echo zoulaaaaaaaaaaa | nc  192.168.111.1 80

resulting in:

2020-01-26 11:51:10.606417 IP 192.168.111.122.43372 > 192.168.111.1.80: Flags [P.], seq 1:17, ack 1, win 502, options [nop,nop,TS val 3518227831 ecr 86824426], length 16: HTTP
    0x0000:  4500 0044 048c 4000 4006 d65b c0a8 6f7a  E..D..@.@..[..oz
                                           src-ip--
    0x0010:  c0a8 6f01 a96c 0050 8a87 b04c 40e2 7841  ..o..l.P...L@.xA
             dst-ip--  spt  dpt
    0x0020:  8018 01f6 ad1e 0000 0101 080a d1b3 e577  ...............w
    0x0030:  052c d5ea 7a6f 756c 6161 6161 6161 6161  .,..zoulaaaaaaaa
                       ^
                       |_ Offset 52
    0x0040:  6161 610a                                aaa.

By modifying your experimental iptables rules to this:

$ sudo iptables -I OUTPUT 1 -m string --algo bm --string boula --from 46 --to 51 -j DROP
$ sudo iptables -I OUTPUT 1 -m string --algo bm --string coula --from 47 --to 52 -j DROP
$ sudo iptables -I OUTPUT 1 -m string --algo bm --string doula --from 48 --to 53 -j DROP
$ sudo iptables -I OUTPUT 1 -m string --algo bm --string eoula --from 49 --to 54 -j DROP
$ sudo iptables -I OUTPUT 1 -m string --algo bm --string foula --from 50 --to 55 -j DROP
$ sudo iptables -I OUTPUT 1 -m string --algo bm --string goula --from 51 --to 56 -j DROP
$ sudo iptables -I OUTPUT 1 -m string --algo bm --string houla --from 52 --to 57 -j DROP
$ sudo iptables -I OUTPUT 1 -m string --algo bm --string ioula --from 53 --to 58 -j DROP
$ sudo iptables -v -x -n -L
Chain INPUT (policy ACCEPT 23 packets, 1800 bytes)
 pkts      bytes target     prot opt in     out     source               destination

Chain FORWARD (policy ACCEPT 0 packets, 0 bytes)
 pkts      bytes target     prot opt in     out     source               destination

Chain OUTPUT (policy ACCEPT 11 packets, 1816 bytes)
pkts      bytes target     prot opt in     out     source               destination
   0        0 DROP       all  --  *      *       0.0.0.0/0            0.0.0.0/0            STRING match  "ioula" ALGO name bm FROM 53 TO 58
   0        0 DROP       all  --  *      *       0.0.0.0/0            0.0.0.0/0            STRING match  "houla" ALGO name bm FROM 52 TO 57
   0        0 DROP       all  --  *      *       0.0.0.0/0            0.0.0.0/0            STRING match  "goula" ALGO name bm FROM 51 TO 56
   0        0 DROP       all  --  *      *       0.0.0.0/0            0.0.0.0/0            STRING match  "foula" ALGO name bm FROM 50 TO 55
   0        0 DROP       all  --  *      *       0.0.0.0/0            0.0.0.0/0            STRING match  "eoula" ALGO name bm FROM 49 TO 54
   0        0 DROP       all  --  *      *       0.0.0.0/0            0.0.0.0/0            STRING match  "doula" ALGO name bm FROM 48 TO 53
   0        0 DROP       all  --  *      *       0.0.0.0/0            0.0.0.0/0            STRING match  "coula" ALGO name bm FROM 47 TO 52
   0        0 DROP       all  --  *      *       0.0.0.0/0            0.0.0.0/0            STRING match  "boula" ALGO name bm FROM 46 TO 51

We can try to gain more insight into the interpretation of the to and from parameters:

doug@rpi01:~ $ echo boulaaaaaaaaaaa | nc  192.168.111.1 80
Worked...
doug@rpi01:~ $ echo coulaaaaaaaaaaa | nc  192.168.111.1 80
^C  HTTP packet blocked
doug@rpi01:~ $ echo doulaaaaaaaaaaa | nc  192.168.111.1 80
^C HTTP packet blocked
doug@rpi01:~ $ echo eoulaaaaaaaaaaa | nc  192.168.111.1 80
^C HTTP packet blocked
doug@rpi01:~ $ echo foulaaaaaaaaaaa | nc  192.168.111.1 80
^C HTTP packet blocked
doug@rpi01:~ $ echo goulaaaaaaaaaaa | nc  192.168.111.1 80
^C HTTP packet blocked
doug@rpi01:~ $ echo houlaaaaaaaaaaa | nc  192.168.111.1 80
^C HTTP packet blocked
doug@rpi01:~ $ echo ioulaaaaaaaaaaa | nc  192.168.111.1 80
Worked...
doug@rpi01:~ $ sudo iptables -v -x -n -L
Chain INPUT (policy ACCEPT 742 packets, 71452 bytes)
    pkts      bytes target     prot opt in     out     source               destination

Chain FORWARD (policy ACCEPT 0 packets, 0 bytes)
    pkts      bytes target     prot opt in     out     source               destination

Chain OUTPUT (policy ACCEPT 509 packets, 59196 bytes)
    pkts      bytes target     prot opt in     out     source               destination
       0        0 DROP       all  --  *      *       0.0.0.0/0            0.0.0.0/0            STRING match  "ioula" ALGO name bm FROM 53 TO 58
      11      748 DROP       all  --  *      *       0.0.0.0/0            0.0.0.0/0            STRING match  "houla" ALGO name bm FROM 52 TO 57
      11      748 DROP       all  --  *      *       0.0.0.0/0            0.0.0.0/0            STRING match  "goula" ALGO name bm FROM 51 TO 56
      11      748 DROP       all  --  *      *       0.0.0.0/0            0.0.0.0/0            STRING match  "foula" ALGO name bm FROM 50 TO 55
      11      748 DROP       all  --  *      *       0.0.0.0/0            0.0.0.0/0            STRING match  "eoula" ALGO name bm FROM 49 TO 54
      11      748 DROP       all  --  *      *       0.0.0.0/0            0.0.0.0/0            STRING match  "doula" ALGO name bm FROM 48 TO 53
      11      748 DROP       all  --  *      *       0.0.0.0/0            0.0.0.0/0            STRING match  "coula" ALGO name bm FROM 47 TO 52
       0        0 DROP       all  --  *      *       0.0.0.0/0            0.0.0.0/0            STRING match  "boula" ALGO name bm FROM 46 TO 51

From the man pages:

   --from offset
          Set the offset from which it starts looking for any matching. If not passed, default is 0.

   --to offset
          Set the offset up to which should be scanned. That is, byte offset-1 (counting from 0) is the last one that is scanned.  If not passed, default is the packet size.

I assumed that to meant the last byte of the packet that would be checked. So, I would have expected only one of those packets to be blocked, not 6. However, and based on the man page description, then the results mostly make sense, when byte 52, the string start character, is included in the match window. However, this line:

  11      748 DROP       all  --  *      *       0.0.0.0/0            0.0.0.0/0            STRING match  "coula" ALGO name bm FROM 47 TO 52

Does not make sense, as byte 52 should have been excluded as a pattern start byte.

EDIT: I investigated. the example in my answer was from a pre 5.2 version kernel. This seems to have been fixed as of kernel 5.2-rc1, and that above line now doesn't block packets.


Ubuntu 17.04 forgetting wifi password after every reboot

Go to the network icon in the top panel. In "Edit Connections..." delete the profile for that particular wireless network, and any duplicates like profilename1/profilename2, and then connect to that same wireless network. It'll ask for your password as it recreates the profile, but it shouldn't ask again.


I'm not sure what this "Advanced options" you refer to is; I don't recall such a thing on my GRUB menus. Is this something in your motherboard's firmware? If so, it could be that GRUB has gotten "lost" from the firmware's NVRAM. (Under UEFI, the NVRAM holds boot loader data and the firmware can present its own boot manager menu. Unfortunately, most firmware implementations have pretty awful boot managers. This system also means that if the NVRAM gets reset or changed, your boot loader may fail to launch.)

You can edit your firmware's NVRAM boot loader settings with the efibootmgr utility in Linux. You can use it something like this:

sudo efibootmgr -c -l \\EFI\\ubuntu\\grub.efi -L Ubuntu

This adds the boot loader stored at EFI/ubuntu/grub.efi on the EFI System Partition (ESP) to the NVRAM, giving it the title Ubuntu. You might need to change these details for your system, of course. Note the use of the doubled-up backslashes as directory separators; this is a requirement. Ordinarily, Ubuntu mounts the ESP at /boot/efi, so this example would add the Linux file /boot/efi/EFI/ubuntu/grub.efi as a boot loader. Check to see if this file, or one like it, is present on your system.

Since you say you're using a UEFI-based computer, you should not install the grub-pc package, as Kalle Elmér suggested; that's the BIOS version of GRUB, and if your system is (or was) booting in UEFI mode, installing the BIOS version of GRUB will at best do nothing useful and at worst it will create a mess that will be harder to fix.


Tried to delete files; disappeared from home folder, but did not appear in Trash (Btrfs)

Turns out the quasi-deleted files were moved to a root-only directory called .Trash-0
In order to remove them, I opened that directory as root, as well as another (in my case Documents), and had to cut and paste the files from .Trash-0 to Documents in order to properly delete them.


PCIe Bus Error: severity=Corrected, type=Physical Layer, id=00e4(Receiver ID) - link done to WIFI module and sky lake architecture

I had the same problem. I could solve it only disabling ASPM - Active-State Power Management, a resource which helps PCI-E devices saves power.
sudo nano /etc/default/grub

Then, edit the variable GRUB_CMDLINE_LINUX_DEFAULT adding the parameter pcie_aspm=off, like this:
GRUB_CMDLINE_LINUX_DEFAULT="quiet pcie_aspm=off"

Save the file, and in terminal type
sudo update-grub
sudo reboot

If it still doesn't work try to create a file in /etc/modprobe.d/rtl8723be.conf with the following content. Then reboot again.
options rtl8723be ips=0 fwlps=0 aspm=0


The problem here is that Aptitude does not suggest you remove initramfs, because it is considered a core package, and Aptitude never proposes to remove core packages.

The only obvious way to work around this problem would be to tell Aptitude to remove initramfs-tools:

aptitude install dracut initramfs-tools-

However, if you try this command, you'll see that it triggers other important dependency problems:

The following packages have unmet dependencies:
 dmsetup : Depends: initramfs-tools but it is not going to be installed.
 console-setup : Depends: initramfs-tools (>= 0.85eubuntu12) but it is not going to be installed.
 linux-image-3.5.0-22-generic : Depends: initramfs-tools (>= 0.36ubuntu6) but it is not going to be installed.
 linux-image-3.5.0-17-generic : Depends: initramfs-tools (>= 0.36ubuntu6) but it is not going to be installed.
 kpartx-boot : Depends: initramfs-tools but it is not going to be installed.
 [...]

All that packages should actually depend on linux-initramfs-tools (which is a virtual package provided by both initramfs-tools and dracut). This is a bug, and should be reported as such.

In short, the only solution is to modify the dependencies of that packages. With the current situation, you cannot install dracut without having broken packages. (Though, if it's OK for you to have broken packages, then you can play with dpkg --force-all, remove initramfs-tools and install dracut.)


I looked a bit more, and it seems like this is the relevant bug on Launchpad:

https://bugs.launchpad.net/ubuntu/+source/net-retriever/+bug/1067934

I've confirmed that using the netboot files from the precise-updates directory fixes the issue for me. Good luck!

@Joren/@jokerdino: Comment-answers are a natural consequence of the 50 karma minimum for posting comments. In the future, maybe avoid punishing new Ubuntu users for mistakes in how this site has been configured.


Chromium freezes after resuming from standby (Kubuntu 14.04)

Deleting the .config/chromium folder and seems to have solved the issue.


It seems this requires python2, but not a specific version of it to execute. You need to have the python-minimal package installed, as it is what provides the /usr/bin/python symlink.


Ubuntu 12.04 Desktop package installed, but can't launch "gnome-terminal", "cannot open display"

Try setting the DISPLAY environment variable:

export DISPLAY=:0

If it helps, you can append this line to your .bashrc.


files list for package 'patch' is not a regular file

try -

Go into the /var/lib/dpkg directory
Make a backup of the "status" file
Open the status file as root and find the package that causes the error.
Delete all the text until the next PACKAGE: declaration in the file.

or you can use terminal to edit the status file as shown below but make a copy of that file before editing  -

sudo edit /var/lib/dpkg/status

If you could attach the complete error then only we can give you the direct and clear error, even we will do the same , but we can mention the line that has to be omitted.

hope it helped you.


iSCSI: ubuntu tgt with Windows Initiator

Problem solved: Ubuntu does not conform to RFC 3722 "String Profile for iSCSI Names" which states "In addition, any upper-case characters input via a user interface MUST be mapped to their lower-case equivalents."
My host is named UV1, so I set up an IQN like "iqn....:UV1-test" but the Windows initiator connects to "iqn....:uvi1-test" which is met with a "Target not found" ...


Running the guest OS in NAT networking mode and setting the port forwarding rules in the guest settings in VirtualBox so that port 5500 on my host forwards to 3389 on the guest allowed me to connect using localhost:5500 as the server IP and port in Remmina.


Running sudo -i in the console will drop you into "root" mode.


Uninstall Gnome completly from Ubuntu 14.04 LTS

I suggest using tasksel which is an ncurses based tool that allows you to install groups of packages ( used in the debian and ubuntu minimal installers).

After launching the tool from your terminal you will be given a list of package groups. to uninstall gnome simple untick ( using the spacebar) ubuntu-gnome-desktop this should give you a clean slate to work with once applied.


How do I start Compositing in LXDE for programs like docky?

When I clicked AskUbuntu to post this question, I searched one more thing and finally got the answer in the form of a youtube video. No tutorials exist that I could find. Therefore, please enjoy this post:

The first step is to install the manager that is going to be doing the work:
sudo apt-get update && sudo apt-get install xcompmgr
 This will go through the usual install routine. Once it is done, you need to run the following:
leafpad ~/.config/autostart/xcompmgr.desktop
 And paste the following:

[Desktop Entry]
Name=XCompositing Manager
GenericName=Compiz
Comment=This enables Compositing for LXDE
Exec=xcompmgr -n
Terminal=false
Type=Application
Icon=dropbox
Categories=
StartupNotify=false
Name[en_US]=Xcompmgr
Comment[en_US]=This was created by Geary

Save it and open your file manager to ~/.config/autostart and run the xcompmgr plug in. If docky is running, you should see the bar blink and come back with the better graphics enabled.


low resolution VGA monitors (640x480 or 480p) in Ubuntu

You can use xrandr:

The commands to be executed in order:

cvt 640 480
xrandr --newmode "640x480_31.00" 173.00 1920 2048 2248 2576 1080 1083 1088 1120 -hsync +vsync

The part of the line after xrandr --newmode is similar to the ouput you should get when using the cvt command, so copy the output from the "resolution_refreshRate" ("640x480_31.00" here) point to the +vsync point and add it to xrandr --newmode.

Then:

xrandr --addmode LVDS1 resolution_refreshRate (don't use speechmarks)
xrandr --output LVDS1 --mode resolution_refreshRate

If you want to make the changes permanent:

Create a bash script, xrandr.sh for example, and place your xrandr commands into it: #!/bin/bash
sudo xrandr --newmode ""640x480_31.00"" 173.00 1920 2048 2248 2576 1080 1083 1088 1120 -hsync +vsync
sudo xrandr --addmode LVDS1 640x480_31.00
xrandr --output LVDS1 --mode 640x480_31.00
Make the script executable with chmod +x xrandr.sh
Search for "Startup Applications" in the dash, run it, and add the script as a startup application.

The commands will now run every time you log into your account.

Note: I'm using LVDS1 as the supposed monitor name, but yours probably won't be the same. You can find your monitor name using:

xrandr | grep " connected " | awk '{ print$1 }'


I just ran this on a VM (Kubuntu 16.04) with hadoop version 2.7.3.

Prerequisites:

Ubuntu OS
Non-root user with sudo privileges
Installed java

Steps:

Download hadoop version from here by

Clicking the binary option under the tarball column for desired version
Click on the link under We suggest the following mirror site for your download: or right click and save link

if the link was saved then download using:

  wget http://www-us.apache.org/dist/hadoop/common/hadoop-2.7.3/hadoop-2.7.3.tar.gz

Check the integrity of the download:

Download .md5 file from download page

Run shasum -a 256 hadoop-2.7.3.tar.gz and compare result with cat hadoop-2.7.3.tar.gz.mds, at this line

...
 hadoop-2.7.3.tar.gz: SHA256 = D489DF38 08244B90 6EB38F4D 081BA49E 50C4603D B03EFD5E 594A1E98 B09259C2
...

Install hadoop:

Decompress and move:

tar -xzvf hadoop-2.7.3.tar.gz && sudo mv hadoop-2.7.3 /usr/local/hadoop

locate java on your system with:

readlink -f /usr/bin/java | sed "s:bin/java::"
# result
/usr/lib/jvm/java-8-openjdk-amd64/jre/

edit hadoop-env.sh file sudo nano /usr/local/hadoop/etc/hadoop/hadoop-env.sh:

Option 1 (static value):

#export JAVA_HOME=${JAVA_HOME}
export JAVA_HOME=/usr/lib/jvm/java-8-openjdk-amd64/jre/

Option 2 (dynamic value changes with change in java on system):

#export JAVA_HOME=${JAVA_HOME}
export JAVA_HOME=$(readlink -f /usr/bin/java | sed "s:bin/java::")

Run hadoop:

/usr/local/hadoop/bin/hadoop

Output:

Usage: hadoop [--config confdir] [COMMAND | CLASSNAME]
CLASSNAME            run the class named CLASSNAME
or
where COMMAND is one of:
fs                   run a generic filesystem user client
version              print the version
jar <jar>            run a jar file
                     note: please use "yarn jar" to launch
                          YARN applications, not this command.
checknative [-a|-h]  check native hadoop and compression libraries availability
distcp <srcurl> <desturl> copy file or directories recursively
archive -archiveName NAME -p <parent path> <src>* <dest> create a hadoop archive
classpath            prints the class path needed to get the
credential           interact with credential providers
                     Hadoop jar and the required libraries
daemonlog            get/set the log level for each daemon

Test:

mkdir ~/input
cp /usr/local/hadoop/etc/hadoop/*.xml ~/input

/usr/local/hadoop/bin/hadoop jar /usr/local/hadoop/share/hadoop/mapreduce/hadoop-mapreduce-examples-2.7.3.jar grep ~/input ~/grep_example 'principal[.]*';

Check for errors in the result:

 File System Counters
        FILE: Number of bytes read=1247674
        FILE: Number of bytes written=2324248
        FILE: Number of read operations=0
        FILE: Number of large read operations=0
        FILE: Number of write operations=0
 Map-Reduce Framework
        Map input records=2
        Map output records=2
        Map output bytes=37
        Map output materialized bytes=47
        Input split bytes=114
        Combine input records=0
        Combine output records=0
        Reduce input groups=2
        Reduce shuffle bytes=47
        Reduce input records=2
        Reduce output records=2
        Spilled Records=4
        Shuffled Maps =1
        Failed Shuffles=0
        Merged Map outputs=1
        GC time elapsed (ms)=61
        Total committed heap usage (bytes)=263520256
  Shuffle Errors
        BAD_ID=0
        CONNECTION=0
        IO_ERROR=0
        WRONG_LENGTH=0
        WRONG_MAP=0
        WRONG_REDUCE=0
 File Input Format Counters
        Bytes Read=151
 File Output Format Counters
        Bytes Written=37

Source:

https://www.digitalocean.com/community/tutorials/how-to-install-hadoop-in-stand-alone-mode-on-ubuntu-16-04

Add path to .bashrc:

# hadoop executable
export PATH="/usr/local/hadoop/bin:$PATH"


How can I create a a playlist file of all of the mp3s in the current directory from the terminal?

If an m3u file will suffice, just create a text file containing the directory you want (e.g. /home/user/music_for_playlist/ and save it with an m3u extension. m3u playlists allow this as a special instance, you don't have to enumerate all the files in the directory (your player does that when you open the playlist).

Alternatively, the following will create an m3u playlist containing all the mp3/wav/ogg/wma files in the current directory, this may be better if you want to exclude specific files or re-save the playlist:

find . -iregex '.*\.\(mp3\|wav\|ogg\|wma\)' -print > playlist.m3u


Per an answer to my original (since edited) question by bigjools, I'm posting his answer here as well. See below... thanks bigjools!

  Is it possible to specify an image or list of packages to install on a per-node basis in MAAS? Or, is this a job for juju instead?

That's a job for Juju.


Mp3 ID3 info in Nautilus properties window

There's something called MediaInfo which does this. Here's a link to the website:

https://mediaarea.net/en/MediaInfo

To install MediaInfo, enter the terminal and paste in the following commands:

sudo apt-get install mediainfo

nautilus -q && nautilus & (this restarts nautilus).

Now you should have a tab in the properties of audio files which looks like this:

picture


Unity 3d not working after Ubuntu 12.04 upgrade

Happening with me as well. Using Docky (which is working just fine) I can get to any application and it all works fine. Screenlets don't start. I got into software center and synaptic but couldn't identify anything I had updated that looked off. I am using 2D right now. All versions of Gnome work too.


How to upgrade from Ubuntu 14.04 LTS to Ubuntu 14.04.1 LTS?

If your system(14.04) is updated once successfully on or after the date July 24, 2014 your system must have 14.04.1 automatically.

If you didn't, Do the following,

Open terminal(Ctrl+Alt+T)

1) To update type following command in terminal,

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

2) To check it type following command in terminal,

$ lsb_release -a

You will get result as,

Distributor ID: Ubuntu
Description:    Ubuntu 14.04.1 LTS
Release:        14.04
Codename:       trusty


just like any laptop there is usually a key that makes the keyboard characters change or makes new characters appeared I were you I would go through your keys and see if anything works if not see if Ubuntu already has answered another question like this or look it up online.


Before you start playing with Juju, check your MAAS correct function.

Each time you add a new node in MAAS GUI and hit commision node, it should automaticaly boot the machine (node), run the commisioning scripts and then it will turn off the node with Ready state.

You can do this as many times as you want and this way you can check that MAAS is able to power on the node remotely, via PXE.

Once this works, you can call command

  juju add-machine node_with_name_in_maaas

this will force to power up the node, install ubuntu server, change the state to Allocated to ___ and then you can deploy charms on it..


Prompt string PS4 duplicating itself when using set -x

The distinction here is not where you place the -x, it's whether you specify a shell to use (either via a shebang, or by invoking the script explicitly with bash -x).
According to man bash, PS4:

   PS4    The value of this parameter is expanded  as  with  PS1  and  the
          value  is  printed  before  each command bash displays during an
          execution trace.  The first character of PS4 is replicated  mul‐
          tiple  times, as necessary, to indicate multiple levels of indi‐
          rection.  The default is ``+ ''.

however it is not forthcoming about what "levels of indirection" means in this context.
When you try to execute a text file without specifying what interpreter to use, the system call to execve fails with ENOEXEC (Exec format error). What happens next depends on the shell from which you are trying to execute it, as described here:

Which shell interpreter runs a script with no shebang?

In particular, if the invoking shell is bash, then the script appears to get executed directly by the invoking shell: this appears to be the "indirection" mentioned in the manual:
$ strace -e trace=%process -f bash -c 'echo "Starting $0"; ./hw_no_shebang; echo "Finished."'
execve("/bin/bash", ["bash", "-c", "echo \"Starting $0\"; ./hw_no_sheb"...], 0x7ffd3dadbee8 /* 25 vars */) = 0
arch_prctl(ARCH_SET_FS, 0x7f95fe939740) = 0
Starting bash
clone(child_stack=NULL, flags=CLONE_CHILD_CLEARTID|CLONE_CHILD_SETTID|SIGCHLD, child_tidptr=0x7f95fe939a10) = 26515
strace: Process 26515 attached
[pid 26514] wait4(-1,  <unfinished ...>
[pid 26515] execve("./hw_no_shebang", ["./hw_no_shebang"], 0x555e5058a4f0 /* 25 vars */) = -1 ENOEXEC (Exec format error)
++ echo Hello
Hello
++ echo World
World
++ set +x
[pid 26515] exit_group(0)               = ?
[pid 26515] +++ exited with 0 +++
<... wait4 resumed> [{WIFEXITED(s) && WEXITSTATUS(s) == 0}], 0, NULL) = 26515
--- SIGCHLD {si_signo=SIGCHLD, si_code=CLD_EXITED, si_pid=26515, si_uid=1000, si_status=0, si_utime=0, si_stime=0} ---
wait4(-1, 0x7fffba5272d0, WNOHANG, NULL) = -1 ECHILD (No child processes)
Finished.
exit_group(0)                           = ?
+++ exited with 0 +++

Note that the bash -c in the strace call here takes the place of your interactive shell, rather than of the bash -x that you used in your last example.
As soon as we add a shebang, ex.:
$ cat hw_shebang
#!/bin/bash

set -x
echo "Hello"
echo "World"
set +x

then (regardless of whether -x is invoked using set or otherwise), then execve succeeds and the script is executed in its own shell, without "indirection":
$ strace -e trace=%process -f bash -c 'echo "Starting $0"; ./hw_shebang; echo "Finished."'
execve("/bin/bash", ["bash", "-c", "echo \"Starting $0\"; ./hw_shebang"...], 0x7ffccc0af338 /* 25 vars */) = 0
arch_prctl(ARCH_SET_FS, 0x7f81b9ed2740) = 0
Starting bash
clone(child_stack=NULL, flags=CLONE_CHILD_CLEARTID|CLONE_CHILD_SETTID|SIGCHLD, child_tidptr=0x7f81b9ed2a10) = 26553
strace: Process 26553 attached
[pid 26552] wait4(-1,  <unfinished ...>
[pid 26553] execve("./hw_shebang", ["./hw_shebang"], 0x55879d9924f0 /* 25 vars */) = 0
[pid 26553] arch_prctl(ARCH_SET_FS, 0x7fa55de83740) = 0
+ echo Hello
Hello
+ echo World
World
+ set +x
[pid 26553] exit_group(0)               = ?
[pid 26553] +++ exited with 0 +++
<... wait4 resumed> [{WIFEXITED(s) && WEXITSTATUS(s) == 0}], 0, NULL) = 26553
--- SIGCHLD {si_signo=SIGCHLD, si_code=CLD_EXITED, si_pid=26553, si_uid=1000, si_status=0, si_utime=0, si_stime=0} ---
wait4(-1, 0x7ffda2983b10, WNOHANG, NULL) = -1 ECHILD (No child processes)
Finished.
exit_group(0)                           = ?
+++ exited with 0 +++

If you'd invoked the no-shebang script from dash for example, the behavior would be different: after the initial failed execve, it would have execve'd /bin/sh to execute the script:
$ strace -e trace=%process -f dash -c 'echo "Starting $0"; ./hw_no_shebang; echo "Finished."'
execve("/bin/dash", ["dash", "-c", "echo \"Starting $0\"; ./hw_no_sheb"...], 0x7ffc283d8638 /* 25 vars */) = 0
arch_prctl(ARCH_SET_FS, 0x7fd2cc787540) = 0
Starting dash
clone(child_stack=NULL, flags=CLONE_CHILD_CLEARTID|CLONE_CHILD_SETTID|SIGCHLD, child_tidptr=0x7fd2cc787810) = 26590
strace: Process 26590 attached
[pid 26589] wait4(-1,  <unfinished ...>
[pid 26590] execve("./hw_no_shebang", ["./hw_no_shebang"], 0x557143e3c8d8 /* 25 vars */) = -1 ENOEXEC (Exec format error)
[pid 26590] execve("/bin/sh", ["/bin/sh", "./hw_no_shebang"], 0x557143e3c8d8 /* 25 vars */) = 0
[pid 26590] arch_prctl(ARCH_SET_FS, 0x7f3b9aa14540) = 0
+ echo Hello
Hello
+ echo World
World
[pid 26590] exit_group(0)               = ?
[pid 26590] +++ exited with 0 +++
<... wait4 resumed> [{WIFEXITED(s) && WEXITSTATUS(s) == 0}], 0, NULL) = 26590
--- SIGCHLD {si_signo=SIGCHLD, si_code=CLD_EXITED, si_pid=26590, si_uid=1000, si_status=0, si_utime=0, si_stime=0} ---
Finished.
exit_group(0)                           = ?
+++ exited with 0 +++


How to open Ubuntu without a user name and password

Well, you kind of need a user to run the whole graphical interface, but you can set Ubuntu to skip the login screen.

But first you need to reset the password of your user, you can do it like this: (taken from Ubuntu Recovery Mode)

Switch on your computer.
Wait until the BIOS has finished loading, or has almost finished. (During this time you will probably see a logo of your computer manufacturer.)
Quickly press and hold the Shift key, which will bring up the GNU GRUB menu. (If you see the Ubuntu logo, you've missed the point where you can enter the GRUB menu.)

Select the line which starts with "Advanced options".

Select the line ending with "(recovery mode)", probably the second line, something like:

Ubuntu GNU/Linux, with Linux 3.8.0-26-generic (recovery mode)

Press Return and your machine will begin the boot process.

After a few moments, your workstation should display a menu with a number of options. One of the options (you may need to scroll down to the bottom of the list) will be "Drop to root shell prompt". Press Return with this option highlighted.

The root partition is mounted read-only. To mount it read/write, enter the command

mount -o remount,rw /

Since you seem to have forgotten what your username was, have a look at the passwd file :

cat /etc/passwd

Near the bottom of the output you should find a line that tells you your username next to "1000:1000"(which is the ID of the first user)

<username>:x:1000:1000:<username>,,,:/home/<username>:/bin/bash

now you can set a password for this user

passwd <username>

Now you can reboot your VM

reboot

Log in with your username and password (that you just set)

Now you can enable "automatic login" - click the small downwards arrow in the right upper corner

Click your username

Click the symbol of a padlock that is displayed in the menu bar near "Unlock" and enter your password

Now you can toggle on "Automatic Login" and close the window and you are done - on the next reboot you should not need to login any more


Problems changing resolution using xrandr: Bad Match

Ok, at the time of writing this answer, you don't have a menu bar, and I haven't seen your xorg.conf file yet, but I believe I know enough to know what you need to do, and I believe you will be able to make changes to your xorg.conf file from recovery mode if you can't do it in normal boot mode without a menu bar.

First of all, I believe the [    28.338] (WW) NVIDIA: GPU:0: Unable to read EDID for display device DVI-I-0 warnings are significant, but I don't think anything is "wrong", more that it might be a limitation of your monitor, or VGA cables, or your computer, or some combination. My computer, VGA, TV combination also does not detect the EDID automatically.

Wikipedia has an entry on EDID that you may find a useful reference: https://en.wikipedia.org/wiki/Extended_Display_Identification_Data

You have already created an xorg.conf file, but for completeness I will include the steps in this answer. You follow Alexander Malakhov's answer in this question:

Alt+Ctrl+F1 to switch to console mode
Stop the X server by stopping the display manager: sudo service gdm stop (or sudo service lightdm stop if you have Lubuntu and/or LXDE environment).
sudo X -configure to create an xorg.conf.new file
sudo mv xorg.conf.new /etc/X11/xorg.conf to rename and move the file to where the xorg.conf goes
sudo service gdm start or sudo service lightdm start to restart the display manager and X server. sudo start gdm and sudo start lightdm also work.

You now have the file /etc/X11/xorg.conf file. What it says now and what it should say depends on your own system. I shall share the relevant parts of my own xorg.conf file (correctly configured for my system) here and talk you through it.

But first, how to edit it? If everything is working correctly, then you can edit it by opening a terminal and typing sudo nano /etc/X11/xorg.conf. If you are having trouble editing it in normal boot mode, then you can edit it in recovery mode: start your computer, and from the grub boot menu, select "Advanced options", then the recovery mode of your most recent kernel, then select the root shell prompt. You will need to enter the command: mount -o remount,rw / to make everything read-write. Then you can edit the xorg.conf file with the command nano /etc/X11/xorg.conf (sudo is not needed in root shell prompt mode). (When you are done with root shell prompt, enter exit, then select "Resume normal boot", you might then need to reboot to see if changes have taken effect.)

This link gives helpful info on recovery mode.

Here are the relevant parts of my xorg.conf file, yours may differ. You can access the xorg.conf manual by typing man xorg.conf into a terminal, or you can find it in several places on the internet, like here. There is also an Ubuntu wiki on it here.

Section "Monitor"
    Identifier   "Monitor0"
    VendorName   "Monitor Vendor"
    ModelName    "Monitor Model"
        HorizSync       28.0 - 83.0
        VertRefresh     56.0 - 75.0
EndSection

Section "Device"
        ### Available Driver options are:-
        ### Values: <i>: integer, <f>: float, <bool>: "True"/"False",
        ### <string>: "String", <freq>: "<f> Hz/kHz/MHz",
        ### <percent>: "<f>%"
        ### [arg]: arg optional
        #Option     "SWcursor"              # [<bool>]
        #Option     "kmsdev"                # <str>
        #Option     "ShadowFB"              # [<bool>]
    Identifier  "Card0"
    Driver      "sis"
    BusID       "PCI:1:0:0"
EndSection

Section "Screen"
    Identifier "Screen0"
    Device     "Card0"
    Monitor    "Monitor0"
    SubSection "Display"
        Viewport   0 0
        Depth     1
    EndSubSection
    SubSection "Display"
        Viewport   0 0
        Depth     4
    EndSubSection
    SubSection "Display"
        Viewport   0 0
        Depth     8
    EndSubSection
    SubSection "Display"
        Viewport   0 0
        Depth     15
    EndSubSection
    SubSection "Display"
        Viewport   0 0
        Depth     16
    EndSubSection
    SubSection "Display"
        Viewport   0 0
        Depth     24
                 Modes     "1360x768"
    EndSubSection
EndSection

I believe you would have the correct Driver in your Section "Device", yours should be something like nvidia.

Next, let's look at Section "Screen". You may, like me, have a number of subsections, in which case the only one you need to worry about is the Depth    24 subsection. Insert the line:

Modes     "1680x1050"

into that subsection. Your computer was not able to determine the screen size using EDID, so we are manually telling the computer what the screen size is.

I believe this is the change you need to make to get it working. Reboot the machine and see if the resolution is fixed.

There is a chance you may need to make a further change: in the Section "Monitor" section, you can see HorizSync and VertRefresh lines in my xorg.conf. You may also need these lines in yours. However, the range you need to specify for both lines depends on your monitor. If you have the manual for your monitor, look in the "specifications" towards the back of the manual. If you do not have the manual, ASUS appear to provide them on their website, but I do not know the model name/number of your monitor. You may be able to get the model name/number from a sticker on the back of the monitor.

Somewhere in the Specifications section of the manual is a tabulated list of resolutions, and corresponding horizontal and vertical values. You want the HorizSync range to include all horizontal values for every resolution that you might use: find the lowest value in the list and make that the lower limit, and make the upper limit the same as the highest value in the list. Likewise, with the VertRefresh, use the lowest and highest values in the Vertical column (an ASUS manual I have picked at random just calls this "Refresh Rate"). If you add the HorizSync and VertRefresh lines, then save and reboot to see if this fixes the problem.

Please do share by comment, at which point, if any, the resolution issue is fixed. If it is still not fixed, we may need to look at your /etc/X11/xorg.conf and /var/log/Xorg.0.log files again.


How to fix external hard disk READ ONLY?

Try executing the following command in a terminal:
sudo mount -o remount,uid=1000,gid=1000,rw /dev/sdc1

Explanation:

-o means "with these options".
remount - remounts the drive over the same mount point with the same previous options.
uid=1000 - this option makes the user with id 1000 the owner of the drive. This is probably your username's id if you only have one username. If you have more than one username on your system, run the command id and use the number after uid=.
gid=1000 - this option makes the group with id 1000 the group owner of the drive. Same notes as previous point.
rw - this option mounts the drive as read/write. It was probably read/write anyways, but this is just to double check.
/dev/sdc1 is the name of the partition or device (can be checked in GParted in case you need to do the same with a different hardisk)

Since you've already tried this command and it didn't work, let's try manually mounting the drive. Follow the below:

sudo umount /dev/sdc1

This unmounts the drive.

sudo mkdir toshibaHDD

This will create a new mount point.

sudo mount -o rw,uid=1000,gid=1000,user,exec,umask=003,blksize=4096 /dev/sdc1 /media/toshibaHDD

user - permits any user to mount the drive
exec - allows for execution of binaries on this drive. You can remove this option if you want.
umask=003 - this will give rwxrwxr-- permissions to everything (directories and files) inside the drive. Alternatively, you can use dmask and fmask instead of umask to give separate permissions to directories and files (respectively).
/media/toshibaHDD - is the name of the hardisk (can be checked in GParted in case you need to do the same with a different hardisk)

Now check the permissions of your drive.

##Edit
Follow the steps to make it permanent:

Unplug your external hard disk.
cd /etc
sudo cp fstab fstab.bak

This takes a backup of the file we're about to edit.

sudo nano fstab

This opens up the fstab file in a text editor.

Move the blinking cursor to the end of the file, and paste the following two lines:
 # line for mounting the external drive
 UUID=D04A-0AE4   /media/toshibaHDD  exfat   rw,uid=1000,gid=1000,user,exec,umask=003,blksize=4096   0   0

Hit Ctrl+X, then Y, then Enter to save and close.

That's it. Now, when you plug your external hard disk in, it will always have those options.


I found the solution. I can use the NAT tables:

# the ip of node which is in MSD network. This can be for example edge node
IP_OF_SOURCE_NODE=50.50.50.1
# ip of destination database where we want to connect (do not forget on port)
IP_OF_DESTINATION_NODE=50.50.30.1:22
# ip address of VPN network adapter
IP_OF_VPN_NETWORK_ADAPTER=50.50.51.1

# Need to change the destination ip to database ip for the packets incoming from default network from specific source (for example dge node)
iptables -t nat -A PREROUTING -i ens5 -p tcp -s ${IP_OF_SOURCE_NODE} --dport 22 -j DNAT --to-destination ${IP_OF_DESTINATION_DATABASE}

# Need to change the source ip to inet address of vpn network address for packets leaving VPN network adapter
iptables -t nat -A POSTROUTING -o tun0 -p tcp -s ${IP_OF_SOURCE_NODE} --dport 22 -j SNAT --to-source ${IP_OF_VPN_NETWORK_ADAPTER}

After this I successfully connect to node 50.50.30.1 from 50.50.50.1 via 50.50.40.1


Screencloud Tray Icon Disappeared, Already Installed libqt4-svg

This question is related to this one. It happen to me after an update the icons disappear.

You should do the following.

sudo apt-add-repository ppa:gurqn/systray-trusty
sudo apt-get update
sudo apt-get upgrade

This is an article of Ubuntu Forum


Macbook Pro boots with full screen brightness and keyboard backlight

To fix the screen brightness on my Macbook I stopped the apple_bl kernel module from being loaded. This seem to fix this for me.

Create a file called: /etc/modprobe.d/blacklist-applebl.conf
In the above file add the line:

 blacklist apple_bl

Reboot.


How to install Point Cloud Library v1.8 (pcl-1.8.0) on Ubuntu 16.04.2 [LTS] for C++?

INSTALLATION

Install oracle-java8-jdk:

sudo add-apt-repository -y ppa:webupd8team/java && sudo apt update && sudo apt -y install oracle-java8-installer

Install universal pre-requisites:

sudo apt -y install g++ cmake cmake-gui doxygen mpi-default-dev openmpi-bin openmpi-common libusb-1.0-0-dev libqhull* libusb-dev libgtest-dev
sudo apt -y install git-core freeglut3-dev pkg-config build-essential libxmu-dev libxi-dev libphonon-dev libphonon-dev phonon-backend-gstreamer
sudo apt -y install phonon-backend-vlc graphviz mono-complete qt-sdk libflann-dev

For PCL v1.8, Ubuntu 16.04.2 input the following:

sudo apt -y install libflann1.8 libboost1.58-all-dev

cd ~/Downloads
wget http://launchpadlibrarian.net/209530212/libeigen3-dev_3.2.5-4_all.deb
sudo dpkg -i libeigen3-dev_3.2.5-4_all.deb
sudo apt-mark hold libeigen3-dev

wget http://www.vtk.org/files/release/7.1/VTK-7.1.0.tar.gz
tar -xf VTK-7.1.0.tar.gz
cd VTK-7.1.0 && mkdir build && cd build
cmake ..
make
sudo make install

cd ~/Downloads
wget https://github.com/PointCloudLibrary/pcl/archive/pcl-1.8.0.tar.gz
tar -xf pcl-1.8.0.tar.gz
cd pcl-pcl-1.8.0 && mkdir build && cd build
cmake ..
make
sudo make install

cd ~/Downloads
rm libeigen3-dev_3.2.5-4_all.deb VTK-7.1.0.tar.gz pcl-1.8.0.tar.gz
sudo rm -r VTK-7.1.0 pcl-pcl-1.8.0

For PCL v1.8.1, Ubuntu 17.10 input the following:

sudo apt -y install libflann1.9 libboost1.63-all-dev libeigen3-dev

cd ~/Downloads
wget http://www.vtk.org/files/release/8.0/VTK-8.0.1.tar.gz
tar -xf VTK-8.0.1.tar.gz
cd VTK-8.0.1 && mkdir build && cd build
cmake ..
make
sudo make install

cd ~/Downloads
wget https://github.com/PointCloudLibrary/pcl/archive/pcl-1.8.1.tar.gz
tar -xf pcl-1.8.1.tar.gz
cd pcl-pcl-1.8.1 && mkdir build && cd build
cmake ..
make
sudo make install

cd ~/Downloads
rm VTK-8.0.1.tar.gz pcl-1.8.1.tar.gz
sudo rm -r VTK-8.0.1 pcl-pcl-1.8.1

VALIDATION

cd ~
mkdir pcl-test && cd pcl-test

Create a CMakeLists.txt file:

cmake_minimum_required(VERSION 2.8 FATAL_ERROR)
project(pcl-test)
find_package(PCL 1.2 REQUIRED)

include_directories(${PCL_INCLUDE_DIRS})
link_directories(${PCL_LIBRARY_DIRS})
add_definitions(${PCL_DEFINITIONS})

add_executable(pcl-test main.cpp)
target_link_libraries(pcl-test ${PCL_LIBRARIES})

SET(COMPILE_FLAGS "-std=c++11")
add_definitions(${COMPILE_FLAGS})

Create a main.cpp file:

#include <iostream>

int main() {
    std::cout << "hello, world!" << std::endl;
    return (0);
}

Compile:

mkdir build && cd build
cmake ..
make

Test:

./pcl-test

Output -> hello, world!

This method of installation aims to be as compatible as possible and make for an easy means of getting up and running with the Point Cloud Library. This method does not include Kinect configuration which requires the prior installation of further packages before pcl can be set up.


Remove install dialog from ubuntu usb stick

You can do that by first formatting the USB and then install the ISO image to a CD.

Next plug both USB and CD in and reboot. When you reboot to the CD select install but install it to your USB drive and for the bootloader select your USB drive unless you want problems.


Unless you've skipped some characters when writting the syslog output in your question, it looks like you've made a typo in your CRON command by forgetting the / in front of the command that should looks like :

/home/wayne/scripts/mysql_backup.sh


You should use NTFS format.
Why?
because the max size of a single file that can be stored on a FAT32-formatted HDD is 4GB (on NTFS Maximum file size: 16 TB), that means if you have to store a 9GB movie, you won't be will be able to store that on this.
on the other hand, NTFS is supported by Windows, Mac, and Linux.
FAT32 formateed drives are more vulnerable to disk errors.


Multiple terminal windows in Windows Ubuntu?

Windows Terminal Way:

Windows Terminal is a terminal emulator for Windows 10 written by Microsoft.

Download it from Microsoft Store
Click on Drop-down and choose Ubuntu. If it doesn't exists add that. See: How do I add application on Windows Terminal?

CMD Way:

This could be achieved. You need to open multiple windows of command prompt and type ubuntu or ubuntu1604 or ubuntu1804 depending on the version you've downloaded on all the prompts. You'll get multiple terminals.

In this screenshot I have opened one "Terminal" in app and four in cmd


Validity Sensor (138a:0017) fingerprint reader not working

Finally the official package libfprint0 in repo of 15.10 does support this reader(138a:0017).

I have a T440p with same fingerprint reader, I've tried it some weeks ago as login credential.

Now I give it up, because comparing with windows driver and application, its accuracy is a bit poor; but at least, it can be correctly recognized by system.


How do I use the console fonts in normal applications?

AFAIK You cannot use those fonts in normal applications because they are not the right kind of font. These "console fonts" are purely bitmap fonts for use on the command line (specifically ttys and on boot, etc).

Fonts you would use in your applications are usually either truetype or opentype fonts, and another kind of bitmap font (I forgot the extension).

If pcf is supported by applications (I don't remember) you can copy the .pcf files to /usr/share/fonts and then restart your computer or update your font cache.


Can't find file for Ubuntu 64 bit to load into the pendrivelionux program

You have first to download the ISO  Once that is done, make sure you save it to a known location.  Proceed with either Universal USB Installer or UNetbootin.

  The recommended way to install Ubuntu from a USB flash drive is to use
  the usb-creator program, point it at a ISO image of a Ubuntu
  installation CD that you have downloaded, and let it create a bootable
  USB that you can use instead of the CD.

Source: Installation/FromUSBStick


It is my experience that Windows updates knock out the dual boot process.  How exactly, I don't know.  I fix it either by reinstalling Ubuntu (there is an option that repairs and saves your files) or; with USB bootable stick and recovery mode.  In recovery mode, various options will clean & repair the grub entries.


Network failure when booting with network cable plugged

Maybe is problem on device boot order in bios. Go to bios and change order of boot devices or turn off PXE boot aka boot via lan card.


Nvidia Problems - how to completely "reset" Xorg?

Generally speaking you can reset xserver with

sudo dpkg-reconfigure xserver-xorg

or

sudo X -configure

But I've seen cases of people for which this didn't work.


Ubuntu is available for only Nexus smart phones. That too only for developer purpose. I don't think there is any custom rom available as of now for other devices.


According to this post on UbuntuForums.org:

  You need to pay attention to your error message and issue a command
  for your missing locale.

  For example, this is the error I got:

  Code:

perl: warning: Setting locale failed. perl: warning:
Please check that your locale settings:
LANGUAGE = "en_CA:en",
LC_ALL = (unset),
LANG = "en_CA"
are supported and installed on your system.
perl: warning: Falling back to the standard locale ("C").

  The LANG string is the one you need.

By the looks of your error message, this should work for you:

sudo locale-gen en_US en_US.UTF-8 pl_PL pl_PL.UTF-8
sudo dpkg-reconfigure locales

In retrospect, googling this error message reveals a lot of fixes; but very little in the way of "why" or "how" it is caused.  I suspect it has something to do with users running multiple locales, which may exist in varying degrees of completeness.  But I really don't have anything to base that on, other than:

I have never seen it on my own machines.
Users on my machines are configured to use only one locale.

Further references:

installArchives() failed: perl: warning: Setting locale failed.
https://help.ubuntu.com/community/Locale


How to disable input language switching in terminal

Note on the answer below

The answer was originally written for 14.04, but rewritten January 6, 2017, to also work on (at least) 16.04 and 16.10. wmctrl is no longer needed.

Script to automatically set a different language for a single application.

What it does

Running the script in the background, the user can set a different language for a specific application (in this case gnome-terminal). Just run the script and, with the application in front, set the desired language.
The language will be remembered, in the script (while running) as well as in a hidden file, to be remembered on the next time the script runs (on restart of the computer).
If the user sets focus to another application, the script switches back to the default language, whatever that was. Also the default language will be remembered, but user can change it any time (also the changed language is remembered)

Notes

The script uses an extended set of tools (functions) to take into account that user should be able to change the set of used languages, and the languages should be remembered, as suggested in the comment(s). Nevertheless it is very "light", since it only uses the function(s) when it is needed.

The script

#!/usr/bin/env python3
import subprocess
import time
import os
import ast

#--- set the "targeted" exceptional application below
app = "gnome-terminal"
#---

l_file = os.path.join(os.environ["HOME"], app+"_lang")
def_lang = os.path.join(os.environ["HOME"], "def_lang")
k = ["org.gnome.desktop.input-sources", "current", "sources"]

def get(cmd):
    # helper function
    try:
        return subprocess.check_output(cmd).decode("utf-8").strip()
    except subprocess.CalledProcessError:
        pass

def run(cmd):
    # helper function
    subprocess.Popen(cmd)

def front():
    # see if app has active window
    front = get(["xdotool", "getactivewindow"])
    data = get(["xprop", "-id", front])
    if all([front, data]):
        return app in get(["xprop", "-id", front])
    else:
        pass

def getlang():
    # get the currently set language (from index, in case the sources are changed)
    currindex = int(get(["gsettings", "get", k[0], k[1]]).split()[-1])
    return sources[currindex]

def get_stored(file):
    # read the set language
    return sources.index(ast.literal_eval(open(file).read().strip()))

def get_sources():
    return ast.literal_eval(get(["gsettings", "get", k[0], k[2]]))

sources = get_sources()
appfront1 = None
currlang1 = getlang()

while True:
    time.sleep(1)
    appfront2 = front()
    if appfront2 != None:
        currlang2 = getlang()
        # change of frontmost app (type)
        if appfront2 != appfront1:
            if appfront2:
                try:
                    run(["gsettings", "set", k[0], k[1], str(get_stored(l_file))])
                except FileNotFoundError:
                    open(l_file, "wt").write(str(currlang2))
            elif not appfront2:
                try:
                    run(["gsettings", "set", k[0], k[1], str(get_stored(def_lang))])
                except FileNotFoundError:
                    open(def_lang, "wt").write(str(currlang2))
        elif currlang2 != currlang1:
            f = l_file if appfront2 else def_lang
            open(f, "wt").write(str(currlang2))

        appfront1 = appfront2
        currlang1 = currlang2

How to use

The script uses xdotool:

sudo apt-get install xdotool

Copy the script above into an empty file, save it as set_language.py
Test-run it by the command:

python3 /path/to/set_language.py

While running the script:

set the (default) language.
open the (gnome-) terminal, set the language to be used with the terminal
Switch between the two and see if the language automatically switches.

You can change both default language as the terminal language at any time. The set language(s) will be remembered.
If all works as expected, add it to Startup Applications: Add to Startup Applications: Dash > Startup Applications > Add. Add the command:

python3 /path/to/set_language.py

Explanation, the short (conceptual) story:

The script uses two files, to store the set languages for both the default language and the language, used in the exceptional application (gnome-terminal in this case, but you can set any application).

The script then periodically (once per second) does two tests:

If the active window belongs to the exceptional application
What is the currently set input language

The script compares the situation with the test(s) one second ago. Then if:

there was a change in application:

exceptional --> default: read language file for default language & set language. If the file does not exist (jet), create it, store the current language as default.
default --> exceptional: the other way around.
If there was a change in language (but not in window class):

We may assume user set a different language for either the exceptional application or the default input language --> write the currently used input language into the according file (either for default language or the exceptional language).


Help needed with Eazycap (somagic) PLEASE!

AFAIK, this driver is only able to put out video through stdout, which is then directed into mplayer or ffmpeg.

This script will duplicate this stream with tee, and direct it into both mplayer and ffmpeg.

https://gist.github.com/Brick85/0b327ac2d3d45e23ed33

It requires some tweaking, like replacing PAL with NTSC, if appropriate.


How to restart a sleeping PC at scheduled time if unattended-upgrades has scheduled a restart

"Reboot required" is indicated by the existence of the files /var/run/reboot*.
You could create a root cron job (note: root's crontab is a different format, read man 5 crontab), to run at 4AM and do something like:
#!/bin/bash
zz="$(find /var/run -type f -name 'reboot*')"
[[ -n "$zz" ]] && shutdown -r +10


Why is my laptop keyboard laggy after Ubuntu upgrade?

This is probably a driver issue and not related to Ubuntu (but not entirely sure).
After my charger was destroyed I used a ThunderBolt charger from another laptop (the original wasn't ThunderBolt). On Dell forums I found the following link which led me to try pulling out the ThunderBolt cable, and then that led to my laptop keyboard being as good as normal:
https://www.dell.com/community/XPS/XPS-13-9370-amp-TB16-USB-Keyboard-Lag-Missing-Keystrokes/td-p/6070559/page/3
So if I am charging via Thunderbolt the keyboard is too laggy to use but an external keyboard is fine; if I stop charging via Thunderbolt then the laptop keyboard works fine.


HDMI port has stopped working on 12.04 LTS

I have fixed it. I ended up plugging it into a monitor with a lower resolution and was able to then enable the second monitor in the Systems Settings -> Screen Display window and then it worked with the original 1080p monitor again.


If your shell is bash, one way could be to use commands in ~/.bash_logout. From man bash:

When a login shell exits, bash reads and executes commands from the file
~/.bash_logout, if it exists.

SSH runs a login shell, so when it exits .bash_logout should be run. You can check whether it is an SSH session by testing the value of the SSH_TTY variable. So you can edit (or create) ~/.bash_logout containing, for example:

if [[ -n $SSH_TTY ]]
then
    stop your service
fi


error during the cups operation 'client-error-document-format-not-supported'

Legacy (non-modern) printers require printer drivers.
sudo apt-get install printer-driver-all
sudo systemctl restart cups

Also, make sure your printer is being added in Settings > Printers

You could also add the printer from the cups web interface at localhost:631.
Under administration click on Find New Printers. If your printer is plugged in you'd find it under the local printers.


secure is Installation of ubuntu or should be dual with windows?

I would definitely recommend the third choice.

Like you said, the first choice is bad since you're basically running within Windows. The second choice is alright, but if you can run Ubuntu on a separate HDD that would be best in my opinion.

If Ubuntu gets corrupted, there's no need for you to format the drive or partitions before recovering your data. If you're going to be running Windows as well, you can access the Linux partitions, granted that you don't encrypt them (if you do I'm sure you still can I just don't know how)

WIndows 7 can natively read Ext2, 3 and 4. If you're using an earlier version of Windows you can download and use ext2fsd to view the linux partitions.


telnet to zimbra 110 port failed from ubuntu 12.04

Verify that pop3 service is up with sudo netstat -tulnp | grep 110

If it is up, then there's probably something in between is blocking port 110.


The repository 'http://ppa.launchpad.net/moonlight-team/pinta/ubuntu bionic Release' does not have a Release file

Looking deeper, going through ./pool/main/p/pinta/ you can see this repos is ancient:

pinta_0.5+dfsg-1~dhx1_all.deb   2010-11-03 20:27

While I'm sure you can download the packages manually, I would suggest this is a dead repo and should be left well alone. The "official" pinta-maintainers/pinta-stable repo is in a similar state, last updated in 2015.

Pinta itself seems a bit abandoned (last release was 2015) and while it still works (I have it installed) the packaging for it, how it links into the rest of the system, needs regular maintenance as Ubuntu changes. Your best bet is probably installing it from a Flatpak package. These have the advantage that they get bundled with most of their requirements so should keep working indefinitely, often to a fault.


Your filepath looks invalid, Ubuntu doesn't have a C drive.

Do a 'Save As...' instead and save your file wherever you'd like.