groupadd mysql
useradd -g mysql mysql
/usr/local/mysql/bin
# ./configure --prefix=/usr/local/mysql /
#--with-charset=gb2312
开始编译并安装:
# make
# make install
#/usr/local/mysql/bin/mysql_install_db --user=mysql
##############
To start mysqld at boot time you have to copy support-files/mysql.server
to the right place for your system
PLEASE REMEMBER TO SET A PASSWORD FOR THE MySQL root USER !
To do so, start the server, then issue the following commands:
/usr/local/mysql/bin/mysqladmin -u root password 'new-password'
/usr/local/mysql/bin/mysqladmin -u root -h anet-if password 'new-password'
See the manual for more instructions.
NOTE: If you are upgrading from a MySQL <= 3.22.10 you should run
the /usr/local/mysql/bin/mysql_fix_privilege_tables. Otherwise you will not be
able to use the new GRANT command!
You can start the MySQL daemon with:
cd /usr/local/mysql ; /usr/local/mysql/bin/mysqld_safe &
You can test the MySQL daemon with the benchmarks in the 'sql-bench' directory:
cd sql-bench ; perl run-all-tests
Please report any problems with the /usr/local/mysql/bin/mysqlbug script!
The latest information about MySQL is available on the web at
http://www.mysql.com
Support MySQL by buying support/licenses at http://shop.mysql.com
###############
cd /usr/local/mysql
#chown -R root .
(注意后面有个”.")
#chown -R mysql var
#chgrp -R mysql .
#启动服务
./bin/mysqld_safe --user=mysql &
#访问服务
./bin/mysql -u root -p