Coda File System

Problems with mysql

From: Steffen Neumann <sneumann_at_TechFak.Uni-Bielefeld.DE>
Date: Fri, 2 Feb 2001 16:00:13 +0100 (MET)
Hi,

I have problems with mysql-3.22.32,
which won't start if it is to store its data 
to our coda partition. 
I tried mysql-3.23.32 as well, same problem.

Problems go away if I set datadir to an ext2 filesystem.
General question: how to debug those problems 
that might be coda related ?

>From the strace attached below I see that
line 23 differs, where it reads back the data 
sent to ./mysql/bla.frm with pwrite() in line 11, 
after the lseek(SEEK_END) in line 9.

Is there documentation what filesystem features 
or system calls coda does not support ?


So long,
yours,
Steffen

------------------------------------------------- 

	datadir on /coda                                                         datadir on /tmp/mysql

     1	read(0, create table bla (bla int);				read(0, create table bla (bla int);
     2	"create table bla (bla int);\n", 1024) = 28			"create table bla (bla int);\n", 1024) = 28
     3	access("./mysql/bla.frm", F_OK)         = -1 ENOENT (No such 	access("./mysql/bla.frm", F_OK)         = -1 ENOENT (No such 
     4	open("./mysql/bla.frm", O_RDWR|O_CREAT|O_TRUNC, 0660) = 5	open("./mysql/bla.frm", O_RDWR|O_CREAT|O_TRUNC, 0660) = 5
     5	write(5, "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\	write(5, "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\
     6	lseek(5, 64, SEEK_SET)                  = 64			lseek(5, 64, SEEK_SET)                  = 64
     7	write(5, "//\0", 3)                     = 3			write(5, "//\0", 3)                     = 3
     8	write(5, "\0 \0\0", 4)                  = 4			write(5, "\0 \0\0", 4)                  = 4
     9	lseek(5, 0, SEEK_END)                   = 4096			lseek(5, 0, SEEK_END)                   = 4096
    10	write(5, "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\	write(5, "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\
    11	pwrite(5, "\376\1\7\7\3\0\0\20\1\0\0000\0\0\20\0\6\0\0\0\0\0\	pwrite(5, "\376\1\7\7\3\0\0\20\1\0\0000\0\0\20\0\6\0\0\0\0\0\
    12	pwrite(5, "\0\0\6\0\2\0,\0", 8, 4096)   = 8			pwrite(5, "\0\0\6\0\2\0,\0", 8, 4096)   = 8
    13	lseek(5, 4112, SEEK_SET)                = 4112			lseek(5, 4112, SEEK_SET)                = 4112
    14	write(5, "\376\0\0\0\0\377", 6)         = 6			write(5, "\376\0\0\0\0\377", 6)         = 6
    15	lseek(5, 8192, SEEK_SET)                = 8192			lseek(5, 8192, SEEK_SET)                = 8192
    16	write(5, "h\1\0\20\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\	write(5, "h\1\0\20\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\
    17	write(5, "7\0\2\1\2\24)                         "..., 55) = 5	write(5, "7\0\2\1\2\24)                         "..., 55) = 5
    18	write(5, "\4\4\v\v\2\0\33\200\0\0\0", 11) = 11			write(5, "\4\4\v\v\2\0\33\200\0\0\0", 11) = 11
    19	write(5, ",", 1)                        = 1			write(5, ",", 1)                        = 1
    20	write(5, "bla,\0", 5)                   = 5			write(5, "bla,\0", 5)                   = 5
    21	close(5)                                = 0			close(5)                                = 0
    22	open("./mysql/bla.frm", O_RDONLY)       = 5			open("./mysql/bla.frm", O_RDONLY)       = 5
    23	read(5, "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0 |	read(5, "\376\1\7\7\3\0\0\20\1\0\0000\0\0\20\0\6\0\0\0\0\0\0\
    24								      >	lseek(5, 64, SEEK_SET)                  = 64
    25								      >	read(5, "//\0\0 \0\0", 7)               = 7
    26								      >	lseek(5, 4096, SEEK_SET)                = 4096
    27								      >	read(5, "\0\0\6\0\2\0,\0", 8)           = 8
    28								      >	pread(5, "\376\0\0\0\0\377", 6, 4112)   = 6
    29								      >	lseek(5, 8192, SEEK_SET)                = 8192
    30								      >	read(5, "h\1\0\20\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0
    31								      >	read(5, "7\0\2\1\2\24)                         "..., 72) = 72
    32								      >	close(5)                                = 0
    33								      >	lstat("./mysql/bla", 0xbfffc9c4)        = -1 ENOENT (No such 
    34								      >	open("./mysql/bla.ISM", O_RDWR|O_CREAT|O_TRUNC, 0660) = 5
    35								      >	open("./mysql/bla.ISD", O_RDWR|O_CREAT|O_TRUNC, 0660) = 6
    36								      >	getpid()                                = 602
    37								      >	time(NULL)                              = 981123665
    38								      >	time(NULL)                              = 981123665
    39								      >	write(5, "\376\376\5\2\0\0\250\2\310\0\234\0\0\2\0\0\0\0\0\0\
    40								      >	write(5, "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\
    41								      >	write(5, "\0\4\0\0\0\0\0\0\0\0\0\0\6\0\0\0\377\377\377\377\37
    42								      >	write(5, "\0\0\1\0", 4)                 = 4
    43								      >	write(5, "\0\0\4\0", 4)                 = 4
    44								      >	write(5, "\0\0\1\0", 4)                 = 4
    45								      >	lseek(5, 0, SEEK_END)                   = 680
    46								      >	write(5, "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\
    47								      >	close(6)                                = 0
    48	close(5)                                = 0			close(5)                                = 0
    49	write(2, "ERROR: 1033  Incorrect informati"..., 62ERROR:      <
    50	                 1033  Incorrect information in file: './mysq <



Complete strace output repeated  ---------------------------------------------------------------


starting a freshly installed mysqld with 

strace /coda/vol/mysql/libexec/mysqld --bootstrap 
       --skip-grant-tables --basedir=/coda/vol/mysql 
       --datadir=/coda/vol/mysql/var 


create table bla (bla int); leads to :



read(0, create table bla (bla int);
"create table bla (bla int);\n", 1024) = 28
access("./mysql/bla.frm", F_OK)         = -1 ENOENT (No such file or directory)
open("./mysql/bla.frm", O_RDWR|O_CREAT|O_TRUNC, 0660) = 5
write(5, "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"..., 4096) = 4096
lseek(5, 64, SEEK_SET)                  = 64
write(5, "//\0", 3)                     = 3
write(5, "\0 \0\0", 4)                  = 4
lseek(5, 0, SEEK_END)                   = 4096
write(5, "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"..., 4096) = 4096
pwrite(5, "\376\1\7\7\3\0\0\20\1\0\0000\0\0\20\0\6\0\0\0\0\0\0\0\0"..., 64, 0) = 64
pwrite(5, "\0\0\6\0\2\0,\0", 8, 4096)   = 8
lseek(5, 4112, SEEK_SET)                = 4112
write(5, "\376\0\0\0\0\377", 6)         = 6
lseek(5, 8192, SEEK_SET)                = 8192
write(5, "h\1\0\20\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"..., 288) = 288
write(5, "7\0\2\1\2\24)                         "..., 55) = 55
write(5, "\4\4\v\v\2\0\33\200\0\0\0", 11) = 11
write(5, ",", 1)                        = 1
write(5, "bla,\0", 5)                   = 5
close(5)                                = 0
open("./mysql/bla.frm", O_RDONLY)       = 5
read(5, "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"..., 64) = 64
close(5)                                = 0
write(2, "ERROR: 1033  Incorrect informati"..., 62ERROR: 
                 1033  Incorrect information in file: './mysql/bla.frm') = 62


With datadir set to an ext2 fs it looks like this:

strace /coda/vol/mysql/libexec/mysqld 
	--bootstrap --skip-grant-tables 
	--basedir=/coda/vol/mysql 
	--datadir=/tmp/mysql

read(0, create table bla (bla int);
"create table bla (bla int);\n", 1024) = 28
access("./mysql/bla.frm", F_OK)         = -1 ENOENT (No such file or directory)
open("./mysql/bla.frm", O_RDWR|O_CREAT|O_TRUNC, 0660) = 5
write(5, "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"..., 4096) = 4096
lseek(5, 64, SEEK_SET)                  = 64
write(5, "//\0", 3)                     = 3
write(5, "\0 \0\0", 4)                  = 4
lseek(5, 0, SEEK_END)                   = 4096
write(5, "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"..., 4096) = 4096
pwrite(5, "\376\1\7\7\3\0\0\20\1\0\0000\0\0\20\0\6\0\0\0\0\0\0\0\0"..., 64, 0) = 64
pwrite(5, "\0\0\6\0\2\0,\0", 8, 4096)   = 8
lseek(5, 4112, SEEK_SET)                = 4112
write(5, "\376\0\0\0\0\377", 6)         = 6
lseek(5, 8192, SEEK_SET)                = 8192
write(5, "h\1\0\20\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"..., 288) = 288
write(5, "7\0\2\1\2\24)                         "..., 55) = 55
write(5, "\4\4\v\v\2\0\33\200\0\0\0", 11) = 11
write(5, ",", 1)                        = 1
write(5, "bla,\0", 5)                   = 5
close(5)                                = 0
open("./mysql/bla.frm", O_RDONLY)       = 5
read(5, "\376\1\7\7\3\0\0\20\1\0\0000\0\0\20\0\6\0\0\0\0\0\0\0\0"..., 64) = 64
lseek(5, 64, SEEK_SET)                  = 64
read(5, "//\0\0 \0\0", 7)               = 7
lseek(5, 4096, SEEK_SET)                = 4096
read(5, "\0\0\6\0\2\0,\0", 8)           = 8
pread(5, "\376\0\0\0\0\377", 6, 4112)   = 6
lseek(5, 8192, SEEK_SET)                = 8192
read(5, "h\1\0\20\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"..., 288) = 288
read(5, "7\0\2\1\2\24)                         "..., 72) = 72
close(5)                                = 0
lstat("./mysql/bla", 0xbfffc9c4)        = -1 ENOENT (No such file or directory)
open("./mysql/bla.ISM", O_RDWR|O_CREAT|O_TRUNC, 0660) = 5
open("./mysql/bla.ISD", O_RDWR|O_CREAT|O_TRUNC, 0660) = 6
getpid()                                = 602
time(NULL)                              = 981123665
time(NULL)                              = 981123665
write(5, "\376\376\5\2\0\0\250\2\310\0\234\0\0\2\0\0\0\0\0\0\0\0"..., 200) = 200
write(5, "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"..., 312) = 312
write(5, "\0\4\0\0\0\0\0\0\0\0\0\0\6\0\0\0\377\377\377\377\377\377"..., 156) = 156
write(5, "\0\0\1\0", 4)                 = 4
write(5, "\0\0\4\0", 4)                 = 4
write(5, "\0\0\1\0", 4)                 = 4
lseek(5, 0, SEEK_END)                   = 680
write(5, "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"..., 344) = 344
close(6)                                = 0
close(5)                                = 0
Received on 2001-02-02 10:00:29