The proper way to install virtualbox on Ubuntu Linux

 sudo apt-get install -y dkms linux-headers-generic

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

For Ubuntu 14.04

sudo sh -c 'echo "deb http://download.virtualbox.org/virtualbox/debian trusty contrib" >> /etc/apt/sources.list.d/virtualbox.list'

For Ubuntu 13.10

sudo sh -c 'echo "deb http://download.virtualbox.org/virtualbox/debian saucy contrib" >> /etc/apt/sources.list.d/virtualbox.list'

For Ubuntu 13.04

sudo sh -c 'echo "deb http://download.virtualbox.org/virtualbox/debian raring contrib" >> /etc/apt/sources.list.d/virtualbox.list'

For Ubuntu 12.10

sudo sh -c 'echo "deb http://download.virtualbox.org/virtualbox/debian quantal contrib" >> /etc/apt/sources.list.d/virtualbox.list'

For Ubuntu 12.04

sudo sh -c 'echo "deb http://download.virtualbox.org/virtualbox/debian precise contrib" >> /etc/apt/sources.list.d/virtualbox.list'

For Ubuntu 11.10

sudo sh -c 'echo "deb http://download.virtualbox.org/virtualbox/debian oneiric contrib" >> /etc/apt/sources.list.d/virtualbox.list'

For Ubuntu 11.04

sudo sh -c 'echo "deb http://download.virtualbox.org/virtualbox/debian natty contrib" >> /etc/apt/sources.list.d/virtualbox.list'

Once you added the repo using the above command, Update your repository.

sudo apt-get update && sudo apt-get install -y virtualbox-4.3

http://www.howopensource.com/2013/04/install-virtualbox-ubuntu-ppa/

Fix Mysql Workbench passwords not being saved in keychain – Debian – Ubuntu

 A fix for this issue with Ubuntu

echo $XDG_RUNTIME_DIR

/run/user/1000

add this path to your .profile 

GNOME_KEYRING_CONTROL=$XDG_RUNTIME_DIR

reload the source

log off your gnome session,

try with workbench again

You should be prompted for a password to unlock the keychain if it is locked. Use your current account password to do so.

This is a temporary workaround. 

 

Another fix submitted by a user

 

Thanks for the tip! I placed the following wrapper script at /usr/local/bin/mysql-workbench to work around the bug:

#!/bin/sh
if [ -n "${XDG_RUNTIME_DIR}" ]; then
  GNOME_KEYRING_CONTROL="${XDG_RUNTIME_DIR}/keyring/control"
  [ -z "${GNOME_KEYRING_CONTROL}" ] || export GNOME_KEYRING_CONTROL
fi
/usr/bin/mysql-workbench ${@}
 
 

 

References:

https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=769393

Samba Debian 7 Wheeze – Cannot Install Updates apt-get -f does not work

Seem this is due to a bug.

How to fix.

run this command

rm /etc/dhcp3 

 

I came accross this ina  similar situation.
When installing samba-common:

dpkg: error processing /var/cache/apt/archives/samba-common_2%3a3.6.3-2ubuntu2.3_all.deb (--unpack):
 unable to open '/etc/dhcp3/dhclient-enter-hooks.d/samba.dpkg-new': No such file or directory

In my case /etc/dhcp3 was a link to /etc/dhcp, because it was needed for Vmware customisations scripts:
http://javierin.com/2012/09/05/template-customization-para-debian-squeeze-en-vsphere-5-0u1/

The samba package just cannot handle that at all though.
Removing the link, allows samba to install:
rm /etc/dhcp3
(or copying the directory as noted above).
Howver this is not nice at all, having two directories for dhcp and one or the other might be read depending on circumstances.

So to me this is bug in the samba packaging.
==> Could this issue be re-opend please and the samba packaing examined?

-- 
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to samba in Ubuntu.
https://bugs.launchpad.net/bugs/993660

Title:
  package samba-common 2:3.5.8~dfsg-1ubuntu2.4 failed to
  install/upgrade: unable to open '/etc/dhcp3/dhclient-enter-
  hooks.d/samba.dpkg-new': Too many levels of symbolic links

Status in “samba” package in Ubuntu:
  Expired

Bug description:
  When I tried "apt-get install -f" from a command line, I got this:

  Reading package lists... Done

 

Creds: https://lists.ubuntu.com/archives/foundations-bugs/2013-February/137216.html

How to check and set locale settings Ubuntu / Debian

This is useful when you need to install apps that require precise locale settings..

 

From a terminal run:

nano /etc/locale.gen

 

You will get something like this

 

en_GB ISO-8859-1

en_GB.UTF-8 UTF-8

en_GB.ISO-8859-15 ISO-8859-15

en_US.UTF-8 UTF-8

# aa_DJ ISO-8859-1

# aa_DJ.UTF-8 UTF-8

# aa_ER UTF-8

# aa_ER@saaho UTF-8

# aa_ET UTF-8

 

 

Valid locale settings are en_GB.UTF-8 , en_US.UTF-8 

 

Change Ubuntu / Debian Hostname after installation

 

Using the terminal,

sudo nano /etc/hostname

 

Using Terminal and graphical editor. (this requires Ubuntu / Desktop desktop edition)

[ Also, this method requires gksu which can be installed using

sudo apt-get -y install gksu

]

gksudo gedit /etc/hostname

 

Change the hostname to what you desire and reboot.

 

To change the hostname for the current session without making permanent change you can also use

 

sudo hostname mnewhost.localdomain

Make Install / Checkinstall

 

 

How to uninstall packages that are installed using ‘make install’

 

This stack overflow article shows different options

 

make clean removes any intermediate or output files from your source / build tree. However, it only affects the source / build tree; it does not touch the rest of the filesystem and so will not remove previously installed software.

If you’re lucky, running make uninstall will work. It’s up to the library’s authors to provide that, however; some authors provide an uninstall target, others don’t.

If you’re not lucky, you’ll have to manually install it. Running make -n install can be helpful, since it will show the steps that the software would take to install itself but won’t actually do anything. You can then manually reverse those steps.

+1; Watch out for files that might also have been installed by other packages. Simply deleting these files (one interpretation of “manually reversing those steps”) could break the other packages. This is (one of many reasons) why package managers were invented. – Merlyn Morgan-Graham May 10 ’13 at 0:41

this is only possible if you keep the same configured and compiled build directory right? thus not very useful since most people would delete it after install. He wants to uninstall things regardless if he kept the build folder, and regardless if the package has been correctly configured for an make uninstall option. Clarification: what he wants to do is to enable some kind of management for packages that works for things he compiled himself. – Nisse Jul 27 ’13 at 6:11

If sudo make uninstall is unavailable:

In a debian based system, instead of doing make install you can run sudo checkinstall (or .rpm etc. equivalent) to make a .deb that is also automatically installed. You can then remove it using synaptic.

see http://community.linuxmint.com/tutorial/view/162

 

This answer is proof that the best answers often don’t get a lot of up-votes. Thanks! I’ve wanted to know how to do this for a long time. I always hesitate doing a “make install” because I know it will almost certainly be a pain to remove. – doug65536 May 24 ’13 at 18:53

also the LFS book has some information on package management systems, Since you have to set it up yourself. The information there should be helpful in getting this kind of thing work better(cleaner, more general). There are scripts that simply listen to what gets installed and then creates a script that when launched deletes all those files, or something like that. – Nisse Jul 27 ’13 at 6:18

This worked beautifully for me, even though I already had run make install before using checkinstall instead. – LukeGT Mar 6 at 7:43

 

Creds: http://stackoverflow.com/questions/1439950/whats-the-opposite-of-make-install-ie-how-do-you-uninstall-a-library-in-lin

Fix fusemount: fialed to open /dev/fuse: Permission denied

 

On Debian reboot after making these changes. It will save your time and avoid issues. 

 

If you haven’t already discovered the wonders of sshfs, you really should start using it — it’ll probably shave hours of your day as a web developer.  Every now and then I come across the following problem when first installing sshfs and have to take a moment to think about the problem, so I’ve decided to post it up here to help anyone else and as a reminder to my forgetful self.

Problem:
fusermount: failed to open /dev/fuse: Permission denied

Solution:
usermod -aG fuse <your-username>

exec su -l $USER

 

Depending on your setup you may need to prefix the solution commands with sudo although this isn’t specific to any platform and many user su. You may not need to reboot but it could save you some hassle in the long run if the problem still persists.  It’s common sense but just in case you didn’t get it, replace <your-username> with the username you use.

 

Creds: http://www.elfnet.org/2010/06/29/sshfs-failed-to-open-devfuse-permission-denied/