Solved

Deploying a .war on Tomcat

Posted on 2003-11-21
6
2,651 Views
Last Modified: 2012-08-14
I have .war (downloaded from net) and i want to deploy that to my Tomcat4.1. I put the .war in webapps and on startup of tomcat it opens up and gets deployed. but the thing is it has multiple directories and the top most directory "samples" doesn't contain the WEB-INF but a directory inside this "samples" , which is "tsamples", contains the JSPs and WEB-INF directory. in WEB-INF/classes it has got some servlets (in packages) and the also has the required .xml file( i.e. mapping for servlets to /servlet/*) . But when i invoke the servlets (in web-inf/classes/client/servlets) through the html (in /samples/tsamples/html/abc.html) it gives http status 404. the address i am using for servlet calling is http://localhost/samples/tsamples/servlet/name_of_servlet.
 
In the tomcat logs i have
2003-11-21 23:23:45 ContextConfig[/samples]: Missing application web.xml, using defaults only

Do i need to have an .xml in the "samples" ... ? Can anyone suggest something on this.

thanx.

0
Comment
Question by:asip
  • 3
  • 3
6 Comments
 
LVL 9

Expert Comment

by:vzilka
ID: 9802924
Copy the tsamples directory to the webapps directory. You must have a WEB-INF directory that contains a web.xml file in each web application you deploy.
0
 

Author Comment

by:asip
ID: 9806453
But the url for all html and servlets are with respect to samples. I'll have to change everything in the code in that case.

thanks
0
 
LVL 9

Expert Comment

by:vzilka
ID: 9808731
Another alternative is to move the WEB-INF directory to the samples root (instead of tsamples).
0
PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

 

Author Comment

by:asip
ID: 9818200
I tried that, but it gives error.
It throws some load exception in the servlets. I am trying to look into this and will get back to you soon.


thanks
asip
0
 
LVL 9

Accepted Solution

by:
vzilka earned 500 total points
ID: 9818211
Can you give the URL from where you downloaded the WAR? this sounds very weird.
0
 

Author Comment

by:asip
ID: 9820046
I am sending the information on ur mail id liran@2train4.com
0

Featured Post

Netscaler Common Configuration How To guides

If you use NetScaler you will want to see these guides. The NetScaler How To Guides show administrators how to get NetScaler up and configured by providing instructions for common scenarios and some not so common ones.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Convert websphere application server default chained Certificates from 1024 to 2048 keysize or higher size and also you can change signatureAlgorithm . Please make sure Websphere Application Server fixpack 7.0.0.23 or Above. The following steps a…
Meet the world's only “Transparent Cloud™” from Superb Internet Corporation. Now, you can experience firsthand a cloud platform that consistently outperforms Amazon Web Services (AWS), IBM’s Softlayer, and Microsoft’s Azure when it comes to CPU and …
This tutorial gives a high-level tour of the interface of Marketo (a marketing automation tool to help businesses track and engage prospective customers and drive them to purchase). You will see the main areas including Marketing Activities, Design …
Nobody understands Phishing better than an anti-spam company. That’s why we are providing Phishing Awareness Training to our customers. According to a report by Verizon, only 3% of targeted users report malicious emails to management. With compan…

809 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question