[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: kernel-package??



On Thursday 30 April 2009 14:30:42 Manoj Srivastava wrote:
> On Thu, Apr 30 2009, thveillon.debian wrote:
>
> ers are non-essential.
>
> > Installing the created .deb will take care of all the linking (/initrd,
> > /vmlinuz, build dir...), boot-loader update (with grub at least), initrd
> >  creation/update and such.
>
>         Actually, with the 12.XX branch, you get to choose what happens
>  when the kernel image is installed, by dropping scripts into
>  /etc/kernel -- by default, no action is taken
>
>          For example, to create an initramfs, I did:
> --8<---------------cut here---------------start------------->8---
>  cp /usr/share/kernel-package/examples/etc/kernel/postinst.d/yaird \
>     /etc/kernel/postinst.d/
>  cp /usr/share/kernel-package/examples/etc/kernel/postrm.d/yaird \
>     /etc/kernel/postrm.d/
> --8<---------------cut here---------------end--------------->8---
>
>         Or, alternately, you could do:
> --8<---------------cut here---------------start------------->8---
>  cp /usr/share/kernel-package/examples/etc/kernel/postinst.d/initramfs \
>     /etc/kernel/postinst.d/
>  cp /usr/share/kernel-package/examples/etc/kernel/postrm.d/initramfs \
>     /etc/kernel/postrm.d/
> --8<---------------cut here---------------end--------------->8---
>
>         To run grub, I have in /etc/kernel-img.conf:
> --8<---------------cut here---------------start------------->8---
> postinst_hook = update-grub
> postrm_hook   = update-grub
> --8<---------------cut here---------------end--------------->8---
>
>         But really, you can substitute your own scripts, or decide not
>  to use initrds (which is a sane option if you are building your own
>  kernels and thus might not have any modules at all).
>
>         manoj

My intention at this point is to make a detailed list of the components on a 
particular system so I can remove everything that is not needed. These would 
be older systems that will never be upgraded or need new hardware so the 
kernel don't need a lot of options concerning hardware. For example, I have 
used ext3 on the drives and they don't need to access anything else and will 
remove all support for ext2, ext4, NTFS and everything else.  I intend to 
compile everything into the kernel without using modules. It's my 
understanding from what I have read that this will result in a leaner and some 
what faster kernel for that system. Is that a reasonable assumption and 
approach?

The whole subject of initrds scripts is something I will need to study up on. 
But are you saying that if I don't use modules that I don't need to worry 
about needing these scripts?

Thanks,
Randy


Reply to: