eclipse安装tomcat时只有locahost,不显示server name Cannot create a server using the selected type

Eclipseh中无法安装Tomcat,报错信息如下

Cannot create a server using the selected type

 
 

原因:以前安装的tomcat目录改变

解决方法:Window->preferences->Server->Runtime Environment,改变tomcat的目录为你安装的目录,然后保存,这样就可以建立Tomcat server了。

还有另一种方式:
在当前工作区中如下路径:/.metadata/.plugins/org.eclipse.core.runtime/.settings,记住不是eclispe程序的路径。

把其下org.eclipse.wst.server.core.prefs和 org.eclipse.jst.server.tomcat.core.prefs这两个文件去掉

后重启eclipse即可。

猜你喜欢

转载自www.cnblogs.com/xiaoyingzhanchi/p/9107022.html