Foros del Web » Administración de Sistemas » Unix / Linux »

chkconfig --add httpd... no he podido

Estas en el tema de chkconfig --add httpd... no he podido en el foro de Unix / Linux en Foros del Web. Hola, acabo de instalar httpd-2.2.19.tar.gz en OpenSuse 11.4. Todo ok. Mi idea es que cuando encienda el equipo se inicie el httpd que he instalado. ...
  #1 (permalink)  
Antiguo 23/08/2011, 21:31
 
Fecha de Ingreso: junio-2004
Ubicación: Ciudad de Panama
Mensajes: 551
Antigüedad: 19 años, 10 meses
Puntos: 8
Pregunta chkconfig --add httpd... no he podido

Hola,

acabo de instalar httpd-2.2.19.tar.gz en OpenSuse 11.4. Todo ok.

Mi idea es que cuando encienda el equipo se inicie el httpd que he instalado. Para ello cree en /etc/init.d un script httpd que contiene lo siguiente:

Código PHP:
#!/bin/bash
#
# Startup script for the Apache Web Server
#
# chkconfig: - 85 15
# description: Apache is a World Wide Web server.  It is used to serve \
#              HTML files and CGI.
# processname: httpd
# pidfile: /usr/local/apache2/logs/httpd.pid
# config: /usr/local/apache2/conf/httpd.conf

# Source function library.
. /etc/rc.d/init.d/functions

if [ -/etc/sysconfig/httpd ]; then
        
. /etc/sysconfig/httpd
fi

# This will prevent initlog from swallowing up a pass-phrase prompt if
# mod_ssl needs a pass-phrase from the user.
INITLOG_ARGS=""

# Path to the apachectl script, server binary, and short-form for messages.
apachectl=/usr/local/apache2/bin/apachectl
httpd
=/usr/local/apache2/bin/httpd
pid
=$httpd/logs/httpd.pid
prog
=httpd
RETVAL
=0


# The semantics of these two functions differ from the way apachectl does
# things -- attempting to start while running is a failure, and shutdown
# when not running is also a failure.  So we just do it the way init scripts
# are expected to behave here.
start() {
        echo -
$"Starting $prog: "
        
daemon $httpd $OPTIONS
        RETVAL
=$?
        echo
        [ 
$RETVAL ] && touch /var/lock/subsys/httpd
        
return $RETVAL
}
stop() {
        echo -
$"Stopping $prog: "
        
killproc $httpd
        RETVAL
=$?
        echo
        [ 
$RETVAL ] && rm -/var/lock/subsys/httpd $pid
}
reload() {
        echo -
$"Reloading $prog: "
        
killproc $httpd -HUP
        RETVAL
=$?
        echo
}

# See how we were called.
case "$1" in
  start
)
        
start
        
;;
  
stop)
        
stop
        
;;
  
status)
        
status $httpd
        RETVAL
=$?
        ;;
  
restart)
        
stop
        start
        
;;
  
condrestart)
        if [ -
f $pid ] ; then
                stop
                start
        fi
        
;;
  
reload)
        
reload
        
;;
  
graceful|help|configtest|fullstatus)
        
$apachectl $@
        
RETVAL=$?
        ;;
  *)
        echo $
"Usage: $prog {start|stop|restart|condrestart|reload|status"
        
echo $"|fullstatus|graceful|help|configtest}"
        
exit 1
esac

exit $RETVAL 
Al ejecutar chkconfig --add httpd me reporta el siguiente mensaje:
Código PHP:
insservwarningscript 'httpd' missing LSB tags and overrides
insserv
script httpd is not an executable regular fileskipped!
httpd 
Me podrian ayudar a solucionar esto?

Mil gracias de antemano

Un Cordial Saludo
  #2 (permalink)  
Antiguo 24/08/2011, 08:17
AlvaroG
Invitado
 
Mensajes: n/a
Puntos:
Respuesta: chkconfig --add httpd... no he podido

¿por qué no lo instalas de los repositorios? sería mucho más sencillo.

No sé lo que son las "LSB tags and overrides", pero el segundo mensaje parece debido a que el script httpd no tiene permisos de ejecución, agrégaselos.


saludos.

Etiquetas: add
Atención: Estás leyendo un tema que no tiene actividad desde hace más de 6 MESES, te recomendamos abrir un Nuevo tema en lugar de responder al actual.
Respuesta




La zona horaria es GMT -6. Ahora son las 17:29.