Re: rcService: command not found

2007-07-30 Thread Ralf S. Engelschall
On Tue, Jul 31, 2007, Olivier Kaloudoff wrote:

> Hello list !
> I just installed snort on current,
> but at rc.snort start, it fails with rcService: command not found.
>
> Browsing the web, it turns out that it might be a mismatch
> between snort rc scripts and openpkg ones, so I updated openpkg to
> 20070718 ..
>
> still the same problem .. any ideas ?
>
> -bash-3.00# sh -x /openpkg/etc/rc.d/rc.snort  start
> [...]

Sorry, rc.xxx are _NOT_ a regular shell scripts!
See the first "she bang" line in rc.xxx scripts:

| #!/bin/openpkg rc

So, it has to be executed through the "openpkg rc" "shell". You can't
just run "sh -x" on it as it contains RPM-style sections, etc. You have
to run it via:

$ /openpkg/bin/openpkg rc snort [...]# canonical   way
$ /openpkg/etc/rc.d/rc.snort [...]   # alternative way

   Ralf S. Engelschall
   [EMAIL PROTECTED]
   www.engelschall.com

__
OpenPKG http://openpkg.org
Developer Communication List   openpkg-dev@openpkg.org


rcService: command not found

2007-07-30 Thread Olivier Kaloudoff

Hello list !

I just installed snort on current,
but at rc.snort start, it fails with rcService: command not found.

Browsing the web, it turns out that it might be a mismatch
between snort rc scripts and openpkg ones, so I updated openpkg to
20070718 ..

still the same problem .. any ideas ?


-bash-3.00# sh -x /openpkg/etc/rc.d/rc.snort  start
+ %config
/openpkg/etc/rc.d/rc.snort: line 6: fg: no job control
+ snort_enable=
+ snort_if=
+ snort_flags='-N -Afast -o'
+ snort_log_prolog=true
+ snort_log_epilog=true
+ snort_log_numfiles=10
+ snort_log_minsize=1M
+ snort_log_complevel=9
+ snort_update_time=once
+ snort_update_source=file:///openpkg/share/snort/rules.tar.gz
+ %common
/openpkg/etc/rc.d/rc.snort: line 18: fg: no job control
+ snort_cfgfile=/openpkg/etc/snort/snort.conf
+ snort_logdir=/openpkg/var/snort
+ snort_piddir=/openpkg/var/snort
+ snort_pidfile=/openpkg/var/snort/snort_.pid
+ %status -u root -o
/openpkg/etc/rc.d/rc.snort: line 30: fg: no job control
+ snort_usable=no
+ snort_active=no
+ /openpkg/sbin/snort -q -T -u openpkg-r -g openpkg-r -i '' -c 
/openpkg/etc/snort/snort.conf -l /openpkg/var/snort

+ '[' . = . ']'
+ snort_usable=no
+ rcService snort enable yes
/openpkg/etc/rc.d/rc.snort: line 41: rcService: command not found
+ echo 'snort_enable=""'
snort_enable=""
+ echo 'snort_usable="no"'
snort_usable="no"
+ echo 'snort_active="no"'
snort_active="no"
+ %start -p 100 -u root
/openpkg/etc/rc.d/rc.snort: line 46: fg: no job control
+ rcService snort enable yes
/openpkg/etc/rc.d/rc.snort: line 47: rcService: command not found
+ exit 0
-bash-3.00# openpkg rpm -qa | egrep "snort|openpkg"
snort-2.7.0-20070714
perl-openpkg-5.8.8-20061013
openpkg-20070718-20070718
__
OpenPKG http://openpkg.org
Developer Communication List   openpkg-dev@openpkg.org