You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Theodore Andreadis <an...@hnms.gr> on 2001/04/21 02:41:43 UTC

Preventing Tomcat shutDown by ordinary users

******************* In Linux:

I run experimentally Tomcat my pc, under redHat7. I start Tomcat in rc5.d
(only) with the
script command:

start() {
 daemon `cat /opt/tomcat/bin/start.txt`&

where start.txt contains the line:
  java -cp /opt/tomcat/lib/ -Dtomcat.home=/opt/tomcat/ -Djava.home=/opt/java
org.apache.tomcat.startup.Tomcat

(I have expanded the jars in lib) and works just fine, except that:

even as an ordinary user I can shut it down running the
  java -cp /opt/tomcat/lib/ -Dtomcat.home=/opt/tomcat
org.apache.tomcat.startup.Tomcat -stop

What am I doing wrong? How can I enable only root to shutdown Tomcat?


******************* In Server 2000:

I run the startup.bat as a system service, under SYSTEM account (using a
resource toolkit
utility that adds the registry instruction in the registry, to run a program
as a service)
The problem is that although Tomcat starts at system boot, it stops when the
first log off
is performed (under any account). Is there a way to prevent this?


how can I unsubscribe from this list

Posted by Dana Marcusanu <dm...@yahoo.com>.
--- Theodore Andreadis <an...@hnms.gr> wrote:
> ******************* In Linux:
> 
> I run experimentally Tomcat my pc, under redHat7. I start Tomcat in
> rc5.d
> (only) with the
> script command:
> 
> start() {
>  daemon `cat /opt/tomcat/bin/start.txt`&
> 
> where start.txt contains the line:
>   java -cp /opt/tomcat/lib/ -Dtomcat.home=/opt/tomcat/
> -Djava.home=/opt/java
> org.apache.tomcat.startup.Tomcat
> 
> (I have expanded the jars in lib) and works just fine, except that:
> 
> even as an ordinary user I can shut it down running the
>   java -cp /opt/tomcat/lib/ -Dtomcat.home=/opt/tomcat
> org.apache.tomcat.startup.Tomcat -stop
> 
> What am I doing wrong? How can I enable only root to shutdown Tomcat?
> 
> 
> ******************* In Server 2000:
> 
> I run the startup.bat as a system service, under SYSTEM account (using a
> resource toolkit
> utility that adds the registry instruction in the registry, to run a
> program
> as a service)
> The problem is that although Tomcat starts at system boot, it stops when
> the
> first log off
> is performed (under any account). Is there a way to prevent this?
> 


__________________________________________________
Do You Yahoo!?
Yahoo! Auctions - buy the things you want at great prices
http://auctions.yahoo.com/