Centos 7 源码编译安装mysql 5.6.22(整理篇)
# cd scripts/# ls
mysql_install_db
# ./mysql_install_db --user=mysql--datadir=/data/mydata
FATAL ERROR: please install the followingPerl modules before executing ./mysql_install_db:
Data::Dumper
初始化过程中会报错,需要安装perl-Module-Install.noarch
# yum install -yperl-Module-Install.noarch
# scripts/mysql_install_db --user=mysql--datadir=/data/mydata
To start mysqld at boot time you have tocopy
support-files/mysql.server to the rightplace for your system
PLEASE REMEMBER TO SET A PASSWORD FOR THEMySQL root USER !
To do so, start the server, then issuethe following commands:
./bin/mysqladmin -u root password 'new-password'
./bin/mysqladmin -u root -h localhost.localdomain password'new-password'
Alternatively you can run:
./bin/mysql_secure_installation
which will also give you the option ofremoving the test
databases and anonymous user created bydefault.This is
strongly recommended for productionservers.
See the manual for more instructions.
You can start the MySQL daemon with:
cd . ; ./bin/mysqld_safe &
You can test the MySQL daemon withmysql-test-run.pl
cd mysql-test ; perl mysql-test-run.pl
Please report any problems athttp://bugs.mysql.com/
The latest information about MySQL isavailable on the web at
http://www.mysql.com
Support MySQL by buying support/licensesat http://shop.mysql.com
New default config file was created as./my.cnf and
will be used by default by the serverwhen you start it.
You may edit this file to change serversettings
页:
[1]