Ask Ubuntu is a question and answer site for Ubuntu users and developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I am writing a shell script in which I must close Adobe Acrobat.

What command should I use?

share|improve this question
up vote 2 down vote accepted

Well, depending on what you are doing with your scripting but closing applications can be achieved by the pkill command, and for your specific case you can take a look at this. pkill From Wikipedia

In this case, dropping the pkill -3 acroread in a terminal (or via your shell script) will result in the "forcing to close" Adobe Acrobat Reader.

Good luck!

share|improve this answer
Thank you! Why the -3 though? – David Faux Apr 21 '12 at 18:09
I have read that in the majority of the cases, pkill command without any number sends the "signal 15" which is used in order to terminate the process the normal way. Certain processes can't be killed this way as they ignore it and won't terminate, in which case we need to use signal 9 option. Nevertheless, someday I found a document reading that sending the -3 will result in a not so aggressive kill signal, which will be useful for your case. Understanding this I think that you can use -15 but it won't ensure that the process will be killed, so we better use -3 – Geppettvs D'Constanzo Apr 21 '12 at 18:31

Your Answer


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.