The directory structure i used for my web app is MyApp JspServlets WEB-INF classes lib web.xml
I tried to invoke my servlet by http://localhost:8080/MyApp/Greet But i am getting 404 error. I have given the url-pattern and everything in web.xml. Please help me to solve this problem.
404 is for resource not found. Check once more the web.xml mappings.
Deployment structure should be.. jsp's and HTML's , images should be out side WEB-INF; jar's should be in lib folder within WEB-INF;classes should be in classes folder inside WEB-INF and web.xml should be inside web.xml.
It's difficult for us to see what your directory structure is when you enter it that way. If you're still having this problem, post the directory structure again by type it the way Prabhu venkatachalam did.