[Samba] smbd and nmbd

Joel Hammer Joel at HammersHome.com
Thu Mar 14 04:25:03 GMT 2002


If I follow this, you had smbd and nmbd in your inetd.conf file.
If so, the inetd was watching those ports.  This is not the suggested
arrangement.

It is easy to make a startup script for these two daemons. Here is the
script that I use.

#!/bin/bash
case "$1" in
 start)        
  killall smbd
  killall nmbd
/usr/local/samba/bin/smbd -D
/usr/local/samba/bin/nmbd -D
  ;;

 stop)
  killall smbd
  killall nmbd
 ;;
 reload)
 kill -SIGHUP `cat /usr/local/samba/var/locks/smbd.pid`
 kill -SIGHUP `cat /usr/local/samba/var/locks/nmbd.pid`
 ;;
 *)
 echo Usage: 
 echo start stop reload
 ;;
esac
exit 0


There may already be a samba startup script around on your box.

The location of your binaries and lock files might be different from mine. I
used the tarball from samba.org and accepted the defaults.

If you don't want to mess around with leaning about run levels and all, and
just want a quick and dirty solution, put this script into your equivalent
of rc.local. If you need help on figuring out how to make startup scripts
start and stop daemons at various run levels, post again.

Joel



> I had a problem were smbd wouldn't start, it always give me an error message
> in the log file.
>  
> standard input is not a socket, assuming -D option
> bind failed on port 139 socket_addr=0.0.0.0 (Address already in use)
> 
> So I stopped the TCP Daemons and tried to start it and it worked.
>  
> So I took both entry's out of the inetd.conf file (nmbd and smbd) and
> restarted the server.  Obviously they didn't start automatically.
>  
> But when I went to started them manually, they both worked fine.
>  
> So my question is, is there any other way of automatically starting them at
> start-up.
>  
> Cheers
>  
> Carl
> 
> -- 
> To unsubscribe from this list go to the following URL and read the
> instructions:  http://lists.samba.org/mailman/listinfo/samba




More information about the samba mailing list