• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

problem in stopping the server

 
Ranch Hand
Posts: 123
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Now i have downloaded tomcat3 again. this time server is starting properly. but at the time os stopping it it gives following message:
stopping Tomact
stopping tomcat on :8007 null
Error stopping Tomcat with APj12 on my IPaddress:8007 java.net.connectionException: connection refused: no further information
Also localhost:8080 is giving page cannot be displayed
 
Ranch Hand
Posts: 3695
IntelliJ IDE Java Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I kinda wish you'd make up your mind.

You've tried version 3,4 AND 5.

Windows 98 is problematic. Is there no chance you can use NT or 2000 or XP ?


If the answer is no, then here are my recommendations.

0) Uninstall ALL previous versions of Tomcat. If you have more than one JDK, pick the 1.4 one and uninstall the rest.

1) Ensure that in autoexec.bat, your JAVA_HOME is pointing to c:\jdk141. DO NOT use the long file name. If the directory is more than 8 characters and/or contains spaces, RENAME the jdk directory to something less than 8 long, NO spaces. Restart Windows to have this change take effect.

2) Use Tomcat 4.1.29. Use the exe installer.

3) When installing, make sure it finds a "Java Development Kit" and the path it tells you (in a dialog box) should be exactly the same as your JAVA_HOME variable. If it's not, STOP, cancel the install. Double check you've followed step 0, and restart windows. Try installing Tomcat again. If it still doesn't pick it up, post here with your autoexec.bat file settings.

4) DO NOT install Tomcat in c:\program files\apache group\etc, etc. Instead, like the JDK, ensure the path is less than 8 characters and has NO spaces. I like: c:\tomcat41

This ought to be enough. I've just completed an install of 4.1.29 on Windows98 with 256MB RAM. I made sure JAVA_HOME was set to a 8.3 filepath BEFORE installing Tomcat. The jdk was 1.4.1_02. I installed Tomcat under c:\tomcat4. I double clicked the 'start tomcat' shortcut, and localhost:8080 works fine.
 
Dhanashree Mankar
Ranch Hand
Posts: 123
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
thanx mike i did all the steps as per ur suggesion But i don't understand what's wrong here when i start startup.bat
syntax error
Using CATLINA_BASE: C:\tomcat4
Using CATLINA_HOME: C:\tomcat4
Using CATLINA_TMPDIR: Cl\tomcat4\temp
Using JAVA_HOME: C:\jdk1.4
and other window opened with some contents
This is my autoexec.bat
set CATALINA_HOME=c:\tomcat4
set JAVA_HOME=c:\jdk1.4
set PATH=c:\jdk1.4\bin;
set CLASSPATH=.;c:\jdk1.4\jre\lib\rt.jar;
set CLASSPATH=%CLASSPATH%c:\tomcat4\common\lib\servlet.jar
Is there anything wrong?
 
Mike Curwen
Ranch Hand
Posts: 3695
IntelliJ IDE Java Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
don't use the startup.bat file.

Use the shortcut in the start menu
 
Dhanashree Mankar
Ranch Hand
Posts: 123
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Use the shortcut in the start menu[/QB]

Mike, I used shortcut in start menu But some window opend with some contents and immediately disappeared
 
Dhanashree Mankar
Ranch Hand
Posts: 123
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Windows 98 is problematic. Is there no chance you can use NT or 2000 or XP ?

I am having windows 2000 server also. But I don't want to go there.
But if no other option is remaining then i have to try there.
Can u tell me which jdk and tomcat version will compatible with windows2000 server.And also r there any things to be done during installation.
plz guide me
 
Author and all-around good cowpoke
Posts: 13078
6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I don't understand the advice not to use startup.bat when debugging.
When I am debugging a tomcat startup problem, I execute the startup.bat from a command prompt window and I modify the next to last line in startup.bat:
call "%EXECUTABLE%" start %CMD_LINE_ARGS%
By changing the start to run the window will stay open and you can see whats going on.
If your first try does not disclose the problem, change the @echo off line at the start of catalina.bat so it will write everything.
It is best to increase the line memory in the command prompt window so it will remember more lines of output.
If you are stuck with Win98 you must increase the environment memory space as discussed elsewhere.
Bill
 
Dhanashree Mankar
Ranch Hand
Posts: 123
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
[If you are stuck with Win98 you must increase the environment memory space as discussed elsewhere.
Bill[/QB]
I ahve already increased memory space to 4096
 
Dhanashree Mankar
Ranch Hand
Posts: 123
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Can anyone tell me how can i copy my dos errors here
 
William Brogden
Author and all-around good cowpoke
Posts: 13078
6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
You can copy text out of a Command Prompt window by:
1. left click upper left corner
2. from the Edit menu item -> mark
3. now the first click in the text will start a selection box - use mouse to control the selection.
4. press enter - selected text can now be pasted.
Bill
 
Dhanashree Mankar
Ranch Hand
Posts: 123
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanx a lot Bill
These r the errors i am getting after typing startup.bat on command prompt:

C:\tomcat4>bin\startup
Using CATALINA_BASE: c:\tomcat4
Using CATALINA_HOME: c:\tomcat4
Using CATALINA_TMPDIR: c:\tomcat4\temp
Using JAVA_HOME: c:\jdk1.4
Nov 24, 2003 9:27:24 AM org.apache.coyote.http11.Http11Protocol init
INFO: Initializing Coyote HTTP/1.1 on port 8080
Starting service Tomcat-Standalone
Apache Tomcat/4.1.29
Nov 24, 2003 9:27:28 AM org.apache.struts.util.PropertyMessageResources <init>
INFO: Initializing, config='org.apache.struts.util.LocalStrings', returnNull=tru
e
Nov 24, 2003 9:27:28 AM org.apache.struts.util.PropertyMessageResources <init>
INFO: Initializing, config='org.apache.struts.action.ActionResources', returnNul
l=true
Nov 24, 2003 9:27:29 AM org.apache.struts.util.PropertyMessageResources <init>
INFO: Initializing, config='org.apache.webapp.admin.ApplicationResources', retur
nNull=true
Nov 24, 2003 9:27:35 AM org.apache.coyote.http11.Http11Protocol start
INFO: Starting Coyote HTTP/1.1 on port 8080
Nov 24, 2003 9:27:36 AM org.apache.jk.common.ChannelSocket init
INFO: JK2: ajp13 listening on /0.0.0.0:8009
Nov 24, 2003 9:27:36 AM org.apache.jk.server.JkMain start
INFO: Jk running ID=0 time=0/60 config=c:\tomcat4\conf\jk2.properties
---------------------------------------------------------------------------
And these errors i am getting after typing shutdown.bat on command prompt:
Using CATALINA_BASE: c:\tomcat4
Using CATALINA_HOME: c:\tomcat4
Using CATALINA_TMPDIR: c:\tomcat4\temp
Using JAVA_HOME: c:\jdk1.4
Catalina.stop: java.net.ConnectException: Connection refused: connect
java.net.ConnectException: Connection refused: connect
at java.net.PlainSocketImpl.socketConnect(Native Method)
at java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:305)
at java.net.PlainSocketImpl.connectToAddress(PlainSocketImpl.java:171)
at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:158)
at java.net.Socket.connect(Socket.java:434)
at java.net.Socket.connect(Socket.java:384)
at java.net.Socket.<init>(Socket.java:291)
at java.net.Socket.<init>(Socket.java:119)
at org.apache.catalina.startup.Catalina.stop(Catalina.java:581)
at org.apache.catalina.startup.Catalina.execute(Catalina.java:402)
at org.apache.catalina.startup.Catalina.process(Catalina.java:180)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl
java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcce
sorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:203)
 
William Brogden
Author and all-around good cowpoke
Posts: 13078
6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
That looks like a normal startup - can you then see the Tomcat example pages and documentation by addressing localhost:8080 ?
Do you also have an Apache webserver running?
Bill
 
Dhanashree Mankar
Ranch Hand
Posts: 123
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by William Brogden:
That looks like a normal startup - can you then see the Tomcat example pages and documentation by addressing localhost:8080 ?
No i am not getting that page
Do you also have an Apache webserver running?
Bill


No Apache serveri haven't downloaded
 
Mike Curwen
Ranch Hand
Posts: 3695
IntelliJ IDE Java Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
William, the advice to use the shortcut was based on my experience of installing on Win98 (about 5 minutes before posting).

If you double click the startup.bat, you'll get the memory errors, but with the shortcut in the start menu, you don't.

I think it's because the startmenu shortcut is simply a call to "catlina.jar -start" whereas the startup scripts do all sorts of command line magic that win98 chokes on.

And I'll echo your comment... there is nothing wrong with the output from the DOS window. Dhanashree, after starting Tomcat, try localhost:8080/. I get the exact same information in my window after starting on Win98.

Can u tell me which jdk and tomcat version will compatible with windows2000 server I recommend JDK 1.4.2 and Tomcat 4.1.29
 
Dhanashree Mankar
Ranch Hand
Posts: 123
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi
It's working perfectly now. Thanx a lot William and Mike
But with localhost:8080 it gives page not found. With 127.0.0.1:8080 it is working properly I hope this will not create any problem in future.
I placed my compiled file in C:\tomcat4\webapps\examples\WEB-INF\classes
So everytime i have to put my class file here? Is there any other method?
 
William Brogden
Author and all-around good cowpoke
Posts: 13078
6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

I placed my compiled file in C:\tomcat4\webapps\examples\WEB-INF\classes
So everytime i have to put my class file here? Is there any other method?


Yes, but you really should consult a good servlets book, a tutorial, and/or the published servlet API for a more complete explanation. You might find the JavaRanch FAQ department helpful.
Bill
 
reply
    Bookmark Topic Watch Topic
  • New Topic