Connect to Remote Database with PhpMyAdmin

on Database Server:
apt-get install mysql-server mysql-client

Backup original configuration:
cp /etc/mysql/my.cnf /etc/mysql/my.cnf_orig

Let mysql server listen on all interfaces:
grep -l bind-address /etc/mysql/my.cnf | xargs sed -i -e 's/bind-address/#bind-address/'

Restart mysql server
/etc/init.d/mysql restart

Check if MySQL binds on every interface
netstat -tap

it should look like this:
tcp 0 0 *:mysql *:* LISTEN 2487/mysqld

Now give root user logon permission from Webserver where phpmyadmin is running
mysql -u root -p
mysql> use mysql;
mysql> update user set host=’WEBSERVER-IP’ where host=’127.0.0.1′ and user=’root’;
mysql> flush privileges;

Restart mysql server
/etc/init.d/mysql restart

On Webserver:
apt-get install apache2 php5 phpmyadmin

Edit /etc/phpmyadmin/config-db.php and set the variables
$dbuser='root';
$dbpass='R00tPassW0rd';
$dbname='mysql';
$dbserver='DBSERVER-IP';
$dbport=''; // leave blank if mysql runs on default port

Open your Browser and point to http://yourwebserver/phpmyadmin

Xen: Device xxx (x) could not be connected. Failed to find an unused loop device

If you are using Xen and get an error Device xxxxx (xxx) could not be connected. Failed to find an unused loop device when you try to create a guest. This is because you are out of loop devices.

Run this on command line:
echo "options loop max_loop=32" > /etc/modprobe.d/xen

With the value 32 you are able to run 16 Guests on your host, assuming you aren’t using loop devices for other purposes. Use a number suitable for your needs.

Shutdown your guests and run this on command line:
rmmod loop && modprobe loop

Show all loop devices:
ls -l /dev/ | grep loop

Kubuntu 11.04 install Kernel 3.0.1

Kernel version 3.0.1 stable was just released a week ago. I’m a lazy guy, so I install the precompiled .deb packages.

Get the linux-headers-*-all.deb, linux-headers-*-generic-*.deb, and finally linux-image-*.deb from http://kernel.ubuntu.com/~kernel-ppa/mainline/v3.0.1-oneiric/
Install the .deb Packages in this Order:
dpkg -i linux-headers-*-all.deb
dpkg -i linux-headers-*-generic-*.deb
dpkg -i linux-image-*.deb

Restart your machine, enter the grub menu by typing shift and boot the new kernel. Its possible that u get in trouble while booting the new kernel – just restart and take an older one. Remove linux-headers-3 and linux-image-3 if it didn’t work.

Maybe u need module-init-tools 3.13 where u can get here https://launchpad.net/ubuntu/oneiric/amd64/module-init-tools/3.13-1ubuntu1

Other precompiled Kernel versions http://kernel.ubuntu.com/~kernel-ppa/mainline/