Hello Alex, On Tue, Jan 20, 2004, [EMAIL PROTECTED] wrote: > I found in the doc that you use th rc script to manage things like that, > but I could not understand how I set up a service to start at runlevel N > and how do I check if a service is active (equivalent of: > /etc/init.d/named status). > The OpenPKG equivalent would be:
# cd /opkg/etc # ./rc bind status OpenPKG: status: bind. bind_enable="yes" bind_usable="yes" bind_active="yes" You type 'bind' and not 'named', because in /opkg/etc/rc.d/ there is a file called 'rc.bind' and not 'rc.named'. Do you follow that? Also, you can type 'status', 'start', 'stop', and so on. To learn which labels you can use, simply look at the file 'rc.bind' in this case. > I saw that in my /etc/init.d now is the opkg script that starts 'all' > OpenPKG, but how I specify what 'all' should be for this runlevel ? > Remember that in OSs which use SVR4 init scripts (Solaris, Linux...) the files under /etc/rc?.d are the ones that count. So check out your /etc/rc3.d directory for example, and you will see a file 'S99opkg'. Unfortunately, the run command processor is not yet mature enough to handle multiple packages at once. That means that for more granular control of what packages are started you must use multiple calls (rc bind start; rc ntp status; rc apache restart...). It sounds like you want only certain packages to start automatically. To do this you have add lines 'sasl_enable="no"', 'arpd_enable="no"'... to your '/opkg/etc/rc.conf' file, causing these daemons to never react to rc commands. If you want both granular and conditional manipulation of your daemons controlled by each individual run level, then some serious hacking is needed. The 'rc.conf' file can be left alone in this case, but you'll have to modify the 'S99opkg' and 'K00opkg' scripts installed during bootstrap time. This last approach is not advisable however, because the init scripts are not preserved in bootstrap updates. Please use the 'rc.conf' variant instead, even if it means some manual work each time you change run levels. Regards, Michael -- [EMAIL PROTECTED] Development Team, Operations Northern Europe Cable & Wireless Telecommunications Services GmbH
pgp00000.pgp
Description: PGP signature
