FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.


» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > Debian > Debian User

 
 
LinkBack Thread Tools
 
Old 02-03-2008, 02:42 PM
"Javier Vasquez"
 
Default Removing /lib/modules/ after linux-image removal

Hi,

I have the following /etc/kernel-img.conf:

do_symlinks = no
do_bootloader = no
do_bootfloppy = no
do_initrd = yes
postinst_hook = /usr/sbin/update-grub
postrm_hook = /usr/sbin/update-grub
#ramdisk = /usr/sbin/mkinitrd.yaird

So when removing a particular kernel image, I get the grub menu update
automatically. However I was wondering if there's already a script
that instead could have called update-grub, and after could have
removed /lib/modules/<corresponding_kernel>.

So far I've been removing manually the modules library, but I guess I
could create a script that does it for me and include it in the
portrm_hook field, but then I should make sure update-grub is also
called from the same script, otherwise I'd keep having non present
kernels in the grub menu. But before doing such thing, I was
wondering this was already accomplished, so that kind of an official
approach ca be taken, .

Thanks,

--
Javier


--
To UNSUBSCRIBE, email to debian-user-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
 
Old 02-04-2008, 04:37 AM
"Kushal Kumaran"
 
Default Removing /lib/modules/ after linux-image removal

On Feb 3, 2008 9:12 PM, Javier Vasquez <jevv.cr@gmail.com> wrote:
> Hi,
>
> I have the following /etc/kernel-img.conf:
>
> do_symlinks = no
> do_bootloader = no
> do_bootfloppy = no
> do_initrd = yes
> postinst_hook = /usr/sbin/update-grub
> postrm_hook = /usr/sbin/update-grub
> #ramdisk = /usr/sbin/mkinitrd.yaird
>
> So when removing a particular kernel image, I get the grub menu update
> automatically. However I was wondering if there's already a script
> that instead could have called update-grub, and after could have
> removed /lib/modules/<corresponding_kernel>.
>
> <snip>

Shouldn't the directory be removed for you by the package manager
automatically once the appropriate packages are gone? Check with dpkg
-S /lib/modules/<whatever directory>. It should tell you what
packages are keeping that directory back for you.

--
Kushal


--
To UNSUBSCRIBE, email to debian-user-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
 

Thread Tools




All times are GMT. The time now is 05:04 PM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright 2007 - 2008, www.linux-archive.org