locked
Linux Integration Services + DKMS + removing old kernel RRS feed

  • Question

  • Linux Integration Services + DKMS + old remove kernel


    Guys,
    Need a little help with Dynamic Kernel Module Support (DKMS) 
    Installed as described: http://support.microsoft.com/kb/2387594

    Updated kernel to next version from 2.6.18-274.3.1.el5 to 2.6.18-274.7.1.el5

    Checked:
    # /sbin/modinfo vmbus
    filename:       /lib/modules/2.6.18-274.7.1.el5/weak-updates/vmbus.ko
    version:        2.1.25
    license:        GPL
    srcversion:     3C1899C419665CB2514F2D0
    depends:       
    vermagic:       2.6.18-274.3.1.el5 SMP mod_unload 686 REGPARM 4KSTACKS gcc-4.1
    parm:           vmbus_irq:int
    parm:           vmbus_loglevel:int

    Removed old kernel:
    yum remove $(rpm -q kernel | grep -v `uname -r`)

    Loaded plugins: fastestmirror
    Setting up Remove Process
    Resolving Dependencies
    --> Running transaction check
    ---> Package kernel.i686 0:2.6.18-274.3.1.el5 set to be erased
    --> Finished Dependency Resolution

    Dependencies Resolved

    =============================================================================================================================
     Package                   Arch                    Version                                Repository                    Size
    =============================================================================================================================
    Removing:
     kernel                    i686                    2.6.18-274.3.1.el5                     installed                     47 M

    Transaction Summary
    =============================================================================================================================
    Remove        1 Package(s)
    Reinstall     0 Package(s)
    Downgrade     0 Package(s)

    Is this ok [y/N]: y
    Downloading Packages:
    Running rpm_check_debug
    Running Transaction Test
    Finished Transaction Test
    Transaction Test Succeeded
    Running Transaction
    dkms: removing: linuxic 2.1 (2.6.18-274.3.1.el5) (i686)

    -------- Uninstall Beginning --------
    Module:  linuxic
    Version: 2.1
    Kernel:  2.6.18-274.3.1.el5 (i686)
    -------------------------------------

    Status: Before uninstall, this module version was ACTIVE on this kernel.
    Removing any linked weak-modules

    vmbus.ko:
     - Uninstallation
       - Deleting from: /lib/modules/2.6.18-274.3.1.el5/extra/
     - Original module
       - Archived original module found in the DKMS tree
       - Moving it to: /lib/modules/2.6.18-274.3.1.el5/kernel/drivers/vmbus/

    netvsc.ko:
     - Uninstallation
       - Deleting from: /lib/modules/2.6.18-274.3.1.el5/extra/
     - Original module
       - Archived original module found in the DKMS tree
       - Moving it to: /lib/modules/2.6.18-274.3.1.el5/kernel/drivers/vmbus/

    storvsc.ko:
     - Uninstallation
       - Deleting from: /lib/modules/2.6.18-274.3.1.el5/extra/
     - Original module
       - Archived original module found in the DKMS tree
       - Moving it to: /lib/modules/2.6.18-274.3.1.el5/kernel/drivers/vmbus/

    blkvsc.ko:
     - Uninstallation
       - Deleting from: /lib/modules/2.6.18-274.3.1.el5/extra/
     - Original module
       - Archived original module found in the DKMS tree
       - Moving it to: /lib/modules/2.6.18-274.3.1.el5/kernel/drivers/vmbus/
    depmod....

    Removing original_module from DKMS tree for kernel 2.6.18-274.3.1.el5 (i686)

    DKMS: uninstall Completed.

    ------------------------------
    Deleting module version: 2.1
    completely from the DKMS tree.
    ------------------------------
    Done.
      Erasing        : kernel                                                                                                1/1

    Removed:
      kernel.i686 0:2.6.18-274.3.1.el5                                                                                           

    Complete!
    #
    # reboot

    Broadcast message from root (pts/1) (Tue Oct 25 16:49:48 2011):

    The system is going down for reboot NOW!

    # /sbin/modinfo vmbus
    modinfo: could not open /lib/modules/2.6.18-274.7.1.el5/weak-updates/vmbus.ko: No such file or directory


    vmbus module disappeared
    L

    Obviously, it was removed from 2.6.18-274.3.1.el5 only, not from 2.6.18-274.7.1.el5

    >Status: Before uninstall, this module version was ACTIVE on this kernel.
    >Removing any linked weak-modules
    Do I have to reinstall it every time I remove old kernels?

    Tuesday, October 25, 2011 9:11 PM

Answers

  • Got it, the sequence below explains everything (no need to for dkms add -m linuxic -v 2.1):

    dkms status

    yum remove $(rpm -q kernel | grep -v `uname -r`)
    dkms status

    dkms build -m linuxic -v 2.1
    dkms status

    dkms install --force -m linuxic -v 2.1
    dkms status

    Tuesday, October 25, 2011 10:49 PM

All replies

  • That was for CentOS 5.6
    Tuesday, October 25, 2011 9:16 PM
  • Got it, the sequence below explains everything (no need to for dkms add -m linuxic -v 2.1):

    dkms status

    yum remove $(rpm -q kernel | grep -v `uname -r`)
    dkms status

    dkms build -m linuxic -v 2.1
    dkms status

    dkms install --force -m linuxic -v 2.1
    dkms status

    Tuesday, October 25, 2011 10:49 PM