Re: [users@httpd] start at boottime??

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

 



dan wrote:

RYAN vAN GINNEKEN wrote:

What? Freebsd does not even have an inittab does anyone else have any ideas?


PINNI, BALANAND (SBCSI) wrote:

Put startup script in /etc/inittab.

Balanand Pinni
23-H-4
SBC Services Inc
OBC ,Stl MO
*   314-206-5911
* bp3965@xxxxxxxxxxxxxx
* 1- 800- 451- 6897




-----Original Message-----
From: RYAN vAN GINNEKEN [mailto:luck@xxxxxxxxxxxxxxx] Sent: Thursday, February 17, 2005 9:13 PM
To: users@xxxxxxxxxxxxxxxx
Subject: [users@httpd] start at boottime??

How come my apache does not start at boot time? I have the following
files in my rc.d

-r-xr-xr-x  1 root  wheel   2063 Feb 17 19:19 apache.sh
-r-xr-xr-x  1 root  wheel   2063 Feb 17 19:27 apache2.sh

even went so far as to create an apache2.sh the contents of the file are

below.  Have added the following lines to
my /etc/rc.conf the only way i can get apache to start is to type
apachectl startssl or to modify the apache.sh and apache2.sh scripts and
change the default values from NO to YES.  Running freebsd 4.10 and
apache 2.0.52

apache2_enabled="YES"
apache2ssl_enabled="YES"


#!/bin/sh
#
# $FreeBSD: ports/www/apache2/files/apache.sh,v 1.11 2005/01/11 13:45:05
clement Exp $
#

# PROVIDE: apache2
# REQUIRE: NETWORKING SERVERS
# BEFORE: DAEMON
# KEYWORD: FreeBSD shutdown

#
# Add the following lines to /etc/rc.conf to enable apache2:
# apache2_enable (bool):      Set to "NO" by default.
#                             Set it to "YES" to enable apache2
# apache2ssl_enable (bool):   Set to "NO" by default.
#                             Set it to "YES" to start apache with SSL
#                             (if <IfDefined SSL> exists in httpd.conf)
# apache2limits_enable (bool):Set to "NO" by default.
# Set it to yes to run `limits $limits_args`
#                             just before apache starts.
# apache2_flags (str):        Set to "" by default.
#                             Extra flags passed to start command.
# apache2limits_args (str):   Default to "-e -C daemon"
#                             Arguments of pre-start limits run.
#
. %%RC_SUBR%%

name="apache2"
rcvar=`set_rcvar`

start_precmd="apache2_precmd"
restart_precmd="apache2_checkconfig"
reload_precmd="apache2_checkconfig"
command="%%PREFIX%%/sbin/httpd"
pidfile="/var/run/httpd.pid"
required_files=%%PREFIX%%/etc/apache2/httpd.conf

[ -z "$apache2_enable" ]       && apache2_enable="NO"
[ -z "$apache2ssl_enable" ]    && apache2ssl_enable="NO"
[ -z "$apache2_flags" ]        && apache2_flags=""
[ -z "$apache2limits_enable" ] && apache2limits_enable="NO"
[ -z "$apache2limits_args" ]   && apache2limits_args="-e -C daemon"

load_rc_config $name

checkyesno apache2ssl_enable && \
                       apache2_flags="-DSSL $apache2_flags"

apache2_checkconfig()
{
       echo "Performing sanity check on apache2 configuration:"
       ${command} ${apache2_flags} -t
}

apache2_precmd()
{
       if test -f %%PREFIX%%/sbin/envvars
       then
               . %%PREFIX%%/sbin/envvars
       fi
       if checkyesno apache2limits_enable
       then
               eval `/usr/bin/limits ${apache2limits_args}` 2>/dev/null
       else
               return 0
       fi

}

sig_reload=SIGUSR1

extra_commands="reload"
run_rc_command "$1"



Please bottom-post.

FreeBSD has an rc.conf, and it works if you installed Apache from ports. Looks like you have done that, however.

You can also drop your init scripts into /usr/local/etc/rc.d and they will be executed upon boot-up.

did you read my message ? read it again please and tell me something that can help me


...and don't put stuff in /etc/inittab.  that's bad.

Hope that helps

no help but thanks already

-dant

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx
  "   from the digest: users-digest-unsubscribe@xxxxxxxxxxxxxxxx
For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx



---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx
  "   from the digest: users-digest-unsubscribe@xxxxxxxxxxxxxxxx
For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx



[Index of Archives]     [Open SSH Users]     [Linux ACPI]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Squid]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]

  Powered by Linux