Server Fault is a question and answer site for system and network administrators. 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 love how "zypper ps" in openSuse 11.2 tells you which currently running processes need to be restarted after an update with "zypper update".

How can I do this with other distros, in particular CentOS?

share|improve this question

A generic solution would be:

lsof | grep deleted

This gives a list of files which are deleted, but still referenced by processes.

FYI, internally, the system already replaced the filename, hence it points to the new data. The old data blocks still exist at the disk until the remaining applications have closed the file.

share|improve this answer

I can see this is a very old post, but nevertheless here's answer for at least Fedora:

yum install yum-plugin-ps

After installation yum will tell you which processes need restart after upgrading packages.

share|improve this answer

In Debian you can use checkrestart from the debian-goodies package.

share|improve this answer

yum has no option to do this. and i don't know about a plugin which could this. but when you have time and fun with scripting, it should be possible to do it with yum commands.

  • get package update list
  • get whatprovides for this list
  • check the whatprovides list against your running processes
  • for every match print out a line to restart the service

this is just a rough outline of the script, but should do the same as zypper ps.

share|improve this answer

For Fedora/CentOS/RHEL the command yum ps doesn't actually exist. Instead look at needs-restarting which is provided by the yum-utils package. This looks like it will provide the information you're wanting.

share|improve this answer
I don't understand the downvotes on this. I tried this and it seems to work. – Michael Hampton Oct 7 '13 at 16:13
Unfortunately needs-restarting is only included in yum-utils for RHEL >= 6, so I'm out of luck on my RHEL 5 boxes. – metavida Feb 25 at 23:46

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.