How do I wake from sleep using a bluetooth Keyboard

What I found

I am going to take the time to explain a few things that I found out. This should help people understand why this is such a complicated process, and what they can do to help make it better, at least for them.

First, the Bluetooth radio on the MBP is a "USB" device. This is quite common on laptops and even some desktops. Because of that Linux treats it as a USB device and you can configure it accordingly.

Second, the Bluetooth radio has two modes HID mode with is a very basic "profile" for keyboards and mice only. This mode is what lets you use the keyboard before there is a Application managing the Bluetooth device. For  example when your using your Bluetooth keyboard in the GRUB menu, that is HID mode. Your laptop and your keyboard still need to be paired, but they can operate at this very low level without issue or intervention (again once paired). However HID mode is very limited, and certain things will not work. For instance the battery level of the keyboard will not work. Also in HID mode I had a hard time with function keys and media keys (on this keyboard they are the same key and it can be toggled by software).

Next, you need to get the keyboard to send "something" to the laptop. You also need the laptop to receive "something". Then you have to tie it all together to get the laptop to actually wake up.

Finally, Linux, Ubuntu, Bluez, or someone, seems to think that all Bluetooth controllers should act in HCI mode. This is probably a very sane default given that even this keyboard is very limited in HID mode, and that anything beyond a simple mouse and keyboard (for example a cell phone, or head set) would require HCI mode. However HCI mode requires a full software stack to run and will not run while the laptop is suspended/sleep/powered off. So by default when your laptop sleeps it disconnects your keyboard and quits listening.

Actual Steps to get it Working

Step 0: A workaround

When I was doing this I got very frustrated by the fact that I was unable do anything to trouble shoot the issue. You can't do anything when the laptop is asleep, and at least with the Mac Book Pros you can't close the lid without them going to sleep. So your left with a situation where either Video won't work (because it's going to your external monitor that isn't plugged in when undocked) or you can see everything but have no keyboard (because it's not working/paired/whatever, and the internal one is not accessible).  To get around this should you run into it. Use the visual keyboard at LDM's login screen. If you wake up to a password prompt, you should be able to click switch user, then use the visual keyboard to login. As long as you login as the same user your session should not be lost. That said, I wouldn't leave any work unsaved while going through these steps.

Step 1: Pre-pair your keyboard.

As I was testing I noticed this step was required. However, I don't fully understand why. Apple does some strange stuff so I am just gonna let it go.

Reset your PRAM/NVRAM/Whatever. This will clear your current OS X settings, and may not be needed but better to start clean. The Apple support website has instructions. You do not need to reset the PMU.
Start, or restart, into OS X and pair your keyboard normally. I recommend leaving all your other bluetooth devices turned off and focusing on your keyboard. From what I can tell this will store some information in NVRAM and all the keyboard to communicate with the powered down laptop.
Click on Advanced (in OS X, once paired) and check "Allow bluetooth devices to wake computer". Once again the apple support website has instructions
Restart the computer into Linux. At ReFIT/GRUB/while booting the keyboard should work just fine.

Step 2: Getting Linux to work with the keyboard

For some reason the keyboard will loose it's pairing as you login. Probably because the Bluetooth controller is switched to HCI mode. To correct this, you need to pair in Linux. This will break the pairing you did in step 1, but will not break HID mode when the laptop is powered off or booting. That said, when you reboot, your keyboard won't work till your bluetooth stack is fully running again in HCI mode. This is because the keyboard is trying to talk in HCI mode but no one is listening. If you shutdown and wait for the connection to time out, the keyboard will work again in HID mode.

Install bluez-compat by running sudo apt-get install bluez-compat This will allow you to pair with ease. Without the Bluetooth manager just crashed for me.
Pair your Keyboard normally with Linux. Run Bluetooth from the Unity Dash and click the plus. Put your keyboard in pairing mode (hold down the power button on the Apple Wireless keyboard) and follow the instructions. It should pair quite smoothly. At this point your keyboard should work just fine in Linux and even sends signals to a HID controller when the laptop is asleep.

Step 3: Telling Linux it needs to wake up

Now we need to tell Linux to wake up if the bluetooth device gets "something". To do this is pretty easy thanks to the scripts at this site. Basic instructions are below but you should read the site if anything is unclear. Almost all of this comes from the linked site.

Install some dependencies sudo apt-get install notify-send zenity
Download the udev resume script and copy to /usr/local/sbin/enable-wakeup.
Download the device selection script and copy to /usr/local/sbin/select-resume-devices
Make the scripts executable: chmod a+x /usr/local/sbin/select-resume-devices and chmod a+x /usr/local/sbin/enable-wakeup.
Run with root permissions the device selection script. sudo /usr/local/sbin/select-resume-devices
Select, at a minimum, "Apple, Inc. Bluetooth Host Controller", "Belkin Components B8T017 Bluetooth+EDR 2.1", "Apple Inc. Internal Keyboard/Trackpad (ANSI)" and any other devices you want to use to resume your computer.
Click OK.
Review the file /etc/udev/rules.d/90-hid-wakeup-enable.rules and make sure it makes sense.
Restart the computer.

Step 4: Testing and catches

Everything should work fine now that you restarted your computer. Once your logged back in, put your computer in sleep mode somehow. Smack a key on your keyboard and the laptop should resume. There are however a couple of catches.

When the computer is in sleep mode it's looking for HID devices. So the keyboard starts in HID mode. When your done resuming from sleep mode, Linux is looking for an HCI device. The keyboard (not the laptop) needs to reset the connection. This happens naturally after about 45 seconds. You can force it by removing the batteries, but that may mess up the pairing. If you don't use the keyboard to resume from sleep this is not a problem.
When rebooting, the keyboard will still be trying to communicate in HCI mode but the laptop will only be looking for HID devices. Again after the timeout the keyboard will get it, and work correctly again.


Pendrive with Persistent Partion out of space in OS partition

Persistent live drives are more sensitive than standard installed systems

Persistent live systems can use a file or partition for persistence, a casper-rw file (as created by most tools) or a casper-rw partition (as created by mkusb). The file system in the casper-rw file or partition is vulnerable to corruption. That said, there are ways to keep a persistent live system running.

Avoid filling the system's storage (the casper-rw partition).
Allow the system to shut down completely (flushing the buffers in RAM to the casper-rw partition). Never unplug the USB drive while the computer is running. I'm sure you know this, but sometimes it is difficult to wait, and it is a common cause of failure.
Avoid general update & upgrade. Only install necessary extra program packages, do the tweaks and keep 'what is absolutely necessary' up to date.
If you want a major update & upgrade, keep/backup the .../upper/home directory (in the casper-rw partition) and create a new system (with mkusb using a new iso file) and after that copy .../upper/home to the new casper-rw partition. Do this when booted live-only.
Back up the casper-rw partition at regular intervals. Backup and restore scripts are bundled with mkusb. Do this when booted live-only.
Remember to backup also the data files in the usbdata partition (if you have such a partition).

See the following links,

help.ubuntu.com/community/mkusb

help.ubuntu.com/community/mkusb/persistent

More differences between persistent live and installed systems

The persistent live systems are compared to systems installed into a USB pendrive in the same way as into an internal drive.

Both systems are portable between computers. A persistent live system is more portable, because it is set up with a vast amount of hardware drivers. An installed system should be installed without proprietary drivers to be portable.
A persistent live system needs less drive space because a lot of program packages are stored in a compressed file system. On the other hand it needs more RAM because the compressed file system is expanded into RAM.
A persistent live system performs less write operations but an installed system can be tweaked to reduce the writing to avoid excessive wear of the memory cells. See this link.
A persistent live system cannot use new kernels. Normal program packages can be updated & upgraded. An installed system can be completely updated & upgraded.
You can install (an installed system) with disk encryption. In principle, a persistent live system in not encrypted, there is not even a log in feature, but you arrive directly at the desktop environment.
A Ubuntu persistent live system can boot in both UEFI and BIOS mode, while an installed system is normally created for either UEFI or BIOS mode, but not both. It is possible to tweak an installed system to boot in both UEFI and BIOS mode according to the following link,

help.ubuntu.com/community/Installation/UEFI-and-BIOS


How can I locate and remove an application in Ubuntu 16.04 LTS?

Here's how to do it on the command line:

Open up your terminal, and run dpgk -l | grep $APPNAME, where `$APPNAME' is the name of the application you are looking for. This searches all of the packages installed on your computer.

The package names are listed in the second column. Pick the one you want to remove, then run sudo apt-get remove $PACKAGE_NAME, with the appropriate name substituted to remove the application.


No internet connection on install [14.04]

While I have never seen behavior such as you describe, I find myself asking
if it's possible that the wireless card is recognized and configured. When I did my install, I had no wifi access, but soon discovered that my card was not set up. Broadcom wireless cards require some special effort. Searching for 'Broadcom wifi' will get info that is needed for driver installation. There are several steps required, but the information I found provided great detail and I was able to do this driver install 2 times (upgraded from 12.10 to 14.04 LTS).  Hope this helps  Craig


You could have removed GRUB from your hard disk pretty easily, just by deleting some files. That ship has sailed, though....

The easiest way to do what you want is:

Start the Ubuntu installation media, but select the option to try Ubuntu without installing rather than the option to install Ubuntu.
Launch a Terminal window.
Type ubiquity -b or ubiquity --no-bootloader. The installer will run, but in such a way that it will not install GRUB.
Select options to install Ubuntu on your USB flash drive. Be sure to include a FAT partition on the USB flash drive that will eventually hold a boot loader. (550MiB is a good size for this; it should not be the whole drive, and it should not be your root partition.)
Install the boot loader of your choice on the USB flash drive's FAT partition. Install it as EFI/BOOT/bootx64.efi on that partition. Personally, I'd use rEFInd for this purpose, since it's easy to configure and flexible; but as I'm rEFInd's maintainer, I'm biased.

When you want to boot Ubuntu, insert its USB flash drive and use the computer's built-in boot manager to pick the USB drive.

There are other ways to achieve your main goal. For instance, you could set up rEFInd on your hard disk. Configure it to make your Linux kernel the default, with Windows as the second choice. When the USB flash drive is not inserted, Windows will boot; and when it is inserted, Ubuntu will boot.


First, make sure you have the drivers needed, so open a terminal, and run this:

sudo apt-get purge fglrx*
sudo apt-get install fglrx
sudo mv /etc/X11/xorg.conf /etc/X11/xorg.conf.bak
sudo aticonfig --initial

Then reboot.

If ubuntu is still slow, you might want to change your desktop environment to something like LXDE, XFCE, KDE, or GNOME (though GNOME under ubuntu can be slower than unity, partly due to the excessive patching made by canonical).


How can I make the gtk2 font the same as gtk3?

Alright, turns out this wasn't a "gtk2" problem, but a firefox and thunderbird problem. Only happened with them. What I did is I deleted the $HOME/.config/fontconfig folder and now everything's back to normal. I'm not sure as of why, but it works.


Why have I just got a terminal on restarting my Ubuntu VM?

The error message describes that you have packages that are broken, for whatever reason. This could have been caused by a bad dpkg command being ran in the past or power was lost during an update, etc.

As the error describes you need to run:

sudo dpkg --reconfigure -a

which means "reconfigure all my packages" which will validate the integrity of files on disk and ensure configurations etc. are not corrupted.


Would This Fedora Method of Encrypting /boot Work With Ubuntu 16.10?

I can confirm that it works with Ubuntu 16.04.

The script does need to be adjusted a bit, though. Here's what I used:

$ sudo mkdir /mnt/root-bind && sudo mount --bind / /mnt/root-bind
$ sudo cp --archive --no-target-directory /boot /mnt/root-bind/boot
$ sudo diff -ur /boot /mnt/root-bind/boot  # Check output of this to verify that no differences are found.
$ sudo umount /mnt/root-bind && sudo rmdir /mnt/root-bind
$ sudo umount /boot
$ sudo cp -a /etc/fstab /etc/fstab.backup-before-removing-boot && sudo sed -i -e '/\/boot/d' /etc/fstab
$ echo 'insmod cryptodisk' | sudo tee --append /etc/grub.d/40_custom
$ echo 'GRUB_ENABLE_CRYPTODISK=y' | sudo tee --append /etc/default/grub
$ sudo update-grub
$ sudo grub-install /dev/sda  # Or whatever your main drive is.

That's what I just used, and it will (shortly [1]) be documented in more detail on this page of mine: Karl's IT Docs: Eddings Setup.

[1] Just as soon as I copy that site over to my rebuilt server, that is.


Would it be a problem to use a directory inside the home as Mercurial repo, and not the home directory itself? I just ask this, since it's a bit unfortunate: like bash creates .bash_history, some commands can have there config files written into the home, so you have to fight with those as well, whenever you use some commands/utils of these kind.


Well provided you haven't overwritten it, it's possible.

sudo apt-get install testdisk
sudo testdisk

Here's a full thread showing how somebody restored their EXT4 partition (including some complications): http://ubuntuforums.org/showthread.php?t=1376383


How to install and use new icon sets in *ubuntu:

First Method

Download some icon packs from deviantart and extract them to ~/.icons. If this directory doesn’t exist, create one using the following command:

mkdir ~/.icons

The following command will download and unzip an icon pack (that I think is very cool) called Uniform by 0rax0:

(For the current user only)

wget -O ~/.icons/uniform-icons http://www.deviantart.com/download/453054609/uniform_icon_theme_by_0rax0-d7hqj69.zip?token=a235ea7bccd82b62276464a126eb9d665c511c45&ts=1444170923

(or for all users on the system)

wget -O /usr/share/icons/uniform-icons http://www.deviantart.com/download/453054609/uniform_icon_theme_by_0rax0-d7hqj69.zip?token=a235ea7bccd82b62276464a126eb9d665c511c45&ts=1444170923

Now, once you've installed the icon set, you can use Unity Tweak Tool to change the icon theme.

Use the following command to install Unity Tweak Tool:

sudo apt-get install unity-tweak-tool

Once installed, run unity-tweak-tool from a terminal, or run the app from the menu, and click on Appearance then click on Icons.

You can select your preferred icon set from what is available here. And just keep adding more icons you find on the net.

Second Method

Lets see some beautiful icon sets available for Ubuntu Unity (probably Gnome and others as well, but I haven't tested):

To install Moka icons pack in Ubuntu and other Linux distributions, use the following commands:

sudo add-apt-repository ppa:moka/stable
sudo apt-get update
sudo apt-get install moka-icon-theme

Numix Circle icon theme. There are more themes, along with some wallpapers available in the Numix PPA:

sudo add-apt-repository ppa:numix/ppa
sudo apt-get update
sudo apt-get install numix-icon-theme numix-icon-theme-circle

Also check out Plateau icon themes Ubuntu 14.04
You can download the flat icon themes Plateau from Deviantart.
And another one is  called Simple but that is Gnome only.


usermod says account doesn't exist but adduser says it does

To edit /etc/group directly use vigr

From man vigr

NAME
       vipw, vigr - edit the password, group, shadow-password or shadow-group file

SYNOPSIS
       vipw [options]

       vigr [options]

DESCRIPTION
       The vipw and vigr commands edits the files /etc/passwd and /etc/group, respectively. With the -s flag,
       they will edit the shadow versions of those files, /etc/shadow and /etc/gshadow, respectively. The
       programs will set the appropriate locks to prevent file corruption. When looking for an editor, the
       programs will first try the environment variable $VISUAL, then the environment variable $EDITOR, and
       finally the default editor, vi(1).

Hence, you can edit the /etc/group file with

sudo vigr

The format of group entries can be found in man.
From man group:

NAME
       group - user group file

DESCRIPTION
       The  /etc/group file is a text file that defines the groups on the system.  There is one entry per line,
       with the following format:

           group_name:password:GID:user_list

       The fields are as follows:

       group_name  the name of the group.

       password    the (encrypted) group password.  If this field is empty, no password is needed.

       GID         the numeric group ID.

       user_list   a list of the usernames that are members of this group, separated by commas.

FILES
       /etc/group


SSH to a login to Ubuntu 16 Core on Raspberry Pi3 requires password

It is written in the first section of all the guides:

  User management in Raspbian is done on the command line. The default user is pi, and the password is raspberry. You can add users and change each user's password.


What do the various dpkg flags like 'ii' 'rc' mean?

Where to find this information in the system

You can find this information out in the head of dpkg -l output, as it's just a formatting convention:

dpkg -l | head -3

Copied here for reference:

Desired=Unknown/Install/Remove/Purge/Hold
| Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend
|/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)

Description of each field

As you can see from the first three lines:

First letter -> desired package state ("selection state"):

u ... unknown
i ... install
r ... remove/deinstall
p ... purge (remove including config files)
h ... hold

Second letter ->  current package state:

n ... not-installed
i ... installed
c ... config-files (only the config files are installed)
U ... unpacked
F ... half-configured (configuration failed for some reason)
h ... half-installed (installation failed for some reason)
W ... triggers-awaited (package is waiting for a trigger from another package)
t ... triggers-pending (package has been triggered)

Third letter -> error state (you normally shouldn't see a third letter, but a space, instead):

R ...  reinst-required (package broken, reinstallation required)


This question was addressed a couple times, the relevant links are

How to install software or upgrade from an old unsupported release?

Can I skip over releases when upgrading?

Both of them suggest that it's probably a mess to upgrade from 12.10 to 14.04 since it would involve 3 upgrades, so it might be easiest to change archive.ubuntu.com to old-releases.ubuntu.com (as in the top answer in the first link) and do a fresh install when I have the time.


How to upgrade 12.04.2 kernel and HWE to raring?

According to the Ubuntu X team's R-series LTS backport page,

  The official hardware enablement stack will be officially released as part of the 12.04.3 update.

And according to the Precise Pangolin Release Schedule, this will happen on 15 August 2013.

The upgrade policy around this is shown under the Kernel/LTSEnablementStack page.


Install google-chrome-stable with apt on 16.04

apt and apt-get share the same config files. apt-key is a separate command, apt doesn't have any of apt-key's functionality. The steps from the blog post will remain the same, except that you can replace apt-get with apt for the last two commands.

It might be easier to just download the Google Chrome package from its website, and then install it using:

sudo apt install ./google-chrome-stable_current_amd64.deb

Chrome's package adds both the key and the repository, so I think this is the simplest way. Note that this wouldn't be directly possible with apt-get, since apt-get doesn't support installing deb files directly, and if you used dpkg, you'd have to run apt-get install -f later to fix dependency issues.


I bought a Shuttle XS35 specifically to use as a media centre for my lounge room.

Installation of Ubuntu 10.10 was a breeze up until it was time to reboot.
The eject button on the DVD Drive did not work so I rebooted anyway without removing install disc.
After reboot, the eject would still not work, it just made a soft screeching type sound.
Trying to run the "eject" command from the console gave the same response.
I managed to get it open using a pin in the "emergency eject" pinhole of the drive.
Now eject seems to work normally - strange.

Next thing I found is that Ubuntu would not auto-detect my Wireless LAN.
This seems to be a problem in BIOS 1.08 as shipped with the box (as mentioned above).
BIOS 1.08 offers the following options for "Wireless Power Control": "Disabled", or "Switch by AP".

Now according to ubuntuforums posts, this can be fixed by flashing to BIOS 1.09 and selecting the new option of "Always On".
I have yet to try this as BIOS 1.09 has been removed from the Shuttle website.

I tried installing and running XBMC before I had installed the proprietary NVidia drivers to see how it would fare on ION without GPU acceleration - it was completely unusable.
Fortunately installing the NVidia proprietary drivers was straightforward and now XBMC works with no performance issues.

With default install my MCE compatible remote control had some buttons working and others not.
After installing lirc and configuring it for my device (a single drop-down during install), it is working a charm!
I am puzzled that it partly worked at all without lirc ... ?

In summary, so far everything has been awesome except the wireless problem, which is a serious pain.


If you don't use LVM, root volume encryption, software RAID, etc., and otherwise just have your root volume on a plain-jane filesystem with no intermediate layers, then you don't need it.

Really, the most important files in booting are the kernel image (vmlinuz) and the initramfs image (initrd.img). If both of those (and the GRUB configuration files) are accessible by GRUB with no special handling, then a separate /boot volume is not necessary.


Using ubuntu one with usb modem rather than router

Currently, Ubuntu One uses Network Manager to detect whether you are online.

Could it be that you are not connecting using Network Manager?


I have tried to run ./Resonalyzerv2 from the author's provided zip archive here on my 18.04 system, and can confirm that it exits immediately with status 0.
Based on your ldd output, we can guess that the program was compiled using fort77 - which uses f2c under the hood to convert legacy Fortran code to C.
There is a reported bug in the Ubuntu fort77 package that matches the symptoms you describe. Running a version recompiled using fort77 with debugging (f77 -g) shows that it exits with
[Inferior 1 (process 27235) exited normally]

before even attempting to write the program's banner. My strace-fu is weak, but strace ./Resonalyzerv2 does not appear to be much more informative.
I don't know if any progress has been made in resolving the bug, or if it affects later Ubuntu versions, but since the zip archive includes Fortran source code of the two programs you can try compiling them yourself using gfortran instead of fort77.
First, install the gfortran package if you have not already done so. Then either:

compile using gfortran directly, perhaps using the legacy code standard
 gfortran -std=legacy -o Resonalyzerv2 ../source/Resonalyzerv2.f

or

compile using the gfortran-provided version of f77
 f77 -o Resonalyzerv2 ../source/Resonalyzerv2.f

If you have installed ifort as well as gfortran, then you will need to use update-alternatives to confirm which package is providing f77 and adjust if necessary.


How to make the keyboard shortcuts like macOS on Ubuntu?

Ubuntu 20.04, June 2020
After spending an insane amount of time trying to figure out how to get MacOS-like shortcuts working on Ubuntu, I've found kinto. Just follow the instructions, it worked perfectly on 20.04 for me using an Apple aluminum keyboard. CMD-C/V copies & pastes everywhere and CTRL-C etc. work in the terminal.


It probably carried the command out, you're just not aware of it yet.

If the command begins with "sudo" substitute "gksu" for the sudo command so that you get a visual password prompt to carry the command out.


Permission denied for sickrage and transmission

By adding the line to the options
file_mode=0777, dir_mode=0777 and removing rw
and changing auto to cifs

SickRage & Transmissions was able to write to the mapped drive.


open a terminal you should be in your home directory {~}:$ .. type

cd .config
cp monitors.xml monitors.xml.bak
rm monitors.xml
reboot

See if that solves the issue
If not or it creates more of an issue .. you can go back to terminal and type

cd .config
cp monitors.xml.bak monitors.xml
reboot

that should put the original file back

if this doesn't work .. if you could try to save the monitors.xml  to a flash drive or something and open it somewhere else and edit your question copy and paste the contents into it so we can see and try to find a different solution.

lol I suggest saving it somewhere else because I have no idea how you use a 4x4 screen basically if you can open the monitors.xml and copy and paste the text in your question using that device then you can do that.


What packages are needed for German spell-check support in LO Writer 5.0.4.2?

Maybe libreoffice-l10n-de, but I'm unsure whether this is just the language of the app itself, and not its dictionaries.

I've just peeked in my personal install-fresh-ubuntu-desktop.sh script and I can see that I include a few more packages than you mentioned (I also install for a more languages, but you can ignore that).  I don't know if this will help you:

for x in da en-gb de; do
  sudo apt-get --yes install aspell-$x
done

for x in da en-us de; do
  sudo apt-get --yes install myspell-$x
done

for x in da en-us de-de; do
  sudo apt-get --yes install hunspell-$x
done

for x in en-us en-gb de; do
  sudo apt-get --yes install hyphen-$x
done

for x in en-us de; do
  sudo apt-get --yes install mythes-$x
done

for x in danish british american ngerman; do
  sudo apt-get --yes install w$x
done


Installing Ubuntu on Windows 2000 Pro laptop

yes you can, you just create a installation dvd or usb and boot from that. in the installation you choose to replace windows and you have a Ubuntu pc! I can give you a full description on how to install Ubuntu but you can find it here


You can't expand sda5, not because of its mounting status, but because there is a tiny sda4 fat32 partition in front of it. You must do something with that sda4 partition in order to expand sda5. Delete it or move it.
I suggest making sure you have solid backups before performing any partition operations.


There could be several reasons but make sure /usr/share/applications has a .desktop file for the application. HUD needs that. There are good instructions for intalling this app on Ubuntu at http://eduardgrebe.net/2012/10/installing-stata-12-on-ubuntu-12-04/


There's a easy way you can know if you have Hardware Acceleration:

glxinfo | grep render
direct rendering: Yes
OpenGL renderer string: Gallium 0.4 on ATI RV515

If direct rendering is "No" or the renderer string contains "llvm" you are pretty sure you don't have hardware acceleration.

If both are OK, then is the games implementation (or wine) that doesn't support hardware acceleration. If your card supports it you can try installing the latest fglxr drivers but I wouldn't recommend it if everything else is fine.


I'm too green to leave this as a comment, but does python3 -m pip do anything for you? (python3 -m pip install pyyaml for example?)


It may be that your router does not allow outside traffic to come in (ICMP may be disabled from within your router firmware).

Are you (or your friends) able to ping your public IP address?

You may need to enable ping requests (open DD-WRT web interface for your router, go to Security tab, make sure "Block Anonymous Internet Requests (ping)" is unchecked. Reboot your router. Check if you can ping your public IP.

Note: The "block anonymous" wording may differ depending on your version of DD-WRT.


Multitouch doesn't work on touchpad on acer spire v3 771G

1) Check the System Settings Mouse and Touch-pad and be sure two finger scrolling is selected.

If that doesn't work,

2) download and install Synaptiks Touchpad Management through the Software Centre, this worked for me.


Cannot install Ubuntu 14.04 on ASUS X453M

Ok I think I have solved it: I used USB 2 to install and in the bios changed 'OS SELECTION to  WINDOWS 7 ( Instead of Windows 8 ) '

Works for me.


'sudo' not working after changing the permissions of '/usr' directory

There are actually two mechanisms set up in Ubuntu for performing administrative tasks. sudo is one of them, and it and its graphical frontends (like gksu and gksudo) are not going to work until you fix the permissions problem.

The other mechanism is PolicyKit. Depending on exactly what you have done to your file permissions, it's likely that you can still recover using PolicyKit to run commands as root.

The pkexec command will run any (nongraphical) command as root (provided that the user invoking it is an administrator on the system). pkexec is capable of running graphical commands (like nautilus) as root, too, but this is quite nontrivial, as you have to set up configuration files for them describing how they are supposed to be run and what they are supposed to be allowed to do. Therefore, you're best off using the command-line to fix this problem...at least to the point where sudo works again. (Then you can run gksu nautilus to get a root file browser, if you're more comfortable using that to edit file permissions recursively.)

I don't know exactly what you did to your permissions, so it's hard for me to give you a specific pkexec command to run, to fix the problem. But you can rectify the specific problem that sudo is currently complaining about. It says:

sudo: /usr/lib/sudo/sudoers.so must be only be writable by owner

So remove group and other write permissions (while not modifying owner write permissions) for that file:

pkexec chmod go-w /usr/lib/sudo/sudoers.so

Then you can see if sudo works (by running some innocuous command like sudo ls).

If you need to perform other operations on file permissions from the command-line with chmod, see man chmod.

(By the way, here's another, related situation where it's handy to know about pkexec.)

If you have trouble getting pkexec to work for this, please feel free to comment here, and I'll try to render further assistance. But you should know that even if this method does not work, you shouldn't have to reinstall Ubuntu.

Instead, you can fix the problem from an Ubuntu live CD/DVD or live USB system, because the live system will be functioning--sudo will work on it--and you can mount your Ubuntu partition and change the permissions that way.

Or as a third option (as forestpiskie has suggested), you could use recovery mode.


VMWare Windows 7 (host) Ubuntu 14.04 (guest) shared folder won't mount

As told here the problem seems to be VMWare Tools, and it gets fixed with Tools 9.6.2 version. The main problem seems that this version of Tools come with Workstation 10, not 9.


Obviously some sort of error occurred.  I've seen something similar a couple of times.  Often what works best for me is to boot the computer to a live cd and use gparted from that cd to pretend to try to slightly resize any partition.  It seems the action causes gparted to check and adjust its partitions so everything is corrected.


Quickly share error (Can't upload to ppa)

It sounds like you may not have your SSH & or your GPG keys setup properly. You should be able to see both of them from the account page on Launchpad ( off to the right side a little is where they should be when looking at your profile )

You want to make sure that they indeed are as thats how the Package mgmt authenticates that you can upload and also indeed made the packages your self.

Cheers!

EDIT:: More info to your updates ...

OK , and seeing your other edit , have you also ensured that DEBEMAIL and DEBNAME are correct in the environment as that will be used to fill in the change-log thus also what is used to look for a private key of the same email address, so make sure those match, as well as run "gpg --list-secret-keys" to make sure the one for your email does show up and then you can force it tobe used with debhelper by using the -k fag when building ( thats how package uploads are often signed when sponsored into debian so very common and documented well )


Can't get wifi to work on Ubuntu 16.04 with Intel wireless 7260 (rev c3)

Run in terminal

sudo tee /etc/modprobe.d/blacklist-acer.conf <<< "blacklist acer_wmi"

and reboot.


Disk partitions for Windows 7 & Ubuntu dual boot

If you "install ubuntu along side with windows" during installation then, your C drive space gets reduced and split into 35.74GB (in this partition you will have Ubutnu installed) and 3.87GB (this is for the Swap space) partitions

or if u installed ubuntu into your 39.64GB unallocated partition it split into 35.74GB(Ubutnu OS) and 3.87GB(Swap space)

for C drive showing boot=>'bootable drive' page file=>'showing your windows page file is located in C' which is not a problem

i think you installed ubutnu along side with windows thats why your C drive shows those

you can install ubuntu into seperate partition by selecting "something else" option which is below "install along side with windows" option during installation


Problem solved completely. Solution is given below.

Firstly create a script to you want to run in it. I want to run rosbridge_websocket automatically when computer starts up. My script name is auto and is located at home/username/auto.sh. Content of the script is:

#!/bin/bash

cd $home

source /opt/ros/indigo/setup.bash

roslaunch rosbridge_server rosbridge_websocket.launch

exit 0

You must check that your script file is executable. To executable script file use the command: $ sudo chmod u+x /home/username/auto.sh

To do run this script in rc.local which is located at /etc/rc.local. It is created using gksudo gedit /etc/rc.local. Inside the rc.local is:

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

/home/username/auto.sh

exit 0

Finally, you must reboot your system using $ sudo reboot .
When you starts up the computer your script is completely work.


Installing Gnome 3.8 on Ubuntu 13.04 fails

I'm not sure if your problem is to do with dependencies or not, but if you install something with dpkg and it fails due to dependencies run

sudo apt-get install -f

This will complete the failed install and install the required packages.

I learned this from a 26k user the other day when I incorrectly advised someone to do it a very long winded way.


Can't connect to the Internet, can to my router

I seem to be having the same problem my workaround was using a different vpn (or tor also works) I've noticed that pinging any ip seems to work as long its an external ip for example the google dns server on 8.8.8.8, although after i removed windscribe i was able to connect to my router using its ip (i didn't try before removing windscribe) so i'm assuming that windscribe messes in some way with the dns settings.
After a bit of digging i found this DNS not working after upgrade 17.04 to 17.10 so after

    sudo dpkg-reconfigure resolvconf

everything was back to normal


Load Unity tweak or Gnome Tweak - they'll provide the needed dialog box.

unity-tweak-tool
gnome-tweak-tool

I had to turn off hinting with 14.10. Theres a bug, not well understood.


Because you interpret 'used memory' the wrong way. In Linux unused memory = bad memory, so Linux tries to use every available memory if possible. An example is caching. This memory can be freed up anytime as soon as an application needs it.

You can flush these cached contents manually:

# free
             total       used       free     shared    buffers     cached
Mem:       1022560     470596     551964          0      27872     189784
-/+ buffers/cache:     252940     769620
Swap:      6587388          0    6587388

# sync
# echo 3 > /proc/sys/vm/drop_caches
# free
             total       used       free     shared    buffers     cached
Mem:       1022560     300952     721608          0        972      53216
-/+ buffers/cache:     246764     775796
Swap:      6587388          0    6587388


A simple picture editing software - for adding text to image

Command line

Very fast, medium difficulty:
Imagemagick
For some ideas on how to use the convert -annotate flag of Imagemagick, check the answers to this question:

GUI

The ever classic, generally steep learning curve, but very easy for the simple task you asked for:
The Gimp

In Gimp, you will find the functionality under tools --> text

Another alternative, I have never tested myself though is pinta.


On GRUB screen after BIOS Start-up

Try to repair files from system using recovery mode.

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


How can I stop Ubuntu 12.04 from mounting Fedora 16's Swap Partition?

I suggest that you get rid of the extra swap line in /etc/fstab.


I am unsure whether it will be officially back-ported in a point release but the preview PPA has support for 12.04 already.  On your system, just run sudo add-apt-repository ppa:webapps/preview then sudo apt-get update && sudo apt-get install unity-webapps-preview

Source: https://launchpad.net/~webapps/+archive/preview


random shutdown since clean install of xubuntu 15.04

It usually happens due to overheating. Maybe something is wrong with the temperature sensors. Lets try to check this out:

Install the program lm-sensors (run in terminal).

sudo apt-get install lm-sensors

Detect all sensors (run in terminal):

sudo sensors-detect

Get temperature data (run in terminal):

sensors


Will the Samsung galaxy s7, run Ubuntu mobile OS

as this page clearly states, there is currently no image for the Galaxy S7.
Also the folks from ubports.com are not working on it so the answer is no, sorry.


How can I stop following output in less, without affecting the command generating the output?

I can't find any way of exiting the F mode in less, so you will have to use a workaround. For example, save the output to a tmp file and then watch that tmpfile instead:

node server.js > tmpfile & less tmpfile

The & makes the node.js command run in the background. This means that less tmpfile will start immediately and will be tracking the tmpfile.

Once in less, you can press F to enter follow mode but now Ctrl+C won't kill the server, it will only stop the follow. You can now scroll around as you would like and can hit F to resume following.


Dell XPS 15z Overheats When Using Optirun

most probably installing the correct VGA driver can reduce overheating. To install correct VGA driver

you need to do some simple things if your using ubuntu 12.10

first go to software center and type drivers.
in there find additional drivers. and install it.
after installation complete open it. it will search drivers for your VGA card. warning! do not close it. because additional drivers not working properly in 12.10 so once you close you cannot find it anywhere. then you must remove it and re-install it again through software center.
install all available VGA drivers for your machine.
after installation complete it will ask you to restart. you done!.
after restart go to Settings >  Details there you can see your VGA name and type.


Certificate error when using Citrix Receiver

To prevent the SSL error 61 when accessing remote sessions:

Make Firefox's certificates accessible to Citrix,

sudo ln -s /usr/share/ca-certificates/mozilla/* /opt/Citrix/ICAClient/keystore/cacerts

Source: Citrix help page


How can I solve the problem that bzr cannot acquire lock?

Break the lock over ssh rather than http (which doesn't provide write access on launchpad):

bzr break-lock lp:~orschiro/+junk/audio-recorder


Unable to connect to mobile broadband.. But it is detected

Use wvdial. Automatic detect USB modem and disable storage.


If you are truly concerned about the rebooting due to kernel panics as the title of your post suggests, you can check the file /etc/sysctl.conf for a directive similar to kernel.panic = n where n is some number that indicates how many seconds to delay before rebooting in the even of a kernel panic. Research indicates that it's not supposed to reboot by default.

If instead, as I suspect you are more concerned with determining the root cause of these reboots (some hardware related failure is my opinion) you'll want to review the Machine check events in order to determine what hardware is malfunctioning. If you don't have the file /var/log/mcelog You may need to install the mcelog package by enabling the Universe repository (if not already enabled in your sources) and issuing the command sudo apt install mcelog Then moving forward these events will be logged to /var/log/mcelog

For clarity here's an excerpt from the man mcelog

X86  CPUs  report  errors  detected  by the CPU as machine check events
       (MCEs).  These can be data corruption detected in the  CPU  caches,  in
       main memory by an integrated memory controller, data transfer errors on
       the front side bus or CPU interconnect or other internal errors.   Pos‐
       sible  causes can be cosmic radiation, instable power supplies, cooling
       problems, broken hardware, or bad luck.

       Most errors can be corrected by the CPU by  internal  error  correction
       mechanisms. Uncorrected errors cause machine check exceptions which may
       panic the machine.

More information on the mcelog file format can be found here

Linux systems don't typically reboot due to kernel panic by default so you may widh to check the file /etc/sysctl.conf mentioned previously.

Sources:

http://www.techrepublic.com/blog/linux-and-open-source/auto-reboot-linux-after-a-kernel-panic/

http://packages.ubuntu.com

"mce: [Hardware Error]: Machine check events logged" appears in syslog. What should I do?

http://mcelog.org/logfile.html

Based on your mcelog, CPU's 1 and 3 in your system are overheating. throttling down, cooling off and throttling back up (all this is by design to protect the CPU from overheating). The root cause could be a poorly applied thermal compound between the CPU and heatsink, a loose heatsink, blocked vents, or overly dusty or failing cooling equipment (fan?).  Another (unlikely) possibility is a failure in the thermal detection capabilities of the CPU.


The source of the problem seems to be in /etc/wpa_supplicant/wpa_supplicant.conf

ctrl_interface=/run/wpa_supplicant
ctrl_interface_group=admin # group admin can use wpa_cli

  CTRL: Invalid group 'wheel' Failed to initialize control interface
  '/run/wpa_supplicant'.

The group admin doesn't exists, you can try to replace it with group sudo which do exists in Ubuntu.

ctrl_interface=/run/wpa_supplicant
ctrl_interface_group=sudo

or in group root which do exists in Ubuntu.

ctrl_interface=/run/wpa_supplicant
ctrl_interface_group=root


Ubuntu 14.04 running well on Intel integrated graphics, is it worth trying Nvidia graphics?

I'm inferring a laptop's "Optimus" setup from your question.

If you don't need it, using the Intel card alone is probably more power efficient but that relies on the discrete graphics card dropping into lower power levels, controlling fans accurately, etc. I would suspect that for it to work as designed, you'll still need the proprietary driver installed.

That will also give you the option  of running things through optirun (or whatever system you use) in the future for 3D-heavy games if you want to. There are 600 games in Steam, 18 months after launch so I wouldn't say it's a complete gaming desert any more.

This seems like the latest best question on handling all this:

How to set up nVidia Optimus/Bumblebee in 14.04


It looks like you booted to the USB. See if Ubuntu is at the top of your boot options. If it is, your boot loader must be broken.


As you haven't installed the drivers yet, let's try that.

If you want the latest drivers add the repository to software sources:

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

sudo apt-cache search nvidia | grep -oE "nvidia-[0-9]{1,3}"

I have a list like this:

nvidia-340
nvidia-346
nvidia-346
nvidia-346
nvidia-346
nvidia-346
nvidia-346
nvidia-346
nvidia-346
nvidia-352
nvidia-352
nvidia-355
nvidia-355

View full output here.

Then you need to install one of them. I currently have nvidia-355 (the latest at time of writing) active, but I have also got 352, 346 and 340 as well.

I'd suggest installing the latest non-dev version, which you can find by searching the nVidia site. This is 355 at the moment, so run this command:

sudo apt-get install nvidia-355

Then restart the computer when this completes. When it boots up, check everything is okay and login and then check the Additional Drivers window.

If anything looks buggy, use Ctrl + Alt + F2 to enter tty and login. Then you can install an earlier version, with one of the following commands:

sudo apt-get install nvidia-331
sudo apt-get install nvidia-340
sudo apt-get install nvidia-346
sudo apt-get install nvidia-352
sudo apt-get install nvidia-355


Looking for a small fix to Ambiance themed Nautilus window!

I had the same problem, I looked into the codes too (gtk-3 and unity folders in the Ambiance theme) but, at the end, the problem is related to themes associated with Ambiance (it's explained here). Steps to fix:

Kill Nautilus (ALT+F2 killall nautilus)
Open Unity Tweak Tool
Select the Ambiance theme
Open Nautilus again


Applications can't connect the X server to launch

The fact that the "Slot" column of snap interfaces is empty is telling: it means you have no snaps providing those interfaces, and you have several wanting to consume them. I'm guessing snap list doesn't include the ubuntu-core snap, correct? The fix may be as simple as snap install ubuntu-core. How you got there, I have no idea.

If that doesn't work your snap installation may have become very messed up somehow. I've found this script helps to get back to a working point, but only by cleaning it completely.


Cannot install anything through Terminal - apt-get -f install

Okay, from what I can tell, your problem is that you've added a PPA to try and upgrade to the latest version of GIMP, and it hasn't worked out. I think the best option for now is to remove the PPA so you can get back your ability to install software.

Open Update Manager and hit Settings. This will bring you to the Software Sources manager, which you can read more about here. Go to the "Other Software" tab and untick any PPA's you added related to GIMP.

Then open a terminal, and type these commands one at a time (you may have to run the third command before sudo apt-get remove gimp if it fails):

sudo apt-get update
sudo apt-get remove gimp
sudo apt-get -f
sudo apt-get upgrade

GIMP will be uninstalled, but it should get your system working again. You should also be able to reinstall the default version of GIMP from the repositories.


A work around to the compiz memory leak is to:

sudo kill -HUP <compiz_process_id>

Not a great solution, but it frees up leaked memory without completely killing the process.


Copying to ntfs from ubuntu slower than ext4 - why?

Ubuntu made copying to NTFS slower

NTFS is implemented in Linux using a non native driver. One would expect it is not faster than a native implementation. Its not that we made it this way, its just the way it is.

Think the question should be: Is copying using Ubuntu's ntfs-3g driver slower than when you do it with other distros? The answer should, and within specs will be, no.


Which is the proper way to add Lightning calendar to Thunderbird (60+)?

Mozilla provides Lightning as bundled in the last versions, but Ubuntu (and Debian?) package do not [...]

yes, both do not, but they provide lightning via a seperate package (xul-ext-lightning resp. lightning) in their repositories.
debian also provides lang-packs (lightning-l10n-...) for lightning and ubuntu does not. --> that's IMHO the main issue.

  [...] so now there is a mismatch between the Thunderbird version in the repositories and the add-on provided by Mozilla [...]

there isn't really a "mismatch"... for whatever reason mozilla simply does not provide lightning as add-on anymore.
EDIT: have a look at the last section of this answer.

  (5.4, only useful for Thunderbird ≤52)

to avoid further confusion: lightning 5.4 is only intended to work with thunderbird 52.0!

there is no "one and only right solution" because every workaround has it's pros & cons and depends on your preferences and skills... nonetheless i try to prioritize them:

(if you are ok with lightning in english) the best is definitely to uninstall the lightning-addon and install lightning (xul-ext-lightning) via the repositories:
https://askubuntu.com/a/1084095/354350

EDIT: at the latest now jump to the last section of this answer.

if you need a different language, probably extracting the {e2fda1a4-762b-4020-b5ad-a41df1933103}.xpi (=lightning-addon) from the official mozilla-releases (for every release) and installing into your profile via the addon-manager may be a reasonable workaround:
https://askubuntu.com/a/1084220/354350
you can also use the archive provided by mozilla as a whole and update it on its own. - the packages (thunderbird* and xul-ext-lightning) from the repository should be uninstalled in this case.
if you are not afraid of potential bugs and do frequent backups of your data, installing the lightning-betas may also work for you:
https://askubuntu.com/a/1084255/354350
if you are a skilled tinkerer, you can perhaps use the debian-packages or parts of it (eventually with auto-update), but it is very likely you will end in dependency hell!
if you are that skilled and seriously think about the last workaround, creating a PPA with lightnings lang-packs and providing them to all other users may be by far a better utilization of your time.
staying with an old thunderbird <60 for ages and using an already outdated lightning 5.4 is a really bad idea and should definitely be avoided!

there may be 2 future-proof real solutions for all users, but i would not count on that we see even one of them soon:

ubuntu should finally fix it's packages and include lang-packs into/for the lightning-package (xul-ext-lightning)! ...as debian does.
mozilla could probably release lightning as add-on again and stop forcing users to fiddle around with separately downloaded betas and so on...
EDIT: since january 2019 (after nearly 2 years) mozilla resp. thunderbird (re)published lightning >=6.2 (for thunderbird >=60) as addon again!


GPG not asking passphrase using gnome keyring in awesome

I found the root cause of the issue. gpg-agent should automatically set $GPG_AGENT_INFO during invocation but it is not setting the env variable. Similarly the file gpg-agent.info was not present as mentioned in the above post hence the above code wasn't working. As per the gpg documentation GPG_AGENT_INFO should point to the gpg-agent socket file followed by pid of gpg-agent and then the protocol (default 1). These three fields should be separated by colon.

So I put the following code in my ~/.profile to solve the issue (S.gpg-agent file is the socket file created by gpg-agent after it starts),
Code:

if (pgrep -u "${USER}" gpg-agent); then
  export GPG_AGENT_PID=`pgrep -u ${USER} gpg-agent`
  export GPG_AGENT_INFO=${HOME}/.gnupg/S.gpg-agent:${GPG_AGENT_PID}:1
else
  eval `gpg-agent --enable-ssh-support --daemon`
  export GPG_AGENT_PID=`pgrep -u ${USER} gpg-agent`
  export GPG_AGENT_INFO=${HOME}/.gnupg/S.gpg-agent:${GPG_AGENT_PID}:1
fi

Still I am not sure why gpg-agent is not able to set GPG_AGENT_INFO.


There is only difference of desktop environment in Ubuntu and Kubuntu.

You can use Kde desktop environment in Ubuntu and turn it into Kubuntu , you dont need to remove Ubuntu

Open terminal by pressing Crtl + Alt + T and then execute following command one by one :

sudo apt-get update

sudo apt-get install software-properties-kde

sudo apt-get install kubuntu-desktop

If you still want to remove Ubuntu and Install Kubuntu.

Burn iso image(kubuntu 14.04.2.iso ) into a DVD and Visit this site for step by step process of installing Ubuntu (or Kubuntu)


I had a similar problem when I upgraded from 18.04 to 18.10. gdm failed to start.

In order to be sure that the problem is with gdm, try booting in safe-mode (see here how), drop a root terminal and type sudo dpkg-reconfigure lightdm. Then reboot and check if it boots correctly. If yes, you can try the solution offered here for a similar problem by disabling Wayland and reinstalling ubuntu-session.


How to set the environment variabile using java

If you're talking of something like this:

$ java Foo
$ echo ${var_set_by_foo}

This cannot be done. A process cannot affect another's environment, and a Java program is perforce run as a separate process from your shell.


Error while trying to compile luminance, an open source control system for Phillips Hue

The issue appears to be that the luminance-master.zip file has been created without its .git directory - and configure.ac tries to use git describe to pass the software's version number to AC_INIT:

AC_PREREQ([2.69])
AC_INIT([luminance],
        m4_esyscmd(echo -n `git describe --always --tags`),
        [https://github.com/craigcabrey/luminance/issues],
        [luminance],
        [https://craigcabrey.github.io/luminance/])

A fairly straightforward fix is to edit the configure.ac template to hard-code the version string:

AC_INIT([luminance],
        [v1.0.1],
        [https://github.com/craigcabrey/luminance/issues],
        [luminance],
        [https://craigcabrey.github.io/luminance/])

The diff is simply

$ diff configure.ac.bak configure.ac
3c3
<         m4_esyscmd(echo -n `git describe --always --tags`),
---
>         [v1.0.1],

Alternatively, forget about the master.zip file and clone the repository instead:

git clone https://github.com/craigcabrey/luminance.git


Add multimedia keyboard shortcuts in Xubuntu

I don't use XFCE myself but I found this thread that suggests that you can use the keyboard settings to set XF86AudioNext to exaile --next and XF86AudioPrev to exaile --prev. If that doesn't work out of the box, you may need to see what keycodes these media keys use with xev and put them in your .Xmodmap as described in the FAQ.


Ubuntu Mozilla Security, do I need this? General questions

The description for that PPA clearly states:

Mozilla Security/Stability testing archive for Ubuntu.

So: No, don't install that!
I would:

Install NoScript (I did this years ago and never looked back)
Disable JS everywhere, except on secure, trustworthy sites
Turn off the sound and notifications in NoScript: it becomes much less annoying after that!

;-)


Unknown Filesystem type while mounting SDXC card

I think you don't have the exfat drivers to write. You could try the -ro option in your mount command, it should work (but you obviously won't be able to write on your card^^).

Here's what I found on Google (in French) : ubuntu-fr.org

Exfat (or fat64) is the latest AND non open-source file format by Microsoft, to overcome the 4gb limit size of fat32. To access exfat with read-write, add the ppa relan/exfat and install the package exfat-utils :

sudo add-apt-repository -y ppa:relan/exfat
sudo apt-get update -qq
sudo apt-get install exfat-utils

Another solution would be to format your card in NTFS (non open-source, but Ubuntu should be able to write it with ntfs-3g package installed) or EXT4 format (free open-source yeay!), but it depends on the use you have of the card.

Here you can learn more about the various formats.

To change the format of your card, you can use a GUI programm like Gparted (root access needed) :

sudo apt-get install gparted


How do I recover my data on Windows machine?

I assume that you're getting a message on the screen asking you to format the drive when you go into Windows. That's normally the case when windows sees a unrecognised partition.

I think the best option would be to boot into a Ubuntu Live CD on a working computer, choose the option "try Ubuntu" and see if you can view your files.

If you can see your files, then you can back them up onto an external hard drive otherwise you can look into hardcore data recovery options.


Memory size not the same as in partition?

Disk storage capacity and memory are two different things; although, they are measured with the same unit.

Your partition size (6.5GB) measures how much data can be stored on your drive.

Memory is how much RAM you have installed + any virtual memory (swap space) that may be in use. In your case, you have 3.7GB RAM and ~0.4GB Swap


You could, if your PC BIOS permits it, but switching would require going into your BIOS Setup ( by pressing F1 or F2 or Del or Esc or some other key, depending on your PC model which you have not told us ) every time to select the boot drive, unless your PC has a hardware button (e.g., the Blue Button on some Lenovos) to allow you to override the Boot Order.


How to make the "Steam key" on ASUS ROG laptop work

Update: This will make the "video" button and the "rog" button next to the keypad also launch steam. Will look into that when I have the time.

This is how I made the "Steam button" work on my ASUS ROG G751. I would not be surprised if there is a simpler way to do this :) I am using xbindkeys to bind the steam key to a script. The script will start steam if it is not already running. If steam is running the script will change focus to steam. To achieve this I am using xdotool.

Install xbindkeys:

sudo apt-get xbindkeys
sudo apt-get xbindkeys-config
xbindkeys --defaults > ~/.xbindkeysrc

Run:

xbindkeys-config

Add a new item with:
Name: Steam,
Key: Mod2 + NoSymbol | m:0x10 + c:248, or you can use the "Get Key" function.
We want to execute a script as Action: ~/opensteam
This script will start steam if not started. Change focus to steam if started.

Install xdomod

sudo apt-get install xdotool

Script (opensteam):

nano ~/opensteam

Enter this into nano:

#!/bin/bash
if [ -n "$(tail /var/log/kern.log -n 1 | grep 'key 7f pressed')" ]; then
 if [ -z "$(xdotool search --name steam)" ]; then
  echo "Focus"
  steam &
 else
  echo "Execute"
  xdotool search --name steam windowactivate
 fi
else
 echo "Steam key was not pressed"
fi

Make opensteam executable

chmod a+x opensteam

Open "startup applications" either via the menu or via command:

gnome-session-properties

In startup applications add:
Name, command and comment: xbindkeys

This will make the xbindkeys launch when you log in. It runs in the background.

Edit: Added a nasty hack to fix the issue where the ROG key and the video key also started steam.


How do I install and keep updated with the most recent versions of Blender on Ubuntu?

I suggest you add this blender ppa as follows:

sudo add-apt-repository ppa:irie/blender

Followed by sudo apt-get update and sudo apt-get install blender

From now on, any updates to the ppa should be offered automatically.


Is it possible to change the order of icons in the indicator applet?

The system indicators are in a fixed order by design.  While you might not like the order, it makes support easier by having a fixed order (we can argue about the order endlessly).  The application indicators work a little bit differently, they're designed so that there is a default order but applications can adjust that for continuity.  For instance, if an application had two indicators that it wanted next to each other.

Because this system leads to a possible abuse by application developers there is a set of overrides in the system.  The first is at the system level so that it can be managed by packages once the distro figures out there is an abusing application it can be fixed for all users.  It's located at:

   /usr/share/indicator-application/ordering-override.keyfile

You can put any status notifier ID in there and give it a new ordering index that will because the new index for that application.  There is also a per-user override file that can exist in your home directory at:

  ~/.local/share/indicators/application/ordering-override.keyfile

Hopefully that will give you some help in adjusting your panel the way that you prefer!


You are mistaken: there is no reason to use "configure". I downloaded the tar.gz, extracted and it has ONLY 1 file that is an executable. All I had to was click the executable:

There is a catch though for it to actually work:

ADBbrowser is a GUI based file and application browser for Android devices. It will run on most 32 and 64 bit Linux systems and Windows 32 bit. Originally written for my Sony Ericsson X10i, But should work with all android phones.
Adbbrowser requires Android SDK to be installed!

How you do this? See: Complete Installation Guide for Android SDK / ADT Bundle on Ubuntu


It looks like a bug has been reported relating to this issue here.

Reading through some of the comments, it sounds like it may be related to GTK3. One of the comments suggests running eclipse with GTK2 using the following:

  SWT_GTK3=0 ./eclipse

This doesn't fix the issue but may give you a workaround until the bug has been fixed.


WiFi randomly disconnected on Ubuntu 18.04 LTS

Try disabling wifi power management by opening /etc/NetworkManager/conf.d/default-wifi-powersave-on.conf and changing

wifi.powersave = 3

to

wifi.powersave = 2

Do not set it to 0, which is the default value. From nm-setting-wireless.h:

/**
 * NMSettingWirelessPowersave:
 * @NM_SETTING_WIRELESS_POWERSAVE_DEFAULT: use the default value
 * @NM_SETTING_WIRELESS_POWERSAVE_IGNORE: don't touch existing setting
 * @NM_SETTING_WIRELESS_POWERSAVE_DISABLE: disable powersave
 * @NM_SETTING_WIRELESS_POWERSAVE_ENABLE: enable powersave
 *
 * These flags indicate whether wireless powersave must be enabled.
 **/
typedef enum {
    NM_SETTING_WIRELESS_POWERSAVE_DEFAULT       = 0,
    NM_SETTING_WIRELESS_POWERSAVE_IGNORE        = 1,
    NM_SETTING_WIRELESS_POWERSAVE_DISABLE       = 2,
    NM_SETTING_WIRELESS_POWERSAVE_ENABLE        = 3,
    _NM_SETTING_WIRELESS_POWERSAVE_NUM, /*< skip >*/
    NM_SETTING_WIRELESS_POWERSAVE_LAST          =  _NM_SETTING_WIRELESS_POWERSAVE_NUM - 1, /*< skip >*/
} NMSettingWirelessPowersave;


How can I install CuDNN on Ubuntu 16.04?

Step 0: Install cuda from the standard repositories. (See How can I install CUDA on Ubuntu 16.04?)

Step 1: Register an nvidia developer account and download cudnn here (about 80 MB)

Step 2: Check where your cuda installation is. For the installation from the repository it is /usr/lib/... and /usr/include. Otherwise, it will be /usr/local/cuda/ or /usr/local/cuda-<version>. You can check it with which nvcc or ldconfig -p | grep cuda

Step 3: Copy the files:

Repository installation:

$ cd folder/extracted/contents
$ sudo cp -P include/cudnn.h /usr/include
$ sudo cp -P lib64/libcudnn* /usr/lib/x86_64-linux-gnu/
$ sudo chmod a+r /usr/lib/x86_64-linux-gnu/libcudnn*

Runfile installation:

$ cd folder/extracted/contents
$ sudo cp include/cudnn.h /usr/local/cuda/include
$ sudo cp lib64/libcudnn* /usr/local/cuda/lib64
$ sudo chmod a+r /usr/local/cuda/lib64/libcudnn*


Why does the error message for two colons as a command (::) in bash have three colons, but a single colon give no output?

The last colon is just part of the default "not found" message:

$ x
x: command not found
$ ::
::: command not found

The reason a single colon produces nothing is that : is a valid command - although it does nothing (except return TRUE). From the SHELL BUILTIN COMMANDS section of man bash:

   : [arguments]
          No effect; the command does nothing beyond  expanding  arguments
          and  performing any specified redirections.  A zero exit code is
          returned.

You will sometimes see it in constructions like

while :
do
  something
done

See for example What purpose does the colon builtin serve?


Sony VAIO VPCEB1Z1E Ubuntu 13.10 Fan control

I had a similar issue on my laptop. Its fan went on/off for seemingly no reason (temp cca. 40 Celsius). The following grub update did the trick to me:

In terminal:

gksudo gedit /etc/default/grub

Then change the line starting with GRUB_CMDLINE_LINUX_DEFAULT= to

GRUB_CMDLINE_LINUX_DEFAULT="quiet splash acpi_osi=Linux"

and after this line add

GRUB_CMDLINE_LINUX='acpi_osi="!Windows 2012"'

It works like a charm for me.


Internet connection for PC from laptop via cable

In the terminal...

dpkg -l *dnsmasq* # looking for dnsmasq-base

un dnsmasq <none> <none> (no description available)
ii dnsmasq-base 2.75-1ubuntu0.1.04 amd64 Small caching DNS proxy and DHCP/TFTP server

Look for dnsmasq-base as the only installed dnsmasq anything. It should be status "ii". If you don't see it, then:

sudo apt update # update the software database

sudo apt install dnsmasq-base # install dnsmasq-base

Set up the laptop as you have before...

On the laptop, typed nm-connection-editor in the terminal, chose
'Wired Connection', clicked on 'Edit' and then selected 'Shared
to other computers' as 'Method' under the IPv4 Settings.

Set up the PC with an ethernet connection set to DHCP (not manual).

Connect the ethernet cable and it should work.

If for some reason DHCP doesn't work, try a manual connection profile, with:

address = 10.42.0.2/24

gateway = 10.42.0.1

Retry connection.


Ubuntu 17.04 Nvidia 384 and Kernel Update

Had the same issue.
There is a way to boot with Ubuntu "live CD" or "Live USB stick",
then select "Try Ubuntu".
When in, you can mount your "broken" system in terminal with:

sudo mount /dev/sda2 /mnt
sudo mount --bind /dev /mnt/dev
sudo mount --bind /proc /mnt/proc
sudo mount --bind /sys /mnt/sys
sudo chroot /mnt

now you can delete all the nvidia stuff and revert the blacklisting....


Stop the recording after some period of time

Use the -t option. From man ffmpeg:

  -t duration (input/output)

  When used as an input option (before -i), limit the duration of data read from the input file.

  When used as an output option (before an output filename), stop
  writing the output after its duration reaches duration.

  duration must be a time duration specification, see the Time duration
  section in the ffmpeg-utils(1) manual.

  -to and -t are mutually exclusive and -t has priority.

Example that records for one hour:

ffmpeg -f v4l2 -i /dev/video0 -t 01:00:00 output

Or in seconds:

ffmpeg -f v4l2 -i /dev/video0 -t 3600 output


Landscape server for personal use does not register clients

If I'm reading your question correctly, the key error is:

certificate subject name (linux-server.tpgi.com.au)

"certificate subject name" coming from a cert.  In other words, you are trying to contact the server at linux-server.home but the cert says linux-server.tpgi.com.au.  Is this the case?

Unfortunately, the hostname you contact needs to match your certificate.  This is the only way that the landscape-client has to validate the landscape-server (at this point in time).

Also, I'm including another link that you will run into later if you don't have agreement with the root_url and what landscape thinks the hostname of your installation is.

References:

https://help.landscape.canonical.com/LDS/SSL


DNS server with Bind9: can't resolve DNS records in forward and reverse zone files

So forwarding is working fine. Things in your configuration files do look a little odd to me. Note that I have never been able to make things work with $ORIGIN. I'm sure that somehow it does work, just not for me.

For dirks.crtn.db try:

$TTL 38400
@      IN SOA filtjener.dirks.crtn. webmaster.dirks.crtn. (
       1263527838    ; serial
       10800         ; refresh
       3600          ; retry
       604800        ; expire
       38400 )       ; Negative Cache TTL
       IN  A  192.168.56.2
;
; name server - NS records
@      IN  NS   filtjener.dirks.crtn.
; name server - A records
filtjener IN   A    192.168.56.2

host1   IN A   192.168.56.21
host2   IN A   192.168.56.22
host3   IN A   192.168.56.23

For rev.56.168.192.in-addr.arpa try:

$TTL 38400

@ IN SOA filtjener.dirks.crtn. webmaster.dirks.crtn. (
     1263187356    ; serial
     38400         ; refresh
     3600          ; retry 1 hour
     60400         ; expire 1 week
     38400 )       ; negative cache TTL
;
@    IN   NS    filtjener.dirks.crtn.
2    IN   PTR   filtjener.dirks.crtn.
21   IN   PTR   host1.dirks.crtn.
22   IN   PTR   host2.dirks.crtn.
23   IN   PTR   host3.dirks.crtn.

You do not need to use sudo with named-checkzone and note that for reverse zone checking the command is:

named-checkzone 56.168.192.in-addr.arpa rev.56.168.192.in-addr.arpa

reference


Ubuntu 16.10 Server MariaDB (MySql) open_file_limit won't go higher than 16364

thanks to @jerichorivera who wrote the answser here https://serverfault.com/a/833909

  16K is the limit for LimitNOFILE for MariaDB, so you might want to
  increase that in the systemd service definition. For more details
  check this page: https://mariadb.com/kb/en/mariadb/systemd/


No HDMI 2.0 output from NUC6i7KYK on 16.04 -- fixes?

Having the same problem myself.  If I downgrade my kernel to 4.2, it comes back.  But 4.4 & 4.7 (I tried the latest released kernel to see if it was fixed), and no HDMI.  Yes, this helps me rationalize a 4K monitor, but jeepers, it would be nice if HDMI just... y'know, worked.


Command Options on Command Line - Details and Functions?

The acceptable flags for programs, and what those flags do, differ from program to program.  Because the -v or -l flags (or any flags, for that matter) will vary from program to program, it is best to read the manpages for each application to figure out what does what.

In your case, you specify fdisk and shred. Try reading the manpages for each.  (man fdisk and man shred)


How to recreate removed Ubuntu entry from EFI partition?

Thanks to @PRATAP answer I was able to recover grub and boot into Ubuntu. Thanks!

Steps to fix:

I've installed Ubuntu 17.10 on Virtual box.
Copy /boot/efi/EFI/ubuntu to Z:\EFI\ubuntu
Thanks to How to Rescue a Non-booting GRUB 2 on Linux article I was able to boot Ubuntu. Basicly in my case:

grub> set root=(hd0,1)
grub> linux /vmlinuz root=/dev/sda1
grub> initrd /initrd.img
grub> boot

After booting into Ubuntu I've fixed grub config sudo update-grub
Following the instructions from the description of the bug I've installed Kernel linux-image-4.15.0-041500rc6-generic_4.15.0-041500rc6.201712312330+20170103+1_amd64
After 2 reboots I was able to change BIOS settings once again


Sudden problem when turning on the computer

After reading the comments responding to this question, I am also
of the mind that it is a hardware issue. First, the problem showed
up so quickly, and the OS is not able to find the root partition
(/ - equivalent to C:\ in Windows). There are almost certainly
Hard Disk problems. It may be possible to correct them with the
instructions given by the last commenter (Bernard Decock?).
  If you are in a time crunch with the work presentation there
may be a way to deal with that and then spending the time to correct
the PC. If the liveUSB will boot and give you access to software
that is needed for your work, you might be able to save your work
to remaining free space on the USB stick. If no space on that stick,
see if a 2nd USB stick can be seen and save to that.
  If this would allow you to focus on the presentation and get it done,
great. Do your work and then fix the PC.   Hope this helps.


Extending linux root partition with unallocated space

You can only resize with empty space that is to the right of the partition. You have to move partitions first until the empty space is in the right position.


Where is the LANGUAGE environment variable set?

Taken from help.ubuntu.com

The LANGUAGE priority list

The "LANGUAGE" environment variable, which is set by the GUIs more often than not on
Ubuntu desktops, controls language for message and menu display for GNU compatible
applications. For such applications it overrides whatever locale names are set in
"LANG" and "LC_MESSAGES".

Unlike "LANG" and "LC_*", "LANGUAGE" should not be assigned a complete locale name
including the encoding part (e.g. ".UTF-8"). Instead "LANGUAGE" should contain a
colon separated priority list of language codes, for instance "es:de:en". A single
language code is also correct.

As lame as a link answer is, this is probably what you want.

The post referenced in the link above explains that if you want to change the language that appears on the command-line then you need to set both LANG and LANGUAGE accordingly in either /etc/default/locale or ~/.pam_environment.

Since you've already tried setting LANGUAGE in /etc/default/locale, I'd try setting it in ~/.pam_environment since that's a user config file and its contents should overwrite anything set in the global environment.

EDIT:

I went ahead and tried duplicating the problem that you described by setting LANGUAGE in /etc/default/locale to "en:ru:en" logging out and then logging back in.  It worked.  Error messages were then displayed in Russian, at least for the root account (which was the account I was testing this on).  Changing the value of LANGUAGE to "en" fixed it.


How to install programs? Keep getting archive manger error

You could try using Ubuntu Tweak. It has a built-in cleaning function which might do what you want.


Find the package a program is installed with

The following will assume you know the command that executes it, but I'll use ls as an example.

I find out where ls is actually located

guiverc@d960-ubu2:~/Pictures$   whereis ls
ls: /bin/ls /usr/share/man/man1/ls.1.gz

Now I know where that, I can ask the package management system to give me a package name

guiverc@d960-ubu2:~/Pictures$   dpkg -S /bin/ls
coreutils: /bin/ls

Now I know the package name, to remove it I could

$ sudo apt remove coreutils

Alas I didn't do that; I need it.

If you only access a program through menus, you didn't tell us what release/desktop you are using, but on some you can click & get details very easily, others you can view xml (formatted text files) and see programs run by menus, or you could just start it & htop or ps to look for the running program to get it's name. In your case with you knowing the name, it may be called something like topspin, so I'd type tops at a command prompt, and hit  to see if it auto-completes to the executable name, then you can use the two aforementioned commands.

The above assumes it was deb/apt (package management system) installed.  If @user53733 is correct and you installed it another way; the method differs.

snap list will list your snaps, where you can snap remove <snappackage> if installed as a snap.

If installed from source; follow the uninstall instructions, or do the reverse of how you installed it (if there is no uninstall directions; though this assumes more knowledge/understanding of procedure and should probably be skipped if not understood)


I am not sure whether this will help but I will share my configurations here.
I configured environment variables as follows.
export PATH="/usr/local/cuda-11.0/nsight-compute-2020.1.0:$PATH"
export PATH="/usr/local/cuda-11.0/bin:$PATH"
export CUDA_HOME="/usr/local/cuda-11.0"
export LD_LIBRARY_PATH="/usr/local/cuda-11.0/lib64":$LD_LIBRARY_PATH

Before adding CUDA_HOME and LD_LIBRARY_PATH, I got the same error "nvcc fatal   : Path to libdevice library not specified".

when I'm doing nvcc --version, I'm seeing version 9.1. which is also weird

Is your /usr/lib/cuda/bin the first item in $PATH?
Bash finds the first program it matches.
Maybe /usr/local/cuda/bin is before your /usr/lib/cuda/bin?

I also find out that I have nvidia-cuda-toolkit at /usr/lib/nvidia-cuda-toolkit, and that libdevice is inside, (i.e /usr/lib/nvidia-cuda-toolkit/libdevice)

In my case, libdevice is located at /usr/local/cuda-11.0/nvvm/libdevice rather than /usr/local/cuda-11.0/libdevice.


Problem with unzipping archives on Ubuntu

Funnily, to zip and unzip .zip files with Archive Manager you need to install exactly these packages first:

sudo apt install zip unzip

The command line tool p7zip-full however comes with an own version of zip and unzip, in case you don't need a GUI to pack/unpack your files. Use it as follows:

# create archive superstrong.zip with uncrackable password “1234”
7z a -p1234 superstrong.zip /path/to/dir /path/to/file.wtf

# extract archive superstrong.zip, this prompts for password if necessary
7z x /path/to/superstrong.zip


dpkg --configure -a does not remove any software: (from the man page)

--configure package...|-a|--pending
          Configure a package which has been unpacked but not yet  config‐
          ured.   If  -a  or  --pending  is  given instead of package, all
          unpacked but unconfigured packages are configured.

That does not revert nor continue the work you triggered by apt-get, but continues and completes a substep carried out by dpkg. After you've done that you should issue the initial apt-get command again.

You may have to reinstall the packages with this command (reinstalls all direct dependencies):

apt-get --reinstall --purge install libaio1 libdbd-mysql-perl libdbi-perl libhtml-template-perl libnet-daemon-perl libplrpc-perl libterm-readkey-perl mysql-client-5.5 mysql-client-core-5.5 mysql-server-5.5 mysql-server-core-5.5

Also, an apt-get update does the trick sometimes.


Looks like the option -an should do the trick.  Just ran a file, confirmed, new file had no sound.

-an (output)
   Disable audio recording.

from http://manpages.ubuntu.com/manpages/precise/man1/avconv.1.html


Ubuntu 20.04.1 slow to boot and sometimes fails

could you try don't use snaps? because the Ubuntu system mounts a virtual disk for snap installed every time it boots, this should make linux boot faster
If you enabled some services that can fail sometimes, try to disable then and enable manually when you need it


Here is a video demonstration of how to Dual boot windows 8 with Ubuntu.


Ubuntu 16.04 progress dots remain flashing in centre of screen after successful boot

I removed nomodeset from after quiet splash, and it seems to have fixed it.


Installed Plasma widgets and login screens don't show up

Sometimes that happens because the widgets you downloaded and installed aren't fully compatible with the KDM Greeter. Not all of the downloadble login screens you see do work, even if they say they're installed.


Why Ubuntu 14.04 not Sending Correct Awakening Signal to a Display after sleep?

What is your graphics card?

This is most likely caused by a bug in the open-source driver. Have you tried installing the proprietary drivers? (Dash > Additional Drivers)

[Not to mention you will get way better performance with the proprietary driver]


How can I make a fresh install of Ubuntu?

Go to the Ubuntu download Page and get one of the Ubuntu versions. Then download usb universal installer and boot up using a flash or CD. Then after that you have the option while installing to wipe everything and install Ubunut.

-Regards


Dnsmasq has changed the way it works in 12.10 - can someone point me to documentation or info on the changes

NetworkManager talks with dnsmasq over dbus now. This has one advantage: dnsmasq does not have to be restartet everytime something changes.

The big downside: You can't really see what's going on anymore.
/var/log/syslog now has entries that describe what goes on a bit:

Jan 21 22:10:13 bogo dnsmasq[28993]: vorgelagerte Server von DBus gesetzt
Jan 21 22:10:13 bogo dnsmasq[28993]: Benutze Namensserver 192.168.3.3#53

But that's - in my eyes - not really a satisfying solution, especially when something goes wrong.


open your terminal and type this

sudo dpkg -r ia32-libs
sudo apt-get update
sudo apt-get install -f


Well here's your chipset and it's fairly mature:

http://ark.intel.com/products/27679/Intel-82801GB-IO-Controller

The Ethernet should be on the PCI bus, that it's not showing up
can really only be attributed to a firmware issue. Whether you
did it deliberately or some piece of software during the upgrade
twiddled a port and shutoff your controller in the BIOS. It's
essentially not there anymore.

Enter you BIOS ensure it's on, even if it is, toggle it
off and on again, then, reset to defaults and reboot.

Turn off the boot splash screen for the BIOS and pay attention
to the option roms loading. Do you see one for PXE? That would
tell you for sure if your Ethernet is functioning correctly.

I doubt this was a driver regression, chipset is too old. If
what I prescribed earlier didn't work try changing the acpi_osi
tag to an earlier version of Windows. What can happen sometimes
is Linux advertises itself as a newer version of Windows, which
triggers conditional code executed in the BIOS.

It might be that pretending to be Windows 7 hit a bug in your
firmware and as a result it decided not to present your Ethernet
device. The result is no different than disabling the peripheral in
the BIOS setup. Isn't runtime conditional code (ACPI) execution fun?


When installing Ubuntu 18.04.5 Desktop from a USB flash drive, how do I disable `iio-sensor-proxy`?

You can use Cubic to create a custom ISO with this package removed.
How to use Cubic to create a custom Ubuntu live CD image?
Just install Cubic. Then on the Terminal page, execute apt remove iio-sensor-proxy to remove this package. Click through the next pages to generate the customized ISO. Finally, "burn" the ISO to a USB as you normally would and use it to install Ubuntu.


try to install intel opensource driver, in most cases it works better https://01.org  and then set acpi backlight and acpi osi to grub, also check this link https://wiki.ubuntu.com/Kernel/Debugging/Backlight


Ubuntu terribly slow, barely able to move mouse

64-bit on only 2GB RAM?

I don't know much about systems, but don't you think 32-bit would be more reliable for that small of an amount of RAM?


Ubuntu Touch: Add contact list and calendars

I can share this script based on alexandre_payet answers, which will add 1 Contact address-book, and 1 calendar, from your owncloud server, to sync with your phone.

Script

#!/bin/bash
# ---------------------------------------------------------------------------
# Ubuntu Phone - Sync Owncloud Contacts & Calendar Account
# Carddav & Caldav.

# Tested on : Ubuntu-touch vivid - ubuntu-touch/rc-proposed/bq-aquaris.en/vegetahd/
# Last edit : 2015/08/23.
# Author : Romain Fluttaz, boTux.fr, <romain@botux.fr>

# ============= [ Configuration ] ============= #

# --------------- [ OwnCloud ] ---------------- #

# Server and user informations
HTTP_PROTOCOL="https"               # "http" or "https". It's recommended to use an $HTTP_PROTOCOL connection
OWNCLOUD_URL="cloud.domain.com"         # Without the last /.
USERNAME="owncloud-user"            # Your OwnCloud username
PASSWORD="owncloud-password"            # Your OwnCloud password

# Contact addressbooks
CONTACT_ADDRESSBOOK_NAME="contacts"     # Check in the contact setting page.

# Calendar
CALENDAR_NAME="personnel"           # Check in the calendar setting page.

# Database
OC_DATABASE_NAME="owncloud"

# ----------------- [ Phone ] ----------------- #

# Database name :
CONTACT_DB_NAME="Contacts-name"         # Contact addressbook name on the phone
CALENDAR_DB_NAME="Calendar-name"        # Calendar name on the phone

# CRON job
CRON_FREQUENCY="hourly"             # Cronjob frequency. "hourly", "dayly", "weekly", "monthly". See $HTTP_PROTOCOL://help.ubuntu.com/community/CronHowto#Advanced_Crontab

# ============= [ /Configuration ] ============ #

# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.

# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
# GNU General Public License at <http://www.gnu.org/licenses/> for
# more details.

# Thanks to :
# alexandre_payet @ https://askubuntu.com/questions/616081/ubuntu-touch-add-contact-list-and-calendars
# alexandre_payet @ https://askubuntu.com/questions/611761/syncevolution-in-cronjob-to-sync-the-ubuntu-phone-via-caldav-arddav
# alexandre_payet @ https://askubuntu.com/questions/629219/automatically-sync-calendar-on-ubuntu-phone/629728#629728

# Usage: Edit the config section and run the script.

# Revision history:
# 2015-08-22 Adding 1 Contact & 1 Calendar.
# 2015-08-22 Add cronjob support.
# ---------------------------------------------------------------------------

echo "\e[4mAdding OwnCloud account : **$OWNCLOUD_URL**\e[0m"
echo ""

# Contact
echo -e "[\e[0;34m Contacts \e[m] $CONTACT_ADDRESSBOOK_NAME @ $OC_DATABASE_NAME"
syncevolution --create-database backend=evolution-contacts database=$CONTACT_DB_NAME
syncevolution --configure --template webdav username=$USERNAME password=$PASSWORD syncURL=$HTTP_PROTOCOL://$OWNCLOUD_URL/remote.php/ keyring=no target-config@$OC_DATABASE_NAME
syncevolution --configure backend=evolution-contacts database=$CONTACT_DB_NAME @default $CONTACT_DB_NAME
syncevolution --configure database=$HTTP_PROTOCOL://$OWNCLOUD_URL/remote.php/carddav/addressbooks/$USERNAME/$CONTACT_ADDRESSBOOK_NAME backend=carddav target-config@$OC_DATABASE_NAME $CONTACT_DB_NAME
syncevolution --configure --template SyncEvolution_Client Sync=None syncURL=local://@$OC_DATABASE_NAME username= password= $OC_DATABASE_NAME $CONTACT_DB_NAME
syncevolution --configure sync=two-way backend=evolution-contacts database=$CONTACT_DB_NAME $OC_DATABASE_NAME $CONTACT_DB_NAME
echo "             +--> $CONTACT_DB_NAME @ local"
syncevolution --sync refresh-from-remote $OC_DATABASE_NAME $CONTACT_DB_NAME
syncevolution --sync slow $OC_DATABASE_NAME $CONTACT_DB_NAME
echo -e "[\e[0;34m Contacts \e[m] +--> Done."
echo ""

# Calendar
echo -e "[\e[33m Calendar \e[m] $CALENDAR_NAME @ $OC_DATABASE_NAME"
syncevolution --create-database backend=evolution-calendar database=$CALENDAR_NAME
syncevolution --configure --template webdav username=$USERNAME password=$PASSWORD syncURL=$HTTP_PROTOCOL://$OWNCLOUD_URL/remote.php/ keyring=no target-config@$OC_DATABASE_NAME
syncevolution --configure backend=evolution-calendar database=$CALENDAR_NAME @default $CALENDAR_NAME
syncevolution --configure database=$HTTP_PROTOCOL://$OWNCLOUD_URL/remote.php/caldav/calendars/$USERNAME/$CALENDAR_DB_NAME backend=caldav target-config@$OC_DATABASE_NAME $CALENDAR_NAME
syncevolution --configure --template SyncEvolution_Client syncURL=local://@$OC_DATABASE_NAME username= password= $OC_DATABASE_NAME $CALENDAR_NAME
syncevolution --configure sync=two-way database=$CALENDAR_NAME $OC_DATABASE_NAME $CALENDAR_NAME
echo "             +--> $CALENDAR_DB_NAME @ local"
syncevolution --sync refresh-from-remote $OC_DATABASE_NAME $CALENDAR_NAME
echo -e "[\e[33m Calendar \e[m] +--> Done."
echo ""

# Cron
echo -e "[\e[0;36m Cron \e[m]"
echo -e "         +--> \e[0;31mGranting SuperUser Access\e[m"
sudo mount /dev/loop0 / -o remount,rw
CRON_LINE="@$CRON_FREQUENCY export DISPLAY=:0.0 && export DBUS_SESSION_BUS_ADDRESS=$(ps -u phablet e | grep -Eo 'dbus-daemon.*address=unix:abstract=/tmp/dbus-[A-Za-z0-9]{10}' | tail -c35) && /usr/bin/syncevolution $OC_DATABASE_NAME"
(crontab -u phablet -l; echo "$CRON_LINE" ) | crontab -u phablet -
sudo service cron restart
crontab -l | grep "$CRON_LINE"
echo -e "[\e[0;36m Cron \e[m] +--> Added."
echo ""

# First Normal Sync
echo -e "[\e[0;32m Syncronisation \e[m]"
syncevolution $OC_DATABASE_NAME
echo -e "[\e[0;32m Syncronisation \e[m] +--> Done."

# Print information
echo ""
echo ""
echo ""
echo "# To manually sync your accounts, use the command below :"
echo ""
echo -e "                           syncevolution $OC_DATABASE_NAME \e[m"
echo "                                          or"
echo -e "\e[0;34msyncevolution $OC_DATABASE_NAME $CONTACT_DB_NAME\e[m | \e[33msyncevolution $OC_DATABASE_NAME $CALENDAR_NAME\e[m"
echo ""
echo "See 'syncevolution --help' to get more information."

  Download ubuntu-touch_owncloud-sync_contact-calendar.sh | Github
  Gist

Tested on the ubuntu-touch/rc-proposed/bq-aquaris.en/vegetahd channel

How to use

Edit the configuration section, and execute on your ubuntu-phone.

From an Ubuntu desktop

(with : phablet-tools installed from ppa)

Add phablet-shellsudo add-apt-repository ppa:phablet-team/tools
sudo apt-get update
sudo apt-get install phablet-tools
Activate Developer mode
Download and edit the script :wget https://gist.githubusercontent.com/boTux/069b53d8e06bdb9b9c97/raw/a03be09136c5275b2956c512accdad69b30e8074/ubuntu-touch_owncloud-sync_contact-calendar.sh
gedit ubuntu-touch_owncloud-sync_contact-calendar.sh

In the [Configuration] / [OwnCloud] Section

Enter your OWNCLOUD_URL, whithout the last /.
Enter your USERNAME & PASSWORD.
Enter the name of your owncloud address-book & calendar.

In the [Configuration] / [Phone] Section

Edit CONTACT_DB_NAME & CALENDAR_DB_NAME with names of your choosing.
Edit CRON_FREQUENCY to the sync interval you need.

Save

Connect your phone via USB and copy the script (via nautilus, for example in Documents/)
Connect via phablet-shell and run the script :phablet-shell
chmod +x Documents/ubuntu-touch_owncloud-sync_contact-calendar.sh
./Documents/ubuntu-touch_owncloud-sync_contact-calendar.sh

I'm hoping this can help some of you...


How to Restore Win 7 Boot Loader to use Veracrypt after Dual Booting Ubuntu

1 - Remove Ubuntu so I can reload it differently.

That depends on how different. You could use only home folder encryption (PAM & ecryptfs) if that is sufficient for you (it obviously is good enough to land in the next version of Android) and avoid reinstalling. Alternatively you could also encrypt your home partition and mount it during login (PAM & LUKS).

  2 - Restore the Win 7 boot loader

This was answered here: How to create or recover Windows Bootloader after deleting Ubuntu boot drive

Ideally you should get rid of MBR and its limitations (and therefore Windows 7), but a UEFI loader for Veracrypt may still take a while to develop and release. Using one hard drive for each OS is always the best option, no matter if booting MBR or UEFI

It's possible to chainload an image of the Truecrypt MBR loader in Grub to boot Windows and loading Veracrypt MBR should be possible too. (How do I get Grub2 to boot a Truecrypt-encrypted MBR? Remember to always backup your headers, some solutions even make use of backed up headers and rescue images.)

So this would be my suggestion for MBR with one HDD and 3-4 primary partitions (try to avoid extended partitions):

Grub installed by Ubuntu for OS selection

boot unencrypted Ubuntu Root

encrypted home with LUKS or ecryptfs (PAM_mount)

boot chainloaded Veracrypt Windows

Related: Is there a reason to use TrueCrypt over VeraCrypt?


The crucial point isn't the redirection, but the content of your file. exec executes your file. That means, it looks at the content of your file and tries to run the commands written in it. But your file does not contain any commands that the shell knows about.

It comes across hi, but there's no such command. So it tells you that:

sh: hi: command not found

Then, it tries the next line. It reads 'so', but there's no such command. So it tells you that:

sh: so: command not found

If you want to hand over your file as input to a program, you need to bring that program into play somehow. Don't just throw the data to the shell and hope for it to figure out on its own what do with it ;)


Terminal shortcut key stopped working - Ubuntu 20.04

A workaround was to add a new keyboard shortcut to the gnome-terminal. The Launch Terminal shortcut is still not working


Screen shuts off when using proprietary NVidia drivers

I had a similar issue when I upgraded my video card.  I was able fix this by blacklisting the nouveau driver as well as some other steps, similar to what @Ted suggested here.  Googling "nouveau driver causes nvidia black screen" yields an array of solutions.


Make Diodon use the Faenza-Darkest icon in the top panel

I have this problem too when installing diodon this morning. I am using Faenza set too. In Ubuntu 14.04 LTS.

This solution worked for me.

Create '.icons' directory on your home dir

username@hostname:~$ cd
username@hostname:~$ mkdir -p .icons/Faenza/status/22

Now copy the 'edit-paste' icon from 'Faenza-Darkest' icon set

username@hostname:~$ cp /usr/share/icons/Faenza-Darkest/actions/22/edit-paste.png ~/.icons/Faenza/status/22/diodon-panel.png

Now the diodon applet will use Faenza's edit-paste icon.


Open a terminal and run the following command.

sudo apt-get install pluma

And Pluma is installed.


Prevent/stop wpa_supplicant from starting

Should be enough to remove the file

/usr/share/dbus-1/system-services/fi.epitest.hostap.WPASupplicant.service

Move it somewhere so you can restore it, rather than immediately delete it. ;-)


Stata 14 fails to start on Ubuntu 16.10/17.04/17.10, with "libpng12.so.0" error. How do I install libpng12?

Your symlinks won't work because you're creating a link to a i386 library in a path that is commonly searched for amd64 libraries. Executables compiled for one architecture (amd64) can't load shared libraries compiled for another architecture (i386).
You may be able to trick Stata to use libpng16 instead of libpng12 if you ensure that it's for the same architecture as the Stata executable itself. I’ll assume that the latter is for amd64 (considering that the error message complains about an invalid ELF class ELFCLASS32 which is used for i386 instruction sets only).
It looks like Stata explicitly checks the libpng version, so the trick described above and thus the two solutions building upon it below won't work. Refer to the Better Solution instead.
Quick and dirty solution
Masquerade libpng16.so.16 as libpng12.so.0 to all amd64 executables:

sudo ln -sfT libpng16.so.16 /usr/lib/x86_64-linux-gnu/libpng12.so.0

Still dirty but with fewer future surprises
Masquerade libpng16.so.16 as libpng12.so.0 to selected executables only (thus eliminating the risk that another applications picks up the bogus libpng12.so.0 by mistake):

Create a directory for “masquerade” shared libraries, e. g.:
sudo mkdir -p /usr/local/lib/stata/shared-library-hack

Place a symbolic link to the masked shared library into it:
sudo ln -s /usr/lib/x86_64-linux-gnu/libpng16.so.16 /usr/local/lib/stata/shared-library-hack/libpng12.so.0

Run the program with a modified library search path:
LD_LIBRARY_PATH=/usr/local/lib/stata/shared-library-hack [COMMAND] [ARGUMENTS...]

Or if you want to retain potentially existing alterations to the library search path:
LD_LIBRARY_PATH="${LD_LIBRARY_PATH:+"${LD_LIBRARY_PATH}:"}/usr/local/lib/stata/shared-library-hack" [COMMAND] [ARGUMENTS...]

If you don't want to type such a long command each time you start such an application, you can either use a shell script wrapper or edit the application starter description (i. e. the Exec= stanza in the .desktop file) accordingly.

Better solution
Actually install libpng12.so.0. The easiest way is to download and install the Deb package of an earlier Ubuntu release:

Go to https://packages.ubuntu.com/xenial/amd64/libpng12-0/download, pick a mirror and download the package archive.

Use your favourite package manager to install the package archive.
On the command line you can use:
sudo apt install [DOWNLOAD-PATH]/libpng12-0_*_amd64.deb

(Replace [DOWNLOAD-PATH] with whichever path you used as the target directory of the download earlier.)

This is not a proper solution, because updates to libpng12, including security updates, will not be automatically installed, so doing this introduces a security risk. – fkraiem Dec 8 '17 at 4:36


You question is not clear.

If you are getting 844762a208593ee5cf396cb09522b1dfa127c65b79f71f4863c062039215d0d8 for your file, then that is correct.

If you are getting 22580b9f3b186cc66818e60f44c46f795d708a1ad86b9225c458413b638459c4 for your file, then somehow, you have downloaded the Ubuntu 18.04.2 desktop iso version instead of the kubuntu version.

I downloaded the kubuntu iso:

doug@s15:~/iso$ shasum -a 256 kubuntu-18.04.2-desktop-amd64.iso
844762a208593ee5cf396cb09522b1dfa127c65b79f71f4863c062039215d0d8  kubuntu-18.04.2-desktop-amd64.iso
doug@s15:~/iso$ ls -l kubuntu-18.04.2-desktop-amd64.iso
-rw-rwxr--+ 1 doug doug 1923727360 Jun 13 23:57 kubuntu-18.04.2-desktop-amd64.iso

which is the correct checksum.


How to disable touchpad while typing on Ubuntu GNOME

Run syndaemon with options that follow your preferences as a startup script. See man syndaemon for help. The command is in xserver-xorg-input-synaptics package.


Split VPN (PPTP) in Ubuntu 13.10 not working -- Router problem?

Do you have PPTP Passthrough, or something like it, enabled on your router? If not, I suspect that your router might be blocking proxy traffic.


Touchpad drivers worked in 16.04 and don't work on 18.04

Installing xserver-xorg-input-synaptics ended up fixing the problem

sudo apt-get install xserver-xorg-input-synaptics