aⅴgo安装包下载_Mysql 安装

wget https://downloads.mysql.com/archives/get/file/mysql-5.6.36.tar.gz

yum install -y gcc gcc-c++automake autoconf

yum-y install cmake bison-devel ncurses-devel libaio-devel

预编译:

cmake .-DCMAKE_INSTALL_PREFIX=/usr/local/mysql-5.6.36\-DMYSQL_DATADIR=/usr/local/mysql-5.6.36/data \-DMYSQL_UNIX_ADDR=/usr/local/mysql-5.6.36/tmp/mysql.sock \-DDEFAULT_CHARSET=utf8 \-DDEFAULT_COLLATION=utf8_general_ci \-DWITH_EXTRA_CHARSETS=all \-DWITH_INNOBASE_STORAGE_ENGINE=1\-DWITH_FEDERATED_STORAGE_ENGINE=1\-DWITH_BLACKHOLE_STORAGE_ENGINE=1\-DWITHOUT_EXAMPLE_STORAGE_ENGINE=1\-DWITH_ZLIB=bundled \-DWITH_SSL=bundled \-DENABLED_LOCAL_INFILE=1\-DWITH_EMBEDDED_SERVER=1\-DENABLE_DOWNLOADS=1\-DWITH_DEBUG=0编译&&安装:

make&&make install

安装后操作:

useradd-s /sbin/nologin mysql -M

ln-s /usr/local/mysql-5.6.36 /usr/local/mysql

chown-R mysql.mysql /usr/local/mysql/data/usr/local/mysql/scripts/mysql_install_db --user=mysql --basedir=/usr/local/mysql --datadir=/usr/local/mysql/data/bin/cp /usr/local/mysql/support-files/my-default.cnf /etc/my.cnf/bin/cp /usr/local/mysql/support-files/mysql.server /etc/init.d/mysqld

echo'export PATH=/usr/local/mysql/bin:$PATH' >> /etc/profile

./etc/profile

chkconfig--add mysqld/usr/local/mysql/bin/mysqladmin -u root password 'xx'启动错误:

Starting MySQL.Logging to'/usr/local/mysql-5.6.36/data/db01.err'.171113 13:07:01 mysqld_safe Directory '/usr/local/mysql-5.6.36/tmp' for UNIX socket file don't exists.

ERROR! The server quit without updating PID file (/usr/local/mysql-5.6.36/data/db01.pid).

mkdir/usr/local/mysql-5.6.36/tmp

chown-R mysql.mysql /usr/local/mysql-5.6.36/tmp-----------------------------------------------------------------------------To start mysqld at boot time you have to copy

support-files/mysql.server to the right place foryour system

PLEASE REMEMBER TO SET A PASSWORD FOR THE MySQL root USER!Todoso, 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 iZ2zedsleruuvamkhs3he4Z password 'new-password'Alternatively you can run:/usr/local/mysql/bin/mysql_secure_installation

which will also give you the option of removing the test

databases and anonymous user created bydefault. This isstrongly recommendedforproduction servers.

See the manualformore instructions.

You can start the MySQL daemon with:

cd . ;/usr/local/mysql/bin/mysqld_safe &You can test the MySQL daemon with mysql-test-run.pl

cd mysql-test ; perl mysql-test-run.pl

Please report any problems at http://bugs.mysql.com/

The latest information about MySQLisavailable on the web at

http://www.mysql.com

Support MySQL by buying support/licenses at http://shop.mysql.com

Newdefault config file was created as /usr/local/mysql/my.cnf and

will be used bydefaultby the server when you start it.

You may editthisfile to change server settings--------------------------------------------------------------------------------

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值