LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 11-22-2008, 09:51 PM   #1
mahi
LQ Newbie
 
Registered: Sep 2007
Location: mysore
Distribution: Debian
Posts: 16

Rep: Reputation: 0
servlet error


hello people...
i've succesfully setup both jdk and apache-tomcat...
the problem is i'm unable to execute servlet programs...
all the class files given as examples are workin..
but when i give
javac greet.java // a servlet program
i'll get errors like.
cannot find superclass of greet HttpServlet
and etc like this for all those which i invoke from this HttpServlet...
i kno the problem may be with import....
import javax.servlet.*;
import javax.servlet.http.*;

i tried to find servlet.jar on ma system but dint find it except for servlet-api.jar and servlet-2.3.jar...
anyways i added those also to classpath but dint work...
so anybody with some idea please help as to wat i should do...
thanks a lot....
 
Old 11-22-2008, 11:03 PM   #2
jstephens84
Senior Member
 
Registered: Sep 2004
Location: Nashville
Distribution: Manjaro, RHEL, CentOS
Posts: 2,098

Rep: Reputation: 102Reputation: 102
Can you post what your path is and what version of the java sdk did you install?
 
Old 11-23-2008, 12:17 AM   #3
mahi
LQ Newbie
 
Registered: Sep 2007
Location: mysore
Distribution: Debian
Posts: 16

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by jstephens84 View Post
Can you post what your path is and what version of the java sdk did you install?
ya sure....
my jdk path is /usr/lib/jdk (Java_HOME)
its jdk 5.0 update 16
and catalina home is
/usr/lib/apache-tomcat
its version 5.5....
i hope this is wat u asked.....
 
Old 11-23-2008, 01:37 AM   #4
jstephens84
Senior Member
 
Registered: Sep 2004
Location: Nashville
Distribution: Manjaro, RHEL, CentOS
Posts: 2,098

Rep: Reputation: 102Reputation: 102
nope just do and echo $PATH and then post that.
 
Old 11-23-2008, 10:37 AM   #5
mahi
LQ Newbie
 
Registered: Sep 2007
Location: mysore
Distribution: Debian
Posts: 16

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by jstephens84 View Post
nope just do and echo $PATH and then post that.
its
/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/bin/X11
 
Old 11-23-2008, 12:27 PM   #6
jstephens84
Senior Member
 
Registered: Sep 2004
Location: Nashville
Distribution: Manjaro, RHEL, CentOS
Posts: 2,098

Rep: Reputation: 102Reputation: 102
Looks like the problem is that the jdk is not in your path. You need to add to your Path. I think the command is PATH = $PATH:/usr/lib/jdk That should add it for you. But you might want to check my syntax for accuracy.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
servlet on fedora9 tannu_ah Linux - Newbie 1 11-13-2008 11:51 PM
servlet programming sajith Programming 1 03-03-2007 11:02 AM
running servlet sajith Ubuntu 1 02-26-2007 09:13 PM
servlet programming sajith Ubuntu 1 02-23-2007 07:43 PM
servlet error sajith Programming 1 02-23-2007 07:19 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 10:01 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration