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

when I do a killall java there is no response...However the next time I press enter I get a response.

Is this normal? Its ruining my cron job as it doesnt mail the killall output.

Using Centos 6.

share|improve this question
    
Java is quite touchy, in my experience. It does not like to die right away, but instead will finish up whatever it's doing before exiting gracefully. –  Joel E Salas Feb 7 '12 at 0:24
    
What do you mean by "there is no response"? Do you mean your killall hangs? Or returns without any output? Or do you mean it appears to work normally but the process doesn't die? Or what? –  David Schwartz Feb 7 '12 at 0:32

1 Answer 1

up vote 0 down vote accepted

A killall, by default, is a polite request for the process to shut down. It may take its time, it may ignore it, it may fail to do it. A common pattern is to send a regular killall, wait a few seconds to see if the process has terminated, send another if not, wait a few more seconds, and then switch to more aggressive termination methods if needed.

share|improve this answer

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.