Ask Ubuntu is a question and answer site for Ubuntu users and developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I would like to know, what is the difference between initrd and initramfs?

share|improve this question
up vote 11 down vote accepted

Initrd is deprecated, replaced by Initramfs, which doesn't have some of the weaknesses of initrd:

  • Initrd requires at least one file system driver be compiled into the kernel
  • A disk created by Initrd has got to have a fixed size
  • All of the reads/writes on Initrd are buffered redundantly (unnecessarily) into main memory

I think that's all.

How does this update-initramfs command generate /boot/initrd.img?

It makes the necessary files into a cpio archive, which is a binary archive format (very similar to tar, not extensively used in Linux) and then uses gzip to compress that archive. Gzip is not an archive itsef, just a compression (which is why you get .tar.gz archive files).

At boot time, the archive is uncompressed and unpacked onto a   ram-disk.

Also see: How a computer boots

share|improve this answer
"Initrd requires at least one file system driver be compiled into the kernel".. I dint get much idea on this. Could you please explain this?? – Sen Nov 26 '10 at 10:16
Normally, File system drivers can be bolted onto the operating system at will, for some things they have to be compiled right into the kernel. Which is a pain, since all kernel versions have to be customised, get larger, introduce additional dependencies and so on. (At least that's what I believe to be the case, could well be wrong, I've not got great knowledge about file systems specifically) – Stefano Palazzo Nov 26 '10 at 10:28
Is it like initramfs need not be mounted initially?? – Sen Nov 26 '10 at 10:55
All file systems have to be mounted before they can be used. If you want to learn about initramfs in depth, have a look at - there's a far more detailed explanation. – Stefano Palazzo Nov 26 '10 at 11:02
How does this update-initramfs command generate /boot/initrd.img? – Sen Dec 8 '10 at 4:56
  • initrd was block device based, initramfs is file base.

  • with initrd, you created a file system image. with initramfs, you create an archive with the files which the kernel extracts to a tmpfs.

share|improve this answer
could you please explain me the steps from the start to the loading and reading of initramfs? – Sen Nov 26 '10 at 12:12

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.