Description:
After a brief power failure, I rebooted the mysql server machine, and got this
error on startup:
Starting mysqld daemon with databases from /var/lib/mysql
/usr/bin/safe_mysqld: line 254: 1844 Segmentation fault (core dumped)
$NOHUP_NICENESS $ledir/$MYSQLD $defaults --basedir=$MY_BASEDIR_VERSION
--datadir=$DATADIR $USER_OPTION --pid-file=$pid_file --skip-locking $err_log 21
010910 13:32:48 mysqld ended
I tried running myisamchk -re on every *.MYI file under /var/lib/mysql, and they
seemed to repair successfully, however the crash still occurs. From the strace output,
I don't think mysqld even gets as far as opening these files. What else can I try to
get mysqld running again?
Extra info:
The following lines appeared at boot time immediately after the power failure:
Sep 7 10:29:43 plex5 fsck: / was not cleanly unmounted, check forced.
Sep 7 10:29:43 plex5 fsck: /:
Sep 7 10:29:43 plex5 fsck: Deleted inode 314548 has zero dtime. FIXED.
Sep 7 10:29:43 plex5 fsck: /: Deleted inode 315383 has zero dtime. FIXED.
Sep 7 10:29:43 plex5 fsck: /:
Sep 7 10:29:43 plex5 fsck: Deleted inode 657264 has zero dtime. FIXED.
Sep 7 10:29:43 plex5 fsck: Setting filetype for entry 'mysql.sock' in /var/lib/mysql
(163202) to 6.
Sep 7 10:29:43 plex5 fsck: Setting filetype for entry 'log' in /dev (195841) to 6.
Sep 7 10:29:43 plex5 fsck: Setting filetype for entry 'gpmctl' in /dev (195841) to 6.
Sep 7 10:29:43 plex5 fsck: Setting filetype for entry 'fs7100' in /tmp/.font-unix
(315379) to 6.
Sep 7 10:29:43 plex5 fsck: Setting filetype for entry 'plex5.oz.agile.tv:0.0' in
/tmp/.sawmill-root (473314) to 6.
Sep 7 10:29:43 plex5 fsck: Setting filetype for entry 'X0' in /tmp/.X11-unix (526411)
to 6.
Sep 7 10:29:43 plex5 fsck: Setting filetype for entry 'orb-1329759521518799309' in
/tmp/orbit-root (526413) to 6.
Sep 7 10:29:43 plex5 fsck: Setting filetype for entry 'pump.sock' in /var/run
(734401) to 6.
Sep 7 10:29:43 plex5 fsck: Setting filetype for entry '6797' in /tmp/.ICE-unix
(848723) to 6.
Sep 7 10:29:43 plex5 fsck: /: 291612/897600 files (1.0% non-contiguous),
1510399/1793247 blocks
Sep 7 10:29:43 plex5 rc.sysinit: Checking root filesystem succeeded
Strace output:
execve(/usr/sbin/mysqld, [/usr/sbin/mysqld, --basedir=/,
--datadir=/var/lib/mysql, --user=mysql,
--pid-file=/var/lib/mysql/plex5.oz.agile.tv.pid, --skip-locking], [/* 41 vars */])
= 0
fcntl(0, F_GETFD) = 0
fcntl(1, F_GETFD) = 0
fcntl(2, F_GETFD) = 0
personality(PER_LINUX) = 0
geteuid() = 0
getuid()= 0
getegid() = 0
getgid()= 0
getpid()= 2130
getrlimit(RLIMIT_STACK, {rlim_cur=8192*1024, rlim_max=2147483647}) = 0
setrlimit(RLIMIT_STACK, {rlim_cur=120*1024, rlim_max=2147483647}) = 0
uname({sys=Linux, node=plex5.oz.agile.tv, ...}) = 0
rt_sigaction(SIGRT_0, {0x81303dc, [], 0x400}, NULL, 8) = 0
rt_sigaction(SIGRT_1, {0x8130448, [], 0x400}, NULL, 8) = 0
rt_sigaction(SIGRT_2, {0x8130508, [], 0x400}, NULL, 8) = 0
rt_sigprocmask(SIG_BLOCK, [RT_0], NULL, 8) = 0
brk(0) = 0x82272b8
brk(0x82272e8) = 0x82272e8
brk(0x8228000) = 0x8228000
getpid()= 2130
open(/etc/localtime, O_RDONLY)= 3
read(3, TZif\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\4\0\0\0\4\0..., 44) = 44
read(3, \234N\246\234\234\274 \360\313T\263\0\313\307Wp\314\267..., 80) = 80
fstat64(3, 0xb404) = -1 ENOSYS (Function not implemented)
fstat(3, {st_mode=S_IFREG|0644, st_size=160, ...}) = 0
old_mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) =
0x4000
read(3, \0\0\232\260\1\0\0\0\214\240\0\0\0\0\232\260\1\0\0\0\214..., 4096) = 36
close(3)= 0
munmap(0x4000, 4096)= 0
time(NULL) = 999841159
uname({sys=Linux, node=plex5.oz.agile.tv, ...}) = 0
open(/etc/my.cnf, O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open(/var/lib/mysql/my.cnf, O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or
directory)
open(/root/.my.cnf, O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
lstat(/, {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
open(/usr/share/mysql/charsets/Index, O_RDONLY|O_LARGEFILE) = 3
fstat(3, {st_mode=S_IFREG|0755, st_size=549, ...}) = 0
old_mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) =
0x4000
read(3, # sql/share/charsets/Index\n#\n# T..., 4096) = 549
brk(0x822a000) = 0x822a000
read(3, , 4096) = 0
close(3)= 0
munmap(0x4000, 4096)= 0
stat(/usr/share/mysql/charsets/dec8.conf,