Tuesday, May 26, 2009

How to create new user on mysql using command line on windows

1. Quote : cd apache/mysql/bin

2. Quote : mysql -u root -p

3. Quote : use mysql;

4. Quote : create user modcert;

5. Quote : update user set password = PASSWORD('sqlpassword') where User = 'kunkun';

6. Quote : flush privileges;

7. Quote : grant select, insert, delete, update on database.* to 'kunkun'@'localhost' identified by 'sqlpassword';

8. Quote : flush privileges;

Enjoy ubuntu... ;)

How to update user mysql using command line on windows

1. Quote : cd apache/mysql/bin

2. Quote : mysql -u root -p

3. Quote : use mysql

4. Quote : set password for 'root'@'localhost' = OLD_PASSWORD('newpassword');

5. Quote : update user set password = OLD_PASSWORD('newpassword') where Host = 'localhost' AND User = 'root';

6. Quote : flush privileges;

Enjoy ubuntu... ;)

How to check current ubuntu version using command line

Quote : lsb_release -a
root@kunkun-laptop:/home/kunkun# lsb_release -a
LSB Version: core-2.0-ia32:core-3.0-ia32:core-3.1-ia32:core-3.2-ia32:core-2.0-noarch:core-3.0-noarch:core-3.1-noarch:core-3.2-noarch:cxx-2.0-ia32:cxx-3.0-ia32:cxx-3.1-ia32:cxx-3.2-ia32:cxx-2.0-noarch:cxx-3.0-noarch:cxx-3.1-noarch:cxx-3.2-noarch:desktop-3.1-ia32:desktop-3.2-ia32:desktop-3.1-noarch:desktop-3.2-noarch:graphics-2.0-ia32:graphics-3.0-ia32:graphics-3.1-ia32:graphics-3.2-ia32:graphics-2.0-noarch:graphics-3.0-noarch:graphics-3.1-noarch:graphics-3.2-noarch:languages-3.2-ia32:languages-3.2-noarch:multimedia-3.2-ia32:multimedia-3.2-noarch:printing-3.2-ia32:printing-3.2-noarch
Distributor ID: Ubuntu
Description: Ubuntu 8.04.2
Release: 8.04
Codename: hardy

Enjoy ubuntu... ;)

kunkun-laptop .... ;)