我尝试在 11.10 上仅使用 Ubuntu 提供的软件包设置 Jenkins。之后apt-get install jenkins
,Jenkins 无法启动。我将其追溯到缺失的/usr/lib/jvm/default-java/bin/java
。
Desired=Unknown/Install/Remove/Purge/Hold
| Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend
|/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)
||/ Name Version Description
+++-===============================-=======================================-==============================================================================
ii jenkins 1.409.1-0ubuntu4.2 Continuous Integration and Job Scheduling Server
ii openjdk-6-jre 6b24-1.11.3-1ubuntu0.11.10.1 OpenJDK Java runtime, using Hotspot JIT
# update-alternative --config java
There is only one alternative in link group java: /usr/lib/jvm/java-6-openjdk/jre/bin/java
Nothing to configure.
哪个包创建了 /usr/lib/jvm/default-java ?
答案1
您可以使用 apt-file 搜索此信息。您可能需要先设置 apt-file 才能使用它。
sudo apt-get install apt-file #Installs
sudo apt-file update #Updates local file list
apt-file search <path to file/directory> #Does the searching
它报告说这default-jre-headless
就是您应该寻找的包。