Current-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: Proposed new /etc/rc.d/drvctl script



On Thu, 10 Apr 2025, Paul Goyette wrote:

> > echo '$start_precmd="$start_precmd; drvctl -d pchb0' >>
> > /etc/rc.conf.d/modules
>
> Getting close...
>
> # more /etc/rc.conf.d/modules
> $start_precmd="$start_precmd; drvctl -d pchb0"
> # more /var/run/rc.log
> [/etc/rc starting at Thu Apr 10 06:17:10 PDT 2025]
> [running rcorder]
> [running /etc/rc.d/wdogctl]
> [running /etc/rc.d/fsck_root]
> Starting root file system check:
> /dev/rdk2: file system is clean; not checking
> [running /etc/rc.d/modules]
> /etc/rc.conf.d/modules: load_rc_config: =; drvctl -d pchb0: not found

modules is a shell script and you have extranous $ and missing " as the
precmd is a command

#!/bin/sh

start_precmd="modules_prestart"

modules_prestart()
{
	drvctl -d pchb0
}

would probably do it..  I don't know that you need to care about a
pre-existing start_precmd?

iain


Home | Main Index | Thread Index | Old Index