Hi. I'm getting messages to the effect: Inetd: /usr/local/samba/lib/nmbd: Hangup Last messages repeat 319 times I start samba from inetd. Should I be starting it as a daemon or starting it in init.d? If starting it as a daemon in in init.d, does someone have a script that can let me use? I'm running samba on an a Sun E450, with Solaris 2.7. Thanks. grant
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
> So my question is, is there any other way of automatically starting them at > start-up.Try to start them from /etc/init.d/samba (included in most distributions). Jelmer -- Jelmer Vernooij <jelmer@nl.linux.org> - http://nl.linux.org/~jelmer/ Development And Underdevelopment: http://library.thinkquest.org/C0110231/ 13:10:01 up 6 days, 15:54, 23 users, load average: 1.28, 1.25, 1.27
> I have know file called init.d or directory. I' using AIX if that makes an > difference..just starting `which smbd` and `which nmbd` in your init should fit. Jelmer -- Jelmer Vernooij <jelmer@nl.linux.org> - http://nl.linux.org/~jelmer/ Development And Underdevelopment: http://library.thinkquest.org/C0110231/ Listening to Radio 3FM 13:48:06 up 6 days, 16:32, 23 users, load average: 1.52, 1.44, 1.33
I don't think those lock files are around unless the daemons are running. And, depending on how the daemons were compiled, they might be in several locations. Where have you looked? Have you tried locate smbd.pid? There is a /var/lock/samba directory on my system left over, I believe, from my original distro specific installation of samba. Joel On Thu, Mar 14, 2002 at 03:08:14PM +0100, Routledge, Carl wrote:> Thanks for sending this replay, it looks like exactly what I need. But I > have little problem, I have got the smbd.pid and nmbd.pid files. I looked > in the lock directory and they aren't there. > > > > -----Original Message----- > From: Joel Hammer [ mailto:Joel@HammersHome.com > <mailto:Joel@HammersHome.com> ] > Sent: Thursday, March 14, 2002 12:11 > To: Routledge, Carl; samba@lists.samba.org > Subject: Re: [Samba] smbd and nmbd > > > 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 > <http://lists.samba.org/mailman/listinfo/samba> >
I started the daemons and they still didn't appear. Mine version of Samba is a fairly old one 1.9 something and it was and installp (AIX) file. I did a find in the root directory (/) and searched for *.pid. On my system it is /var/samba/locks. Do you have to have a certain version of AIX to be able to use the latest Samba?? Cheers Carl -----Original Message----- From: Joel Hammer [ mailto:Joel@HammersHome.com <mailto:Joel@HammersHome.com> ] Sent: Thursday, March 14, 2002 14:33 To: Routledge, Carl; samba@lists.samba.org Subject: Re: [Samba] smbd and nmbd I don't think those lock files are around unless the daemons are running. And, depending on how the daemons were compiled, they might be in several locations. Where have you looked? Have you tried locate smbd.pid? There is a /var/lock/samba directory on my system left over, I believe, from my original distro specific installation of samba. Joel On Thu, Mar 14, 2002 at 03:08:14PM +0100, Routledge, Carl wrote:> Thanks for sending this replay, it looks like exactly what I need. But I > have little problem, I have got the smbd.pid and nmbd.pid files. I looked > in the lock directory and they aren't there. > > > > -----Original Message----- > From: Joel Hammer [ mailto:Joel@HammersHome.com<mailto:Joel@HammersHome.com>> < mailto:Joel@HammersHome.com <mailto:Joel@HammersHome.com> > ] > Sent: Thursday, March 14, 2002 12:11 > To: Routledge, Carl; samba@lists.samba.org > Subject: Re: [Samba] smbd and nmbd > > > 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<http://lists.samba.org/mailman/listinfo/samba>> < http://lists.samba.org/mailman/listinfo/samba<http://lists.samba.org/mailman/listinfo/samba> >>
Yeah I run smbd from command line as root and there isn't any errors it runs. Any idea on the *.pid files or version. Cheers Carl -----Original Message----- From: Joel Hammer [ mailto:Joel@HammersHome.com <mailto:Joel@HammersHome.com> ] Sent: Thursday, March 14, 2002 15:02 To: Routledge, Carl; samba@lists.samba.org Subject: Re: [Samba] smbd and nmbd When you run smbd -D from the command line, as root if possible, do any error messages show up? If you don't have root priviledges on your machine, you will not be able to bind port 139. Joel P.S. I use linux. On Thu, Mar 14, 2002 at 03:57:08PM +0100, Routledge, Carl wrote:> I started the daemons and they still didn't appear. > > Mine version of Samba is a fairly old one 1.9 something and it was and > installp (AIX) file. > > I did a find in the root directory (/) and searched for *.pid. > > On my system it is /var/samba/locks. > > Do you have to have a certain version of AIX to be able to use the latest > Samba?? > > Cheers > > Carl > > > > -----Original Message----- > From: Joel Hammer [ mailto:Joel@HammersHome.com<mailto:Joel@HammersHome.com>> < mailto:Joel@HammersHome.com <mailto:Joel@HammersHome.com> > ] > Sent: Thursday, March 14, 2002 14:33 > To: Routledge, Carl; samba@lists.samba.org > Subject: Re: [Samba] smbd and nmbd > > > I don't think those lock files are around unless the daemons are running. > And, depending on how the daemons were compiled, they might be in several > locations. > Where have you looked? > Have you tried locate smbd.pid? > There is a /var/lock/samba directory on my system left over, I believe,from> my original distro specific installation of samba. > Joel > > On Thu, Mar 14, 2002 at 03:08:14PM +0100, Routledge, Carl wrote: > > Thanks for sending this replay, it looks like exactly what I need. ButI> > have little problem, I have got the smbd.pid and nmbd.pid files. Ilooked> > in the lock directory and they aren't there. > > > > > > > > -----Original Message----- > > From: Joel Hammer [ mailto:Joel@HammersHome.com<mailto:Joel@HammersHome.com>> < mailto:Joel@HammersHome.com <mailto:Joel@HammersHome.com> > > > < mailto:Joel@HammersHome.com <mailto:Joel@HammersHome.com> <mailto:Joel@HammersHome.com <mailto:Joel@HammersHome.com> > > ]> > Sent: Thursday, March 14, 2002 12:11 > > To: Routledge, Carl; samba@lists.samba.org > > Subject: Re: [Samba] smbd and nmbd > > > > > > 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 frommine.> 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 yourequivalent> > of rc.local. If you need help on figuring out how to make startupscripts> > 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 startingthem> > 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<http://lists.samba.org/mailman/listinfo/samba>> < http://lists.samba.org/mailman/listinfo/samba<http://lists.samba.org/mailman/listinfo/samba> >> > < http://lists.samba.org/mailman/listinfo/samba<http://lists.samba.org/mailman/listinfo/samba>> < http://lists.samba.org/mailman/listinfo/samba<http://lists.samba.org/mailman/listinfo/samba> > >> > >
Hiya! We start them from inetd. The difference we found was in some syntax in the /etc/services file. This is on HP-UX 11.0, YMMV. This doesn't work, notice the underbar in the service name (default HP entries) netbios_ns 137/tcp # NetBIOS Name Service netbios_ns 137/udp # netbios_dgm 138/tcp # NetBIOS Datagram Service netbios_dgm 138/udp # netbios_ssn 139/tcp # NetBIOS Session Service netbios_ssn 139/udp # And this works (note the hyphen in the service name) # Samba netbios daemons netbios-ssn 139/tcp # Samba netbios-ns 137/udp # Samba inetd -c and they started perfectly. HTH/HAND, Mike With every halting step I take, I hang by a thread that will not break -- Phil Keaggy> ---------- > From: Routledge, Carl[SMTP:Carl.Routledge@ucb-group.com] > > 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 >