Re: How do I find out if a certain Linux patch has been applied on a system

From: John Reiser (jreiser_at_BitWagon.com)
Date: 11/21/05


Date: Mon, 21 Nov 2005 11:24:09 -0800


> I am new to Linux. Is there a way, I can find out if a certain patch,
> say for the libc, has been applied on a system. Is there a command I
> can use. This is an RHEL4.
> I know the bug number, but don't know how to ascertain if its been
> applied on this box. Its a production box.

Assuming that the system administrator is using the default RHEL management
of software configuration with RPM:
1. Identify the RPM package which contains the file of interest:
     $ rpm -qf /lib/libc.so.6
     glibc-2.3.5-10.3
2. Verify that the files of the associated package, as currently on the
   system, are unchanged from the .rpm:
     $ rpm --verify glibc-2.3.5-10.3
     [output snipped]
3. Check that the desired patch was included in the source of that package.
   Inspecting the %changelog might suffice, if you trust the developer:
     $ rpm --query --changelog glibc-2.3.5-10.3
   To be 100% sure: you must download the source package .src.rpm from
   RedHat Network, then inspect the source to verify that the patch is
   present, and that the build recipe applies it [and does not remove it]:
     $ rpmbuild -bp --target i686 glibc-2.3.5.spec
     [apply eyeballs and brain]

If the system administrator is not using RHEL management, then it might
require behavioral analysis (trial and error) to determine if the patch
has been applied to your system.

-- 


Relevant Pages

  • RE: Creating RPMS from source without Makefile
    ... Creating RPMS from source without Makefile ... For several applications/tools I'd like to create an RPM to make ... You may want to start with a package less complex than httpd ... "Start with pristine sources; then patch as needed. ...
    (RedHat)
  • Errors applying kernel patch 118833-36
    ... install of Solaris 10 11/06. ... However, once the package list is done, I see a worrisome message: ... Below is the complete console output of the patch run. ... Changes for package SUNWnfsskr will not be applied to the system. ...
    (SunManagers)
  • Re: netkit-telnet compile fail. `exit undeclared in main.cc ?
    ... and in what order to run the patches and what is done to compile, install, ... or remove the package. ... patch prior to actual compilation and this patch process fails ... or just the materials that come in the source rpm? ...
    (comp.os.linux.misc)
  • Re: Fedora Updates: whole packages vs patches
    ... single Solaris patch can patch more than one package. ... that diff file and original rpm to generate updated rpm. ...
    (Fedora)
  • Re: Make RPMs from .spec and package source tarball? how?
    ... and then make an RPM based on the ATRPMS spec for the package. ... Install the mythtv source package from atrpms. ... Make the changes you need to the sources and prepare a patch. ...
    (Fedora)