[Gluster-devel] epoll.c bug
Thierry EXCOFFIER
exco at bat710.univ-lyon1.fr
Mon Dec 10 22:00:11 UTC 2007
Anand Avati wrote:
> do you still face the issue with the latest TLA? there have been some
> changes in the epoll/poll fallback code recently.
I didn't succeed to compile the TLA sources files (autoconf problems)
So I used your link :
http://gnu.zresearch.com/~avati/glusterfs-1.3.8tla604.tar.gz
It does not work even with only one client.
It dies after 2 seconds of 'ls -R' (always a NULL pointer
in the epoll system). My previous patch does not work
for this bug.
In order to have more information, I recompiled with
option '-O0' in order to see all variables in 'gdb'.
With this option, 'glusterfsd' does NOT die with one client.
It did with 2 clients :
Program terminated with signal 11, Segmentation fault.
#0 0x00000000 in ?? ()
(gdb) where
#0 0x00000000 in ?? ()
#1 0x400368a4 in transport_notify (this=0x1b3d8, event=16) at transport.c:154
#2 0x40037570 in epoll_notify (eevent=462576, data=0x1b3d8) at epoll.c:54
#3 0x40037b0c in sys_epoll_iteration (ctx=0xbed6d9c8) at epoll.c:182
#4 0x40036d9c in poll_iteration (ctx=0xbed6d9c8) at transport.c:302
#5 0x00009c08 in main ()
(gdb) up
#1 0x400368a4 in transport_notify (this=0x1b3d8, event=16) at transport.c:154
154 return this->notify (this->xl, ev, this);
(gdb) p *this
$2 = {ops = 0x1b6f0, private = 0x0, xl_private = 0x0, lock = {__data = {
__lock = 0, __count = 0, __owner = 33, __kind = 0, __nusers = 12,
__spins = 0},
__size = "\000\000\000\000\000\000\000\000!\000\000\000\000\000\000\000\f\000\000\000\000\000\000", __align = 0},
refcount = 111408, xl = 0x1,
dnscache = 0x0, buf = 0x0, init = 0x59, peerinfo = {sockaddr = {
sin_family = 9808, sin_port = 17567, sin_addr = {s_addr = 114040},
sin_zero = "\000\000\000\000\000\000\000"}}, fini = 0, notify = 0}
(gdb) up
#2 0x40037570 in epoll_notify (eevent=462576, data=0x1b3d8) at epoll.c:54
54 ret = transport_notify (trans, event);
(gdb) up
#3 0x40037b0c in sys_epoll_iteration (ctx=0xbed6d9c8) at epoll.c:182
182 epoll_notify (ectx->evs[i].events,
(gdb) p *ctx
$1 = {pool = 0x13008, fin = 0 '\0', foreground = 0 '\0',
logfile = 0xa15c "/mnt/disk1/share/YYY/var/log/glusterfs/glusterfsd.log",
loglevel = 3, poll_type = SYS_POLL_TYPE_EPOLL, poll_ctx = 0x197b8,
timer = 0x13058, graph = 0x0, ib = 0x0, node_name = 0x0, lock = {__data = {
__lock = 0, __count = 0, __owner = 0, __kind = 0, __nusers = 0,
__spins = 0}, __size = '\0' <repeats 23 times>, __align = 0}}
(gdb) p *ectx
$6 = {epollfd = 5, fds = 4, evs = 0x53da8, ev_count = 4, lock = {__data = {
__lock = 0, __count = 0, __owner = 0, __kind = 0, __nusers = 0,
__spins = 0}, __size = '\0' <repeats 23 times>, __align = 0}, cond = {
__data = {__lock = 0, __futex = 0, __total_seq = 0, __wakeup_seq = 0,
__woken_seq = 0, __mutex = 0x0, __nwaiters = 0, __broadcast_seq = 0},
__size = '\0' <repeats 47 times>, __align = 0}}
(gdb) p i
$7 = 2
(gdb) p ret
$9 = 3
(gdb) p ectx->evs[0]
$10 = {events = 1, data = {ptr = 0x53820, fd = 342048, u32 = 342048,
u64 = 4295309344}}
(gdb) p ectx->evs[1]
$11 = {events = 0, data = {ptr = 0x11, fd = 17, u32 = 17, u64 = 17}}
(gdb) p ectx->evs[2]
$12 = {events = 462576, data = {ptr = 0x1b3d8, fd = 111576, u32 = 111576,
u64 = 475813657031640}}
====================================================================
# The server configuration (brick-afr is not used)
volume brick1
type storage/posix
option directory /mnt/disk1/gluster
end-volume
volume brick2
type features/posix-locks
subvolumes brick1
end-volume
volume brickafr
type storage/posix
option directory /mnt/disk1/glusterafr
end-volume
volume brick
type performance/io-threads
option thread-count 8
option cache-size 8MB
subvolumes brick2
end-volume
volume server
type protocol/server
subvolumes brick brickafr
option transport-type tcp/server # For TCP/IP transport
option auth.ip.brick.allow 192.168.*
end-volume
====================================================================
About the installation, the 'make install' doesn't use
the configuration --prefix argument to issue the following line :
/usr/bin/install -c 'mount.glusterfs' '/sbin/mount.glusterfs'
====================================================================
Thanks again for your work.
Thierry Excoffier.
--
Thierry.EXCOFFIER@@liris.univ-lyon1.fr// GO: Oriental Strategy Game
LIRIS/UFR Informatique, bat710 //DYLAN: Programming Language
Universite Claude Bernard LYON 1 __// UNIX: Standard Operating System
43 Bd du 11 novembre 1918 //
69622 VILLEURBANNE, FRANCE //WWW: http://www710.univ-lyon1.fr/~exco
More information about the Gluster-devel
mailing list