ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Andrew Zeon <Andr...@hothouse.com.au>
Subject RE: Stopping and starting tomcat using ANT
Date Thu, 03 Apr 2003 07:49:55 GMT
Hi,

I've done what David has written below, but upon executing the my build
script, it just hangs on this:


start.catalina:
     [java] 3/04/2003 17:23:25 org.apache.commons.modeler.Registry
loadRegistry
     [java] INFO: Loading registry information
     [java] 3/04/2003 17:23:25 org.apache.commons.modeler.Registry
getRegistry
     [java] INFO: Creating new Registry instance
     [java] 3/04/2003 17:23:27 org.apache.commons.modeler.Registry getServer
     [java] INFO: Creating MBeanServer
     [java] 3/04/2003 17:23:29 org.apache.coyote.http11.Http11Protocol init
     [java] INFO: Initializing Coyote HTTP/1.1 on port 8080
     [java] Starting service Tomcat-Standalone
     [java] Apache Tomcat/4.1.24
     [java] 3/04/2003 17:23:45 org.apache.coyote.http11.Http11Protocol start
     [java] INFO: Starting Coyote HTTP/1.1 on port 8080
     [java] 3/04/2003 17:23:45 org.apache.jk.common.ChannelSocket init
     [java] INFO: JK2: ajp13 listening on /0.0.0.0:8009
     [java] 3/04/2003 17:23:45 org.apache.jk.server.JkMain start
     [java] INFO: Jk running ID=0 time=2/56  config=/home/antman/tomcat-4.1.
24/conf/jk2.properties

When I do 'ps -ef | grep java' I get this:

antman  6260  6258  2 17:23:21 pts/3    0:23 /usr/j2se/jre/bin/java
-Dcatalina.home=/home/antman/tomcat-4.1.24 -Xmx256m -cla

When I try to access my site, the browsing keeps churning but no page is
displayed.

So, I killed this process, and manually did a restart. Upon typing 'ps -ef |
grep java' I get this:

antman  6284     1 23 17:27:39 pts/3    0:07 /usr/java/bin/java
-Djava.endorsed.dirs=/home/antman/tomcat-4.1.24/common/endor

How can I change the ant script so that my tomcat is run correctly?

Thanks.






-----Original Message-----
From: David La France [mailto:d.lafrance@npcsystem.com]
Sent: Thursday, 3 April 2003 1:24 PM
To: Ant Users List
Subject: Re: Stopping and starting tomcat using ANT


Right, sorry about that.

Catalina allows itself to be booted up using any specified directory as 
it's webapp dir.
So my project creates a web app dir instead of copying wars over to the 
actual
Catalina web abb dir.  This is, of course, entirely optional.

By the way, I got all my info from the Cactus help pages.  Perhaps you 
should check it out.

http://jakarta.apache.org/cactus/integration/ant/howto_ant_cactus.html

Dave



On Thu, 3 Apr 2003 13:12:42 +1000, Andrew Zeon <AndrewZ@hothouse.com.au> 
wrote:

> Would anyone know what 'build.catalina.dir' would have to point to in the
> script below?
>
> Thanks.
>
>
>
> -----Original Message-----
> From: David La France [mailto:d.lafrance@npcsystem.com]
> Sent: Thursday, 3 April 2003 11:56 AM
> To: Ant Users List
> Subject: Re: Stopping and starting tomcat using ANT
>
>
> Sure.  Try something like this.  Please excuse the mess.
>
>
> <!-- =================================================================== -

>
>
> -
>
>>
> <!-- Start Tomcat 4.X   via bootstrap                      -->
> <!-- make tomcat use the build catalina directory by specifying the - 
> Dcatalina.base property -->
> <!-- =================================================================== -

>
>
> ->>
> <target name="start.catalina" description="Start Catalina">
> <java classname="org.apache.catalina.startup.Bootstrap" fork="yes">
> <jvmarg value="-Dcatalina.home=${CATALINA_HOME}"/>
> <jvmarg value="-Dcatalina.base=${build.catalina.dir}"/>
> <jvmarg value="-Xmx256m"/>
> <arg value="start"/>
> <classpath>
> <fileset dir="${CATALINA_HOME}">
> <include name="bin/bootstrap.jar"/>
> </fileset>
> <pathelement location="${JAVA_HOME}/lib/tools.jar"/>
> </classpath>
> </java>
> <!-- give tomcat time to start up -->
> <sleep seconds="5"/>
> </target>
>
>
>
> <!-- =================================================================== -

>
>
> ->
> <!-- Stop Tomcat 4.X   via bootstrap                                -->
> <!-- =================================================================== -

>
>
> ->     <target name="stop.catalina" description="Stop Catalina">
> <java classname="org.apache.catalina.startup.Bootstrap" fork="yes">
> <jvmarg value="-Dcatalina.home=${CATALINA_HOME}"/>
> <jvmarg value="-Dcatalina.base=${build.catalina.dir}"/>
> <arg value="stop"/>
> <classpath>
> <fileset dir="${CATALINA_HOME}">
> <include name="bin/bootstrap.jar"/>
> </fileset>
> </classpath>
> </java>
> </target>
>
>
>
> On Wed, 2 Apr 2003 15:43:08 +1000, Andrew Zeon <AndrewZ@hothouse.com.au> 
> wrote:
>
>> Is there a way I can stop and start a tomcat instance using ANT?
>>
>> Thanks.
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
>> For additional commands, e-mail: user-help@ant.apache.org
>>
>>
>>
>
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
> For additional commands, e-mail: user-help@ant.apache.org
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
> For additional commands, e-mail: user-help@ant.apache.org
>
>
>




---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org

Mime
View raw message