Lines Matching refs:initrd

1 Using the initial RAM disk (initrd)
8 initrd provides the capability to load a RAM disk by the boot loader.
11 from a different device. The previous root (from initrd) is then moved
14 initrd is mainly designed to allow system startup to occur in two phases,
16 where additional modules are loaded from initrd.
18 This document gives a brief overview of the use of initrd. A more detailed
25 When using initrd, the system typically boots as follows:
28 2) the kernel converts initrd into a "normal" RAM disk and
29 frees the memory used by initrd
33 4) root device is mounted. if it is ``/dev/ram0``, the initrd image is
43 9) the initrd file system is removed
46 It is therefore possible to leave processes running on initrd during that
47 procedure. Also note that file systems mounted under initrd continue to
54 initrd adds the following new options::
56 initrd=<path> (e.g. LOADLIN)
64 initrd data is preserved but it is not converted to a RAM disk and
65 the "normal" root file system is mounted. initrd data can be read
66 from /dev/initrd. Note that the data in initrd can have any structure
70 Note: /dev/initrd is read-only and it can only be used once. As soon
71 as the last process has closed it, all data is freed and /dev/initrd
76 initrd is mounted as root, and the normal boot procedure is followed,
85 disk with the desired initrd content, cd to that directory, and run (as an
99 First, a directory for the initrd file system has to be created on the
102 # mkdir /initrd
109 procedure should create the ``/initrd`` directory.
111 If initrd will not be mounted in some cases, its content is still
114 # mknod /dev/initrd b 1 250
115 # chmod 400 /dev/initrd
119 needed to execute programs from initrd (e.g. executable format and file
124 copying the content of the block device to the initrd file. With recent
136 # dd if=/dev/zero of=initrd bs=300k count=1
137 # mke2fs -F -m0 initrd
142 # mount -t ext2 -o loop initrd /mnt
149 5) copy all the files that are needed to properly use the initrd
154 6) correct operation the initrd environment can frequently be tested
163 such a chroot'ed initrd environment.)
168 8) the initrd is now in the file "initrd". Optionally, it can now be
171 # gzip -9 initrd
173 For experimenting with initrd, you may want to take a rescue floppy and
176 initrd.
178 Finally, you have to boot the kernel and load initrd. Almost all Linux
179 boot loaders support initrd. Since the boot process is still compatible
185 (rw is only necessary if writing to the initrd file system.)
189 LOADLIN <kernel> initrd=<disk_image>
193 LOADLIN C:\LINUX\BZIMAGE initrd=C:\LINUX\INITRD.GZ root=/dev/ram0 rw
200 initrd = /boot/initrd.gz
207 Now you can boot and enjoy using initrd.
219 - removing all accesses to the old (initrd) root file system
220 - unmounting the initrd file system and de-allocating the RAM disk
236 # mkdir initrd
237 # pivot_root . initrd
262 Now, the initrd can be unmounted and the memory allocated by the RAM
265 # umount /initrd
268 It is also possible to use initrd with an NFS-mounted root, see the
275 The main motivation for implementing initrd was to allow for modular
280 (e.g. support for RAM disks, initrd, a.out, and the Ext2 FS) and
281 loads initrd
293 7) the boot loader is configured to load an initrd with the set of
294 modules that was used to bring up the system (e.g. ``/initrd`` can be
300 The key role of initrd here is to re-use the configuration data during
308 information as small as possible. In this case, a common initrd could be
314 boot time, but the system loaded from initrd can invoke a user-friendly
320 via initrd from CD; or by booting via a loader like ``LOADLIN`` or directly
334 root file system when linuxrc exits. The initrd file system is then
335 unmounted, or, if it is still busy, moved to a directory ``/initrd``, if
340 the real root file system, not the initrd environment.)
359 mechanism, you may create both ``/linuxrc`` and ``/sbin/init`` in your initrd
369 Once linuxrc exited, the kernel would mount again your initrd as root,
380 .. [#f2] newlib package (experimental), with initrd example