Using an init script that cd's to $JBOOS_HOME/bin will indeed start
the service as desired. However, on the linux I have tried sending a
kill signal
to the initiating script will not stop the java processes spawned by the
start
script, as suggested for example in the FAQ. In addition, since I prefer
to have jboss run in the background, I have to target one of the java
process launched to cleanly shutdown jboss . It seems that one needs to
send a kill signal (1, 9 and 15 all work) to any of the java processus
launched by jboss at startup. I haven't tried the port 8082 solution
yet, but I would prefer to find a java solution. I have not found the "
stop.jar" .  Can someone shed some light on how to initiate jboss
shutdown?

Chris

>
>
> Does the Simple Web Server on 8082 bind to all NIC's cause I see this
> as a possible security problem. Obviously there is no Authentication
> to shutdown or am I missing the point ??
>
> Regards
>
> Scott Warren
> Lead Internet Technologies Developer
>
> ----------------------------------------------------------------------------
>
> Phone: +61 3 5222 6240
> mailto:  [EMAIL PROTECTED]
> web:     www.advancedresource.com.au
>
> ----------------------------------------------------------------------------
>
> -----Original Message-----
> From: Tom Cook [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, 6 February 2001 10:02 AM
> To: jBoss
> Subject: RE: [jBoss-User] Starting jBoss as a service on Linux
>
> Why use a PID file and kill when you there is a 'stop.jar' (admittedly
> this has
> a hardcoded name which doesn't seem to be correct, though this may
> have been
> fixed) or you can just connect to port 8082 and stuff a string like:
>
> GET
> /InvokeAction//DefaultDomain%3Atype%3DShutdown/action=shutdown?shutdown=true
> HTTP/1.0
>
> into the socket?
>
> Tom
>
> On Tue, 06 Feb 2001, you wrote:
> > You have to create it.  Here's an example of what I have used on
> RedHat 6.2.
> > Put this in a file called /etc/rc.d/init.d/jboss and change all the
> > NAMEOFSERVER's to jboss.  You'll have to create a stopServer.sh
> script to
> > kill it (just catch the pid to a file in run.sh and then kill -9
> $(cat
> > /path/to/pid/file) ).  Then you must create symbolic links to this
> file in
> > each of the rc?.d directories under /etc/rc.d.  Startup scripts
> start with S
> > and kill scripts start with K.  Take a look at cron or ipchains for
> an
> > example.  Again I haven't tried setting this up explicity for jboss
> yet, but
> > it works for another pure java server I wrote.
> >
> > #! /bin/sh
> > #
> > # NAMEOFSERVER -  Start and Stop NAMEOFSERVER daemon
> > #
> > # description: bla bla bla bla
> > #
> >
> > # Source function library.
> > . /etc/rc.d/init.d/functions
> > eexport PATH=$PATH:path/to/server:/usr/java/jdk1.3/bin
> > cd /path/to/server
> >
> > RETVAL=0
> >
> > # See how we were called.
> > case "$1" in
> >   start)
> >         echo -n "Starting NAMEOFSERVER daemon: "
> >         daemon /path/to/server/run.sh
> >         RETVAL=$?
> >         echo
> >         [ $RETVAL -eq 0 ] && touch /var/lock/subsys/NAMEOFSERVER
> >         ;;
> >   stop)
> >         echo -n "Stopping NAMEOFSERVER daemon: "
> >         daemon /path/to/server/stopServer.sh
> >         RETVAL=$?
> >         echo
> >         [ $RETVAL -eq 0 ] && rm -f /var/lock/subsys/NAMEOFSERVER
> >         ;;
> >   restart)
> >         echo -n "Stopping NAMEOFSERVER daemon: "
> >         deamon /path/to/server/stopServer.sh
> >         RETVAL=$?
> >         echo
> >         [ $RETVAL -eq 0 ] && rm -f /var/lock/subsys/NAMEOFSERVER
> >         echo -n "Starting NAMEOFSERVER daemon: "
> >         deamon /path/to/server/run.sh
> >         RETVAL=$?
> >         echo
> >         [ $RETVAL -eq 0 ] && touch /var/lock/subsys/NAMEOFSERVER
> >         ;;
> >   *)
> >         echo "Usage: NAMEOFSERVER {start|stop|restart}"
> >         exit 1
> > esac
> > exit $RETVAL
> >
> > > -----Original Message-----
> > > From: [EMAIL PROTECTED]
> > > [mailto:[EMAIL PROTECTED]]On Behalf Of Tim Yates
> > > Sent: Monday, February 05, 2001 10:03 AM
> > > To: jBoss
> > > Subject: Re: [jBoss-User] Starting jBoss as a service on Linux
> > >
> > >
> > > > have you tried putting
> > > >     cd $JBOSS_HOME/bin
> > > > at the top of your init.d script?
> > > >
> > > > I haven't setup jboss this way yet, but I have another pure java
> server
> > > that
> > > > I just recently had to do the same thing for.
> > > >
> > >
> > > Where can I grab an init.d script and info on how to install
> it...?
> > >
> > > I am tired of searching for "run.sh" in the ps -A list and finding
> the
> > > closest java instance to that ;-)
> > >
> > > Hacky, hacky, hacky!!!
> > >
> > > Tim.
> > >



--
--------------------------------------------------------------
To subscribe:        [EMAIL PROTECTED]
To unsubscribe:      [EMAIL PROTECTED]
List Help?:          [EMAIL PROTECTED]

Reply via email to