cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "sameer nanda" <sam_na...@rediffmail.com>
Subject Re: Re: Problem rebuilding Cocoon 2.1.2
Date Sat, 08 May 2004 02:02:47 GMT
<P>
Hello Geoff,<BR>
<BR>
When you say runs of cocoon, what do you mean by that???<BR>
Actually what I interpret is Cocoon is not running as a service, nor am I deplying the cocoon
war file in the servlet engine, which in my case would ne Tomcat, so how do I find out where
and how is cocoon running on my machine ???&nbsp; <BR>
<BR>
Also when I look into the cocoon.xconf file searching for HSQL port , I see the following:<BR>
<BR>
&lt;!--+<BR>
&nbsp; &nbsp; &nbsp; | HSQLDB Server for samples:<BR>
&nbsp; &nbsp; &nbsp; |<BR>
&nbsp; &nbsp; &nbsp; |&nbsp; port&nbsp;  : number&nbsp; &nbsp;
&nbsp; port where the server is listening<BR>
&nbsp; &nbsp; &nbsp; |&nbsp; silent : true/false&nbsp; display all queries<BR>
&nbsp; &nbsp; &nbsp; |&nbsp; trace&nbsp; : true/false&nbsp; display
JDBC trace messages<BR>
&nbsp; &nbsp; &nbsp; +--&gt;<BR>
&nbsp; &lt;hsqldb-server class=&quot;org.apache.cocoon.components.hsqldb.ServerImpl&quot;
logger=&quot;core.hsqldb-server&quot; pool-max=&quot;1&quot; pool-min=&quot;1&quot;&gt;<BR>
&nbsp; &nbsp;  &lt;parameter name=&quot;port&quot; value=&quot;9002&quot;/&gt;<BR>
&nbsp; &nbsp;  &lt;parameter name=&quot;silent&quot; value=&quot;true&quot;/&gt;<BR>
&nbsp; &nbsp;  &lt;parameter name=&quot;trace&quot; value=&quot;false&quot;/&gt;<BR>
&nbsp; &lt;/hsqldb-server&gt;<BR>
<BR>
Now do you know what do I have to change here ????<BR>
I have no clue&nbsp; what to do???<BR>
<BR>
Regards<BR>
Sam<BR>
<BR>
<BR>
On Sat, 08 May 2004 Geoff Howard wrote :<BR>
&gt;Actually, from the stack trace, it looks like the bind exception is happening during
HSQL startup which is historically the leading cause of this in cocoon startups.&nbsp;
Make sure that previous runs of Cocoon are shut down before restarting.&nbsp; If you have
otherwise ensured that Cocoon shut down (or were using the cli the first run through) then
it would seem that hsql did not shut down cleanly, which was a bug at some point(s) in the
past.<BR>
&gt;<BR>
&gt;My recommendation is to look into cocoon.xconf, find the hsql port (or search the
list archives - surely it's there) and see if you have a process attached to that port and
kill the pid.&nbsp; Please report back what happens so others can benefit from your experience.<BR>
&gt;<BR>
&gt;Geoff<BR>
&gt;<BR>
&gt;<BR>
&gt;sameer nanda wrote:<BR>
&gt;<BR>
&gt;&gt;Hello Everybody,<BR>
&gt;&gt;<BR>
&gt;&gt;I am not sure how can I restart Cocoon2.1.2 (or rebuild coccon), after I add
a new database or want to create a new table using the already existing HSQL script &quot;cocoondb.script&quot;.<BR>
&gt;&gt;<BR>
&gt;&gt;I am trying to run the application from the book Cocoon: Building XML Application,
chapter 7, which tell you how to add a new database or connect to the existing HSQL database.<BR>
&gt;&gt;<BR>
&gt;&gt;I have configured my Cocoon2.1.2 from source distribution, as shown below:<BR>
&gt;&gt;<BR>
&gt;&gt;-&gt; downloaded the latest source version and installed using<BR>
&gt;&gt;&nbsp; 1) build cocoon using &quot;build&quot;<BR>
&gt;&gt;&nbsp; 2) run cocoon using&nbsp; &quot;./cocoon.sh cli&quot;<BR>
&gt;&gt;&nbsp; 3) http://ip-add:8888&nbsp; points to the welcome page of cocoon<BR>
&gt;&gt;<BR>
&gt;&gt;I add the follwing lines to the cocoondb.script file :<BR>
&gt;&gt;<BR>
&gt;&gt;CREATE TABLE PORTALUSER_TABLE(ID VARCHAR,PASSWORD VARCHAR,COLOR VARCHAR,UNIQUE(ID))<BR>
&gt;&gt;CREATE TABLE MOREOVER_TABLE(ID INTEGER,NAME VARCHAR,NEWSFEED VARCHAR,UNIQUE(ID))<BR>
&gt;&gt;<BR>
&gt;&gt;INSERT INTO PORTALUSER_TABLE VALUES('cocoon','magic','white')<BR>
&gt;&gt;INSERT INTO PORTALUSER_TABLE VALUES('matthew','wizard','yellow')<BR>
&gt;&gt;INSERT INTO MOREOVER_TABLE VALUES(1,'matthew','banking')<BR>
&gt;&gt;INSERT INTO MOREOVER_TABLE VALUES(2,'cocoon','usa')<BR>
&gt;&gt;INSERT INTO MOREOVER_TABLE VALUES(3,'cocoon','banking')<BR>
&gt;&gt;<BR>
&gt;&gt;=========================================================<BR>
&gt;&gt;<BR>
&gt;&gt;Now since I am trying to add a new table and insert some values into it, I
have to restart my cocoon, this is how I try to restart cocoon using:<BR>
&gt;&gt;<BR>
&gt;&gt;shell&gt; ./coccon.sh cli<BR>
&gt;&gt;<BR>
&gt;&gt;but get an error msg at the end ....<BR>
&gt;&gt;<BR>
&gt;&gt;<BR>
&gt;&gt;-------------------- Executing -----------------<BR>
&gt;&gt;Main Class: org.apache.cocoon.Main<BR>
&gt;&gt;------------------------------------------------------------------------<BR>
&gt;&gt;cocoon 2.1.2<BR>
&gt;&gt;Copyright (c) 1999-2003 Apache Software Foundation. All rights reserved.<BR>
&gt;&gt;------------------------------------------------------------------------<BR>
&gt;&gt;<BR>
&gt;&gt;<BR>
&gt;&gt;ERROR&nbsp;  2004-05-07 14:44:35.412 [&nbsp; &nbsp; &nbsp;
&nbsp; ] (): Could not find the configuration file.<BR>
&gt;&gt;Exception in thread &quot;main&quot; java.lang.reflect.InvocationTargetException<BR>
&gt;&gt;&nbsp; &nbsp; &nbsp; &nbsp;  at sun.reflect.NativeMethodAccessorImpl.invoke0(Native
Method)<BR>
&gt;&gt;&nbsp; &nbsp; &nbsp; &nbsp;  at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)<BR>
&gt;&gt;&nbsp; &nbsp; &nbsp; &nbsp;  at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)<BR>
&gt;&gt;&nbsp; &nbsp; &nbsp; &nbsp;  at java.lang.reflect.Method.invoke(Method.java:324)<BR>
&gt;&gt;&nbsp; &nbsp; &nbsp; &nbsp;  at Loader.invokeMain(Unknown
Source)<BR>
&gt;&gt;&nbsp; &nbsp; &nbsp; &nbsp;  at Loader.run(Unknown Source)<BR>
&gt;&gt;&nbsp; &nbsp; &nbsp; &nbsp;  at Loader.main(Unknown Source)<BR>
&gt;&gt;Caused by: java.io.FileNotFoundException: The configuration file could not
be found.<BR>
&gt;&gt;&nbsp; &nbsp; &nbsp; &nbsp;  at org.apache.cocoon.bean.CocoonWrapper.getConfigurationFile(CocoonWrapper.java:235)<BR>
&gt;&gt;&nbsp; &nbsp; &nbsp; &nbsp;  at org.apache.cocoon.bean.CocoonWrapper.initialize(CocoonWrapper.java:142)<BR>
&gt;&gt;&nbsp; &nbsp; &nbsp; &nbsp;  at org.apache.cocoon.bean.CocoonBean.initialize(CocoonBean.java:119)<BR>
&gt;&gt;&nbsp; &nbsp; &nbsp; &nbsp;  at org.apache.cocoon.Main.main(Main.java:400)<BR>
&gt;&gt;&nbsp; &nbsp; &nbsp; &nbsp;  ... 7 more<BR>
&gt;&gt;<BR>
&gt;&gt;=====================================================================<BR>
&gt;&gt;<BR>
&gt;&gt;<BR>
&gt;&gt;<BR>
&gt;&gt;Now question is that is this the proper way to restart cocoon in my case,
or their is something else i need to do . I even tried with:<BR>
&gt;&gt;<BR>
&gt;&gt;shell&gt; ./cocoon.sh servlet<BR>
&gt;&gt;<BR>
&gt;&gt;and this time I get BindException, which is true bcos its already bound to
the port 8888. This is how the msg looks like:<BR>
&gt;&gt;<BR>
&gt;&gt;./cocoon.sh: using ./build/webapp as the webapp directory<BR>
&gt;&gt;-------------------- Loading --------------------<BR>
&gt;&gt;Processing repository: ./tools/jetty/lib<BR>
&gt;&gt;Adding jar: ./tools/jetty/lib/jetty-4.2.9.jar<BR>
&gt;&gt;Adding jar: ./tools/jetty/lib/servlet-2.3.jar<BR>
&gt;&gt;Processing repository: ./lib/endorsed<BR>
&gt;&gt;Adding jar: ./lib/endorsed/xalan-2.5.1.jar<BR>
&gt;&gt;Adding jar: ./lib/endorsed/xercesImpl-2.5.0.jar<BR>
&gt;&gt;Adding jar: ./lib/endorsed/xml-apis.jar<BR>
&gt;&gt;-------------------- Executing -----------------<BR>
&gt;&gt;Main Class: org.mortbay.jetty.Server<BR>
&gt;&gt;14:47:54.865 EVENT&nbsp; Starting Jetty/4.2.9<BR>
&gt;&gt;14:47:55.846 EVENT&nbsp; Started WebApplicationContext[/,./build/webapp]<BR>
&gt;&gt;server.properties not found, using command line or default properties<BR>
&gt;&gt;Opening database: /home/g_snanda/cocoon-2.1.2/build/webapp/WEB-INF/db/cocoondb<BR>
&gt;&gt;HSQLDB server 1.7.1 is running<BR>
&gt;&gt;Use SHUTDOWN to close normally. Use [Ctrl]+[C] to abort abruptly<BR>
&gt;&gt;Server.run/init: java.net.BindException: Address already in use<BR>
&gt;&gt;java.net.BindException: Address already in use<BR>
&gt;&gt;&nbsp; &nbsp; &nbsp; &nbsp;  at java.net.PlainSocketImpl.socketBind(Native
Method)<BR>
&gt;&gt;&nbsp; &nbsp; &nbsp; &nbsp;  at java.net.PlainSocketImpl.bind(PlainSocketImpl.java:321)<BR>
&gt;&gt;&nbsp; &nbsp; &nbsp; &nbsp;  at java.net.ServerSocket.bind(ServerSocket.java:308)<BR>
&gt;&gt;&nbsp; &nbsp; &nbsp; &nbsp;  at java.net.ServerSocket.bind(ServerSocket.java:266)<BR>
&gt;&gt;&nbsp; &nbsp; &nbsp; &nbsp;  at java.net.ServerSocket.&lt;init&gt;(ServerSocket.java:182)<BR>
&gt;&gt;&nbsp; &nbsp; &nbsp; &nbsp;  at java.net.ServerSocket.&lt;init&gt;(ServerSocket.java:94)<BR>
&gt;&gt;&nbsp; &nbsp; &nbsp; &nbsp;  at org.hsqldb.Server.run(Unknown
Source)<BR>
&gt;&gt;&nbsp; &nbsp; &nbsp; &nbsp;  at org.hsqldb.Server.main(Unknown
Source)<BR>
&gt;&gt;&nbsp; &nbsp; &nbsp; &nbsp;  at org.apache.cocoon.components.hsqldb.ServerImpl.run(ServerImpl.java:199)<BR>
&gt;&gt;&nbsp; &nbsp; &nbsp; &nbsp;  at java.lang.Thread.run(Thread.java:536)<BR>
&gt;&gt;&nbsp; INFO [main] (DirectSchedulerFactory.java:295) - Quartz scheduler
'Cocoon<BR>
&gt;&gt;&nbsp; INFO [main] (DirectSchedulerFactory.java:298) - Quartz scheduler
version: 1.2.3<BR>
&gt;&gt;&nbsp; INFO [main] (QuartzScheduler.java:327) - Scheduler Cocoon_$_Fri_May_07_14:48:09_EDT_2004
started.<BR>
&gt;&gt;14:48:10.138 WARN!! Failed to start: SocketListener@0.0.0.0:8888<BR>
&gt;&gt;14:48:10.142 WARN!!<BR>
&gt;&gt;org.mortbay.util.MultiException[java.net.BindException: Address already in
use]<BR>
&gt;&gt;&nbsp; &nbsp; &nbsp; &nbsp;  at org.mortbay.http.HttpServer.start(HttpServer.java:624)<BR>
&gt;&gt;&nbsp; &nbsp; &nbsp; &nbsp;  at org.mortbay.jetty.Server.main(Server.java:429)<BR>
&gt;&gt;&nbsp; &nbsp; &nbsp; &nbsp;  at sun.reflect.NativeMethodAccessorImpl.invoke0(Native
Method)<BR>
&gt;&gt;&nbsp; &nbsp; &nbsp; &nbsp;  at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)<BR>
&gt;&gt;&nbsp; &nbsp; &nbsp; &nbsp;  at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)<BR>
&gt;&gt;&nbsp; &nbsp; &nbsp; &nbsp;  at java.lang.reflect.Method.invoke(Method.java:324)<BR>
&gt;&gt;&nbsp; &nbsp; &nbsp; &nbsp;  at Loader.invokeMain(Unknown
Source)<BR>
&gt;&gt;&nbsp; &nbsp; &nbsp; &nbsp;  at Loader.run(Unknown Source)<BR>
&gt;&gt;&nbsp; &nbsp; &nbsp; &nbsp;  at Loader.main(Unknown Source)<BR>
&gt;&gt;[0]=java.net.BindException: Address already in use<BR>
&gt;&gt;&nbsp; &nbsp; &nbsp; &nbsp;  at java.net.PlainSocketImpl.socketBind(Native
Method)<BR>
&gt;&gt;&nbsp; &nbsp; &nbsp; &nbsp;  at java.net.PlainSocketImpl.bind(PlainSocketImpl.java:321)<BR>
&gt;&gt;&nbsp; &nbsp; &nbsp; &nbsp;  at java.net.ServerSocket.bind(ServerSocket.java:308)<BR>
&gt;&gt;&nbsp; &nbsp; &nbsp; &nbsp;  at java.net.ServerSocket.bind(ServerSocket.java:266)<BR>
&gt;&gt;&nbsp; &nbsp; &nbsp; &nbsp;  at java.net.ServerSocket.&lt;init&gt;(ServerSocket.java:182)<BR>
&gt;&gt;&nbsp; &nbsp; &nbsp; &nbsp;  at org.mortbay.util.ThreadedServer.newServerSocket(ThreadedServer.java:317)<BR>
&gt;&gt;&nbsp; &nbsp; &nbsp; &nbsp;  at org.mortbay.util.ThreadedServer.start(ThreadedServer.java:389)<BR>
&gt;&gt;&nbsp; &nbsp; &nbsp; &nbsp;  at org.mortbay.http.SocketListener.start(SocketListener.java:153)<BR>
&gt;&gt;&nbsp; &nbsp; &nbsp; &nbsp;  at org.mortbay.http.HttpServer.start(HttpServer.java:655)<BR>
&gt;&gt;&nbsp; &nbsp; &nbsp; &nbsp;  at org.mortbay.jetty.Server.main(Server.java:429)<BR>
&gt;&gt;&nbsp; &nbsp; &nbsp; &nbsp;  at sun.reflect.NativeMethodAccessorImpl.invoke0(Native
Method)<BR>
&gt;&gt;&nbsp; &nbsp; &nbsp; &nbsp;  at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)<BR>
&gt;&gt;&nbsp; &nbsp; &nbsp; &nbsp;  at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)<BR>
&gt;&gt;&nbsp; &nbsp; &nbsp; &nbsp;  at java.lang.reflect.Method.invoke(Method.java:324)<BR>
&gt;&gt;&nbsp; &nbsp; &nbsp; &nbsp;  at Loader.invokeMain(Unknown
Source)<BR>
&gt;&gt;&nbsp; &nbsp; &nbsp; &nbsp;  at Loader.run(Unknown Source)<BR>
&gt;&gt;&nbsp; &nbsp; &nbsp; &nbsp;  at Loader.main(Unknown Source)<BR>
&gt;&gt;===================================================================<BR>
&gt;&gt;<BR>
&gt;&gt;Could anybody let me know what is the proper way of restarting cocoon in my
case... I am trying this for the last 3days ...<BR>
&gt;&gt;<BR>
&gt;&gt;Eagerly waiting for responses, all responses and suggestions accepted.<BR>
&gt;&gt;<BR>
&gt;&gt;Thanks in advance.<BR>
&gt;&gt;<BR>
&gt;&gt;Regards<BR>
&gt;&gt;Sam<BR>
&gt;<BR>
&gt;<BR>
&gt;---------------------------------------------------------------------<BR>
&gt;To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org<BR>
&gt;For additional commands, e-mail: users-help@cocoon.apache.org<BR>
&gt;<BR>

</P>
<br><br>
<A target="_blank" HREF="http://clients.rediff.com/signature/track_sig.asp"><IMG
SRC="http://ads.rediff.com/RealMedia/ads/adstream_nx.cgi/www.rediffmail.com/inbox.htm@Bottom"
BORDER=0 VSPACE=0 HSPACE=0></a>

Mime
View raw message