[CentOS] executable on /etc/rc.local doesn't start

Thu Jul 20 00:56:08 UTC 2006
Mark Quitoriano <markquitoriano at gmail.com>

hi yes it works.
when i start this manually i don't have problem but when i put the same
command on /etc/rc.local the tomcat doesn't start.

On 7/17/06, Guillermo Garron <guillermo.fedora at gmail.com> wrote:
>
> Hi,
>
> First, when you execute the command manually not in the rc.local does it
> works?
>
> if not we can start looking at the
> /var/log/messages
> to see why it is not starting.
>
>
> thanks
> Regards,
> Guillermo.
>
> On 7/17/06, ankush grover <ankushcentos at gmail.com> wrote:
>
> >
>
> On 7/17/06, Horchler, Joerg < joerg.horchler at coremedia.com> wrote:
> >
> > Do you have any logfile output? First check whether the environment
> > (JAVA_HOME for example) is set before calling
> > /usr/apache-tomcat-5.5.17/bin/startup.sh. For example
> >
> > <<<< snip
> > #!/bin/bash
> > export JAVA_HOME=/opt/jdk1.5.0_05_x86_64
> > bin/startup.sh
> > >>>> snip
> >
> > -----Ursprüngliche Nachricht-----
> > Von: centos-bounces at centos.org [mailto: centos-bounces at centos.org] Im
> > Auftrag
> > von Mark Quitoriano
> > Gesendet: Montag, 17. Juli 2006 10:22
> > An: CentOS mailing list
> > Betreff: [CentOS] executable on /etc/rc.local doesn't start
> >
> > Hi
> >
> > i installed apache tomcat on my server and put the startup on
> > /etc/rc.local
> > file so it will boot up everytime i restarted my server. But it never
> > booted
> > up i still need to run it manually what am i missing?
> >
> > here's my rc.local
> > #!/bin/sh
> > #
> > # This script will be executed *after* all the other init scripts.
> > # You can put your own initialization stuff in here if you don't # want
> > to
> > do the full Sys V style init stuff.
> >
> >
> > ntpdate -u 18.145.0.30
> >
> > /usr/local/sbin/apache-tomcat-start
> >
> > touch /var/lock/subsys/local
>
>
> Hey,
>
> Somebody has written the startup script for tomcat 4.
>
> >* -----START CUT-----
> *>*
> *>* #!/bin/sh
> *>* #
> *
> >* # Startup script for the Jakarta Tomcat Java Servlets and JSP server
> *>* #
> *>* # chkconfig: - 85 15
> *>* # description: Jakarta Tomcat Java Servlets and JSP server
> *>* # processname: tomcat
>
>
> *>* # pidfile: /var/run/tomcat.pid
> *>* # config:
> *>*
> *>* # Source function library.
> *>* . /etc/rc.d/init.d/functions
> *>*
> *>* # Source networking configuration.
>
>
> *>* . /etc/sysconfig/network
> *>*
> *>* # Check that networking is up.
> *>* [ ${NETWORKING} = "no" ] && exit 0# Set Tomcat environment.
> *>* export JAVA_HOME=/usr/local/java/j2sdk
>
>
> *>* export
> *>* CLASSPATH=.:/usr/local/java/j2sdk/lib/tools.jar:/usr/local/java/j2re/lib/rt.jar
> *>* export CATALINA_HOME=/usr/local/tomcat
> *>* export CATALINA_OPTS="-Dbuild.compiler.emacs=true
>
> "
> *>* export PATH=/usr/local/java/j2sdk/bin:/usr/local/local/j2re/bin:$PATH
> *>*
> *>* [ -f /usr/local/tomcat/bin/startup.sh ] || exit 0
> *>* [ -f /usr/local/tomcat/bin/shutdown.sh ] || exit 0
>
>
> *>*
> *>* export PATH=$PATH:/usr/bin:/usr/local/bin
> *>*
> *>* # See how we were called.
> *>* case "$1" in
> *>* start)
> *>* # Start daemon.
>
> *>* echo -n "Starting Tomcat: "
> *>* /usr/local/tomcat/bin/startup.sh
> *>* RETVAL=$?
> *>* echo
> *>* [ $RETVAL = 0 ] && touch /var/lock/subsys/tomcat
> *
>
> >* ;;
> *>* stop)
> *>* # Stop daemons.
> *>* echo -n "Shutting down Tomcat: "
> *>* /usr/local/tomcat/bin/shutdown.sh
> *>* RETVAL=$?
> *>* echo
> *
>
> >* [ $RETVAL = 0 ] && rm -f /var/lock/subsys/tomcat
> *>* ;;
> *>* restart)
> *>* $0 stop
> *>* $0 start
> *>* ;;
> *>* condrestart)
> *>* [ -e /var/lock/subsys/tomcat ] && $0 restart
>
>
> *>* ;;
> *>* status)
> *>* status tomcat
> *>* ;;
> *>* *)
> *>* echo "Usage: $0 {start|stop|restart|status}"
> *>* exit 1
> *>* esac
>
> *>*
> *>* exit 0
> *>*
> *>* -----END CUT-----
> *>*
> *>* chown root:root /etc/rc.d/init.d/tomcat
> *>*
> *>* chmod 755 /etc/rc.d/init.d/tomcat
> *
> >*
> *>* chkconfig --add tomcat
> *>*
> *>* chkconfig tomcat on
> *>*
> *>* Go to:
> http://localhost:8080
> *>*
> *>*
>  Note: It will take about 15 seconds to pull up.
> *>
>
>
>
> More informatio is available at
>
>  http://lists.centos.org/pipermail/centos/2005-October/054306.html
> >
> > Change as per your needs.
>
>
>
> Regards
>
> Ankush Grover
>
>
>
> _______________________________________________
> CentOS mailing list
> CentOS at centos.org
> http://lists.centos.org/mailman/listinfo/centos
>
>
>
>
> _______________________________________________
> CentOS mailing list
> CentOS at centos.org
> http://lists.centos.org/mailman/listinfo/centos
>
>
>


-- 
Regards,
Mark Quitoriano, CCNA

Fan the flame...
http://www.spreadfirefox.com/?q=user/register&r=19441
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.centos.org/pipermail/centos/attachments/20060720/84fd2511/attachment-0005.html>