MySQL 5.6社区服务器无法在CentOS 6上启动。
之前,我在CentOS 6上成功安装了mysql社区服务器(文件:mysql-community-release-el6-5.noarch.rpm),二进制源代码来自http://dev.mysql.com/downloads/repo/百胜餐饮
我在configuration/etc/my1.conf和启动脚本/etc/init.d/mysqld1里面做了一些修改,改变了数据,日志和pid文件的位置,请在下面find如下改动:
file: /etc/my1.conf [mysqld] innodb_buffer_pool_size = 128M datadir=/opt/mysql/mysql1 socket=/opt/mysql/mysql1/mysql.sock symbolic-links=0 sql_mode=NO_ENGINE_SUBSTITUTION,STRICT_TRANS_TABLES [mysqld_safe] log-error=/opt/mysql/log/mysqld1.log pid-file=/opt/mysql/run/mysqld1.pid file: /etc/init.d/mysqld1 datadir="/opt/mysql/mysql1" socketfile="/opt/mysql/mysql1/mysql.sock" errlogfile="/opt/mysql/log/mysqld1.log" mypidfile="/opt/mysql/run/mysqld1.pid" defaultfile="/etc/my1.cnf" $exec --defaults-file="$defaultfile" \ --datadir="$datadir" --socket="$socketfile" \ --pid-file="$mypidfile" \ --basedir=/usr --user=mysql >/dev/null 2>&1 &
我在创业后总是失败
$ sudo service mysqld1 start [sudo] password for beepcast: 141230 10:38:57 mysqld_safe Logging to '/opt/mysql/log/mysqld1.log'. 141230 10:38:57 mysqld_safe Starting mysqld daemon with databases from /opt/mysql/mysql1 ... (hang)
当我检查日志文件时,它不显示任何错误,请在下面find以下日志文件:
2014-12-30 10:38:57 0 [Warning] TIMESTAMP with implicit DEFAULT value is deprecated. Please use --explicit_defaults_for_timestamp server option (see documentation for more details). 2014-12-30 10:38:57 2674 [Note] Plugin 'FEDERATED' is disabled. 2014-12-30 10:38:57 2674 [Note] InnoDB: Using atomics to ref count buffer pool pages 2014-12-30 10:38:57 2674 [Note] InnoDB: The InnoDB memory heap is disabled 2014-12-30 10:38:57 2674 [Note] InnoDB: Mutexes and rw_locks use GCC atomic builtins 2014-12-30 10:38:57 2674 [Note] InnoDB: Memory barrier is not used 2014-12-30 10:38:57 2674 [Note] InnoDB: Compressed tables use zlib 1.2.3 2014-12-30 10:38:57 2674 [Note] InnoDB: Using Linux native AIO 2014-12-30 10:38:57 2674 [Note] InnoDB: Not using CPU crc32 instructions 2014-12-30 10:38:57 2674 [Note] InnoDB: Initializing buffer pool, size = 128.0M 2014-12-30 10:38:57 2674 [Note] InnoDB: Completed initialization of buffer pool 2014-12-30 10:38:57 2674 [Note] InnoDB: Highest supported file format is Barracuda. 2014-12-30 10:38:59 2674 [Note] InnoDB: 128 rollback segment(s) are active. 2014-12-30 10:38:59 2674 [Note] InnoDB: Waiting for purge to start 2014-12-30 10:38:59 2674 [Note] InnoDB: 5.6.22 started; log sequence number 1626007 2014-12-30 10:38:59 2674 [Note] Server hostname (bind-address): '*'; port: 3306 2014-12-30 10:38:59 2674 [Note] IPv6 is available. 2014-12-30 10:38:59 2674 [Note] - '::' resolves to '::'; 2014-12-30 10:38:59 2674 [Note] Server socket created on IP: '::'. 2014-12-30 10:38:59 2674 [Note] Event Scheduler: Loaded 0 events 2014-12-30 10:38:59 2674 [Note] /usr/sbin/mysqld: ready for connections. Version: '5.6.22' socket: '/opt/mysql/mysql1/mysql.sock' port: 3306 MySQL Community Server (GPL)
我不知道为什么这样挂? 但肯定mysql服务器运行正常,侦听器端口是打开的。