MySQL server does not start because of missing permissions, but they are given

You stated that you "just copied my old set of databases" The word "copying" in this situation could imply an incorrect approach. Of course your "copying" may have involved other undisclosed steps.  MySQL seems to be structured to export your databases and to then import them into the "new" database. Not actual copying.

Do you still have your original MySQL configuration operational? Are the databases still there and accessible?

Do you have MySQL installed on your "new" system?

Do you have phpMyAdmin installed? If not look into how to use mysqldump.

If phpMyAdmin is available, use phpMyAdmin to export your databases.
After that copy the output to the download folder of the "new" computer system.

On the "new" computer system, again use phpMyAdmin, but in this case, to import the databases from the download folder. Importing your databases should resolve your permissions problem.

For additional more in-depth guidance on how to export/import do an internet search on "mysql exporting databases".

Here is a random pick example based on using mysqldump: "Export and Import all MySQL databases at one time"


Problem installing latest faience theme on ubuntu 14.04

It looks like the package maintainer has released the fix the next day as version 0.7.1. See the changes here: https://launchpadlibrarian.net/177159549/faience-theme_0.7.1_source.changes.

Also make sure you are using ppa:tiheum/equinox instead of ppa:noobslab/themes. The package has not been updated to the lastest in the latter ppa until now.


Download Ubuntu 11.10 from here. 32bit or 64 bit, either will work fine on your laptop.
Follow the directions at the link to make a bootable CD or USB stick. Click the 'Show me how' button to see that you are doing the steps correctly.
Install Ubuntu following the guide on the same page as above.
If you still have errors after following the guide exactly, post the error messages up here with any specifics. Try to copy any error messages you see word-for-word. This helps us both.
Welcome to Ask Ubuntu!


neither kubuntu 13.04 nor ubuntu 12.04 can detect network (wired/wireless) activity

On Ubuntu go to Software Sources, select Additional Drivers tab and if there's any driver listed for your network cards, install it.


You are using bash features, but letting systemd run your script with /bin/sh. Put a #!/bin/bash at the beginning, or rewrite your script to only use sh features.


Dual boot: Ubuntu cannot detect Windows 10 (Legacy) after install

I just looked at my partition table and it seems that your Windows OS partitions' boot flag was removed. It you look at what you posted, the * on /dev/sda1 is only 1G and is marked as BOOT. Unless you loaded your bootloader on that partition.

If we take a look at your partition table, we see that you have 2 partitions that are NTFS which is the format windows uses. You have /dev/sda2 and /dev/sda5. Figure out which one of those 2 is the one with the windows installation by mounting them. Once you figure out which one has the windows installation then you can set a boot flag on it:
being the partition number that has the windows installation on it, you have 2 and 5 available.

We can start by mounting both of them, one at a time and checking their contents.

I know you already mentioned that your files are in /dev/sda2 but im writing these instructions for others who have it different.

mkdir ~/MOUNT <- This will create a temporary directory for us to mount our partition in your home folder. So the path of this folder will be /home/user/MOUNT so you can browse to it via file manager GUI.
sudo mount -t ntfs -o uid=user,gid=user /dev/sda2 ~/MOUNT <- This will mount the second partition as NTFS in the directory we just created. As well as mounting it as your current username that way you can browse to it freely. If the uid and or gid are not added for your user, it will mount as root and only root can browse to it.
If the command completed without error, you should be able to browse in the directory from a file manager and check if it contains your windows installation.
sudo umount /dev/sda2 <- This will unmount your partition.

Now repeat the same steps (1-4) for /dev/sda5 if /dev/sda2 was not where Windows was installed.

Before we make any changes, lets update grub first then reboot and see if that helped (see #5).

Now that you figured out which partition has the Windows installation, and updating grub prior did not have an effect, you can try to manually set a boot flag on your windows partition.

sudo fdisk /dev/sda
In the menu, press a and it will ask which partition to add a boot flag. Which ever you find out has the windows installation, that will be the number you will enter.
Once you have made your choice, you can press P to print out the current partition table and make sure the partition you typed has been marked with an * in the Boot column.
Once you have verified that everything is correct, you can press w to write changes to the partition table and exit.
Now we need to update grub with sudo update-grub or sudo update-grub2, depending on the version of grub you are using.

Let us know if you need more help!


My 4th gen ThinkPad X1 Yoga's keyboard & trackpad not deactivating

Lenovo says the Yoga BIOS design for Yoga machines precludes Linux install, so I'm not surprised. See Lenovo's own statement on the subject https://news.lenovo.com/pressroom/press-releases/lenovo-statement-on-linux-support-for-yoga/


How can I restore a broken theme in GNOME Shell?

After trying 101 things, the solution that finally worked for me was taking a backup of ~/.config/dconf/ and then removing it.  This was regenerated again after the next reboot, with the default window and icons themes coming back.

Note: I also lost a few minor customisations I'd made, and had to redo them again manually.


Ubuntu 14.10 freeze at boot. After upgrade intel graphics (xorg-xserver etc)

The xorg-edgers are known for potentially breaking systems.  You will need to boot into one of the recover modes (the one with networking available) and remove that package:

sudo apt-get install ppa-purge
sudo ppa-purge xorg-edgers
sudo apt-get update
sudo apt-get upgrade

To get into the recovery mode, hold the left shift key down at boot time so that you see the Grub menu - choose the recovery option, and choose a terminal with network capability.  This does take a short while to load and become operational.


I think that the simplest way is to use string operators. For example, if:

str="/somefolder/andsubfolder/my_first_text.txt"

then you can use somethink like:

str=${str##*/}
echo ${str%.txt}

But, you can still use cut with the help of rev (see man cut and man rev for more info):

echo $str | rev | cut -d/ -f1 | cut -d. -f 2- | rev

And the solution using awk is:

echo $str | awk -F/ '{print $NF}' | awk -F. '{$NF=""}1'


How to activate HDMI as my default output starting from BIOS, GRUB, GDM,  and Desktop?

Usually this is selectable in the BIOS of the machine. I have a system with an NVidia card that has both HDMI and VGA outputs. In the BIOS, I had to select "Primary Display Port" as "HDMI", and then it would always default to HDMI for BIOS, grub, console, etc output.


To access recovery mode, as soon as the system boots up, you'll need to hold down SHIFT. You should then see the GNU Grub menu. From here, chose "Advanced Options", then select the option that says "Ubuntu .. recovery mode" or something similar.


I had the same thing after installing 13.04 a couple of months ago, but for me both of the options boot just fine.

If you want to have only the working one in grub, I suggest you hide the faulty loader in grub. The easiest way to manage grub would be to use grub-customizer

sudo add-apt-repository ppa:danielrichter2007/grub-customizer

sudo apt-get update

sudo apt-get install grub-customizer


Up to date tutorial for writing Compiz plugins?

Sam Spillaz (Canonical's key-developer Compiz development) recently held a session in the Developer's week held in March '11 headlined "How to write a Compiz Plugin"

This session took attendees through the following topics:

recent compiz development
how to compile on ubuntu
basic structure of compiz plugin code
walk through on a basic compiz plugin development.

Its well worth a read and I hope to see your efforts soon in some great plugins.  Well done!


So you have Optimus-CUDA graphics card with Geforce GT650M ?

Here is a good (off-topic) - link - but there is anything explained:

https://askubuntu.com/questions/297030/nvidia-frickle-with-hybrid-chipset-is-now-over-finally

You need this package as driver :

CUDA SDK 1.1 Beta for Linux

You find it between center and below at "Download" - Link :

http://www.nvidia.de/object/cuda_1_1_beta.html


Not sure that this is the right "ASK" for your question, but give the following a try, Sounds better than BartPE, (I have not tried it):

http://www.easyuefi.com/wintousb/

Edit:
Oops, did not see the above comment concerning the Lifehacker post.


Ubuntu 16.04: Internal mic not working, headphones not automatically detected, trackpad not working

go into terminal {CTRL ALT T}  and type Sudo apt-get upgrade and install all of your patches than go to your drivers menu and install any extra drivers and reboot.

if that doesnt help have you tried clicking on sound, sound options than go input and click your microphone.


pip: AttributeError: 'module' object has no attribute 'SSL_ST_INIT'

I found that this answer on stackoverflow helped. Basically, it says that you should do this:

rm -rf /home/<Your Username>/.local/lib/python2.7/site-packages/OpenSSL
sudo rm -rf usr/local/lib/python2.7/dist-packages/OpenSSL/
pip install pyOpenSSL


Empty curly braces and semicolon in bash

Both {} and ; have special meanings in bash but in the context of find, it is find which actually interprets these two (actually we want find to interpret these two).

First of all, -exec is an action of find. {} and ; are special parameters for the -exec predicate of find.

The syntax for the -exec action is:

-exec command ;

or

-exec command {} +

So we need to keep {} and ; from being interpreted by shell beforehand.

In the context of find .... -exec:

{} indicates (contains) the result(s) from the find expression i.e. find . -name "FILE-TO-FIND" in this case. Note that empty curly braces {} have no special meaning to shell so we can get away without escaping {}
As bash treats ; as end of a command, we need to escape this with \ i.e. \; so that it can be parsed by -exec not by bash itself.


Someone just remotely entered my computer and start googling for things. How?

They got access because you had Remote Desktop enabled for some reason. You could do similar under Windows.

For security, no matter what OS you are running, do not allow incoming connections unless you know how to secure them, and then only allowing unprivileged usage limited to only those functions you need remote users to have.

svchost.exe is associated with a number of threats so your intruder may have been looking at popping it onto your machine. Of course it is a Windows executable so that wouldn't have impacted you on this Ubuntu box.


"Fontconfig warning: ignoring C.UTF-8: not a valid language tag"

This has been fixed in Debian, according to this bug report, so the fix will propagate to Ubuntu.


Upgrade from 18.04 to 20.04 stucked with `Problem executing scripts APT::Update::Post-Invoke-Success`

I commented out if /usr/bin/test -w /var/cache/app-info … in the file /etc/apt/apt.conf.d/50appstream.

Afterwards GDM showed up and didn't let me sign in (although I'm using lightdm).
I was able to complete the installation although I got stuck a second time and had to kill the update process. I'm sure it would have been better if I would have used

sudo do-release-upgrade -f DistUpgradeViewNonInteractive

instead (note the DistUpgradeViewNonInteractive option!). It's an advice from @user.dz but you should only do it if you can accept that /etc and ~/.config will be overriden.

Also if you are running into this bug:

Check

sudo appstreamcli refresh-cache

(Also an advice from @user.dz)


How can I set a different .bashrc PS1 depending on the directory I'm in?

Look at the code - the real work is done in a function __git_ps1, which is called from inside the prompt.

Replace this function by your own function, e.g.

# this is only a outline of possible code
function myFancyGitPS1() {
   case $(pwd) in
      */someDir/*)
           specialHandling
           ;;
      *)
           __git_ps1 " (\[\033[01;33m\]%s\[\033[00m\])"
          ;;
   esac
}


Ubuntu server 18.04 apache2 how to change the default page?

You need to change document root of apache2

leonid@DevSSD:~$ cat /etc/apache2/apache2.conf |grep DocumentRoot
leonid@DevSSD:~$ cat /etc/apache2/sites-available/000-default.conf |grep DocumentRoot
    DocumentRoot /var/www/html

Above commands not find documentroot in main config, but find it in default virtualhost config, run commands and find out where this setting located. Edit file by sudo nano /etc/apache2/sites-available/000-default.conf
Change DocumentRoot to your site folder /var/www/html/oscommerce/, then restart apache2 by systemctl reload apache2

Update: Apache gives permission error in two cases, first when file permissions not allowing apache2 to read folder/file, when folder requested, e.g. / at end of request line but no index file found.
To fix file/folder permissions:

sudo chown -R youruser:www-data /var/www
sudo chmod -R u=rwX,g=rX,o= /var/www

Additionaly, if web application writes something to some folder, like templates_cache, give that folder write permissions for group.

For index type of error look for DirectoryIndex option in config files

Edited by User asking the question.
The way I fixed this issue is by changing the DocumentRoot for my site config and also creating a index.html file to redirect from the DocumentRoot to the site
Index.html

   <!DOCTYPE html>
    <html>
    <head>
    <meta http-equiv="Refresh" content="5; URL='https://myIPaddress/oscommerce/catalog/index.php'" />
</head>
<body>

</body>
</html>


Will Ubuntu do any damage to my files installed on windows?

You can try ubuntu windows installer WUBI that will install the ubuntu inside the windows7 and it will not harm to your windows drive , files and any other software.
visit :- https://wiki.ubuntu.com/WubiGuide

and on you tube there are various videos for how to use wubi and install ubuntu.

after installing ubuntu you can easy uninstall from add/remove software of windows7 control panel


running vlc whitout it appearing in taskbar kubuntu 16.04

Just open VLC, press the keyboard shortcut Ctrl + P to open "Preferences", in "Interface Settings", inside the box "Look and feel", uncheck "Show systray icon". Restart VLC to check. Voila! :D


How to disable ttyAMA0 console on boot (Raspberry Pi)?

I had this issue resolved for 18.04 by bypassing grub completely by adding these lines to the [ALL] section of /boot/firmware/config.txt:

kernel=vmlinuz
initramfs initrd.img followkernel

I also had device tree commented out in the same file as well but not sure if it  was necessary.


In xubuntu 12.04 you can install ubuntuone-client and ubuntuone-control-panel-qt. Starting ubuntuone-control-panel-qt will then kick off the login and set up your synced folders and everything. Still no thunar integration, but the control panel has enough features that it makes using u1sdtool unnecessary.

For older versions, the previous answer below is probably still useful.

You don't need ubuntuone-client-gnome to use the file sync service of Ubuntu One on your desktop; you lose some integration, but you probably wouldn't appreciate that integration if you're on something other than GNOME anyway.

u1sdtool (part of ubuntuone-client ) is a commandline program that talks to ubuntuone-syncdaemon over dbus, and allows you to do nearly everything you can do via the Nautilus plugin, and some things the Nautilus plugin doesn't know about yet. The only thing not implemented in u1sdtool is sharing a folder with somebody via email; the sharing functionality exported via u1sdtool is slightly arcane, and requires you to know the SSO username of the share receiver, and the share receiver to accept the share using u1sdtool; I'd recommend you use the sharing exposed via the web interface unless you're very confortable with the commandline. The functionality currently in the tool and not in Nautilus includes the ability of unsubscribing from (and resubscribing to) some of your synced folders.

Nobody has done the work to talk to the same dbus interfaces from Thunar (either directly or via libsyncdaemon), but it's certainly possible. Keep in mind that these interfaces sometimes change during development of an Ubuntu release, and while we try to notify other developers of upcoming changes, we make no promises. This communication issue has been the source of some significant frustration in the past, and we're working to address it, hopefully in time for 11.04.


It's not the proper way of doing it, but you can workaround it by unpacking .deb package and copying its content into root fs.

wget http://security.ubuntu.com/ubuntu/pool/main/libp/libpng/libpng12-0_1.2.54-1ubuntu1.1_amd64.deb
dpkg -x libpng12-0_1.2.54-1ubuntu1.1_amd64.deb libpng12

You'll find libraries inside libpng12 folder. Then you just need to copy it into its destination.

But if you don't want anything static in your system you can leave this library alone, but before runing runescape-launcher export LD_LIBRARY_PATH like so:

export LD_LIBRARY_PATH=libpng12/lib/x86_64-linux-gnu
runescape-launcher

I'm not sure about path you need to set, but also try libpng12/lib and libpng12 in case of a problem.

You can also provide custom libraries by using /etc/ld.so.conf.d/. You can read about it here: https://stackoverflow.com/questions/9151491/extending-default-lib-search-path-in-ubuntu


Here is the easiest and fastest way.

Install Menu Editor:

sudo apt install menulibre

Open Menu Editor, Select App, Click on icon to select a new icon:


No " Low Battery " warning in Cinnamon Desktop

Open a browser and go to github. Create and account by registering your email and desired password.

Type in terminal:

ls -al ~/.ssh

Check the directories to see whether you already have any public ssh keys

By default, the filenames of the public keys are one of the following:

id_dsa.pub
id_ecdsa.pub
id_ed25519.pub
id_rsa.pub

If you see an existing public and private key pair listed (for example id_rsa.pub and id_rsa) then type

ssh-agent bash
ssh-add /location/of/key.pub

Test whether you can login

ssh -v host.with.pubkey

If you don't see any existing public key added then type:

ssh-keygen -t rsa -b 4096 -C "your_email@example.com"
ssh-add /location/of/key.pub
ssh -v host.with.pubkey

Now open another terminal and go to

cd /root/.ssh
ls

You will see your public rsa key listed as id_rsa.pub Do

vim id_rsa.pub

Open a browser and login to your github account. Go to settings --> ssh and gpg --> add new ssh -->

In the title bar type the name of your computer. Copy the entire content from vim and paste in in ssh key. Click add.

go to Personal access token --> Generate new token --> check all the boxes --> generate --> copy the token to a text file

Go to first terminal

ssh-agent $(ssh-add /root/.ssh/id_rsa; git clone https://github.com/robin92/cinnamon-power-applet.git)

When asked for user name enter it

When asked for password enter the personal access token

cp -R power@airlog.pisz.pl/ ~/.local/share/cinnamon/applets/

Then add the applet to the desired panel

Hope it helps


fprintd and fingerpring authentication does not work after enrolling my fingerprints on Asus Zenbook UM431DA-AM003

You mentioned enrolling fingers (plural). Try running fprintd-list and seeing which finger is the first listed. Try running printd-verify and testing that finger. Haven't discovered why but on my machine (Synaptics touch reader) it will only properly verify the first print in the list. My current "solution" is to only have a single finger enrolled until I can track down the cause.


Installing pagekite/owncloud remote access on Ubuntu server 12.04

actually I wrote up a tutorial on setting up owncloud a while ago which also deals with port forwarding. It's here.

Gd luck.


Kindle Comic Converter (KCC) installation instructions for Linux

Before install KCC, you need to have KindleGen in your system.

Download the KindleGen tar.gz to a folder such as Kindlegen in home directory (~/KindleGen).
Extract the contents of the file to '~/KindleGen'.

$ cd ~/KindleGen
$ tar xvfz kindlegen_linux_2.6_i386_v2_9.tar.gz

Move the file kindlegen to /usr/local/bin/

$ mv ~/KindleGen/kindlegen /usr/local/bin/

After you do that, download Kindle Comic Converter and install it.

Enjoy!


supervisorctl 3.3.1 http://localhost:9001 refused connection

Apparently there are required fields for the configuration file for version 3.0 and upwards http://supervisord.org/configuration.html

[inet_http_server] is required:

  A TCP host:port value or (e.g. 127.0.0.1:9001) on which supervisor
  will listen for HTTP/XML-RPC requests. supervisorctl will use XML-RPC
  to communicate with supervisord over this port. To listen on all
  interfaces in the machine, use :9001 or *:9001.

  Default: No default.

  Required: Yes.

  Introduced: 3.0

Also [rpcinterface:supervisor] is required as it complains.

So my configuration must look like so:

[supervisord]
nodaemon=true

[supervisorctl]

[inet_http_server]
port = 127.0.0.1:9001

[rpcinterface:supervisor]
supervisor.rpcinterface_factory = supervisor.rpcinterface:make_main_rpcinterface

Now it connects.


sda1 is the ESP and you need it to boot in EFI+GPT. sda2 is certainly a boot partition and hold your kernel, and yes you need it.

LVM is tricky to shrink. Look at the previous ansver there: How can I resize an LVM partition? (i.e: physical volume)


ARM Chroot installing xfce fails, packages named different

I guess you need to update you package database, run:

sudo apt-get update


Change the style of specific programs in Xubuntu 12.04

Meng Tian already answered this question here, but the answer is probably even more relevant to my question. Since I did things slightly differently, I'm posting my own answer here.

You can launch programs with a different style/theme by placing GTK2_RC_FILES=/usr/share/themes/YourFavoriteTheme/gtk-2.0/gtkrc before your program's command when running the program from the command line.

For example, if you wanted to run leafpad with the Bluebird style/theme, you could just enter this at the command line:

GTK2_RC_FILES=/usr/share/themes/Bluebird/gtk-2.0/gtkrc leafpad

If you want to make this simpler, you can create an executable .sh script file and put this code in it:

#!/bin/sh

GTK2_RC_FILES=/usr/share/themes/Bluebird/gtk-2.0/gtkrc leafpad "$@"

If you do this, you can also create a launcher for this script which will launch the program in the correct style.

Note: the "$@" allows you to pass arguments through your script to your program. This was all I needed for my purposes, but if you need to do something fancy like pipe output to the program, this script may not work.


Ubuntu cannot detect my Logitech Wireless m510 mouse?

Download HID for your mouse and keyboard and version of Ubuntu here.
Installation And Un-installation Instruction here.

You can also try this before downloading from the above link.

Open your terminal by pressing Ctrl+Alt+T and enter in:

lsusb


You may find this article from Arch Wiki very useful: https://wiki.archlinux.org/index.php/GRUB/Tips_and_tricks

What I got out of that article for my modest needs is setting wallpaper/background:

add line GRUB_BACKGROUND=/path/to/your/image.jpg into /etc/default/grub and run update-grub. Personally I use GRUB_BACKGROUND=/usr/share/backgrounds/Foggy_Forest_by_Jake_Stewart.jpg which is one of the default wallpapers


Launch file manager from terminal with a keyboard shortcut

A keyboard shortcut like this doesn't exist by default, but you can use the bash built-in bind to define one.
Just add the following section to your ~/.bashrc:
# define function that opens default FM in working directory
fmhere(){
    xdg-open "$PWD"
}
# bind hotkey to it (<Alt><Shift><F>)
bind -x '"\eF":"fmhere"'

\eF is the terminal escape sequence of my keyboard shortcut, Alt+Shift+F. Check out @slm's excellent answer over at unix.SE to learn how to determine the correct escape code for your keyboard shortcut of choice.
Another quick way to determine the escape code:
Open your terminal and press Ctrl+V. Now press your favorite keyboard shortcut. The correct escape code should appear. Just make sure to replace ^[ with \e before adding the shortcut to your .bashrc, e.g. replace ^[F with \eF.

Sources:
https://www.gnu.org/software/bash/manual/bashref.html#Bash-Builtins
https://unix.stackexchange.com/q/89622/29245


To see the messages of the console during an applet execution, it is enough to launch the Internet navigator in a terminal. The output message will display there.


Issue xrandr on the console will show you the names of different outputs available on your system (LVDS, VGA-0, etc.) and resolutions available on each:

If you see the desired resolutions available for the output that you want (tv screen), set it via xrandr --output <output> --mode <mode> (example: xrandr --output LVDS --mode 1360x768)

If your desired resolution is not available, following the following example (example showing 800 600 but you should be able to do the same for 1360 768).

$ cvt 800 600
# 800x600 59.86 Hz (CVT 0.48M3) hsync: 37.35 kHz; pclk: 38.25 MHz
Modeline "800x600_60.00" 38.25 800 832 912 1024 600 603 607 624 -hsync +vsync

$ xrandr --newmode "800x600" 38.25 800 832 912 1024 600 603 607 624 -hsync +vsync
$ xrandr --addmode LVDS 800x600
$ xrandr --output LVDS --mode 800x600

Taken from Arch Linux Wiki.


How to install google chrome extensions though Terminal

Here is the script, you gonna need extension ids, they can be found in the address bar when you go to the details of the extension on the market or at chrome://extensions. The script will also install chrome if it is not installed, remove the middle part if that's not needed.

Save this script to the install-chrome.sh file:

#!/bin/bash

install_chrome_extension () {
  preferences_dir_path="/opt/google/chrome/extensions"
  pref_file_path="$preferences_dir_path/$1.json"
  upd_url="https://clients2.google.com/service/update2/crx"
  mkdir -p "$preferences_dir_path"
  echo "{" > "$pref_file_path"
  echo "  \"external_update_url\": \"$upd_url\"" >> "$pref_file_path"
  echo "}" >> "$pref_file_path"
  echo Added \""$pref_file_path"\" ["$2"]
}

if ! which "google-chrome" ; then
  wget -q -O - https://dl-ssl.google.com/linux/linux_signing_key.pub \
  | sudo apt-key add -
  echo 'deb [arch=amd64] http://dl.google.com/linux/chrome/deb/ stable main' \
  | sudo tee /etc/apt/sources.list.d/google-chrome.list
  sudo apt-get update
  sudo apt install google-chrome-stable
else
  echo Chrome already installed
fi

install_chrome_extension "cfhdojbkjhnklbpkdaibdccddilifddb" "adblock plus"
install_chrome_extension "fmkadmapgofadopljbjfkapdkoienihi" "react dev tools"
install_chrome_extension "anmidgajdonkgmmilbccfefkfieajakd" "save pinned tabs"
install_chrome_extension "dbepggeogbaibhgnhhndojpepiihcmeb" "vimium"

Run

sudo bash install-chrome.sh

Restart chrome.

More scripts at https://github.com/grabantot/scripts


Ubuntu server - Will it Run Oracle instant client?

You can install the Oracle Instant Client by following this guide. Of course you have to replace the 11.2 version numbers with the 10.2.0.5.0 version numbers.

I installed the Oracle Instant Client 10.2.0.5.0 in a VM running Ubuntu 14.04, and it works. Installing the php-oci8 module also works, but you have to use the oci8-2.0.11 version for PHP5 (see the output of pecl remote-info oci8):

sudo apt-get install php-pear php5-dev
sudo pecl install oci8-2.0.11
  # enter instantclient,/usr/lib/oracle/10.2.0.5/client64/lib
cd /etc/php5/mods-available
echo 'extension=oci8.so' | sudo tee oci8.ini
sudo php5enmod oci8

If you are using PHP7, this should work:

sudo apt-get install php-pear php-dev
sudo pecl install oci8
  # enter instantclient,/usr/lib/oracle/10.2.0.5/client64/lib
cd /etc/php/7.0/mods-available
echo 'extension=oci8.so' | sudo tee oci8.ini
sudo phpenmod oci8


Ubuntu seems to have completely messed up my laptop's BIOS?

On my Acer, Even though I removed Ubuntu over a year ago, it still showed two instances.  I don't remember the details now, but when I was on the menu, there were options to delete the OSes in the BIOS.  I deleted the two Ubuntu installations.  I don't remember if I deleted Windows or not.  I was thinking about it to see what would happen.

So, go into your BIOS and check for the options where you found Ubuntu. (mine was spelled in lower case "ubuntu") See if you can delete them.


How to Stop KDE Migration Agent Popping Up at Login? (Kubuntu)

I have the same problem.
The solution was to go to kwallet and make a new wallet with new password


Pasting to vim in putty enters to visual mode

Ctrl-V has this function: Enter in visual mode.

To paste you should use instead the Ctrl-Shift-V.


Edit:

Sadly dpkg or apt dosn't keep a log of what packages were installed / removed and when, as far as I know. The best shot here is to look through your .bash_history and try to find what you modifyed. (You do know that dpkg -l will show you all packages that are installed configured etc. right?)

To properly purge a package use:

apt-get remove --purge <package>

To reconfigure ALL packages on your system use the following command (as root):

dpkg -l | cut -d " " -f3 | xargs dpkg-reconfigure

Be aware that this will possibly take some time.

These tools are capable of getting a lot of configuration "reseted" but they are incapable of magic. If you messed up your system really bad then the best solution sometimes is to back-up everything and reinstall.

You can use dpkg-reconfigure <package-name> to "reset" most packages to their defaults; but no-one knows what you installed with your systems main install except you.

You could search for which packages a "default" installation puts on your machine and remove everything else, but then again we can't know what you installed with your system's base install.


Just upgraded to Ubuntu 18.04 and can't use compiz grid window resize commands?

Ubuntu 18.04 dropped support for the Unity desktop compositor in favour of GNOME Shell. GNOME Shell is incompatible with Compiz. You need to look for a method to replicate this behaviour using GNOME Shell and its extensions or install and use an unofficial, community-supported version of Unity.

P.S.: There's a follow-up question with a suggestion for a replacement GNOME Shell extension.


Ubuntu 17.10 volume control does not work

had a similar problem on kubuntu, found this

https://www.kubuntuforums.net/showthread.php/72510-No-audio-volume/page2
and is a hard to find known problem
https://wiki.ubuntu.com/ArtfulAardvark/ReleaseNotes/Kubuntu#Known_Problems

  editing /etc/pulse/default.pa and commenting the last 3 lines:

    #.ifexists module-switch-on-connect.so
    #load-module module-switch-on-connect
    #.endif

  seems to solve the issue in some cases.


Change the video DVD player of upper-right button displayed in Nautilus

It seems that the application displayed there is the one selected under Settings - Details - Removable media - DVD video or, in case 'Ask what to do' or 'Open folder' is selected instead,  the first application displayed in that list.

The general solution seems to be simply to select a specific player (instead of "Ask what to do" or "Open folder") under Settings - Details - Removable media - DVD video. In this way that player will take the first position in that list even if "Ask what to do" or "Open folder" is selected afterwards.


If you look at the config.log file, you will likely see that although the error message is Can't find ext2fs library, the actual error is related to undefined references within libext2fs.a

configure:5298: checking for ext2fs_bmap in -lext2fs
configure:5323: gcc -o conftest   -static conftest.c -lext2fs   >&5
/usr/lib/gcc/x86_64-linux-gnu/7/../../../x86_64-linux-gnu/libext2fs.a(alloc_stats.o): In function `ext2fs_inode_alloc_stats2':
(.text+0x106): undefined reference to `com_err'

I was able to get it to configure and build using

./configure CFLAGS=-pthread LDFLAGS='-pthread -static' LIBS=-lcom_err
make

i.e.

$ file -b ./src/extundelete
ELF 64-bit LSB executable, x86-64, version 1 (GNU/Linux), statically linked, for GNU/Linux 3.2.0, BuildID[sha1]=a03a7d251e42c8a9182b062841f81e5d1cccc7c7, with debug_info, not stripped

Note that I did not try to actually run it.

If you omit the -pthread options, it will likely give other errors about unresolved semaphore prototypes sem_wait etc. I have no idea if this is the "right" resolution.


simple scan program when scanning photo the picture is surrounded by a massive amount of whitespace, how to remove white space via cli batch

-trim won't work because of the black lines along the left and top borders and because some of the "white" area isn't exactly white.  If those edges are present in all of your images, crop those off first, then add a white border so all 4 corners are white, then trim, for example:

convert "Scanned Document-04.png" -shave 10x10 \
        -bordercolor white -border 1x1  -fuzz 20% -trim trimmed.png

The -shave option removes the black edges
The -bordercolor white and -border 1x1 add a thin white border
The -fuzz 20% is needed because some of your "white" pixels are not exactly white.
The -trim option removes the nearly white borders, including the big area you were originally wanting to remove.


Downgrade all external packages to the official ones

You could use apt-forktracer

To install it you must first enable the Universe Repository and then install it either via the software center or with the command sudo apt-get install apt-forktracer

Here's an excerpt from the man page:

apt-forktracer analyzes each installed package separately, reporting on the standard output these packages which are in a "non-standard" state. What "non-standard" means depends on the mode of program operation:

default (non-verbose) mode
    this state means packages in an incorrect state (e.g. no candidate version) or packages whose candidate version is different than the newest available official version.

verbose mode
    this state also includes packages whose installed version is different from the candidate version

And here's an example of the default output:

libavformat57 (7:3.1~~git20160413.62652~ubuntu14.04.1) [LP-PPA-motumedia-ffmpeg-daily: 7:3.1~~git20160413.62652~ubuntu14.04.1]
libavresample3 (7:3.1~~git20160413.62652~ubuntu14.04.1) [LP-PPA-motumedia-ffmpeg-daily: 7:3.1~~git20160413.62652~ubuntu14.04.1]
libavfilter6 (7:3.1~~git20160413.62652~ubuntu14.04.1) [LP-PPA-motumedia-ffmpeg-daily: 7:3.1~~git20160413.62652~ubuntu14.04.1]

For more information see man apt-forktracer

Now that we know the package names in question we can remove (or purge them)

Other methods as @muru notes in his comment are to:

A) use synaptic to locate the obsolete packages.

You can then select those you wish to remove or completely remove as shown below:

Or

B) use aptitude

Upon launching aptitude Select Actions -> Become root and after entering your password Select "Obsolete and Locally Created Packages" as shown below:

Navigate to the package you want to remove as shown below:

Press the - key to mark the package for removal. When you've completed matking the packages you wish to remove press g to remove them Or is you've made a mistake in marking, Ctrlu to Undo yiour changes for the session.

Sources:

https://manpages.debian.org/testing/apt-forktracer/apt-forktracer.8.en.html

http://aptitude.alioth.debian.org/doc/en/ch02s01s02.html


I'm going to assume you ran

sudo airmon-ng start wlan0

to get your mon0-2 monitor channels.

The problem you have now it that you ran the above command 3 times and not just once.
first stop mon1 and 2 by running

sudo airmon-ng stop mon1
sudo airmon-ng stop mon2

Now depending on what you want to do you'll need to chose wlan0 or mon0.
If you simply want to monitor your wifi box you'll need to chose mon0. If you actually want to affect your wifi connection you'll need to chose wlan0.

Your next problem is that you haven't installed the correct drivers for your chipset that work with airmon-ng (if there are any at all. Airmon-ng doesn't support every chipset). You can get it to work without the correct airmon-ng drivers but your mon0 will be set to the -1 channel.

Instructions on how to determine and install the correct airmon-ng drivers for your chipset can be found here.

I would normally include the instructions here but they are several pages long so I decided against that.


How to use debcondf Show results with debconf-set-selections?

You need to use pre-seeding.
The debconf-set-selections command presets answers asked by debconf before installing the package.

E.G.

sudo debconf-set-selections <<< "shared/accepted-oracle-license-v1-1 boolean true"

Then install the package.

sudo apt-get install -y oracle-java7-installer


This is what I did to get everything working the way I want:
Accept incoming TCP connections on ports 443 and 8443
sudo iptables -A INPUT -i eth0 -p tcp --dport 443 -j ACCEPT
sudo iptables -A INPUT -i eth0 -p tcp --dport 8443 -j ACCEPT

Redirect port 8443 to 443
sudo iptables -A PREROUTING -t nat -i eth0 -p tcp --dport 443 -j REDIRECT --to-port 8443

Save changes to iptables
sudo iptables-save


From Environment variables:
$LOGNAME is same as $USER which gives

The name of the currently logged-in user. This variable is set by the
system. You probably shouldn't change its value manually.

From man logname:

logname - print user´s login name

Explained differently used by following example:
pandya@pandya-desktop:~$ sudo su
root@pandya-desktop:/home/pandya# echo $LOGNAME
root
root@pandya-desktop:/home/pandya# logname
pandya
root@pandya-desktop:/home/pandya# exit
exit
pandya@pandya-desktop:~$

Here you can see the difference after logging as root in a terminal,

$LOGNAME gives the name of the currently logged-in user in the terminal (i.e root)
Whereas logname prints the user's login name who logged in to the session (i.e. pandya)


Change tooltip text color of Ubuntu Vimix theme

the one you are looking for is tooltip label

tooltip label {
  color: green;
  min-height: 20px;
  padding: 0 2px;
}

seems to be there are more colors configured for header-bar and title-bars in different conditions in this vimix gtk.3-0 css file.

some i found are below, if you want them in single color, make all feilds same color.

Black

window.tiled headerbar, window.tiled headerbar:first-child, window.tiled headerbar:last-child, window.tiled headerbar:only-child,
window.tiled-top headerbar,
window.tiled-top headerbar:first-child,
window.tiled-top headerbar:last-child,
window.tiled-top headerbar:only-child,
window.tiled-right headerbar,
window.tiled-right headerbar:first-child,
window.tiled-right headerbar:last-child,
window.tiled-right headerbar:only-child,
window.tiled-bottom headerbar,
window.tiled-bottom headerbar:first-child,
window.tiled-bottom headerbar:last-child,
window.tiled-bottom headerbar:only-child,
window.tiled-left headerbar,
window.tiled-left headerbar:first-child,
window.tiled-left headerbar:last-child,
window.tiled-left headerbar:only-child,
window.maximized headerbar,
window.maximized headerbar:first-child,
window.maximized headerbar:last-child,
window.maximized headerbar:only-child,
window.fullscreen headerbar,
window.fullscreen headerbar:first-child,
window.fullscreen headerbar:last-child,
window.fullscreen headerbar:only-child,
window.solid-csd headerbar,
window.solid-csd headerbar:first-child,
window.solid-csd headerbar:last-child,
window.solid-csd headerbar:only-child {
  border-top-left-radius: 0;
  border-top-right-radius: 0;
background-color: black;
}

Black background

Blue

.titlebar:not(headerbar),
headerbar {
  transition: background-color 100ms cubic-bezier(0, 0, 0.2, 1), color 100ms cubic-bezier(0, 0, 0.2, 1);
  min-height: 36px;
  padding: 0 6px;
  box-shadow: 0 1px 1px rgba(0, 0, 0, 0.12), 0 1px 2px rgba(0, 0, 0, 0.24);
  background-color: blue;
  color: red;
}

Blue background

Yellow

.titlebar:backdrop:not(headerbar),
headerbar:backdrop {
  background-color: yellow;
  color: #FFFFFF;
}

Red

.titlebar, .titlebar.background {
  border-top-left-radius: 2px;
  border-top-right-radius: 2px;
background-color: red;
}

Yellow & Red Backgrounds


You might try this I am not sure if it will work or not. I had issues like this as well with a 22 inch Curtis TV / Monitor, I used the following to fix my resolution issue and the monitor not being recognized by Ubuntu.

This may not work but it's worth a shot.

Resolution / Monitor Fix


Sudden fall in wifi internet speed in ubuntu 14.04 LTS

It looks like this adapter does not work well in 802.11n mode. So disabling it improves connection.** sudo tee /etc/modprobe.d/iwlwifi-opt.conf <<< "options iwlwifi 11n_disable=1"** You can also try to disable not all 802.11n, but partially. It can be selected by 11n_disable=2, 11n_disable=4 or 11n_disable=8 instead of 11n_disable=1. You can enable all of them and remove one by one to test which one does the trick. Every new setting overwrites the previous one.


You have an extended partition /dev/sda2 which contains unallocated space, delete the partition first and then extend the 1st partition /dev/sda1


Play a file located on a remote laptop, in that machine itself from distant machine

If you want to control a emus instance on a box remotely via the CLI then you can use cmus-remote.
Demonstration and explanation on this YouTube link:-
https://youtu.be/fWL0bjCau68


Why is 12.04 removing the -server kernel flavour?

As you noticed in the release announcements, the generic and server kernel flavors were merged for the 12.04 release in an effort to reduce the maintenance burden over the life of the LTS.  The two kernel flavors actually only differed with regards to 2 major kernel config options: the default I/O scheduler and the preemption model.

This was discussed in detail on the Ubuntu Kernel Team mailing list

https://lists.ubuntu.com/archives/kernel-team/2011-October/017471.html

As noted in that thread, the default I/O scheduler changed from "deadline" to "cfq".  However, anyone wanting to remain with the Deadline I/O scheduler could do so at boot time by setting elevator=deadline.

The preemption model changed from CONFIG_PREEMPT_NONE to CONFIG_PREEMPT_VOLUNTARY.  At this time, I unfortunately do not have any performance benchmarks on hand to point you at.  Hope this helps some.  Thanks.


Looks like you are using outdated distro, you can read the following on PPA page

  Supported Ubuntu versions:
  - 14.04 (trusty)
  - 14.10 (utopic

Try using xorg-edgers PPA. First disable oibaf PPA
     sudo apt-get install ppa-purgesudo ppa-purge ppa:oibaf/graphics-drivers
Then add xorg-edgerssudo add-apt-repository ppa:xorg-edgers/ppasudo apt-get updatesudo apt-get upgrade


I can't install packages from the updater manager

If can't to solve with apt-get update -f, then try to upgrade system. Before you do this, make backup.


Video game "Gish" will only launch from command line

General advice for this sort of problem

Try changing Exec=/opt/gish/gi.sh to Exec=sh /opt/gish/gi.sh.

If that doesn't work, try changing the Path line so it specifies whatever directory you're in when you run the program in the Terminal. Assuming you're in your home directory, the line would become Path=/home/aberration where aberration is replaced by your username on your Ubuntu system (if different).

If that doesn't work either, then please open the file called .xsession-errors located in your home directory (in PCManFM you'll have to press Ctrl+H or click View > Show Hidden to make this and other files that start with . appear), select its entire contents, copy it to the clipboard, paste it at the Ubuntu Pastebin, and edit your question to include the URL for it. Make sure that you have attempted to run the game from the LXDE menus very shortly before opening .xsession-errors so that messages pertaining to the failure are likely to appear near the end of the file.

Advice specific to the error in .xsession_errors and the script's specific contents

It seems likely that your suspicion is correct; that is, that when the script is run from LXPanel, the test for whether or not your architecture is 64-bit is not working properly. I am not sure exactly what is going wrong. But since the script does not have a leading hashbang line (i.e., a line starting with #! followed immediately by the full path to the program that is to act as the script's interpreter), it is probably being run by a different shell when you run it from LXPanel than when you run it from bash in LXTerminal. When you run it from LXPanel, it is probably being run by the default shell (/bin/sh, which is a symbolic link to the dash shell), whereas when you run it from within bash in LXTerminal, it is being run by bash. The script uses some unusual syntax that I am not familiar with, which might reflect that my scripting knowledge is a bit rusty, but might be because I write scripts for sh/dash rather than bash.

I recommend that you back up the script (sudo cp /opt/gish/gi.sh /opt/gish/gi.sh.old) and then try editing it by adding the line #!/bin/bash to the very top, to make it run with bash. Then see if it runs properly.

If it does, then I recommend submitting a bug report to the creators of gi.sh. (I am guessing this is not an Ubuntu package, since it is installed in /opt, so you'll have to check if the project has its own bug reporting guidelines first.) While the fix detailed above is appropriate for Ubuntu, a fix likely to work properly on a wider variety of Unix-like systems (Linux-based and otherwise) would be to use #!/usr/bin/env bash rather than #!/bin/bash since env is in /usr/bin significantly more often than bash is in /bin. (The authors should also be aware that bash is not present on all Unix-like systems, so if Gish is intended to run on systems that are likely not to have bash and it doesn't otherwise require bash, they might want to edit the script.) And either way, a script that requires bash should not be suffixed .sh, but should instead be suffixed .bash (or not at all).

If that change does not make the script run properly, then it's still worth checking to see if the problem was that the 32-bit version of Gish was running instead of the 64-bit version. So you can make a new .desktop file with the contents:

[Desktop Entry]
Categories=Game;ActionGame;AdventureGame;ArcadeGame;
Exec=/opt/gish/gish_64
Path=/opt/gish
Icon=x-gish
Terminal=false
Type=Application
Name=Gish

Running from that .desktop file--assuming it works--should confirm that the problem is that the wrong executable is being run (and should also work around the problem for you, so you can run Gish from LXPanel).


Keyboard and mouse not responding after booting up 18.04

I've faced this problem before and the problem was xserver-xorg-input-all package , so run the recovery mode and enable the network (better to use cable instead of wifi)  and in terminal just type sudo apt install xserver-xorg-input-all and reboot the system

Hop it'll work


Is there a Perl or Python script I can write which can minimize the Gnome terminal window?

First, install the xdotool command:

sudo apt-get install xdotool

Then, create an alias to be able to run min as a command:

echo 'alias min="xdotool getactivewindow windowminimize"' >> ~/.bashrc`

Reload the .bashrc file:

. ~/.bashrc


Is there any significant difference between `if [ -a FILE ]` and `if [ -e FILE ]`

What  does -a do and why does it exist  ?

The -a option is the same thing as -e, and exists for compatibility with Korn Shell from which Bash borrowed a lot of features.

From POSIX standard, description of test command(link):

  An early proposal used the KornShell -a primary (with the same meaning), but this was changed to -e because there were concerns about the high probability of humans confusing the -a primary with the -a binary operator.

side note: binary means flag that appears between two variables [ $var1 -a $var2  ], primary means appearing in the list of arguments first as in [ -a $var ]

In fact, Korn Shell (ksh93 here) manual states:

  -a file

  Same as -e below.  This is obsolete.

The test command that is used in the TLDP article you referenced uses bash built-in test , however the option is also present in /usr/bin/test despite missing from documentation:

$ /usr/bin/test -a /etc/passwd  && echo 1
1

If functionality is the same, is it good idea to use it?

So long as you are 100% sure your scripts will be used on either Bash or Korn Shell - then yes, it is alright.  However, if you strive for portability of your scripts and want to write script the Right WayTM, you should use -e. The standard Ubuntu shell, /bin/sh, which is actually Dash - Debian Amquist Shell - doesn't recognize that as valid option:

$ dash
$ test -a /etc/passwd
dash: 1: test: -a: unexpected operator

In cases where you want to port your script to other platforms, using -a is not guaranteed to be safe with /usr/bin/test as well, and you should stick with -e because it is in fact specified by POSIX standard.


Error opening cache E: read error -read (5:input/output error)

First make sure that update-manager, synaptic, etc... are all closed and not running somewhere.

Then open a Terminal and enter the following commands:

sudo mkdir /var/lib/apt/lists/partial
sudo dpkg --configure -a
sudo aptitude update
sudo aptitude upgrade
sudo aptitude install -f

After that, retry opening update-manager.

HTH.


Mounting iPad (iOS 8) on Ubuntu 14.04 disaster

You can share files to iPad via WiFi through an ipad app that handles the SMB protocol. I used FileBrowser app available in the App Store and works for me. I had the same problem so far is the only way I've found.


How to make display resolution 1360 x 768 permanantly?

Run terminal: Ctrl+Alt+T.
Type: sudo nano /etc/rc.local.
Add your script to the file (before exit command):

xrandr --newmode "1360x768_60.00"   84.75  1360 1432 1568 1776  768 771 781 798 -hsync +vsync.

xrandr --addmode DP-1 1360x768_60.00.
Save and Exit.
Restart.

The script on /etc/rc.local is called when your computer starts. So you do not need to type the script every time when your computer boots.


Does an Intel 1.80GHz quad core processor meet the 2GHz dual core processor system requirements?

A 1.8GHz quad core processor is the approximate equivalent of a 3.6 GHz dual core processor in overall performance. I have Ubuntu 18.04 installed on a computer with a 1.6 GHz quad core processor and 4 GB RAM and it runs OK, there's nothing wrong with the performance at all.


Screen brightness maximum too low on Thinkpad X300 Ubuntu 16.04

One way to check/possibly fix this is with another program, xbacklight.

In terminal type:

sudo apt-get install xbacklight

then type:

xbacklight -set 50

50 is the brightness range (0 to 100).

You can increase/decrease brightness with:

xbacklight -inc 5

Decrease 5%:

xbacklight -dec 5

If this does not enable you to increase past your previous max, then it is the hardware, and maybe even just the color pallet you have set.


ADB needs root after upgrading to Android 5.1.1

You need add your device id to the rules.
Plug your device through usb.
Make lsusb and look for your device.
You'll receive something like

Bus 003 Device 048: ID 18d1:4ee7 Google Inc.
Bus 003 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

Then add line in /etc/udev/rules.d/51-android.rules similar to others but with idVendor (in this example '18d1'), and idProduct (here '4ee7')

SUBSYSTEM=="usb", ATTR{idVendor}=="18d1", ATTR{idProduct}=="4ee7", MODE="0600", OWNER="{same as others}"

then

sudo udevadm control --reload-rules


I just re-read the questions and noticed that it does not want to use find.

I found two that appear to both give the correct answer:

The first is:

ls -lR | grep ^d | wc -l

The second is:

ls -Rp | grep "/$" | wc -l


It's quite easy to build your own base boxes. Good tools for automating it are Packer and veewee.

There are a lot of templates around, but one good starting point is the Bento project. You can customize the preseed and other configuration scripts to your need.


Is there a way to get the trailing '/' to appear when using cd with a symbolic link directory?

I think you're looking for the readline variables mark-directories, and mark-symlinked-directories.  Just add the following to your ~/.inputrc file and re-load it with CtrlxCtrlr.

set mark-directories on
set mark-symlinked-directories on

To ensure that CtrlxCtrlr works you should also have the following in your ~/.inputrc.  (See this question.)

"\C-x\C-r": re-read-init-file

Incidentally, if you want to list the current settings of your readline variables, use the following command:  (See also man bash for more details.)

bind -v


A lot of errors in xfce after connecting to VNC

Oh gosh.. Took me a lot of hours to figure it out...

~/.vnc/xstartup should be:

#!/bin/bash
xrdb $HOME/.Xresources
startxfce4 &

Not:

~/.vnc/xstartup
#!/bin/bash
xrdb $HOME/.Xresources
startxfce4 &


In the command-line type this content:

wget -q http://download.virtualbox.org/virtualbox/debian/oracle_vbox_2016.asc -O- | sudo apt-key add -


Probably the Gnome installation is missing something. After you boot your machine, try to press Ctrl+Alt+F5 to log in in text mode. Try to log in with your admin user and enter the following command:

$ sudo apt install gnome-session gnome

If the installation goes OK, type

$ shutdown -r 0

to restart you machine. Then try to login to a Gnome session again. Please note, that in the GUI password prompt screen there may be a gear icon (⚙). Click that icon and select GNOME before entering your password.


Blender 2.5 render will not export sound

You should have ffmpeg as an output option in Blender.
In terminal, check whether it's installed or not:
~$ ffmpeg
The program 'ffmpeg' is currently not installed.  You can install it by typing:
sudo apt-get install ffmpeg

When you installed it, check if it's included in the format list in blender:

If not, you need to download and reinstall blender. For some reason you have a version that was compiled without ffmpeg support. You could try one of the new 2.49 RC builds.


I cant install sdl because it has unmet dependencies

Try this one:

sudo apt-get install libsdl1.2-dev libsdl-image1.2-dev libsdl-mixer1.2-dev libsdl-ttf2.0-dev libpulse-dev libxt-dev

If that doesn't work you may use aptitude:

sudo apt-get install aptitude
sudo aptitude install libsdl1.2-dev libsdl-image1.2-dev libsdl-mixer1.2-dev libsdl-ttf2.0-dev libpulse-dev libxt-dev


When I create a new user, how do I automatically create a .virtualenvs directory in their home directory?

Create the directory /etc/skel/.virtualenvs. The /etc/skel directory will be used as a skeleton for a new home directory.

It's defined in /etc/adduser.conf:

# The SKEL variable specifies the directory containing "skeletal" user
# files; in other words, files such as a sample .profile that will be
# copied to the new user's home directory when it is created.
SKEL=/etc/skel


How do I upgrade from 18.04.1 to 18.04.2

If you have been getting the updates, then chances are that you already have Ubuntu 18.04.2. One point to mention is that with Ubuntu 18.04.2, is the inclusion of an updated hardware stack (HWE) which is derived from Ubuntu 18.10. This means an updated kernel (Ubuntu Linux 4.18 kernel). Also included are updated versions of Xserver, Wayland, Mesa and other updated graphics drivers.The thing is, that this does not come automatically, but you can get the updated HWE by running this command:

sudo apt-get install --install-recommends linux-generic-hwe-18.04 xserver-xorg-hwe-18.04

Now:

sudo reboot

After restarting, you can see that the kernel version has been updated from 4.x.x to 4.18.x. with this command:

uname -a

By updating the HWE, you will benefit from the new hardware enablement stack, and will be able to upgrade to newer versions of the stack as they’re released.

NOTE: Those that install Ubuntu 18.04 using the new image already have this HWE.


I figured out what I was doing wrong. I had skipped the import-gpg-key step, and was specifying the filename in the edit-pocket command, instead of the key name.

The following commands worked for me to add the key and get the pockets to sync:

# gpg --keyid-format long --keyserver hkp://keyserver.ubuntu.com --recv-keys 3B4FE6ACC0B21F32
# gpg -a --export 790BC7277767219C42C86F933B4FE6ACC0B21F32 > /tmp/ubuntu-bionic-public-key-2
# landscape-api import-gpg-key ubuntu-bionic-public-key-2  /tmp/ubuntu-bionic-public-key-2
# landscape-api edit-pocket --mirror-gpg-key ubuntu-bionic-public-key-2 release bionic ubuntu


I may confuse you further, but I'm going to add a few more words to that list. I've tried to highlight the buzzwords while I paint a picture of how things fit together.
Window managers
It might sounds silly but window managers manage your windows. They sit right next to the X Server (that controls what gets sent to hardware) and decrees how windows are painted to the desktop (itself a type of window).
As well as managing where the window goes, how big it is, if it's above something else, it's also responsible for decorations. Most window managers defer to another application called a window decorator. These decide how your window borders look, as well as giving you some options (resizing, window buttons, etc).
Metacity (a window manager) has its own window decorator built-in but other window decorators you might see around include gtk-window-decorator (used by Compiz by default) and Emerald, spawned from Beryl which can do slightly fancier things at the cost of CPU cycles.
Beryl, Metacity, Compiz are all window managers. Beryl was a fork of the original Compiz. It advanced well ahead of Compiz and was eventually merged back to form a project called Compiz-Fusion. Compiz-Fusion has now (AFAIK) been renamed back to Compiz although both names still apply to the same, modern project.
Graphical Toolkits
GTK+ (aka GTK) is a graphical toolkit that developers use to create rich, graphical user interfaces. Using tools like Glade, they decide how an application should look by placing GTK+ controls (eg a button) on a window, using further arrangement technologies like Glade.
GTK+ also contains several sub-projects like Cairo and Pango, two graphics libraries that programmers can use to draw things inside their applications. In turn these libraries can reach out to more libraries to help them render things (like using Freetype to render text).
GTK+ development libraries are a bottomless pit. I could literally spend all day listing them out but it won't really help you. So I won't.
Part how these controls are rendered to the screen involves a theme engine. Each engine has n themes available for it and the user picks one in their preferences. That theme uses its engine to let controls render themselves onto the screen. Clearlooks and Murrine are both engines and they both have themes named after them, as well as a ton of other themes knocking around the internet.
The stack would look something like this, from bottom to top:

GTK+ Control
GTK+ Engine and its GTK+ Theme
Application (X Server Client)
Window Decorator
Window Manager (aka compositor)
X Window Server
Hardware

That's ultra-simplified (I've just explained a compositing system) and a lot of that stuff can happen in altered orders, often running parallel rather than on top or beneath another layer... But it should give you an idea of how things get from code to screen.
Qt is another graphical toolkit which is very common in KDE applications. It has its own theming engines, themes and controls that similar to GTK+. They're not interchangable and require heavy code overhauls to port from one toolkit to the other.


What exactly are you trying to accomplish? While the simple "start typing" search in thunar doesn't have wildcards and needs a match from the first letter, the catfish search that already comes with thunar on Xubuntu is quite powerful (and also cpu intensive).

Simply right click on the folder you wish to search and select the "Find in this folder".

A new window will appear, and it is a simple match search. As long as everything you type matches somewhere you'll get the results back. There is no need for a traditional * as wildcard. Just separate the different 'parts' you want to search with a space. There are plenty of other options, like also searching file contents, exact matches, etc.


how to use gsub function awk to replace characters with empty value


Ubuntu 18.04 upgrade : stuck at xubuntu logo, no login screen and broken dpkg

The following steps worked:

Recovery mode shell is not really required as only the GUI part was broken. Press Ctrl+Alt+F3 to login to a shell.
Run the following command to get rid of broken dpkg multiple times until it executes successfully.

sudo dpkg --configure -a


Force Thunderbird to open ALL links in Chrome?

Follow the step to set Default Browser for all Thunderbird mail links

Go to Thunderbird Menu:  Edit-->Preferences
Click Config Editor
Click on "I 'll be careful, I promise'
Then in next screen search below entries one by one,

network.protocol-handler.warn-external.http
network.protocol-handler.warn-external.https
network.protocol-handler.warn-external.ftp

If the value column is false then make it true, you can change value of entry using double click on the row.


The main problem is that the $ is important to perl. When you use it in a system command, you need to escape it:
$thirdlast=`df -H | awk '{print \$(NF-3)}'`;
print $thirdlast;

Otherwise, perl will try to expand $(NF-3) as a perl variable. The variable $( is the perl process's real GID:

$(
The real gid of this process. If you are on a machine that supports membership in multiple groups simultaneously, gives a space separated list of groups you are in.

The variable $) is the process's effective GID:
So, $(NF-3) evaluates to list of groups you are a member of NF-3). For example, on my system, that is:
$ perl -le 'print "$(NF-3)"'
1001 27 29 111 112 1001NF-3)

The next problem is that your awk call is wrong. The % use is $(NF-1), not $(NF-3). So, what you wanted is:
$thirdlast=`df -H | awk '{print \$(NF-1)}'`;

Or, to only print percentages above a certain threshold, for example 90:
$thirdlast=`df -H | awk '(\$(NF-1)>90){print \$(NF-1)}'`;

In any case, you could just process the output of df in Perl itself:
$thirdlast=`df -H`;
@matches=($thirdlast=~/(\S+%)/g);
print "@matches\n";

Or
@matches=(`df -H`=~/(\S+%)/g);
print "@matches\n";

And to set a threshold:
@matches=(`df -H`=~/(\S+%)/g);
@above90=grep {$_>90} @matches;
print "@above90\n";

Or, more directly:
@matches=grep {$_ >90} (`df -H`=~/(\S+%)/g);
print "@matches\n";

The @array=($variable=~/foo/g) will save all matches of the regular expression foo in the variable $variable into the array @matches. That will have the same result as parsing the df with awk.


Why does alt+left shift my virtual terminal left one?

You'll want to look in your compiz settings.  You can install compiz settings with the following command:

 sudo apt-get install compizconfig-settings-manager

Then you'll want to open it up (just run ccsm from a terminal).  And go to the "Advanced Search" section.  Make sure the "Settings Value" box is check and search for the word "left" look through the results and you'll find the settings with the Alt+Left keybinding, then just simply disable it.


How do I install fglrx on an AMD Kaveri machine?

Problem solved. AMD released their Catalyst 14.1 driver with A10-7850K support for Linux. Note that THIS IS A BETA DRIVER, AND IS THEREFORE EXPERIMENTAL. The performance I've got out of it is okay, though. Trine 2, Dota 2, Minecraft (OpenJDK 7), Europa Universalis IV and Guns of Icarus Online all ran reasonably well on 1920x1080 with medium/high settings.

Instructions:

Download the driver from AMD.
Unzip the file.
Make the new file executable. sudo chmod u+x amd-driver*.run should do the trick.
Install the prerequisites: sudo apt-get install cdbs dh-make dkms execstack dh-modaliases linux-headers-generic libqtgui4 lib32gcc1
Create .deb files from the installer: sudo ./amd-driver*.run --buildpkg Ubuntu/saucy  Replace Ubuntu/saucy with your version if applicable. AMD says it's compatible with Ubuntu 12.04 as well, so you'd put --buildpkg Ubuntu/precise at the end.
Do the actual installation bit: sudo dpkg -i fglrx*.deb  This installs multiple .debs.
Optional-ish, initialise the xorg.conf file after restarting your computer: sudo amdconfig --initial -f

And that's that.


Ubuntu 18.04, using a USB Ethernet adapter: after updates, Network Manager says, "No suitable device found for this connection."

Researching this again today, I came across this: Ethernet device not managed

Which led me to editing /usr/lib/NetworkManager/conf.d/10-globally-managed-devices.conf and changing this:

unmanaged-devices=*,except:type:wifi,except:type:wwan

to this:

unmanaged-devices=*,except:type:wifi,except:type:wwan,except:type:ethernet

and then doing this:

sudo service network-manager restart

and suddenly my USB ethernet connection came right up.


Canon LBP2900 printer only works when connected after log in

It sounds like udev is somehow confused.  I suggest double-checking your steps on that page under the heading Starting/Stopping on USB Add/Remove.  Assuming that is all correct, add the output of the following command to your question:

grep lp /etc/udev/rules.d/*


No “Performance” option in “Power Mode” in Ubuntu 21.04

According to this Post you should be able to do that with the Slimbook Battery Tool.
To install it you need to first add the apt-repository:
sudo add-apt-repository ppa:slimbook/slimbook && sudo apt update

Then You should be able to install it with:
sudo apt install slimbookbattery

That fixed this issue for me.


Text/fonts display garbled after resume from hibernation

I've the same error on my Lenovo X200 with intel graphics, too.

According to this thread on Lenovo forums it's an intel driver issue. I think we have to wait for the devs to fix it.


Ubuntu 14.04 64 bits - Only half of the RAM is recognized

AFAIK, a 32bit OS will not be able to handle memory addressing above 4 Gb.
I never had true faith in those PAE things: it needs specific hardware, compatible OS, compatible drivers, compatible applications...

If you are really using a 64bit Ubuntu (seems to be the case, according to your uname -a) and still have not all your RAM available, I strongly recommend you test each module separately (even if Windows shows it all, it may still be faulty)!

If this is a regular PC (ie: not a rented dedicated server), check the BIOS for any fancy RAM custom parameter (overclocking, or some weird a$$ P!Mp My R4M "feature" that may affect it's behavior): I've seen things so weird with so-called "gamer" motherboards...


Shrink Dynamically Expanding Hyper-V VHDX containing LVM Ubuntu Server

OK, so I actually think I figured it out (with help from some of the websites below) - it was not easy.
First, as mentioned, I had to previously (prior to asking the above question) reduce the size of everything in Ubuntu Server (posting below just to be complete) - I did that following the below websites:
https://maideveloper.com/blog/how-to-move-lvm-partition-to-another-disk-drive
How can I resize an LVM partition? (i.e: physical volume)
Here's what I did:
I booted into a LiveCD (Ubuntu Desktop 20.04) and in terminal ran these commands (I think - my memory is a bit hazy at this point):
sudo e2fsck -f /dev/<VOLUME_GROUP/<LOGICAL_VOLUME>
sudo resize2fs /dev/<VOLUME_GROUP>/<LOGICAL_VOLUME> 150G
sudo lvreduce -L 155G /dev/<VOLUME_GROUP>/<LOGICAL_VOLUME>
sudo resize2fs /dev/<VOLUME_GROUP>/<LOGICAL_VOLUME>

You should replace <VOLUME_GROUP> and <LOGICAL_VOLUME> with appropriate entries for your system.  I believe the above commands: checks for errors, then shrinks the file system, then shrinks the logical volume (don't shrink to something smaller than new file system size you just shrunk), then extends the file system to use all available space on the logical volume.  I also think something along these lines might have worked but I didn't try: sudo lvreduce --resizefs -L 155G /dev/<VOLUME_GROUP>/<LOGICAL_VOLUME>
Then I went into GParted GUI on the LiveCD and used that to shrink the partition to it's new 155 GB size and was left with a ton of unallocated space.  This is where my question above picks up.
So next I found this answer: How do I move my LVM 250 GB root partition to a new 120GB hard disk?
Here's what I did:

Used Hyper-V to create a new dynamically expanding VHDX hard drive (this time only 250 GB) and attached it to my existing Ubuntu Server Hyper-V
Booted into LiveCD again and used GParted to create exactly the same partitions on this new VHDX hard drive (sdb) that I had on my existing 6 TB dynamically expanding VHDX hard drive (sda) - even setting the flags, etc.
Booted back into my Ubuntu Server and ran these commands:

sudo pvcreate /dev/sdb3  (sda3 is where my logical volume resides)
sudo vgextend <VOLUME_GROUP> /dev/sdb3
sudo pvmove /dev/sda3 /dev/sdb3
sudo vgreduce <VOLUME_GROUP> /dev/sda3

Booted into Clonezilla and cloned sda1 to sdb1 and then cloned sda2 to sdb2
Modified the settings of the Hyper-V:

removed the new second 250 GB VHDX hard drive
adjusted the primary drive to point to the new 250 GB VHDX hard drive

Booted up the Ubuntu Server Hyper-V and got a weird error initially (briefly) and then it booted fine and voila - I was using the 250 GB hard drive!  The error I got was: System BootOrder not found.  Initializing defaults.  Creating boot entry "Boot0004 with label "ubuntu" for file "\EFI\ubuntu\shimx64.efi"
Realized that if you went to look at the Hyper-V settings under Firmware -> Boot order, there were now 2 shimx64.efi files - one at the very top (the new one that apparently was created by Hyper-V in step 6 above) and one below DVD Drive (the old one).  No easy way to remove the old one - so I found this site: https://vmlabblog.com/2018/08/how-to-change-vm-bootorder-with-powershell/ which provided some guidance
In an administrator PowerShell, ran these commands:

$ubuntuserver = Get-VMFirmware "<NAME OF VIRTUAL MACHINE IN HYPER-V>"
$goodfile = $ubuntuserver.BootOrder[0]
$dvddrive = $ubuntuserver.BootOrder[1]
$badfile = $ubuntuserver.BootOrder[2]
$hddrive = $ubuntuserver.BootOrder[3]
$network = $ubuntuserver.BootOrder[4]
Set-VMFirmware -VMName "<NAME OF VIRTUAL MACHINE IN HYPER-V>" -BootOrder $dvddrive,$goodfile,$hddrive,$network
$ubuntuserver.BootOrder (just to confirm everything)

And I think that did the trick.  I believe I'm now all set.

I would welcome any comments or checks on the above since I'm not entirely sure what I did is OK, but it seems to be.  Hope this helps others in the future too!


What am I doing wrong?
Nothing.
When you copy an image or several images from Digikam to the clipboard with Ctrl-C, they are just that, images, not image files.
You could try copying from other sources like Eye of Gnome eog (I could only copy one image at a time, I don't think it's possible to copy several at a time), to further demonstrate the same behaviour.
Then you can paste the images, e.g., in LibreOffice Impress.
But you cannot paste the image files in Nautilus, since that is not in the clipboard.
There is an extension for Nautilus to do that, nautilus-copypaste-images.
Unfortunately, it is not maintained, and it's not available for focal.
You can check this (once the ppa was added and after sudo apt-get update) with
grep ^Package /var/lib/apt/lists/ppa.launchpad.net_atareao_nautilus-extensions_ubuntu_dists_focal_main_binary-*_Packages | awk '{print $2}' | sort -u

You could try using the .deb file. YMMV.
I did not find any alternative so far
(you could write your own patch, I guess ;-)).
Related:

Ubuntu 18.04 Nautilus copy image instead of path
http://www.webupd8.org/2016/03/copy-and-paste-images-from-clipboard-in.html
https://www.maketecheasier.com/copy-paste-images-clipboard-nautilus/
https://gitlab.gnome.org/GNOME/nautilus/-/issues/540

Non Ctrl-c + Ctrl-v alternative:

Open Digikam and Nautilus.
Arrange them in a side-by-side view (with Win+← and Win+→).
Select in Digikam the files I want to copy (6 images, see screenshot).
Drag to Nautilus.

It works out-of-the-box.


Your .yaml file is incorrect. Try this one... make sure to keep the spacing, indentation, and no tabs...

Note: I also reversed your IP addresses, as I think you had them backwards. Check them out.

network:
  version: 2
  renderer: networkd
  ethernets:
    enp3s0:
      addresses: [192.168.10.10/24]
      gateway4: 192.168.10.1
      nameservers:
        addresses: [8.8.8.8, 8.8.4.4]

sudo netplan --debug generate # generate config files

sudo netplan apply # apply new plan

reboot # reboot computer

Note: see https://netplan.io/examples for more info


Sometimes applications stay in the background and have an empty white arrow in the launcher. How do I fix this?

Some applications hang, as a result they preclude this behaviour. I found this exists in thunderbird and firefox.

I recommend using a little app called FlashFreeze.

Install

FlashFreeze works in Ubuntu 11.04 and 11.10 and can be installed by adding the following PPA (Personal Package Archive) to your Software Sources: -

ppa:shnatsel/flashfreeze

After adding the PPA run an update sudo apt-get update and install ‘flash freeze‘ from the Ubuntu Software Centre.


Open terminal (or also known as command line) by pressing together Ctrl+Alt+T or by finding it in the dash.

Run this command sudo gedit /etc/lightdm/lightdm.conf. This opens text editor with lightdm.conf file located in /etc/lightdm folder.

In the file you should have a line [SeatDefaults]. Below this line, enter session-cleanup-script=/path/to/your-script.sh , where /path/to/your-script.sh is the actual address of the script that you want to run.

Note: make sure your script is set to executable by running:

sudo chmod +x /path/to/script.sh

Save and exit.

NOTE: as of 14.04 version, the config file doesn't exist and must be created manually OR copied from an example file using the following command:

sudo sh -c 'zcat /usr/share/doc/lightdm/lightdm.conf.gz > /etc/lightdm/lightdm.conf'

If you just want a script on a logout of lime a terminal, just put that in ~/.bash_logout.


Ubuntu Server Takes time to resolve website name but not IP address in wget command

Why don't you try using google DNS? Use 8.8.8.8 and 8.8.4.4 as your primary DNS, and see whether it works better.


Cannot Boot into the GUI Mode after Installing "ATI binary X.Org driver" from Ubuntu Software Center

If you have an ATI graphics card, the "ATI binary X.Org driver" is what you would get my default after doing updates. The updater detects what you have and adds the right wrapper.

You can sudo apt-get remove xserver-xorg-video-ati and sudo startx


In your command you were not specifying what should be done with the audio track.

Try this:

avconv -i P3040001.AVI -strict experimental -c:v libx264 -b:v 8000k -c:a ac3 -b:a 192k output.mp4.

Feel free to tweak the bitrates as you like. You may use avinfo to get an idea about original bitrate and transcode to a similar one.

You can also use a GUI program like Avidemux.


How to switch or fix ppa configuration and source for Ubuntu 19.04?

The PPA you have added do not have files for your Ubuntu release (19.04 or Disco Dingo).

So you need to remove it from the system with:

sudo add-apt-repository -r ppa:paulo-miguel-dias/pkppa

and then continue to follow your guide.


Could be anything from over heating to bad ram, can not tell from what you posted. Honestly I am not certain if you are using an upgrade or a fresh install.

Start with a fresh install, upgrade problem can be difficult to sort out and only cloud the picture.

Second, try booting an older kernel.

From there you would need to look though debugging

https://wiki.ubuntu.com/Kernel/Debugging

https://wiki.ubuntu.com/Kernel/KernelDebuggingTricks


Select the Kubuntu live session and, when in the live session the desktop shortcut for "install Kubuntu" can be used to start the installation.

Alternatively the install OEM can be used. This is a special installation mode with a temporary user - oem - with full administrative powers. Additional software can be installed and settings can be changed prior to executing the "Prepare for shipping to end user" tool. In the next boot the end user will be taken to the system setup wizard. Additional information with screenshots: https://help.ubuntu.com/community/Ubuntu_OEM_Installer_Overview


connection refused on localhost 25 (apache James)

Are you sure it is not a misconfiguration or something? For instance, are you sure it runs on port 25? I have had a similar issue with a server I had written, which I tried to telnet on port 7980, when I had asked it to bind to port 7908.

If I were in your shoes the first diagnostics I would run myself is a netstat to make sure that the server is indeed listening on that port. Netstat appears to be just the tool for the job. You might try in a command line something like this: netstat -l --numeric-ports | grep james, and see what you can make out of that. If you are not a command line fan, you can use the application Network tools, go to Netstat, and from the bullet list activate the choice Display: Active Network Services.

If it is indeed running on that port, my next thought would be a firewall or something. Have you tried to reach on the server from another host, on the same network?

[EDIT]: A quick look at the quick start guide suggests that in order to be able to run James properly, you need libc6 installed on Linux !! - sudo apt-get install libc6-i386 libc6-dev-i386. If you have ensured libgc6 is installed, and you have properly added domains and users, though it still doesn't seem to work, you might want to go through the configuration files. Of particular interest seem to be the following: smtpsever.conf, pop3server.conf, and perhaps database.properties and jmx.properties. PLEASE NOTE that you should be careful while editing these files. I suggest that you look for hints as to why your server is not binding to the address properly. I DO NOT know the files' contents ahead of time, so I can not advise on edits.

NOTE: If all else fails, you might want to try using james via the java cli:

usage: java org.apache.james.cli.ServerCmd --host <arg> <command>
    -h,--host </arg>   node hostname or ip address
    -p,--port </arg>   remote jmx agent port number


Recover Windows after reinstalling Ubuntu

How to Recover Your Windows Bootloader in Ten to Fifeteen Easy Steps

Wow, bud, you messed up.  Good news, though, there's an easy fix after which you can start laughing at yourself.  I can already laugh because I've done worse.  So, welcome to the club. 8D

I've had to do most of this very recently.  It seems like a lot of steps at first, but you probably know most of this already.  Don't panic, none of it is hard, and there're loads of resources online.

What you need to do:

Repair windows' boot loader.  This should get you into windows, even if it can't see your ubuntu partition.
Do all the backing up you should have in the first place and recreate your recovery media (if you can).
Boot into your Ubuntu Live CD/USB.  Repair its bootloader (grub2) and run a customizer tool to properly detect and include Windows in its bootloader.

This will work most of the time.  If ubuntu's installation or boot-recovery still can't detect your windows partition, you won't be able to dual boot without making some changes.  Decide which OS you want for now and work on those changes when you're comfortable.

What you'll need to do it:

A windows 8/8.1 installation media. (See below) Put this on a disc or usb.
Free software to create your windows 8/8.1 installation media.  (See below)
A product key.  You won't be installing Windows, so you might not even need this to use the recovery tools.  If you don't have yours handy (and it's hard to find with OEM installations), you can use a "generic" key.  I won't post it here but google will find it for you.  It's perfectly legit; you can't activate an installation using a "generic" key.
A Ubuntu Live USB, on it you'll want:

Boot-Repair comes standard on Ubuntu's live media.  It's pretty easy to use comes standard on it, but if not it's easy to install.
Grub Customizer will help you scan for Windows and edit your grub2 bootloader.  I prefer terminal commands, but this gui tool is great.

Getting a Windows 8/8.1 Installation Media

This is the only hard part.  Microsoft used to make ISO files for their installation media available, but they no longer do for 8/8.1. If you know anyone who has one, or even has an OEM recover disc for a different computer, borrow it. They should both boot into its recovery mode.  Otherwise, you're stuck looking for an ISO in all the usual ways.  I found this article helpful in this regard: How to download and install Windows 8.1 for free

Put the Windows 8/8.1 onto a USB

This should be easy for you, you've already done it for Ubuntu and other distributions as well.  The Windows Installer program for Windows 7 works for Windows 8/8.1 as well.  Life Hacker has a good article on it.

Windows Recovery

Boot into the Windows installation media you borrowed or created.  Choose the recovery "Advanced Options" until it offers you a command prompt or shell.  I'm not sure if you want "bootrec /fixmbr" or "bootrec /fixboot".  They both worked for me.  How To Fix The Windows Bootloader

Boot Windows - Yay!

Hopefully you have a new boot loader that gets you into windows.  Do your backups, see if you can recreate your recovery media, and find your Windows Product Key.  Keep it on a piece of paper, OS installers rarely eat paper.

Use Ubuntu to Scan for Windows and Creat a Dual-Boot Bootloader

I was never happy with the way the Windows bootloader handles a linux os, so I stick with Ubuntu's grub2.  It is possible with EasyBCD, but I didn't like its results.  Log into ubunty, open a terminal and type "boot-repair".  More on boot repair.

Add Windows to Grub2

I don't remember if boot-repair will look for your windows installation.  Grub Customizer is good at scanning.  Its tabs and menus are easy to understand.  There's an "Rescan OS" tool that will be helpful.

That's it!

If all goes well, you've got both of your operating systems on Grub's bootloader, you've configured which one you want as default, and life is good.

Still Can't Find Windows?

If Ubuntu's installation or boot-recovery tools still can't find Windows on your hard dirves, Windows might be using a type of partition table that linux can't see.  I don't know enough about it to be explaining anything, but you'll want to convert your partition table to "mbr".  (Used to be standard on Windows.)  Once you're sure you have a "mbr partiton table", linux and grub should find your windows easily.

I found these two articles helpful:
The Differences Between MBR and GPT
 Convert GPT Disk to MBR Disk

Want to Try Windows' Bootloader Instead of Grub?

Like I said, this isn't as hard as it sounds.  I gave it a try, but ended up preferring Grub2.  Ubuntu Geek has a good article on it.

Good Luck!

After this, you'll be a bootloader pro and feel more comfortable screwing up your partitions in the future.  Good luck!

New Info - BIOS Settings

Hey, I saw in your comment below that you mentioned EFI firmware configurations.  Have you, or are you able to enter your bios settings and disable UEFI and/or Secure Boot?  I wasn't able to even boot from a LiveUSB until I did that and enabled Legacy Boot.  All this is done in the bios settings.  I figured you're past that, 'cause you got Ubuntu installed.

I don't know enough to advise you, and different hardware will have different access to settings.  If you think this might be an issue:  UEFI - Community Help

Windows Fast Boot

Once you get into Windows, you'll want to find and disable "Fast Boot".  Fast boot stores info same as powering-down into hibernation mode.  I can't think how Fast Boot would be directly causing your problem, but if nothing else, it's a "best practice" suggestion to help out down the line.

More info on Fast Boot and Dual Booting Ubuntu


Your kernels are unsigned. This system will fail to boot in a secure boot environment

I ended reverting to the default kernel from ubuntu and it all workend as expected.


I made a post about this over here Nvidia GTS 450 HDMI problem

But basically you need to use the Nvidia settings control panel not the default ubuntu control panel.

You also need to run it as root and then save the x configuration file.

It is pretty simple to do and I have it setup this way on my laptop with a RGB connector and it boots up and pops up from suspend perfectly so there is hope.

I am not sure how the old Gnome works with it since I use Unity, but I assume it is the same.


My pc freezes when I connect to the internet with my iBurst USB modem

Don't Use:
sudo pppoeconf
pon dsl-provider

Using dsl-provider to start the connection always freezes Ubuntu.

Instead Install and use Roaringpenguin
I have Showed how to get iburst up and running Here

Follow This Link https://askubuntu.com/a/366097/207851

I hope this helps you


U1 Music Streaming: Is it possible to have album cover art for OGG files?

Due to Vorbis not having an official way of embedding album art, we don't currently support it.
There are a few different implementations which we may support in the future, but for the time being only mp3's will display album art, I'm sorry.


must the Flash drive be FAT to be bootable?

No, it is not necessary for the flash drive to be FAT to be bootable but as it stands now most devices are able to recognize natively FAT32 format be it your droid,tv  or something else. However you can boot from any format as long as your bootloader recognizes it.

If you are going to use unetbootin then I would recommend using a FAT32 format.

You can also copy a CD image directly to flash drive and make it bootable using dd

dd if=path/to/isofile.iso of=/dev/sdd

Replace /dev/sdd with your flash drive which you can find by,

sudo fdisk -l


Ubuntu 18.04 SD card stopped being recognized on ONE account only

After using the other working account, I looked at the modified dates on files in the account.  The 2 files that seemed the most relevant where .ICEauthority and .config/.dconf/user.  While in the other account I su'd into my account and renamed these two files.

Upon logging into my account again, the first time I tried the SD, nothing happened again. But after a while I tried it again and it is now working.

I can't say that anything I did fixed it.  Would sure like to understand what happened.


Why did my USB drive suddenly stop being detected?

Try this - in terminal type:-

  sudo killall udisks

then load gparted if you have it on your system - format to desired file system.

This command has helped with a lot of USB problems - it may help you.

good luck Mal


You don't need ; after then in then ;echo "{}" >>output.txt.

Use :

then echo "{}" >>output.txt

Also note that rather than playing with {} use positional parameters of shell (i am not familiar with svn so relying upon your commands) :

find /dir/containing/repos -maxdepth 2 -type d -exec bash -c 'if svnlook info /path/to/repo >/dev/null ;then echo "$1" >>output.txt ;svnadmin verify "$1" >>output.txt ;fi' _ {} \;

if svnlook info /path/to/repo >/dev/null will run the command and redirect the STDOUT to /dev/null
If the svnlook info /path/to/repo command is successful (exit code 0), then echo "$1" >>output.txt ;svnadmin verify "$1" >>output.txt commands will be run
Here we are using the directory names {} as the fist argument ($1) to be processed by shell.
_ here is just a placeholder indicating positional parameter 0 as bash -c command starts considering any further argument after the command starting from 0. As _ is the zero-th argument, we can use {} as the first argument. Check man bash to get more idea.


Can an UEFI Ubuntu installation be converted into a BIOS installation?

First, get proper backup hardware! This site -- and indeed the Internet as a whole -- is littered with tales of woe from people who haven't backed up their critical data and, as a result, have lost it all. Don't become another person posting such a story!

Second, but related to that first point, if you no longer have a Windows installation, it's important that you move your personal files off of the Windows NTFS volume. The reason is that there is no Linux NTFS repair utility. Thus, when (note: when) the filesystem needs repair, you won't be able to do it from Linux. You'll have to boot a Windows emergency system or move the disk to another computer to do this job. This is a big hassle, and can be a little risky. (Note that there is a Linux tool called ntfsfix, but its name is misleading. This tool does only the most basic checks and then flags the disk as requiring attention from Windows. It can't actually repair filesystem damage.)

Finally, it is possible to convert a Linux installation made in EFI mode to boot in BIOS mode. Basically, you need to install a BIOS-mode boot loader to the disk. If you're booting via an EFI-mode GRUB 2 (as is the default), I do not recommend you use the BIOS-mode GRUB 2 for this, since the two GRUBs may try to use the same configuration file, but they've got somewhat different needs, so you can end up with a conflict and new problems. Instead, I recommend using GRUB Legacy, SYSLINUX, or LILO. There are numerous sites that describe how to install these tools, but I don't happen to have any bookmarks handy.

That said, unless you have a compelling need, I don't recommend you try setting this up. If you're booting correctly in EFI mode, attempting to install a BIOS-mode boot loader will take time and effort that might be better spent elsewhere. Worse, there's always a risk that you'll create problems for yourself, up to and including data loss -- which brings me back to my lead paragraph.

If you're concerned about your boot loader malfunctioning, you can download a USB flash drive or CD-R version of my rEFInd boot manager and prepare a boot medium. You should be able to use rEFInd to boot your computer if GRUB malfunctions. (Of course, rEFInd's capabilities are limited. If there's a post-GRUB problem like bad filesystem damage, rEFInd won't help -- but then, neither would a BIOS-mode boot loader.)


One source is gnome-look.org.
Not all GTK+3 themes are fallback compatible.  Generally, use the search option and restrict the search criteria for

Type = GTK 3.x Theme/Style
Description = fallback

Then look in detail at each of the search results for what issues are reported for using the theme with gnome-fallback.
to install a theme

make a themes folder: mkdir ~/.themes
extract the zip file.
move the extracted theme folder to the ./themes folder - for example mv Zukini ~/.themes/
Use gnome-tweak-tool and change the theme

Most themes recommend you change the background properties for each panel to use the panel.png that comes with a theme.  As you can see in the image - I'm using the Zukini theme.


Gpartd seems to be saying /dev/sda8 is mounted on /home. If you open nautilus, and it does not open in /home, try scrolling to the bottom of the left panel and selecting "+Other Locations". Then click Computer, which should show you a list your disk root. One of the directories shown should be Home. That's the one you're looking for. Assuming that you are logged in as a user, you should see your user name in there. That's your home directory.

Nautilus tries to protect you from the fact that your home directory is not the mount point. On my system, it shows a little house to the left of "Home" with a capital H at the top of the panel when I access my home directory. When I access the mount point, it shows "home" all lower case.


Unable to access server web pages from internet?

This is a basic suggestion but you need to forward 80th port to your server:
http://portforward.com/english/routers/port_forwarding/Linksys/SPA-2102/Cisco_WVC210.htm


"kde-config not found" error while installing kstars from source

sudo ln -s /usr/bin/kde4-config /usr/bin/kde-config


No grub menu in dual boot with Windows 7

Boot on your Ubuntu disc (DVD or liveUSB)
Choose "Try Ubuntu"
Connect internet
Install and run Boot-Repair's Recommended Repair. If any issue, indicate the URL that will appear.


You should start with an MD5 Checksum on your image.
You should get the following number with md5sum ubuntu-14.04-desktop-amd64.iso dccff28314d9ae4ed262cfc6f35e5153. If not you should redownload the image.


Evolution can't connect to google contacts

From google (https://developers.google.com/identity/protocols/AuthForInstalledApps)

Important: ClientLogin has been officially deprecated since April 20, 2012 and is now no longer available. Requests to ClientLogin will fail with a HTTP 404 response. We encourage you to migrate to OAuth 2.0 as soon as possible.

A solution is to install gnome-online-accounts, then enter your google account information in it.  It will take care of the authorization and let evolution talk to your google account.


Normally installing new os won't effect existing os, so you can install ubuntu without any fear

Your system specifications are not enough to run ubuntu 12.04 smoothly . So I would like to suggest Lubuntu for your pc


See this Ubuntu Insights post:

We have decided that we will ship Xorg by default, and that Wayland
will be an optional session available from the login screen.
Why opt for Xorg by default? There are three main reasons:

Screen sharing in software like WebRTC services, Google Hangouts, Skype, etc works well under Xorg.
Remote Desktop control for example RDP & VNC works well under Xorg.
Recoverability from Shell crashes is less dramatic under Xorg.

For an LTS release, it's not practical to ship Wayland as the default when too much still relies on X11 features.


I need help pleas help me xorg.conf missing Ubuntu 11.10 can't install driver for my Intel GM965 on my Dell Latitude d630

Ubuntu, and many other Linux distros, don't use xorg.conf. If, for some reason, you want xorg.conf, it can be generated.

There is also not need to install Intel graphics drivers, as you probably know, Linux has most open source drivers already included.

In short, don't fix what's not broken. :~)


Using sudo a2enmod wsgi should enable the module for you once you reload apache, as most modules don't need the mod_ prefix when enabling them.


No video on Ubuntu 20.04 minimal VM via virt-manager

I had the same problem with the black screen after installing Ubuntu 20.04 Minimal with the absolute minimum.
In /etc/default/grub you will find this line:
GRUB_CMDLINE_LINUX_DEFAULT="quiet splash"

Edit this file (you need root priviledges, so use sudo) and remove the word "splash".
Then rebuild the grub config and reboot:
sudo update-grub
reboot

The "splash" parameter ultimately leads to the vt.handoff=7 being passed to the kernel as well, but this functionality seems to malfunction.
An explanation of what it is supposed to do can be found in this thread. As I understand it, the output of the boot sequence is maintained on virtual terminal 7 and when the boot sequence is finished and the login prompt is ready (on VT 1-6), the display switch to VT 1 and VT 7 is destroyed.
But the switching seems to fail with the minimal install and nothing is displayed. When the boot sequence completed, you can select "Send Key" --> "Ctrl+Alt+7" in the Virtual Machine Manager menu to switch to VT 7 (even though there are only supposed to be 6 virtual terminals) and you will see the first few lines of the boot sequence.
You can similarly switch to VT 1 (or 2-6) using "Ctrl+Alt+1" (or 2-6) and you will see the boot prompt.


libpoppel.so.7 is missing when running xournal

The version of the shared object is 13 in natty: /usr/lib/libpoppler.so.13.


Is there an API for accessing historical Ubuntu Security Notices?

No, there is no API, but it should be fairly easy to create one by scraping the main CVE or partner CVE list into a db, instead of the USN website or email archive:


I use this adapter for all my operating systems (Ubuntu, Windows 7 64-bit, Mac OSX) and it never failed me EVEN ONCE!


In Apache use the config:

You can use multiple blocks for different website names so that they listen on HTTP or HTTPS which ever the port is required

Listen 443 http
Listen 80
NameVirtualHost *:80
NameVirtualHost *:443
ServerName *:80

<VirtualHost *:443>
 [some non-ssl stuff(directory, docroot)]
 ServerName account.example.com
 SSLEngine on
 SSLCertificateFile /Users/myusername/certs/server.crt
 SSLCertificateKeyFile /Users/myusername/certs/server.key
</VirtualHost>

<VirtualHost *:80>
  SSLEngine off
  [other stuff like docroot]
</VirtualHost>

For single website to work on both the ports, Add rewrite rule to redirrect from http to https in http vhost's .htaccess file:

#Redirrect from http to https
RewriteEngine On
RewriteCond %{HTTPS} off
RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI} [R,L]

Done. You will be able to use both HTTP and HTTPS now.


Cannot use monitor with 2560x1440 resolution 16.04

Try to set it through "nvidia x server settings" not via display settings.

Also check if external monitor support this resolution over connected/chosen port.
(For example some monitors allows only 1080p over HDMI)


Is it possible/worthwhile to install Ubuntu on its own SSD so it can be swapped between machines as needed?

Creating a Full install Ubuntu SSD from a Prebuilt Image File

Download Image File: https://phillw.net/isos/linux-tools/uefi-n-bios/dd_unb_ubuntu-20.04_15GB_2020-06-26.img.xz

Download Rufus: https://github.com/pbatard/rufus/releases/download/v3.11/rufus-3.11.exe

Double click Rufus exe file. (No need to install it).

Select USB2 Target drive in Rufus.

Select above Image File in Rufus.

Click Rufus start button.

Wait for flashing to complete... Done.

(Password is "changeme", change it),
The SSD should boot on almost any modern X86 computer.
Thanks to sudodus for the image file.
In Windows it may be necessary to install 7Zip before proceeding. Rufus will use it when working with the .xz image: https://www.7-zip.org/a/7z1900-x64.exe


suspend is not working after updating to Ubuntu 14.04 from 13.10

You're possibly seeing this bug: Black screen after login from suspend in Xubuntu 14.04. Try removing light-locker and light-locker-settings and installing xscreensaver to solve the issue of buggy suspend/resume.


Installing u-customizer (live cd editor, dependant on gambas2) on ubuntu 14.04

It looks like that is an old, outdated version of U-Customizer from 2012; its new website is https://github.com/kamilion/customizer and the latest version can be downloaded from there.