Centos – on Red Hat Enterprise and CentOS, what is creating /var/run/reboot-required

centosredhatupdate

On CentOS 5.8+ and Red Hat Enterprise 6+, when installing/updating packages, I notice a flag file /var/run/reboot-required is created when appropriate. On Ubuntu (and Debian too, I'm guessing), if package "update-notifier-common" is installed, a package postinst script triggers creation of this flag file. On RHEL/CentOS I can't figure out how this is happening.

For instance, on RHEL and CentOS I recently installed several updates and /var/run/reboot-required was created. One of them was an "openssl" package upgrade. I assume this was what created the flag file, since on Ubuntu it also works this way. However I looked at all "rpm -q –scripts" for each updated package, and didn't see anything that was likely to have created that flag file. Mostly I saw "postinstall program: /sbin/ldconfig".

So my questions are:

  • What creates this flag file on RHEL/CentOS?
  • Does it require a special package to be installed, analogous to the "update-notifier-common" package on Ubuntu?

Best Answer

This file isn't referred to in any package script, nor any rpm macro (see /usr/lib/rpm/**/macros.*).

I suspect this came from a non-official package, based on a common practice in the Debian and Ubuntu communities.

There, it can be created by http://packages.debian.org/squeeze/update-notifier.