This week's book giveaway is in the Jobs Discussion forum.
We're giving away four copies of Java Interview Guide and have Anthony DePalma on-line!
See this thread for details.
The moose likes Servlets and the fly likes How to run Servlets? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Java Interview Guide this week in the Jobs Discussion forum!
JavaRanch » Java Forums » Java » Servlets
Bookmark "How to run Servlets?" Watch "How to run Servlets?" New topic

How to run Servlets?

Anil Kollur
Ranch Hand

Joined: Mar 25, 2000
Posts: 101

Hi! Everybody,
I am using a Win98 machine and I have J2SDK means I have the ServletRunner, can anybody tell me how to run the Servelets.
Thanks in advance,

Everyday is a Learning phase! Hence ask "What have I learnt today?"
prakash muthu
Ranch Hand

Joined: Sep 06, 2000
Posts: 75
a batch file in the name of Startserver.bat will be there.
That file is for starting a server.
Let me know if you want more details

Prakash.M<BR>Bangalore- India<BR>(
Anil Kollur
Ranch Hand

Joined: Mar 25, 2000
Posts: 101

Hi! ,
I am having the Apache web Server and I can start the server from the command line, but what for Startserver.bat file? I could not able to understand, please help me.
One more thing, I am having Java Servlet Dev kit(JSDK)and Apache web server as said earlier, is it enough to start the Servlets?
Thanx in advance
Amit Roy
Ranch Hand

Joined: Oct 10, 2000
Posts: 132
hi thr
First of all u need to need to set the classpath properly as u are using a windows 98 operating sys set ur class path to
c://jsdk1.2/bin/servletrunner (configure it as it is installed in ur machine) Then after compiling ur servlet
1) Place it in your class file in the examples directory.
2) Start the servletrunner by typint the command "servletrunner"
from the dos prompt it will start on port no 8080(default)
3) open ur browser and type in http://localhost:8080/servlet/urclassfilename
hope this helps

<I>Chance Favours the Prepared minds"</I>
Max Hunt

Joined: Mar 06, 2003
Posts: 1
I want use a servletrunner... I be the download of J2sdk 1.4(the last version founded in java site) and I�m don�t have a servletrunner in directory /bin... where I can find the servletrunner.exe ???
Mike Curwen
Ranch Hand

Joined: Feb 20, 2001
Posts: 3695

j2sdk1.4 is for J2SE. It is the standard java libraries, and has nothing to do with Servlets or JSP.

As for servlet runner, it is VERY old technology and you should NOT try to find it or use it.

Tomcat is what you want these days, and it's easy to find from (or )
I agree. Here's the link:
subject: How to run Servlets?
It's not a secret anymore!