Package 'tomcat7' has no installation candidate on ubuntu 12.04
tomcat7
package is only available on security repositories, universe section for precise, saucy to wily is available in the main repository, and newer in the universe repository. So, make sure you have in your /etc/apt/sources.list
the following line:
deb http://security.ubuntu.com/ubuntu precise-security main universe
The line don't have to be exact, it could include multiverse
and restricted
, but it should include all the elements above. If the line was not present in the source.list
file, add it and run apt-get update
. Now you should have tomcat7
available.
If you don't find the source.list
file
-
Execute:
sudo nano /etc/apt/source.list
-
then paste into the file:
deb http://security.ubuntu.com/ubuntu precise-security main universe
-
Hit: Ctrl+O to save the file, then Ctrl+X to exit.
-
Update the package list with
sudo apt-get update
.
I have installed tomcat6
Then you must delete tomcat6
of your system, before trying to install tomcat7
sudo apt-get remove tomcat*
sudo apt-get install tomcat7
This will remove all tomcat related packages the install tomcat7
without problems.
Related videos on Youtube
Comments
-
catch23 over 1 year
I'm trying to install tomcat 7 on Ubuntu Server 12.04 with:
sudo apt-get install tomcat7
I tried to do this according this install tutorial, but immediately I receive this answer:
Reading package lists... Done Building dependency tree Reading state information... Done Package tomcat7 is not available, but is referred to by another package. This may mean that the package is missing, has been obsoleted, or is only available from another source E: Package 'tomcat7' has no installation candidate
Update:
I tried to download & install
tomcat7
step by step as this tutorial. But when I try to run program`$ ./catalina.sh run`
I catch few warnings +
SEVERE: Cannot start server. Server instance is not configured
:nazar_art@nazar-desctop:/usr/local/tomcat/apache-tomcat-7.0.42/bin$ ./catalina.sh run Using CATALINA_BASE: /usr/local/tomcat/apache-tomcat-7.0.42 Using CATALINA_HOME: /usr/local/tomcat/apache-tomcat-7.0.42 Using CATALINA_TMPDIR: /usr/local/tomcat/apache-tomcat-7.0.42/temp Using JRE_HOME: /usr/lib/jvm/java-7-oracle Using CLASSPATH: /usr/local/tomcat/apache-tomcat-7.0.42/bin/bootstrap.jar:/usr/local/tomcat/apache-tomcat-7.0.42/bin/tomcat-juli.jar Jul 25, 2013 8:49:54 PM org.apache.catalina.startup.Catalina load WARNING: Unable to load server configuration from [/usr/local/tomcat/apache-tomcat-7.0.42/conf/server.xml] Jul 25, 2013 8:49:54 PM org.apache.catalina.startup.Catalina load WARNING: Permissions incorrect, read permission is not allowed on the file. Jul 25, 2013 8:49:54 PM org.apache.catalina.startup.Catalina load WARNING: Unable to load server configuration from [/usr/local/tomcat/apache-tomcat-7.0.42/conf/server.xml] Jul 25, 2013 8:49:54 PM org.apache.catalina.startup.Catalina load WARNING: Permissions incorrect, read permission is not allowed on the file. Jul 25, 2013 8:49:54 PM org.apache.catalina.startup.Catalina start SEVERE: Cannot start server. Server instance is not configured.
- How to solve this trouble and install
tomcat7
?
-
mx7 almost 11 yearswhats the result of sudo apt-get update ?
- How to solve this trouble and install
-
catch23 almost 11 yearsI find at /etc/apt/
sources.list.save
=> added thisprecise-security
string =>apt-get update
=>apt-get install tomcat7
=> the same resultE: Package 'tomcat7' has no installation candidate
? -
Thomas Ward almost 11 years@nazar_art the file you need to include as part of your question is
/etc/apt/sources.list
and it does exist on your system otherwise apt would be breaking. Follow Braiam's answer, but note that/etc/apt/sources.list
does exist in any 12.04 environment. -
catch23 almost 11 years@Braiam I did all points from this list(
sources.list
was created successfully). After this when I trysudo apt-get install tomcat7
I have the same resultE: Package 'tomcat7' has no installation candidate
. I can't installtomcat7_7.0.26-1ubuntu1.2_all.deb
. Ubuntu Software Center showsDependency isn't satisfiable: tomcat7-common (>= 7.0.26-1ubuntu1.2)
-
catch23 almost 11 years@Braiam I had the next result
E: Unable to locate package tomcat7
-
catch23 almost 11 years@Braiam I don't know why but I can't write message at this chat room (` You must have 20 reputation on The Stack Exchange Network to talk here. See the faq. `)
-
catch23 almost 11 years
-
catch23 almost 11 years@Braiam I can't write any message.
sudo apt-get update
- is ok Reading package lists... Done. And I see all your messages. -
catch23 almost 11 years@Braiam this doesn't help. stupid system! Keep working at this way.
apt-get
is ok. But I can't installtomcat7
? -
Braiam almost 11 years@nazar_art I pressume it's fixed now?