Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 5 Jan 2001 16:01:11 -0500
From:      David Banning <david@www3.pacific-pages.com>
To:        Lanny Baron <lnb@panda.FreeBSDsystems.COM>
Cc:        David <davidd@datasphereweb.com>, questions@FreeBSD.ORG
Subject:   Re: no samba with inetd start
Message-ID:  <20010105160111.B56360@www3.pacific-pages.com>
In-Reply-To: <20010103173655.A59500@panda.FreeBSDsystems.COM>; from lnb@panda.FreeBSDsystems.COM on Wed, Jan 03, 2001 at 05:36:55PM -0500
References:  <20010102195957.A4104@www3.pacific-pages.com> <20010102170656.A49769@datasphereweb.com> <20010103013318.A7718@www3.pacific-pages.com> <20010103173655.A59500@panda.FreeBSDsystems.COM>

next in thread | previous in thread | raw e-mail | index | archive | help
On Wed, Jan 03, 2001 at 05:36:55PM -0500, Lanny Baron wrote:
Thanks Lanny. That works, I know.
But I'm wondering then, how do the entries in inetd.conf
come in to play?

The entries;

netbios-ssn stream tcp nowait root /usr/local/sbin/sbbd smbd
netbios-ns dgram udp wait root /usr/local/sbin/nmbd nmbd

are shown both in "The Complete FreeBSD" Handbook and
in 
http://www.freebsddiary.org/samba.html

Any ideas?

> Hi,
> Ultimately, you want to start 'mbd' at boot time. Put the following in /usr/local/etc/rc.d as samba.sh:
> #!/bin/sh
> smbspool=/var/spool/samba
> pidfiledir=/var/run
> smbd=/usr/local/samba/bin/smbd
> nmbd=/usr/local/samba/bin/nmbd
> 
> # start
> if [ "x$1" = "x" -o "x$1" = "xstart" ]; then
>         if [ -f $smbd ]; then
>                 if [ -d $smbspool ]; then
>                         rm -f $smbspool/*
>                 fi
>                 echo -n ' Samba'
>                 $smbd -D
>                 $nmbd -D
>         fi
> 
> # stop
> elif [ "x$1" = "xstop" ]; then
>         kill `cat $pidfiledir/smbd.pid`
>         kill `cat $pidfiledir/nmbd.pid`
> fi
> 
> To be clear, if you copy the above it should be in a file with the path being:
> /usr/local/etc/rc.d/samba.sh
> 
> make sure to chmod 755 samba.sh
> 
> Hope that helps you out.
> 
> Lanny Baron
> 
> On Wed, Jan 03, 2001 at 01:33:18AM -0500, David Banning wrote:
> > On Tue, Jan 02, 2001 at 05:06:57PM -0800, David wrote:
> > > On Tue, Jan 02, 2001 at 07:59:58PM -0500, David Banning wrote:
> > > > I have recently installed samba. I seems to run fine
> > > > when I run from the shell;
> > > > 
> > > > $ smbd -D
> > > > $ nmbd -D
> > > > 
> > > > but when I run it by commenting out the entries in inetd.conf;
> > > > 
> > > > netbios-ssn stream tcp nowait root /usr/local/sbin/sbbd smbd
> > > > netbios-ns dgram udp wait root /usr/local/sbin/nmbd nmbd
> > > > 
> > > > it won't run;
> > > > 
> > > > any idea why?
> > > 
> > > I can't give you a reason why other then say "it won't work that way?" 
> > 
> > The only reason I had the belief that it would work that way was this tutorial,
> > which, other than this problem I brought forward, seemed to work great for me.
> > The tutorial shows both ways of running samba, but kind of suggests
> > that the *right* way is through inetd.
> > 
> > http://www.freebsddiary.org/samba.html
> > 
> > Anyway I will run it from rc.d as you suggest. Thanks.
> > 
> > 
> > To Unsubscribe: send mail to majordomo@FreeBSD.org
> > with "unsubscribe freebsd-questions" in the body of the message
> 
> -- 
> -------------------------------------
> Lanny Baron
> Proud to be 100% FreeBSD
> FreeBSD Systems, Inc; Freedom Technologies Corp.
> http://www.FreeBSDsystems.COM
> 1.877.963.1900
> 
> 

-- 
Never be led astray onto the path of virtue.


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-questions" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20010105160111.B56360>