Daemon options - BSD

This is a discussion on Daemon options - BSD ; Hi There is a command to which can be passed to any daemon process in FreeBSD and it will display the rc.conf startup options eg for mysql # mysqld_safe # mysql_enable="YES" for apache # apachectl # apache22_enable="YES" ie the command ...

+ Reply to Thread
Results 1 to 4 of 4

Thread: Daemon options

  1. Daemon options

    Hi

    There is a command to which can be passed to any daemon process in
    FreeBSD and it will display the rc.conf startup options

    eg for mysql

    # mysqld_safe
    # mysql_enable="YES"

    for apache

    # apachectl
    # apache22_enable="YES"

    ie the command informs you of what you need to add to the /etc/rc.conf
    for autoload on startup

    I have used the command previously but have forgot what it is.

    Does anybody know?

    Thanks


  2. Re: Daemon options

    In article <1191177580.062470.295200@r29g2000hsg.googlegroups. com> yash
    writes:
    >
    >There is a command to which can be passed to any daemon process in
    >FreeBSD and it will display the rc.conf startup options
    >
    >eg for mysql
    >
    ># mysqld_safe
    ># mysql_enable="YES"
    >
    >for apache
    >
    ># apachectl
    ># apache22_enable="YES"
    >
    >ie the command informs you of what you need to add to the /etc/rc.conf
    >for autoload on startup
    >
    >I have used the command previously but have forgot what it is.
    >
    >Does anybody know?


    Uh, 'grep'?:-), Seriously, I've never heard of such a command, which
    doesn't mean that it doesn't exist, but I'd have to say that it seems
    a bit redundant when you can just look into the rc file (or rc.conf(5)
    or /etc/default/rc.conf for the base system stuff). To work reliably,
    I guess it requires (would require?) a standard layout of the rc file,
    such as

    # Add the following line to /etc/rc.conf to enable snmpd:
    #
    # snmpd_enable="YES"

    --Per Hedeland
    per@hedeland.org

  3. Re: Daemon options

    Per Hedeland wrote:
    > Uh, 'grep'?:-), Seriously, I've never heard of such a command, which
    > doesn't mean that it doesn't exist, but I'd have to say that it seems
    > a bit redundant when you can just look into the rc file (or rc.conf(5)
    > or /etc/default/rc.conf for the base system stuff). To work reliably,
    > I guess it requires (would require?) a standard layout of the rc file,
    > such as


    Hmm, I just found out that
    tingo@kg-work$ /usr/local/etc/rc.d/mysql-server rcvar
    # mysql
    $mysql_enable=YES

    tingo@kg-work$ /usr/local/etc/rc.d/bsdstats.sh rcvar
    # bsdstats
    $bsdstats_enable=YES

    works!

    Nice, I didn't know about that one.
    --
    Torfinn Ingolfsen,
    Norway

  4. Re: Daemon options

    In article <47013637$1@news.broadpark.no> Torfinn Ingolfsen
    writes:
    >Per Hedeland wrote:
    >> Uh, 'grep'?:-), Seriously, I've never heard of such a command, which
    >> doesn't mean that it doesn't exist, but I'd have to say that it seems
    >> a bit redundant when you can just look into the rc file (or rc.conf(5)
    >> or /etc/default/rc.conf for the base system stuff). To work reliably,
    >> I guess it requires (would require?) a standard layout of the rc file,
    >> such as

    >
    >Hmm, I just found out that
    >tingo@kg-work$ /usr/local/etc/rc.d/mysql-server rcvar
    ># mysql
    >$mysql_enable=YES
    >
    >tingo@kg-work$ /usr/local/etc/rc.d/bsdstats.sh rcvar
    ># bsdstats
    >$bsdstats_enable=YES
    >
    >works!
    >
    >Nice, I didn't know about that one.


    Hm hm:-), not precisely what the OP asked for (especially since you have
    to know the full pathname of the rc file), and while I can see that it
    could be useful for scripting automatic additions to rc.conf, I think
    I'll stick with 'less' for one-off manual usage.:-)

    --Per Hedeland
    per@hedeland.org

+ Reply to Thread