mysql - 启动错误InnoDB: mmap(137363456 bytes) failed; errno 1
(2013-09-16 23:21:07)
标签:
mysql启动错误it |
分类: mysql那些事 |
公司的服务器 mysql开起来 过段时间久宕机 后来开socket写聊天 也是开了基本上一会就宕机 查看服务器 是
total
used
free
shared buffers
cached
ERROR! MySQL server PID file could not be
found!
130716 17:09:15 mysqld_safe mysqld from pid file
/var/mysql/data/AY1305070924544.pid ended
130716 17:09:52 mysqld_safe Starting mysqld daemon with
databases from /var/mysql/data
InnoDB: mmap(137363456 bytes) failed; errno 12
130716 17:09:53 InnoDB: The InnoDB memory heap is
disabled
130716 17:09:53 InnoDB: Mutexes and rw_locks use GCC atomic
builtins
130716 17:09:53 InnoDB: Compressed tables use zlib 1.2.3
130716 17:09:53 InnoDB: Initializing buffer pool, size =
128.0M
130716 17:09:53 InnoDB: Completed initialization of buffer
pool
130716 17:09:53 InnoDB: highest supported file format is
Barracuda.
130716 17:09:53 InnoDB: Waiting for the
background threads to start
130716 17:09:54 InnoDB: 1.1.8 started; log sequence number
4703029
130716 17:09:54 [Note] Server hostname (bind-address):
'0.0.0.0'; port: 3306
130716 17:09:54 [Note] - '0.0.0.0' resolves
to '0.0.0.0';
130716 17:09:54 [Note] Server socket created on IP:
'0.0.0.0'.
130716 17:09:54 [Note] Event Scheduler: Loaded 0 events
130716 17:09:54 [Note]
/usr/local/mysql-DMYSQL_DATADIR=/var/mysql-DMYSQL_UNIX_ADDR=/var/mysql/mysqld.sock/bin/mysqld:
ready for
connections.
查看内存显示
[root@AY1305070924544 /]# free -m
Mem:
995
928
66
0
6
19
-/+ buffers/cache:
903
91
Swap:
0
0
0
重启错误提示
[root@AY1305070924544 /]# /etc/init.d/mysqld start
Starting MySQL. ERROR! The server quit without updating PID
file (/var/mysql/data/AY1305070924544.pid).
[root@AY1305070924544 /]# /etc/init.d/mysqld restart
Starting MySQL. ERROR! The server quit without updating PID
file (/var/mysql/data/AY1305070924544.pid).
这个其实日志里面说的很明白就是 mysql要占用内存的时候 物理内存不够用导致的 所有 vi
/etc/my.cnf
[inonodb]
innodb_buffer_pool_size=64MB 把这个数值改小
高版本的默认是128mb 版本的默认是 8mb

加载中…