Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

missing the initrd file in the kernel package

11 views
Skip to first unread message

Antonio Diaz

unread,
Apr 29, 2009, 4:20:10 PM4/29/09
to

Hi,

When I compile the kernel the file "initrd" is not created in spite
of I'm specifying the "--initrd" option in the command line. Exactly,
the command that I'm using to compile the kernel is:

"make-kpkg --initrd --revision=1:xps.10 kernel_image"

May be there is a problem with the application that creates the
initrd file.

Any suggestions?


______________________________________________
LLama Gratis a cualquier PC del Mundo.
Llamadas a fijos y m�viles desde 1 c�ntimo por minuto.
http://es.voice.yahoo.com


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

Manoj Srivastava

unread,
Apr 29, 2009, 5:30:13 PM4/29/09
to
On Wed, Apr 29 2009, Antonio Diaz wrote:

> When I compile the kernel the file "initrd" is not created in spite
> of I'm specifying the "--initrd" option in the command line. Exactly,
> the command that I'm using to compile the kernel is:
>
> "make-kpkg --initrd --revision=1:xps.10 kernel_image"
>
> May be there is a problem with the application that creates the
> initrd file.
>
> Any suggestions?

,----[ Manual page make-kpkg(1) ]
| --initrd
| If make-kpkg is generating a kernel-image package, arrange to
| convey to the hook scripts that this image requires an initrd,
| and that the initrd generation hook scripts should not short
| circuit early. Without this option, the example initramfs hook
| scripts bundled in with ker‐ nel-package will take no action on
| installation. The same effect can be achieved by setting the
| environment variable INITRD to any non empty value. Please note
| that unless there are hook scripts in /etc/kenel or added into
| the hook script parameter of /etc/kernel-img.conf. no initrd
| will be created.
`----

So, drop in scripts in /etc/kernel/post{inst,rm}.d/ to
create/delete the initramfs files. You can use yaird, or
initramfs-tools. For the latter, there are example scripts that you
could use as a starting point:
/usr/share/kernel-package/examples/etc/kernel/post{inst,rm}.d/initramfs

manoj
--
And then there was the lawyer that stepped in cow manure and thought he
was melting...
Manoj Srivastava <sriv...@acm.org> <http://www.golden-gryphon.com/>
1024D/BF24424C print 4966 F272 D093 B493 410B 924B 21BA DABB BF24 424C

emikaadeo

unread,
Apr 29, 2009, 6:50:16 PM4/29/09
to
Manoj Srivastava wrote:

I upgraded to kernel-package 12.010
If i use a :
make-kpkg --initrd kernel_image
then created .deb will have a initrd image ?
And it will install it ?
Sorry but my english is not so good, so i'm trying to get this clear.

Manoj Srivastava

unread,
Apr 29, 2009, 7:40:05 PM4/29/09
to

No. The initrd image has neer been a part of the kernel image
deb, and it still is not. The initramfs/initrd bits arte always
generated on the machine the kernel image is installed upon.

> And it will install it ?

Well, since the initramfs image is not pat of the linux-image-*
packages, install is not the right word. Create is what actually needs
to happen.

Now, nothing is created automatically. you need to provide a
hook script for this to happen. The user provides such scripts. For
example, to invoke mkinitramfs, I did:
--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---

You can look at other example in the examples directory:
/usr/share/kernel-package/examples/
to see if there are other example script you want to cp into
/etc/kernel -- and you can create your own scripts.

> Sorry but my english is not so good, so i'm trying to get this clear.

That's all right. English was my fourth language as well.

manoj
--
That's no moon... Obi-wan Kenobi


Manoj Srivastava <sriv...@acm.org> <http://www.golden-gryphon.com/>
1024D/BF24424C print 4966 F272 D093 B493 410B 924B 21BA DABB BF24 424C

emikaadeo

unread,
Apr 30, 2009, 2:00:19 AM4/30/09
to
Manoj Srivastava wrote:


> Now, nothing is created automatically. you need to provide a
> hook script for this to happen. The user provides such scripts. For
> example, to invoke mkinitramfs, I did:
> --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---
>
> You can look at other example in the examples directory:
> /usr/share/kernel-package/examples/
> to see if there are other example script you want to cp into
> /etc/kernel -- and you can create your own scripts.
>

Now everything is clear to me ;)
Big thanks!

0 new messages