Howto reset mysql password on ubuntu server 9.10

New IBM server has arrived, its IBM X3100-42X.

Standard install required; DNS, LAMP and OpenSSH server on  Ubuntu Server 9.10.

Problem came when I forgot password for MySQL. I think the solution isn’t far from what I done in FreeBSD.

First attempt login to MySQL server :

# mysql -uroot -p

Enter password:
ERROR 1045 (28000): Access denied for user ‘root’@’localhost’ (using password: NO)

Look MySQL process :

read more »

Open network access for mysql on ubuntu server

Error message came out when I try to access new vps server :

$ mysql -ubox-p -h

Enter password:
ERROR 2003 (HY000): Can’t connect to MySQL server on ‘’ (61)

Edit file :

# nano /etc/mysql/my.cnf

find this line :

bind-address           =

add # in the front into

#bind-address           =

save and restart mysql.

Re try again :

$ mysql -ubox -p -h

Enter password:
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 50
Server version: 5.0.75-0ubuntu10.2 (Ubuntu)

Type ‘help;’ or ‘\h’ for help. Type ‘\c’ to clear the current input statement.


Create tar.gz in OpenSolaris

I need to make backup for our public_html directory

using tar command I used to use :

tar cvzf  filename.tar.gz directory_name

It work in linux or bsd but I have different situation with OpenSolaris :

# uname -a

SunOS TGLxxxxxxx 5.11 snv_86 i86pc i386 i86xpv

# tar cvzf public_html.tar.gz public_html

tar: z: unknown function modifier
Usage: tar {c|r|t|u|x}[BDeEFhilmnopPqTvw@/[0-7]][bfk][X…] [blocksize] [tarfile] [size] [exclude-file…] {file | -I include-file | -C directory file}…

Combine it with gzip using pipe will give tar.gz file :

tar cvf -  public_html | gzip > public_html.tar.gz

Yes, it works!

scp time.

P.S :

In case you want to extract .tar.gz file in OpenSolaris use this command :

gzip -dc filename.tar.gz | tar xvf –