Steve Lord wrote:
>
> This is a very odd problem as stripe alignment should make no visible
> difference at the system call level. Can you please rerun the ltrace
> with the -S option to include system call output as well. We will attempt
> to replicate here.
>
1. the not-working case
mount /dev/sda10 /tmp
ltrace -S /usr/lib/yp/makedbm /tmp/test /tmp/x
[...]
fopen("/tmp/test", "r" <unfinished ...>
SYS_brk(NULL) = 0x0804b2b0
SYS_brk(0x0804b430) = 0x0804b430
SYS_brk(0x0804c000) = 0x0804c000
SYS_open("/tmp/test", 0, 0666) = 3
<... fopen resumed> ) = 0x0804b2b8
calloc(1, 9) = 0x0804b428
sprintf("/tmp/x~", "%s~", "/tmp/x") = 7
gdbm_open(0x0804b428, 0, 19, 384, 0 <unfinished ...>
SYS_open("/tmp/x~", 66, 0600) = 4
SYS_fstat64(4, 0xbffffa6c, 0x0804b438, 0xbffffb84, 4) = 0
SYS_fcntl64(4, 6, 0xbffffb74, 0xbffffb84, 4) = 0
SYS_mmap(0xbffffa64, 196616, 0x40145b2c, 200704, 0x80000000) =
0x4014b000
SYS_fsync(4, 0x0804b438, 0x40033af8, 262144, 0x0804b438) = 0
SYS_fcntl64(4, 6, 0xbffffafc, 262144, 4) = 0
SYS_close(4) = 0
SYS_munmap(0x4014b000, 200704) = 0
<... gdbm_open resumed> ) = 0
fprintf(0x40143a40, "makedbm: Cannot open %s\n", "/tmp/x~" <unfinished
...>
[...]
2. the working case
umount /tmp
mount /dev/sda10 /tmp -o noalign
ltrace -S /usr/lib/yp/makedbm /tmp/test /tmp/x
[...]
fopen("/tmp/test", "r" <unfinished ...>
SYS_brk(NULL) = 0x0804b2b0
SYS_brk(0x0804b430) = 0x0804b430
SYS_brk(0x0804c000) = 0x0804c000
SYS_open("/tmp/test", 0, 0666) = 3
<... fopen resumed> ) = 0x0804b2b8
calloc(1, 9) = 0x0804b428
sprintf("/tmp/x~", "%s~", "/tmp/x") = 7
gdbm_open(0x0804b428, 0, 19, 384, 0 <unfinished ...>
SYS_open("/tmp/x~", 66, 0600) = 4
SYS_fstat64(4, 0xbffffa6c, 0x0804b438, 0xbffffb84, 4) = 0
SYS_fcntl64(4, 6, 0xbffffb74, 0xbffffb84, 4) = 0
SYS_brk(0x0804e000) = 0x0804e000
SYS_write(4, "\316\232W\023", 4096) = 4096
SYS_write(4, "", 4096) = 4096
SYS_write(4, "\001", 4096) = 4096
SYS_fsync(4, 0x0804b438, 0x40033af8, 0x0804b438, 0x0804b438) = 0
<... gdbm_open resumed> ) = 0x0804b438
(gdbm_open !=0 =>ok)
gdbm_store(0x0804b438, 0x08049d14, 14, 0xbffffcf8, 8 <unfinished ...>
[...]
After the first fcntl64 the two traces are different.
xfs_info /tmp
meta-data=/tmp isize=256 agcount=8, agsize=15568
blks
data = bsize=4096 blocks=124495, imaxpct=25
= sunit=16 swidth=48 blks,
unwritten=0
naming =version 2 bsize=4096
log =internal bsize=4096 blocks=4096
realtime =none extsz=65536 blocks=0, rtextents=0
Andrei
|