Subject: Re: s/mndb is not set properly
To: None <netbsd-help@netbsd.org>
From: Keith Mastin <kmastin@beechtree.ca>
List: netbsd-help
Date: 08/26/2002 14:55:26
>On Mon, 26 Aug 2002, Keith Mastin wrote:
>
>> From what I gather from man rc.conf, the rc.conf file is sourced at system
>> startup. It makes sense that the system will also source this file on
>> services, but apparently it's not.
>
>Yes, you don't have to reboot. It gets the setting each time.
>
>As for why it doesn't get the new setting, I don't know why. Maybe some
>typo. Maybe show us the relevant parts in your /etc/rc.conf file.

bash-2.05# /etc/rc.d/samba forcestart
=YES: not found
/etc/rc.d/nmbd: WARNING: $nmbd is not set properly.
/etc/rc.d/smbd: WARNING: $smbd is not set properly.

# Configuration of "wscons" console driver virtual screens.
#
wscons=YES              wscons_flags=""         # setup wscons from 
wscons.conf
nmdb=YES
smdb=YES

..and the sambe run contol file /etc/rc.d/samba:
#!/bin/sh
#
# $NetBSD: samba.sh,v 1.11 2002/05/24 22:28:27 hubertf Exp $
#
# KEYWORD: nostart

if [ -f /etc/rc.subr ]
then
        . /etc/rc.subr
fi

rcd_dir=`/usr/bin/dirname $0`

# NOTE: run_rc_command sets $rc_arg
#
forward_commands()
{
        # Backward compat with NetBSD <1.6:
        [ -z "$rc_arg" ] && rc_arg=$_arg

        for file in $COMMAND_LIST; do
                $rcd_dir/$file $rc_arg
        done
}

reverse_commands()
{
        # Backward compat with NetBSD <1.6:
        [ -z "$rc_arg" ] && rc_arg=$_arg

        REVCOMMAND_LIST=
        for file in $COMMAND_LIST; do
                REVCOMMAND_LIST="$file $REVCOMMAND_LIST"
        done
        for file in $REVCOMMAND_LIST; do
                $rcd_dir/$file $rc_arg
        done
}

COMMAND_LIST="nmbd smbd"

name="samba"
start_cmd="forward_commands"
stop_cmd="reverse_commands"
reload_cmd="forward_commands"
status_cmd="forward_commands"
extra_commands="reload status"

if [ -f /etc/rc.subr ]
then
        run_rc_command "$1"
else
        echo -n ' ${name}'
        _arg="$1"
        ${start_cmd}
fi

I don't see anything out of line in any of them, but the "=YES not found" 
is strange considering it's definitely in rc.conf.

I've been going over the docs with a fine tooth comb looking for an answer 
here, still coming up zero.

Thanx again
-- 
Keith Mastin       BeechTree Information Technology Services Inc.
137 Laird Drive    Toronto    M4G 3V5     http://www.beechtree.ca
  (416)696-6070      Fax(416)696-6072      kmastin@beechtree.ca