Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

i am on ubuntu 10.04 server, having tomcat6. because of some reasons i had to un-install it so i used

apt-get purge tomcat6

it removed tomcat and config files.

now i am trying to install tomcat6 again, using

apt-get install tomcat6

it says

Setting up tomcat6 (6.0.24-2ubuntu1.9) ...
Adding system user `tomcat6' (UID 109) ...
Adding new user `tomcat6' (UID 109) with group `tomcat6' ...
Not creating home directory `/usr/share/tomcat6'.
* Starting Tomcat servlet engine tomcat6            [fail]
invoke-rc.d: initscript tomcat6, action "start" failed.

looked into log

    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:597)
    at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:289)
    at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:414)
java.util.logging.ErrorManager: 1: FileHandler is closed or not yet initialized, unable to log [Dec 2, 2011 7:39:08 AM org.apache.coyote.http11.Http11Protocol pause
INFO: Pausing Coyote HTTP/1.1 on http-8080

I am not tomcat expert, so not sure should i have to reboot server to install tomcat6 again. can anyone please help?

[EDIT] - as suggested by Erick Robertson i uploaded same question on stackfault. As i am looking my answer as soon as possible, you can answer at any location

[EDIT-2] - i have deleted its duplicate on serverfault. Got it working, as mentioned by Mike, i was missing 1 step of killing processes kill -9 pid1 pid2 . Thanks very much Mike

share|improve this question

migrated from stackoverflow.com Dec 2 '11 at 16:28

This question came from our site for professional and enthusiast programmers.

6  
Voted to move to serverfault. –  Erick Robertson Dec 2 '11 at 13:50
2  
@bee You don't need to cross-post your question; moderators have the ability to migrate your question from one StackExchange site to another. –  Mike Dec 2 '11 at 14:10
1  
You should have a line earlier in the log stating the error, the log fragment in your question does not include the root cause. –  Løkling Dec 2 '11 at 14:14
1  
@Mike- Thanks for sharing, i did not know that great feature. So you mean i should delete my question from stackfault –  bee Dec 2 '11 at 14:21
add comment

1 Answer

up vote 3 down vote accepted

If I were looking into this myself, I would run sudo apt-get remove --purge tomcat6 (again). Once that was completed, I would run ps -eaf | grep tomcat | grep -v -e grep to check for any stray running Tomcat processes. Once I had confirmed that Tomcat was no longer running, I would reinstall: sudo apt-get install tomcat6.

share|improve this answer
    
don't you think tomcat processes should be grepped as grep java? –  Oleg Mikheev Dec 2 '11 at 14:00
    
i used <pre><code> apt-get remove --purge tomcat6 </code></pre> it says The group code tomcat6 does not exist. dpkg: warning: while removing tomcat6, directory '/etc/tomcat6/Catalina/localhost' not empty so not removed. dpkg: warning: while removing tomcat6, directory '/etc/tomcat6/Catalina' not empty so not removed. dpkg: warning: while removing tomcat6, directory '/etc/tomcat6' not empty so not removed.code. Should i run coderm -Rf /etc/tomcat6`code` –  bee Dec 2 '11 at 14:03
1  
@Oleg: No, in fact, I do not think that tomcat processes should be grepped as java from experience... @bee: Yes, I would rm -rf /etc/tomcat6 in that case. –  Mike Dec 2 '11 at 14:08
2  
If you do not have the tomcat6 package installed anymore, yet you still have processes running, you should kill them. The above grep command will get you their pids (second column of the grep output). Just run sudo kill -9 pid1 pid2 etc (replace pid1 and pid2 with your actual pids. You can put as many pids on the line as you want.) –  Mike Dec 2 '11 at 14:17
1  
@Mike - thanks very much, your killing method ( kill -9 pid1 pid2 ) was great its working. Thanks again –  bee Dec 2 '11 at 14:32
show 2 more comments

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.