[cosmo-dev] Re: IMPORTANT: new webapp packaging

Brian Moseley bcm at osafoundation.org
Wed Dec 12 10:26:30 PST 2007


On Dec 12, 2007 9:22 AM, Alan Lord <alanslists at gmail.com> wrote:

> Upon startup log4j reports an error in catalina.out about
> logs/osafsrv.log not found. I touched it in $CATALINA_HOME/logs but it
> still complained. Where is the logs/osafsrv.log path in log4j.xml
> relative to?

it's relative to the current working directory, which if you start
Tomcat with catalina.sh will be $CATALINA_HOME.

i've placed the snarf log4j.xml into $CATALINA_HOME/common/classes,
and it specifies "logs/osafsrv.log". when i start up Tomcat,
$CATALINA_HOME/logs/osafsrv.log is created.

check to make sure $CATALINA_HOME/logs exists and is writable by the
user Tomcat runs as. permission errors are reported by the File class
as "File not found".

> Under my tomcat webapps directory I have cosmo-0.12-SNAPSHOT. If I point
> my browser at that, I get a Resource Not Available (404) from tomcat.

sounds like the webapp didn't get started. let's solve the log problem
first. then we can look in the log to see if there are further
problems.

> Using the cosmo-0.12-SNAPSHOT.war I have just built, I get a directory
> under webapps of the same name, and none of the ROOT directory files are
> present so this may be where the process is going wrong...

no, that's expected. the ROOT webapp is mounted at the context path
"/". your cosmo-0.12-SNAPSHOT.war, when deployed by Tomcat, will be
exploded into a directory named cosmo-0.12-SNAPSHOT and mounted at the
context path "/cosmo-0.12-SNAPSHOT". so you're seeing the expected
behavior, but something's preventing the webapp from starting up
cleanly.

btw - I'm keeping some notes on this process at
<http://chandlerproject.org/Journal/CosmoWarAutoDeployment>. when I've
got the installation instructions fully fleshed out, I'll move them to
the Cosmo admin's manual. I'm also going to do some packaging work so
that maven will create a tarball for the webapp with sample
cosmo.properties and log4j.xml and all the dependent jars.


More information about the cosmo-dev mailing list