How To Install MySQL 5.6 On Debian

Valic —  December 31, 2012 — 2 Comments

MySQL 5.6 will add more performance improvements over MySQL 5.5. MySQL 5.6 is not stable yet but I will show you how to install MySQL 5.6.8rc on Debian if you want to test it.

Step1. Add a group and an user for MySQL called mysql:

[email protected]:~# groupadd mysql
[email protected]:~# useradd -r -g mysql mysql

Step2. Install the libaio1 library package. This is used by MySQL:

[email protected]:~# apt-get install libaio1

Step3. Download MySQL 5.6.8rc version in /usr/local location:

[email protected]:~# cd /usr/local
[email protected]:/usr/local# wget -O mysql-5.6.8-rc-linux2.6-x86_64.tar.gz http://dev.mysql.com/get/Downloads/MySQL-5.6/mysql-5.6.8-rc-linux2.6-x86_64.tar.gz/from/http://cdn.mysql.com/
2012-12-30 16:11:31 (5.10 MB/s) - `mysql-5.6.8-rc-linux2.6-x86_64.tar.gz' saved [293210851/293210851]

Step4. Unpack the MySQL archive and rename it to mysql: Continue Reading…

Dump a PostgreSQL database:

[email protected]:~$ pg_dump db_name -v --format=c --file=./db_name.dump

Import the dump to a new PostgreSQL database:

[email protected]:~$ createdb -E UTF8 -T template0 db_new
[email protected]:~$ pg_restore -U user -d db_new ./db_name.dump
[email protected]:~$ psql --command "ALTER DATABASE db_new OWNER TO user;"

How to Get UUID of Hard Disks

Valic —  December 27, 2012 — Leave a comment

The Universally Unique Identifier(UUID) is used to identify a hard disk independent form its device name or mount point. Is mostly used to access a device not by name, for example in /etc/fstab file.

There are many ways to get the UUID. I will show you two ways to do that.

Use the following command to show you all hard disk partitions by UUID:

ls -l /dev/disk/by-uuid

lrwxrwxrwx 1 root root 10 Dec 27 20:02 25c8851a-494b-49f8-a1ac-3df97ca16a5e -> ../../sda5
lrwxrwxrwx 1 root root 10 Dec 27 20:02 2a554679-b975-4f5d-bb41-97374d640f6a -> ../../sda3
lrwxrwxrwx 1 root root 10 Dec 27 20:02 ed57f181-75e7-4fc6-aebe-2865b358da84 -> ../../sdb1
lrwxrwxrwx 1 root root 10 Dec 27 20:02 f6385c06-925a-426f-b689-21a210908ae0 -> ../../sda1

The second way is to use blkid tool:

blkid /dev/sda1
/dev/sda1: UUID="f6385c06-925a-426f-b689-21a210908ae0" TYPE="ext3"

blkid /dev/sdb1
/dev/sdb1: UUID="ed57f181-75e7-4fc6-aebe-2865b358da84" TYPE="ext4"

Enjoy.

I will show you how to degug Fail2ban when you can’t start it and you get the following error:

Starting Fail2ban: [FAILED]

You can’t find any errors in syslog or Fail2ban log because the Fail2ban init script is writing the output of the fail2ban-client to /dev/null The best way to debug Fail2ban is to call directly the fail2ban-client and that will show any syntax error found in the config files. The command and the output looks like this:

fail2ban-client -xd start
WARNING 'findtime' not defined in 'apache-noscript'. Using default value
WARNING 'findtime' not defined in 'pam-generic'. Using default value
WARNING 'findtime' not defined in 'vsftpd'. Using default value Continue Reading...

KDE-4.10

On 19 December  KDE released the primary  RC for its revived Workspaces, Applications, and Development Platform.

KDE 4.10 includes:

Continue Reading…

Page 1 of 41234