Federico Sevilla III
1999-Nov-15 04:34 UTC
Problem with socket options after upgrading to Samba 2.0.6
Hi there everyone, Again another slight thing I noticed since I upgraded to Samba 2.0.6 from 2.0.5a. I'm using RedHat Linux on a Celeron 400 with kernel 2.2.13. My socket options in smb.conf is set to "TCP_NODELAY IPTOS_LOWDELAY SO_KEEPALIVE SO_SNDBUF=8192 SO_RCVBUF=8192". However I've started getting the following everytime I SIGHUP to reload the configs and stop-start: [1999/11/15 12:02:41, 0] lib/util_sock.c:set_socket_options(148) Failed to set socket option SO_KEEPALIVE (Error Bad file descriptor) [1999/11/15 12:02:41, 0] lib/util_sock.c:set_socket_options(148) Failed to set socket option TCP_NODELAY (Error Bad file descriptor) [1999/11/15 12:02:41, 0] lib/util_sock.c:set_socket_options(148) Failed to set socket option IPTOS_LOWDELAY (Error Bad file descriptor) [1999/11/15 12:02:41, 0] lib/util_sock.c:set_socket_options(148) Failed to set socket option SO_KEEPALIVE (Error Bad file descriptor) [1999/11/15 12:02:41, 0] lib/util_sock.c:set_socket_options(148) Failed to set socket option SO_SNDBUF (Error Bad file descriptor) [1999/11/15 12:02:41, 0] lib/util_sock.c:set_socket_options(148) Failed to set socket option SO_RCVBUF (Error Bad file descriptor) I wonder what's up ... hmm? Any tips on at least where I can start to try and narrow down on the problem? Thanks in advance everyone!!! :-) [ Jijo Sevilla ] [ jijo@leather-collection.com ]
David Collier-Brown
1999-Nov-17 13:46 UTC
Problem with socket options after upgrading to Samba 2.0.6
Federico wrote: |Again another slight thing I noticed since I upgraded to Samba 2.0.6 ... | My socket options in smb.conf is set to "TCP_NODELAY IPTOS_LOWDELAY | SO_KEEPALIVE SO_SNDBUF=8192 SO_RCVBUF=8192". However I've started getting | the following everytime I SIGHUP to reload the configs and stop-start: | | [1999/11/15 12:02:41, 0] lib/util_sock.c:set_socket_options(148) | Failed to set socket option SO_KEEPALIVE (Error Bad file descriptor) That's odd, the message is from EBADF, "The socket argument is not a valid file descriptor". This means the fd passed in is bogus! That's a "can't happen" error and should be looked at with a debugger. See if you can attach to smbd and put a breakpoint on set_socket_options... --dave -- David Collier-Brown, | Always do right. This will gratify some people 185 Ellerslie Ave., | and astonish the rest. -- Mark Twain Willowdale, Ontario | http://java.science.yorku.ca/~davecb Work: (905) 415-2849 Home: (416) 223-8968 Email: davecb@canada.sun.com
David Collier-Brown
1999-Nov-18 12:45 UTC
Problem with socket options after upgrading to Samba 2.0.6
Federico Sevilla III wrote:> Sounds "major" but I can't understand too much of what you're saying > (sorry).Oops! Sorry about that...> I'll try to supply more information though (in case this could be > why). Has this problem got to do with the fact that I compiled my Samba > using GCC 2.95.1? Or that it's got the following optimization flags (on > compilation) set: CFLAGS="-O6 -mpentiumpro -march=pentiumpro > -malign-loops=2 -malign-jumps=2 -malign-functions=2"?The options sound Ok, can anyone on the list chack on the version? I recollect problems we had once upon a time with one release of GCC, but it was back in the summer...> Could this problem also be because of some sort of a faulty kernel? > (Although my 2.2.13 kernel has been running pretty smoothly, so far) :-) >Hmmn... The debugging suggestion amounted to compiling with -g finding out the process id (pid) with ps running dbx - <pid> , or gdb with its options putting a breakpoint on the function doing a stack trace single-stepping to where the error occurs. If you just want to **dodge** it, grab a precompiled samba and try it out: if the problem persisst, it's almost certainly the kernel, not the application. --dave -- David Collier-Brown, | Always do right. This will gratify some people 185 Ellerslie Ave., | and astonish the rest. -- Mark Twain Willowdale, Ontario | http://java.science.yorku.ca/~davecb Work: (905) 415-2849 Home: (416) 223-8968 Email: davecb@canada.sun.com