View previous topic :: View next topic |
Author |
Message |
fennec l33t
Joined: 30 Aug 2003 Posts: 613 Location: Montreal
|
Posted: Fri Feb 27, 2004 1:17 am Post subject: apache2 startup script error |
|
|
Getting the following error message when starting apache2
Code: | # runscript.sh apache2 start
/sbin/runscript.sh: line 1:ELF: command not found
* Starting apache2... [ ok ] |
This is my apache2 script file
/etc/init.d/apache2
Code: | #!/sbin/runscript
# Copyright 1999-2003 Gentoo Technologies, Inc.
# Distributed under the terms of the GNU General Public License v2
# $Header: /home/cvsroot/gentoo-x86/net-www/apache/files/2.0.40/apache2.initd,v 1.13 2003/10/31 07:17:45 rajiv Exp $
opts="${opts} reload"
depend() {
need net
use mysql dns logger netmount
after sshd
}
start() {
ebegin "Starting apache2"
[ -f /var/log/apache2/ssl_scache ] && rm /var/log/apache2/ssl_scache
env -i PATH=$PATH /sbin/start-stop-daemon --quiet \
--start --startas /usr/sbin/apache2 \
--pidfile /var/run/apache2.pid -- -k start ${APACHE2_OPTS}
eend $?
}
stop() {
ebegin "Stopping apache2"
/usr/sbin/apache2ctl stop >/dev/null
start-stop-daemon -o --quiet --stop --pidfile /var/run/apache2.pid
eend $?
}
reload() {
ebegin "Gracefully restarting apache2"
/usr/sbin/apache2 -t ${APACHE2_OPTS} &>/dev/null
if [ "$?" = "0" ]
then
if [ -f /var/run/apache2.pid ]
then
kill -USR1 $(</var/run/apache2.pid)
eend $?
else
svc_start
eend $?
fi
else
if [ -f /var/run/apache2.pid ]
then
svc_stop
fi
#show the error(s)
/usr/sbin/apache2 -t ${APACHE2_OPTS}
eend 1
fi
} |
|
|
Back to top |
|
|
juliancoccia Tux's lil' helper
Joined: 10 Jan 2004 Posts: 91 Location: Opensource World
|
|
Back to top |
|
|
fennec l33t
Joined: 30 Aug 2003 Posts: 613 Location: Montreal
|
Posted: Sat Mar 06, 2004 12:35 pm Post subject: |
|
|
I dont know why but i just ranned a world update and it fixed it. |
|
Back to top |
|
|
|