When I click on Run it displays the following error message:
Starting GlassFish v3 Domain
GlassFish v3 Domain start failed.
/Volumes/Private/noname/Sites/projects/java/MyFirstServlet/nbproject/build-impl.xml:602: Deployment error:
GlassFish v3 Domain start failed.
See the server log for details.
BUILD FAILED (total time: 2 minutes 0 seconds)
But then I fire up Terminal in mac and use asadmin start-domain and it starts.
And in netbeans I then Run the project and it fires up Safari and displays the content.
But why can't glassfish start in netbeans? Any idea?
I've met the same problem as I was learning java web programming, but in windows env. I've spent much time guessing what that error could mean because the log file wasn't clearly saying that. Finally I found out that glassfish v3 was trying to run on 8080 port, which was already occupied by reportingservicesservice.exe which is sql server service. I didn't get to know how to switch the port used by glassfish, but I found that in netbeans 6.8 (which I use) in tools->servers I can add a new glassfish server instance which runs on a different, free port - that solved the problem :)
Netbeans IDE X.X --> Tools --> Servers
Add Server --> Choose Server --> GlassFish 3.X
then click (next) browse installation location click (next)
select (register local domain) domain name : domain 2
click on finish button
My problem was with the port 8080, when I type http://localhost:8080, I found that oracle 10g was using it first before I install netbeans 6.8 with glassfish, I deleted oracle database 10g and, wich made the 8080 port free, and now everything is fine, it works.
I just had the same problem, and it happened because of a version mismatch between the local server (Glassfish 4.1) and the remote (Glassfish 4.0).
Only thing that comes to my mind is to check if the JAVA_HOME is properly set. Guess GFv3 requires it to be set to the bin folder in the JDK installation. Just guessing...
Go to following link there i've wrote solution for it...
http://forums.netbeans.org/post-65058.html
I just ran into this same problem with both glassfish and tomcat in netbeans 6.9. My problem and solution were both simple. The problem: tomcat was already running on my machine on port 8080 and therefore netbeans could not create a new instance of either. The solution: shutdown the running instance of tomcat and let netbeans start it up for you. Hope this helps.
You must change the port of glassfish. To do this:
join C:\Program Files\SEMS-v3\glassfish\domains\domain1\config open the file domain.xml
and change the text in 8080 by 9999.
After you do this, enter the remove server netbeans glassfish glassfish addServer then add it so that it can recognize the port changed. Then Started On glassfish server, then run your project.
Here is the link: http://www.srikanthtechnologies.com/blog/java/changeglassfishport.asp
Got the same problem, here are the steps I followed to solve it:
remove the glassfish server under "Services > Servers"
close projet and Netbeans
locate the install directory of Glassfish and go to domains (GlassFish_Server\glassfish\domains).
delete the "domain1" directory
start Netbeans
recreate a Glassfish server
Don't forget to recreate your data sources and connection pools
i have start to learn java recently,i have encountered the same problem too but i found out that when the first time the guidebook ask me to add a server, i put in user and password.
so i give another try to remove the server and add it again without the password.
and it is working.
I faced the same problem and solved by configuring my netbeans config file.
Find NetBeans 8.2\etc\Netbeans.conf file and search for this line :
netbeans_default_options="
Add --locale en to the end before quotes. Eventually this line looks like:
disableMemoryMapping=true --locale en".
Restart Netbeans...
Related
so I've manually installed tomcat version 9.0.10 and the newest java JDK.
I've correctly added the manager-gui and admin-gui users. i have went into the server.xml files and found that all the ports were correct.. (connecting to default port 8080) I had to do []# unset CATALINA_HOME or else it wouldn't let me start tomcat so I did and it started but when I went to the browser and typed in the localhost:8080 it didn't show, it only says firefox could not establish connection with server localhost:8080 so I went into logs to see if there were any errors and sure enough there was an error like so: /usr/local/tomcat/apache-tomcat-9.0.10/bin/catalina.sh: line 464: /usr/bin/Java/jdk-10.0.2/bin/bin/java does not exist.. and its probably right why would there be /bin/bin/ like that in a directory.. so i went into the catalina.sh file copied what it had inside into a blank file in documents and went to line 464 (txt editor numbered the lines for me) and what i found was this line at 464: eval $_NOHUP "\"$_RUNJAVA" "\"$LOGGING_CONFIG\"" $LOGGING_MANAGER $JAVA_OPTS %CATALINA_OPTS\
but I have no idea what to do about it.. i think i might have a path problem or could be a port problem but I don't think so... I've installed apache and it works great in the browser with localhost.. could that affect the tomcat access maybe?
anyway, id really appreciate any help I can get.. I'm very new to this by the way. I'm sorry, I couldn't copy and paste from my virtual machine so I had to type it. im on centos 7.
I think you are looking for tomcat deployment page where you can manage your artifact. If that is correct
First thing you need to check is that whether your installation contains tomcat manager application.
You can verify this by looking in to this path ("apache-tomcat-9.0.10\webapps\manager") If this path is absent you may have to reinstall your tomcat.
Try downloading the zip from the below path and start the server.
If you are trying to deploy your custom application you may have to provide the context path for accessing you application. Also you can verify the deployment by looking in to the above path. For eg: if you are trying to deploy test.war then a folder named test will appear in the webapp folder.
Hope this helps.
I see that problems like mine have been posted before, some of which posts were answered. I've attempted the fixes, which indeed seem like they should have worked, but I'm still running into the same problem:
I'm trying to run a dynamic web project in Eclipse Kepler (Java EE) via apache tomcat 7.0.53 on my localhost. I've created tomcat as a server in Eclipse, and copied the config files from /tomcat/7.0.53/libexec/conf into /workspace/Servers/Tomcat v7.0 Server at localhost-config, and changed the permissions on the files so that they are all readable and writeable.
However, when I try to start the tomcat server in eclipse, I get this error:
Could not load the Tomcat server configuration at /Servers/Tomcat v7.0 Server at localhost-config. The configuration may be corrupt or incomplete.
In case it's helpful, it's all being run in mac osx 10.6.8, on a 64-bit machine.
Thanks in advance for your help.
I am facing this issue. I have fixed as following way,
Step 1: Delete server at local host(Server tab)
Step 2: Delete Servers folder in (navigator/project explorer)
Step 3: After add New->server->Apache->choose path
Step 4: start the server
After it will work......
How to solve:
1.Close Eclipse
2.Copy all files from TOMCAT_7_HOME/conf to WORKSPACE_FOLDER/Servers/Tomcat v7.0.53 Server at localhost-config
3.Start Eclipse
4.Expand the Servers project, click on the Tomcat 7 project and hit F5
5.Start Tomcat from Eclipse
Go to Server --> Apache Tomcat v7.0 --> Add
Select jre7 instead of Workbench default JRE
Click on Finish
Stop Server and then Start Server
This is a permissions problem (I had the same issue in ubuntu 14.04, eclipse luna, tomcat7). The executable files are not marked as "executable" when tomcat is donwloaded from eclipse.
Just go to your "[tomcat]/bin" directory in your file system and add execution permission (x) to all .sh files. Then go back to eclipse/servers tab, delete the tomcat7 entry an create again, finally start tomcat from eclipse.
This same problem happened to me before then i got solution for config load error:
it can be solved Right click on Project-> Build Path-> Configure Build Path->go Library tab-> Add External Jar-> browse (Apache TomCat Folder->lib->and add servlet-api.jar) add click ok. it run fine for me.
Unfortunately, this is not much of an answer. I finally never got this working with eclipse Kepler. However, when I installed linux mint on my computer, and used its software installer to install linux 3.8 (indigo), added all the EE updates (all the web/xml additions via help-->install new software-->indigo update site), installed tomcat 7.0, I finally got eclipse to play nice with tomcat (that is, I can run the webapp on tomcat from eclipse, without copy/pasting all the requisite files into tomcat, which is saving me a boatload of time).
I'm sure there is a better way to do this - if anyone has any thoughts about what may have gone wrong in my initial environment, please advise - I'm curious why it didn't work. Here were the specs:
MacOS 10.6.8
Eclipse 4.3.2
Tomcat 7.0.54
My apologies, Raju, for not responding sooner. Thanks for your post.
How to solve:
Close Eclipse
Copy all files from TOMCAT_7_HOME/conf to WORKSPACE_FOLDER/Servers/Tomcat v7.0 Server at localhost-config
Start Eclipse
Expand the Servers project, click on the Tomcat 7 project and hit F5
Start Tomcat from Eclipse
I found that this is a good old fashion directory naming convention problem. I'm running Linux Ubuntu and noticed that right under {your work space}/Servers there appeared a strange error type file when I opened it had all kinds of chunks of the crazy long directory name "Tomcat 7.0 Server... bla bla" So I deleted the Server, then made use of this little ditty cause my version also won't let me re-add the server again:
1. Close Eclipse
2. In {workspace-directory}/.metadata/.plugins/org.eclipse.core.runtime/.settings delete the following two files:
org.eclipse.wst.server.core.prefs
org.eclipse.jst.server.tomcat.core.prefs
3. Restart Eclipse
Then I re-added the server using a friendlier server name without any crazy spaces or chars: Tomcat7ServerAtLocalHost
The wella... it started with a brand new error for me to debug... which means I'm on the right track... BTW, the new error is: "Cannot publish to the server because it is missing its runtime environment."
So I'm off to debug that mess... Cheers!
This problem is mostly associated with file permissions. So the best way to solve the problem is to install a local copy of Tomcat on your development machine instead of putting Tomcat in a system directory such as /usr/share/tomcat7. This way all Tomcat conf files belong to the user and user group so that it can be run from Eclipse by the user. I normally place Tomcat at my local folder such as /home/abc/dev and it works perfectly with Eclipse development environment.
For me the only solution that works is this solution suggested here:
Could not load the Tomcat server configuration
cd /usr/share/tomcat7
sudo ln -s /var/lib/tomcat7/conf conf
sudo ln -s /var/log/tomcat7 log
sudo ln -s /etc/tomcat7/policy.d/03catalina.policy conf/catalina.policy
sudo chmod -R a+rwx /usr/share/tomcat7/conf
I have installed Apache Tomcat server in my "D:" drive and Eclipse is configured with it. When I start the server from Eclipse it shows started.
But when I enter
http://localhost:8080
It shows following error and not load the Apache server.
the netstat shows the following.
So how can I fix this. Need some help. Thank you!
You are running Tomcat from eclipse in that case, the default tomcat project is not available therefor you are not able to see Apache Tomcat.
So you need to try accessing your app as http://localhost:8080/myWebApp. And if you want to see the Apache Tomcat UI than start the Apache Tomcat from the bin folder using startup.bat file or an application exe which shows you CMD prompt (black screen). But than to access your myWebApp than you must deploy it in Apache tomcat's webapps folder.
You may also want to configure the welcone-file or load-on-startup servlet if you are using jsp-servlet technology.
For further information please refer official documentation from Apache Tomcat or search on Google/YouTube for visual examples.
You can try the following steps,
Try with your your_machine_ipaddress:8080
OR
Try with different port say 8181.
Go to tomcat_installed_directory/conf/server.xml
Search for the string "connector port=" and change the port from 8080 to 8181
Restart the tomcat and try with localhost:8181 or localhost:8181/yourwebappname or your_machine_ipaddress:8181
OR
If you are behind proxy server and trying to access tomcat running in some other machine, then add the ip address of the machine where tomcat is running to your browser bypass proxy.
I did the RAD set up recently and trying to start websphere server.
In the log, it hangs at the following line and get terminated after timeout:
Server server1 open for e-business
Thanks for the help.
In my case, I did following configuration which solved the issue and server started.
Double click on the server (in the servers tab).
In Server connection types and administrative ports select Automatically determine connection settings and save the changes.
Your workspace folder/name could be the issue.
the WAS installation itself. When moved it to C:\was8 everything started to work properly. The default puts it into c:\Program Files... and that was hanging at 23%
a. Please use websphere jre to replace sun hotspot vm to launch the eclipse, like below setting in the eclipse.ini
-vm
D:/IBM/WebSphere/AppServer/java/bin/javaw.exe
b. Please make sure there is not a specail character (like 23%) in the websphere path or eclipse workpsace.
Copy the jar com.ibm.ws.orb_8.5.0.jar from C:\IBM\WebSphere\AppServer\runtimes
to C:\development\endorsed and in eclipse.ini add this just JVM param (under -vmargs)
-Djava.endorsed.dirs=C:\development\endorsed
My Problem is: When I try to add my Tomcat7 to Eclipse EE as a server, I get an error message that says:
"The currently selected server type does not support remote hosts"
Does anyone know how to solve this problem? Or how to enable remote hosts in Tomcat?
The Tomcat support in Eclipse is meant for running Tomcat locally on your own machine. That's necessary because Eclipse deploys web modules to Tomcat by copying them into a folder in the Tomcat installation. It can't deploy things to a remote Tomcat server because it can't copy files into a folder on a different computer.
Typically you'd run Tomcat on your own computer for development, and then (manually) deploy your application to a remote server when you want to make it available to the rest of the world.
As you can see in the image the "server host name" field is "localhost" which is correct parameter value.
Solution:-
in your case it would have been showing something like "cloud" or something else. please make sure that you pass correct value which is "localhost".
i also faced this issue .my case is "i already have created tomcat server and my tomcat server(8) is installation location is
"c:/xyz/apache-tomcat-8.0.28"
then i changed my tomcat server(8) location to another place `
"c:/abc/apache-tomcat-8.0.28"
`after that when i try to create new tomcat server 8.then it showing this error
i solved by changing server runtime Environments in eclipse
preferences => server => Runtime Environments
then select your tomcat type .you can remove the server and add new server runtime Environment or edit existing one by giving correct tomcat installation path.then it won't give "The currently selected server type does not support remote hosts" error.
When you add Tomcat to Eclipse as a server runtime, don't forget to check "Create a new local server".
While defining new Server in eclipse
In server host name box use localhost instead of cloud.
for me I had renamed the tomcat folder after installing and was getting this error message with STS and Tomcat 6. See bobthemagicman's answer here: Eclipse Juno Tomcat 6 Remote Host Not Supported
Try to delete the temp file in your workspace.
...workspace\ .metadata.plugins\org.eclipse.wst.server.core\tmp-data
then make a new server with a new server runtime environment.
Just change Server's Host Name to LOCALHOST
See here