Java 如何在 Fedora 20 中安装 Apache Tomcat
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/24905069/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
How to install Apache Tomcat in Fedora 20
提问by Amit Bera
I want to install Apache Tomcat in fedora 20. I have try to install tomcat using below code
我想在 fedora 20 中安装 Apache Tomcat。我尝试使用以下代码安装 tomcat
yum install tomcat.
Then, enable Tomcat on system startup:
然后,在系统启动时启用 Tomcat:
systemctl enable tomcat
Command is executed properly, but when try http://127.0.0.1:8080
it shows a blank page.
命令执行正确,但尝试http://127.0.0.1:8080
时显示空白页。
Can anyone tell me, how I have to configure tomcat to make it work properly?
谁能告诉我,我必须如何配置 tomcat 才能使其正常工作?
回答by Christian Schlaefcke
I recently got the same problem. And if you are used to yum but not used to install applications manually you can find below how I resolved the problem using yum:
我最近遇到了同样的问题。如果您习惯 yum 但不习惯手动安装应用程序,您可以在下面找到我如何使用 yum 解决问题:
# yum search tomcat
Loaded plugins: langpacks, refresh-packagekit
tomcat-native.x86_64 : Tomcat native library
jglobus-ssl-proxies-tomcat.noarch : Globus Java - SSL and proxy certificate support for Tomcat
jspc-compiler-tomcat6.noarch : JSPC Compiler for Tomcat6
openwebbeans-tomcat7.noarch : Apache OpenWebBeans Tomcat 7 plugin
springframework-instrument-tomcat.noarch : Spring Instrument Tomcat Weaver
**tomcat-admin-webapps.noarch : The host-manager and manager web applications for Apache Tomcat**
tomcat-docs-webapp.noarch : The docs web application for Apache Tomcat
tomcat-javadoc.noarch : Javadoc generated documentation for Apache Tomcat
tomcat-jsp-2.2-api.noarch : Apache Tomcat JSP API implementation classes
tomcat-jsvc.noarch : Apache jsvc wrapper for Apache Tomcat as separate service
tomcat-lib.noarch : Libraries needed to run the Tomcat Web container
tomcat-servlet-3.0-api.noarch : Apache Tomcat Servlet API implementation classes
**tomcat-webapps.noarch : The ROOT and examples web applications for Apache Tomcat**
tomcatjss.noarch : JSSE implementation using JSS for Tomcat
pki-tps-tomcat.noarch : Certificate System - Token Processing Service
tomcat.noarch : Apache Servlet/JSP Engine, RI for Servlet 3.0/JSP 2.2 API
tomcat-el-2.2-api.noarch : Expression Language v1.0 API
Because I ran into this dependency conflict:
因为我遇到了这个依赖冲突:
Error: tomcatjss conflicts with tomcat-native-1.1.30-1.fc20.x86_64
You could try using --skip-broken to work around the problem
You could try running: rpm -Va --nofiles --nodigest
I run yum install with the skip-broken flag:
我使用跳过损坏的标志运行 yum install:
# yum install --skip-broken tomcat*
And now after
现在之后
# service tomcat restart
the Tomcat start Page appears as expected.
Tomcat 起始页按预期显示。