I have created a web application using Eclipse.
While creating the project I have added Tomcat server. Then I ran my application and it worked.
Afterwards I installed Apache Tomcat service by executing the service.bat file through the command line and in the properties I have set startup type to automatic.
Now I can see the Tomcat in services tab but when I tried to access my web page by using my IP address (http://192.168.x.x:8080/myroom/) I am unable to access it.
I am getting the following error:
http:status:404 error - The requested resource is not available
But when I stop the service in task manager, open Eclipse and run my application on server I'm able to access my web page.
Why am I unable to access my web page by starting the service in task manager and then by using IP address?
Eclipse uses a different deployment directory.
You have to deploy your web application in Tomcat server. Just copy your .war file to TOMCAT_HOME/webapps.
Your eclipse tomcat differs from standalone one in web app folder location
When running from eclipse it is .workspace/eclipse wstd core etc... , when running from standalone usually it is somewhere on Tomcat folder
Related
I am getting an error stating that "Could not find a valid parent module to add to the server" when I try to run an application on Websphere using Eclipse.
Are you trying to run a web application on the server or an enterprise application? Traditional WebSphere does not support standalone web applications. Try including the web app in an enterprise app and deploy the enterprise app on the server.
I have managed to solve this by adding <project>PROJECT_NAME</project> inside .project of the EAR Folder
When I access my web service running on tomcat on my local mahine, I can accesss it,say,
http://localhost:8080/UserManagement/something/users
But after I have deployed it to Azure, I am not able to access it if I do,
http://example.azurewebsites.net/UserManagement/something/users
I get resource not found !! Am I making a mistake?
Edit: I created my web service on Eclipse as a dynamic web project and ran it on tomcat. Then I uploaded it successfully on Azure as a web app using Azure plugin for Eclipse.
#Rorschach, According to your web service url, I think you have refered to the article Create a Hello World Web App for Azure in Eclipse deployed your dynamic web project on Azure via publish as Azure Web App in Azure plugin for Eclipse.
To troubleshoot for the webapp, please check whether your project deployment named UserManagement had been deployed at the path site\wwwroot\webapps via Kudu console which can be access via url https://example.scm.azurewebsites.net/DebugConsole.
If the directory UserManagement doesn't exist at the path wwwroot\webapps, I suggest that you can export the project as a war file and deploy it via drag into the webapps path using Kudu console or upload with ftp, then restart the webapp and try to access again.
If the directory webapps doesn't exist at the path wwwroot, I suggest that you can configure the Java web container at the Application Settings tab on Azure portal and re-deploy it.
Hope it helps. Any concern, please feel free to let me know.
I am trying to deploy a war file on RPI which is an Linux device in webapps folder of tomcat 7 director.
When I am running this application I am getting
requested resources not not available
If I am running same war file on my windows tomcat 7 server then it is working fine.
Can you please help me how to deploy war file on Rpi device
You need to provide more information from the tomcat logs. The message is telling you that the web application is trying to use a resource that is not available on your Rpi. Look at the tomcat log, it should provide more details.
You need to know what resources your web app requires, database, thread pools, etc. When you deploy the war, do probably see error logs in the tomcat logs, that should help you figure out what the missing resource is.
i have a java web application that i want to deploy locally.
how am i supposed to do that without running it through netbeans?
do i have anything to download? does xampp or wampserver can do that?
i am using apache tomcat server. and how can i change the url from ipaddress:8084/mywebapp to mywebapp only. or the browser needs the ip and port to access the web app.
when i installed netbeans it has apache tomcat server already can i use that as my host even not running netbeans?
see http://tomcat.apache.org/tomcat-6.0-doc/deployer-howto.html
1- install apache tomcat (http://tomcat.apache.org/download-70.cgi).
2- may be you need to change windows path (for connection between JVM and web server).
3- run apache tomcat(..\Apache Tomcat 7.x.xx\bin\tomcatx.exe).
3- copy and pase '..\dist\mywebapp.war' to Apache Tomcat 7.x.xx\webapp folder)
if web server (if work truly) move this file to work dir.
I wrote a small servlet and jsp project on eclipse and tomcat 5.5, but I don't know with works I do for make that a real site on a real host. Should I war them or I should upload project on host? My host should have which properties? I really don't now how to start?
I would recommend packaging them in a war and deploying it out to the remote tomcat server. Its not a good idea to deploy an unpackaged project directly to the server unless your debugging or testing. Once you have a finished project ready to deploy package it to a war. I typically deploy to server using the tomcat manager page. Just browse for the war, click the upload button and it should start right up. On my local machine this is the url that I use to upload to the server http://localhost:8080/manager. The server itself should have the same properties and settings that you are using in your eclipse workspace, and I would highly recommend that it be the same version as well. The war can also be dropped into a directory on the remote host and Tomcat will load this on startup, this location will vary depending on the host.