Benoit Gauthier
2005-Oct-10 18:31 UTC
[Samba] Samba creating multiple isntances of the deamon
(2005.10.10, 14:25) I am running Samba 3.0.14a-2 on Fedora 4. I have no problem seeing the Linux file system from any of the Windows (2000, SP4) computers attached to the network. The problem is that smbd processes are created for no apparent reason and never die. I noticed this when the computer had been up for about three days and there were some 600 active smbd processes! What could be the cause of this behaviour? More importantly, what is the solution? Clearly, this is not normal behaviour! Thanks in advance for your help. Beno?t ======================================================= Beno?t Gauthier, mailto:gauthier@circum.com R?seau Circum inc. / Circum Network Inc. Nouvelles/News http://circum.com 74, rue du Val-Perch?, Gatineau, Qu?bec (Canada) J8Z 2A6 +1 819.770.2423 t?lec. fax: +1 819.770.5196 ======================================================= http://c2005.evaluationcanada.ca/ http://evaluationcanada.ca/ http://simulation.evaluationcanada.ca/
Gerald (Jerry) Carter
2005-Oct-13 13:39 UTC
[Samba] Samba creating multiple isntances of the deamon
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Benoit Gauthier wrote: | (2005.10.10, 14:25) | | I am running Samba 3.0.14a-2 on Fedora 4. I have | no problem seeing the Linux file system from | any of the Windows (2000, SP4) computers attached | to the network. | | The problem is that smbd processes are created for | no apparent reason and never die. I noticed this when | the computer had been up for about three days | and there were some 600 active smbd processes! | | What could be the cause of this behaviour? More | importantly, what is the solution? Clearly, this is | not normal behaviour! You going to need to attach with gdb or run strace to figure out what the smbd processes are doing. Will one of the long lived processes respond to kill -TERM ? You might also want to run netstat to find the IP addresses associated with the smbd processes. cheers, jerry -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.0 (GNU/Linux) Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org iD8DBQFDTmOiIR7qMdg1EfYRAnORAKDib+Uk8MA/l4rA7xy1CQQw9ZmlmgCghG8m IQQkSXSK8FJC0K65CvDYuh8=AuAy -----END PGP SIGNATURE-----
Benoit Gauthier
2005-Oct-13 19:52 UTC
[Samba] Samba creating multiple isntances of the deamon
(2005.10.13, 15:50) Here is the netstat output for SMB. What does it tell you? tcp 0 0 0.0.0.0:139 0.0.0.0:* LISTEN 0 7150985 8709/smbd tcp 0 0 0.0.0.0:445 0.0.0.0:* LISTEN 0 7150984 8709/smbd tcp 281 0 192.168.0.99:139 192.168.0.199:1531 CLOSE_WAIT 0 7115860 7758/smbd tcp 0 0 192.168.0.99:139 192.168.0.199:1552 ESTABLISHED 0 7172137 9237/smbd tcp 54 0 192.168.0.99:139 192.168.0.199:1546 CLOSE_WAIT 0 7153205 8737/smbd tcp 1 0 192.168.0.99:139 192.168.0.199:1550 CLOSE_WAIT 0 7171470 9214/smbd tcp 0 0 192.168.0.99:139 192.168.0.196:1346 ESTABLISHED 0 7171578 9222/smbd tcp 1 0 192.168.0.99:139 192.168.0.199:1540 CLOSE_WAIT 0 7134524 8211/smbd udp 0 0 127.0.0.1:39332 0.0.0.0:* 0 7115861 7758/smbd udp 0 0 127.0.0.1:39336 0.0.0.0:* 0 7134525 8211/smbd udp 0 0 127.0.0.1:39343 0.0.0.0:* 0 7153206 8737/smbd udp 0 0 127.0.0.1:39350 0.0.0.0:* 0 7171471 9214/smbd udp 0 0 127.0.0.1:39351 0.0.0.0:* 0 7171579 9222/smbd udp 0 0 127.0.0.1:39352 0.0.0.0:* 0 7172138 9237/smbd Beno?t> -----BEGIN PGP SIGNED MESSAGE----- > Hash: SHA1> Benoit Gauthier wrote: > | (2005.10.10, 14:25) > | > | I am running Samba 3.0.14a-2 on Fedora 4. I have > | no problem seeing the Linux file system from > | any of the Windows (2000, SP4) computers attached > | to the network. > | > | The problem is that smbd processes are created for > | no apparent reason and never die. I noticed this when > | the computer had been up for about three days > | and there were some 600 active smbd processes! > | > | What could be the cause of this behaviour? More > | importantly, what is the solution? Clearly, this is > | not normal behaviour!> You going to need to attach with gdb or run strace to > figure out what the smbd processes are doing. > Will one of the long lived processes respond to > kill -TERM ?> You might also want to run netstat to find the IP addresses > associated with the smbd processes.> cheers, jerry > -----BEGIN PGP SIGNATURE----- > Version: GnuPG v1.4.0 (GNU/Linux) > Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org> iD8DBQFDTmOiIR7qMdg1EfYRAnORAKDib+Uk8MA/l4rA7xy1CQQw9ZmlmgCghG8m > IQQkSXSK8FJC0K65CvDYuh8> =AuAy > -----END PGP SIGNATURE-----
Gerald (Jerry) Carter
2005-Oct-13 23:37 UTC
[Samba] Samba creating multiple isntances of the deamon
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Benoit Gauthier wrote: | (2005.10.13, 15:50) | | Here is the netstat output for SMB. What does it tell you? CLOSE_WAIT means that the process is waiting for a socket to shutdown. I think you have a client connecting and disconnecting rapidly. Network browsing perhaps? What is the client at 192.168.0.199? ciao, jerry -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.0 (GNU/Linux) Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org iD8DBQFDTvAEIR7qMdg1EfYRArpxAJ47oTlHKok7062XzT+XLpfRlG9hbQCgvSg4 3ICUAf9kmnjdD7LvaVT5CRk=WSJn -----END PGP SIGNATURE-----
Benoit Gauthier
2005-Oct-14 00:37 UTC
[Samba] Samba creating multiple isntances of the deamon
(2005.10.13, 20:32)> CLOSE_WAIT means that the process is waiting for a socket to > shutdown. I think you have a client connecting and disconnecting > rapidly. Network browsing perhaps?> What is the client at 192.168.0.199?That client is a Windows 2000 desktop which is 99% reserved for backup purposes. It connects to a local Linux computer (192.168.0.99) via Samba (using a mapped drive, of course) and then addresses four NFS mounts to get new and updated files off four distant servers. When Samba goes real crazy with process creations, there is one created every minute during a backup sequence which lasts about 30 minutes. This happens four times a day since the backup software is set up to do backups every six hours. Your help is most appreciated. Beno?t
Gerald (Jerry) Carter
2005-Oct-14 14:15 UTC
[Samba] Samba creating multiple isntances of the deamon
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Benoit Gauthier wrote: | (2005.10.14, 09:59) | |> Is the machine accessing the Samba server via unc path name? You |> might want to try it as a mapped drive. | | It is already accessed via a mapped drive. Can you send me an ethereal trace of a backup (off-list)? What is the name of the backup software? cheers, jerry -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.0 (GNU/Linux) Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org iD4DBQFDT72lIR7qMdg1EfYRArJGAJ4v5DBjjxDZjsbzI3+1fjJm0RT7jgCYg4T9 BzbRKM1HCXFQ9alG5zFRwQ==HR1U -----END PGP SIGNATURE-----
Benoit Gauthier
2005-Oct-17 12:19 UTC
[Samba] Samba creating multiple isntances of the deamon
(2005.10.17, 08:11)> Will one of the long lived processes respond to kill -TERM ?All processes die after a "killall -9 smbd" even though the oldest one takes several seconds to do so. I have additional problems which appear to be associated with version 3.0.20b since I did not experience them before installing it (I used to run the version which comes with Fedora 4, 3.0.14 is it?): after a clear start of the Samba service, I can run my 4-server backup job on the Windows computer without problem. However, when the backup job is started again (automatically, 6 hours later, or manually) various directories on at least one of the servers do not return a file list and time out the backup process. If I stop Samba and re-start it, everything is back to normal... for one iteration of the backup. What additional information would be useful to diagnose the problem? Is there a way to retrofit to the previous version of Samba? Beno?t ======================================================= Beno?t Gauthier, mailto:gauthier@circum.com R?seau Circum inc. / Circum Network Inc. Nouvelles/News http://circum.com 74, rue du Val-Perch?, Gatineau, Qu?bec (Canada) J8Z 2A6 +1 819.770.2423 t?lec. fax: +1 819.770.5196 ======================================================= http://c2005.evaluationcanada.ca/ http://evaluationcanada.ca/ http://simulation.evaluationcanada.ca/
Jeremy Allison
2005-Oct-17 15:35 UTC
[Samba] Samba creating multiple isntances of the deamon
On Mon, Oct 17, 2005 at 08:17:43AM -0400, Benoit Gauthier wrote:> (2005.10.17, 08:11) > > > Will one of the long lived processes respond to kill -TERM ? > > All processes die after a "killall -9 smbd" even though the oldest one > takes several seconds to do so.Never kill smbd with -9. It can leave important tdb files in a corrupt state. Jeremy.
Barry, Christopher
2005-Oct-17 15:41 UTC
[Samba] Samba creating multiple isntances of the deamon
is simply 'killall smbd' the preferre invocation? -C> -----Original Message----- > From: Jeremy Allison [mailto:jra@samba.org] > Sent: Monday, October 17, 2005 11:29 AM > To: Benoit Gauthier; g@samba.org > Cc: samba@lists.samba.org; Gerald (Jerry) Carter > Subject: Re: [Samba] Samba creating multiple isntances of the deamon > > On Mon, Oct 17, 2005 at 08:17:43AM -0400, Benoit Gauthier wrote: > > (2005.10.17, 08:11) > > > > > Will one of the long lived processes respond to kill -TERM ? > > > > All processes die after a "killall -9 smbd" even though the > oldest one > > takes several seconds to do so. > > Never kill smbd with -9. It can leave important tdb files in a > corrupt state. > > Jeremy. > -- > To unsubscribe from this list go to the following URL and read the > instructions: https://lists.samba.org/mailman/listinfo/samba >
William Jojo
2005-Oct-17 15:44 UTC
[Samba] Samba creating multiple isntances of the deamon
----- Original Message ----- From: "Jeremy Allison" <jra@samba.org> To: "Benoit Gauthier" <gauthier@circum.com>; <g@samba.org> Cc: <samba@lists.samba.org>; "Gerald (Jerry) Carter" <jerry@samba.org> Sent: Monday, October 17, 2005 11:29 AM Subject: Re: [Samba] Samba creating multiple isntances of the deamon> On Mon, Oct 17, 2005 at 08:17:43AM -0400, Benoit Gauthier wrote: > > (2005.10.17, 08:11) > > > > > Will one of the long lived processes respond to kill -TERM ? > > > > All processes die after a "killall -9 smbd" even though the oldest one > > takes several seconds to do so. > > Never kill smbd with -9. It can leave important tdb files in a > corrupt state.I have also experienced OpenLDAP related problems from smbd being killed with -9 that required db_recover to be run before slapd would restart nicely with BerkeleyDB. Never use -9!! Cheers, Bill> > Jeremy. > -- > To unsubscribe from this list go to the following URL and read the > instructions: https://lists.samba.org/mailman/listinfo/samba >
Benoit Gauthier
2005-Oct-18 14:51 UTC
[Samba] Samba creating multiple isntances of the deamon
(2005.10.18, 10:48)> Never kill smbd with -9. It can leave important tdb files in a > corrupt state.So, what is the right way to kill smbd altogether? Until a solution is found to the current problem, I need to start it afresh so that my back-ups will take place. Thanks in advance. Beno?t
Benoit Gauthier
2005-Oct-19 11:38 UTC
[Samba] Samba creating multiple isntances of the deamon
(2005.10.19, 07:36)>> OK. I've figured out how to do it. Which of the numerous Samba >> processes should I do this on though?> On one of those you've tried to kill with a normal kill command but > hasn't died....Here is such an output. Beno?t Attaching to program: /usr/sbin/smbd, process 3456 (no debugging symbols found) Loaded symbols for /usr/sbin/smbd Reading symbols from /usr/lib/libldap-2.2.so.7...(no debugging symbols found)...done. Loaded symbols for /usr/lib/libldap-2.2.so.7 Reading symbols from /usr/lib/liblber-2.2.so.7...(no debugging symbols found)...done. Loaded symbols for /usr/lib/liblber-2.2.so.7 Reading symbols from /usr/lib/libgssapi_krb5.so.2...(no debugging symbols found)...done. Loaded symbols for /usr/lib/libgssapi_krb5.so.2 Reading symbols from /usr/lib/libkrb5.so.3...(no debugging symbols found)...done. Loaded symbols for /usr/lib/libkrb5.so.3 Reading symbols from /usr/lib/libk5crypto.so.3... (no debugging symbols found)...done. Loaded symbols for /usr/lib/libk5crypto.so.3 Reading symbols from /usr/lib/libkrb5support.so.0...(no debugging symbols found)...done. Loaded symbols for /usr/lib/libkrb5support.so.0 Reading symbols from /lib/libcom_err.so.2...(no debugging symbols found)...done. Loaded symbols for /lib/libcom_err.so.2 Reading symbols from /lib/libresolv.so.2...(no debugging symbols found)...done. Loaded symbols for /lib/libresolv.so.2 Reading symbols from /usr/lib/libcups.so.2... (no debugging symbols found)...done. Loaded symbols for /usr/lib/libcups.so.2 Reading symbols from /lib/libssl.so.5...(no debugging symbols found)...done. Loaded symbols for /lib/libssl.so.5 Reading symbols from /lib/libcrypto.so.5...(no debugging symbols found)...done. Loaded symbols for /lib/libcrypto.so.5 Reading symbols from /lib/libnsl.so.1...(no debugging symbols found)...done. Loaded symbols for /lib/libnsl.so.1 Reading symbols from /lib/libcrypt.so.1... (no debugging symbols found)...done. Loaded symbols for /lib/libcrypt.so.1 Reading symbols from /lib/libpam.so.0...(no debugging symbols found)...done. Loaded symbols for /lib/libpam.so.0 Reading symbols from /lib/libattr.so.1...done. Loaded symbols for /lib/libattr.so.1 Reading symbols from /lib/libacl.so.1...done. Loaded symbols for /lib/libacl.so.1 Reading symbols from /lib/libdl.so.2...done. Loaded symbols for /lib/libdl.so.2 Reading symbols from /usr/lib/libpopt.so.0...done. Loaded symbols for /usr/lib/libpopt.so.0 Reading symbols from /lib/libc.so.6...done. Loaded symbols for /lib/libc.so.6 Reading symbols from /usr/lib/libsasl2.so.2...done. Loaded symbols for /usr/lib/libsasl2.so.2 Reading symbols from /usr/lib/libz.so.1...done. Loaded symbols for /usr/lib/libz.so.1 Reading symbols from /lib/libaudit.so.0...done. Loaded symbols for /lib/libaudit.so.0 Reading symbols from /lib/ld-linux.so.2...done. Loaded symbols for /lib/ld-linux.so.2 Reading symbols from /usr/lib/gconv/UTF-16.so...done. Loaded symbols for /usr/lib/gconv/UTF-16.so Reading symbols from /usr/lib/gconv/IBM850.so...done. Loaded symbols for /usr/lib/gconv/IBM850.so Reading symbols from /lib/libnss_files.so.2...done. Loaded symbols for /lib/libnss_files.so.2 0x007d1402 in ?? () (gdb) bt #0 0x007d1402 in ?? () #1 0x005e40a6 in flock () from /lib/libc.so.6 #2 0x0098cb52 in open_file_ntcreate () from /usr/sbin/smbd #3 0x0095c105 in reply_ntcreate_and_X () from /usr/sbin/smbd #4 0x009a200f in push_oplock_pending_smb_message () from /usr/sbin/smbd #5 0x009a2668 in process_smb () from /usr/sbin/smbd #6 0x009a2aa2 in smbd_process () from /usr/sbin/smbd #7 0x00b5e970 in main () from /usr/sbin/smbd (gdb)