Dracut/Options

From FedoraProject

< Dracut(Difference between revisions)
Jump to: navigation, search
(NFS)
Line 20: Line 20:
 
<pre>-d, --drivers LIST</pre>
 
<pre>-d, --drivers LIST</pre>
 
{{admon/note|Specify a space-separated list of kernel modules to include in the initramfs.}}
 
{{admon/note|Specify a space-separated list of kernel modules to include in the initramfs.}}
 +
== -k, --kmoddir ==
 +
<pre>-k, --kmoddir</pre>
 +
{{admon/note|Specify the directory, where to look for kernel modules.}}
 +
==--fwdir ==
 +
<pre>--fwdir {DIR}</pre>
 +
{{admon/note|Specify additional directory, where to look for firmwares.}}
 +
==--kernel-only==
 +
<pre>--kernel-only</pre>
 +
{{admon/note|Only install kernel drivers and firmware files.}}
 +
==--no-kernel==
 +
<pre>--no-kernel</pre>
 +
{{admon/note|Do not install kernel drivers and firmware files.}}
 +
==--strip==
 +
<pre>--strip</pre>
 +
{{admon/note|Strip binaries in the initramfs (default).}}
 +
==--nostrip==
 +
<pre>--nostrip</pre>
 +
{{admon/note|No not strip binaries in the initramfs.}}
 
==-h, --help==
 
==-h, --help==
 
<pre>-h, --help</pre>
 
<pre>-h, --help</pre>

Revision as of 08:03, 29 July 2009


Contents

Options

SYNOPSIS

dracut [OPTION]... <image>  <kernel-version>

-f, --force

-f, --force
Note.png
Overwrite existing initramfs file.

-m, --modules

-m, --modules LIST
Note.png
Specify a space-separated list of dracut modules to call when building the initramfs. Modules are located in /usr/share/dracut/modules.d.

-o, --omit

-o, --omit LIST
Note.png
Omit a space-separated list of dracut modules.

-a, --add

-a, --add LIST
Note.png
Add a space-separated list of dracut modules.

-d, --drivers

-d, --drivers LIST
Note.png
Specify a space-separated list of kernel modules to include in the initramfs.

-k, --kmoddir

-k, --kmoddir
Note.png
Specify the directory, where to look for kernel modules.

--fwdir

--fwdir {DIR}
Note.png
Specify additional directory, where to look for firmwares.

--kernel-only

--kernel-only
Note.png
Only install kernel drivers and firmware files.

--no-kernel

--no-kernel
Note.png
Do not install kernel drivers and firmware files.

--strip

--strip
Note.png
Strip binaries in the initramfs (default).

--nostrip

--nostrip
Note.png
No not strip binaries in the initramfs.

-h, --help

-h, --help
Note.png
Display help text and exit.

--debug

--debug
Note.png
Output debug information of the build process

v, --verbose

v, --verbose
Note.png
Verbose output during the build process

-c, --conf

-c, --conf FILE
Note.png
Specify configuration file to use. Default: /etc/dracut.conf

-l, --local

-l, --local
Note.png
Local mode. Use modules from the current working directory instead of the system-wide installed in /usr/share/dracut/modules.d. Useful when running dracut from a git checkout.

-H, --hostonly

-H, --hostonly
Note.png
Host-Only mode: Install only what is needed for booting the local host instead of a generic host.

-i, --include

-i, --include SOURCE TARGET
Note.png
Include the files in the SOURCE directory into the target directory in the final initramfs.

-I, --install

-I, --install LIST
Note.png
Install the space separated list of files into the initramfs.

Dracut kernel command line parameters

The root filesystem used by the kernel is specified in the boot configuration file, as always. The traditional root=/dev/hda1 style device specification is allowed. If a label is used, as in root=LABEL=rootPart the initrd will search all available devices for an ext2 or ext3 filesystem with the appropriate label, and mount that device as the root filesystem. root=UUID=uuidnumber will mount the partition with that UUID as the root filesystem.

Limitations

  • Command line length: 2048
  • dhcp root-path: 255

Standard

init=<path to real init>
root=<path to blockdevice>
Note.png
Specify e.g. /dev/sda1 or /dev/disk/by-path/pci-0000:00:1f.1-scsi-0:0:1:0-part1

I18N

KEYBOARDTYPE=sun|pc
Note.png
Will be written to /etc/sysconfig/keyboard in the initramfs
KEYTABLE=<keytable filename>
Note.png
Will be written to /etc/sysconfig/keyboard in the initramfs
SYSFONT= Console font
Note.png
Will be written to /etc/sysconfig/i18n in the initramfs
SYSFONTACM= Unicode font map
Note.png
Will be written to /etc/sysconfig/i18n in the initramfs
UNIMAP= Unicode font map
Note.png
Will be written to /etc/sysconfig/i18n in the initramfs
LANG=<locale>
Note.png
Will be written to /etc/sysconfig/i18n in the initramfs

Bootsplash - plymouth

rd_plytheme=<theme name>
Note.png
Specify the plymouth bootsplash theme (fallback is text)

LVM

rd_NO_LVM
Note.png
Disable LVM detection
rd_LVM_VG=<volume group name>
Note.png
Only activate the volume groups with the given name

crypto LUKS

rd_NO_LUKS
Note.png
Disable crypto LUKS detection
rd_LUKS_UUID=<luks uuid>
Note.png
Only activate the LUKS partitions with the given UUID

MD

rd_NO_MD
Note.png
Disable MD RAID detection
rd_MD_UUID=<md uuid>
Note.png
Only activate the raid sets with the given UUID

DMRAID

rd_NO_DM
Note.png
Disable DM RAID detection
rd_DM_UUID=<dmraid uuid>
Note.png
Only activate the raid sets with the given UUID

DHCP

root=dhcp
Note.png
Get IP from dhcp server, root-path option from dhcp specifies root location.

NFS

root=[<server-ip>:]<root-dir>[:<nfs-options>]
root=nfs:[<server-ip>:]<root-dir>[:<nfs-options>]
root=nfs4:[<server-ip>:]<root-dir>[:<nfs-options>]
Note.png
Mount nfs share from <server-ip>:/<root-dir> If no server-ip is given use dhcp next_server. nfs-options can be appended with the prefix ":" or ","
root=dhcp root-path=<server-ip>:<root-dir>[,<nfs-options>]
root=dhcp root-path=nfs:<server-ip>:<root-dir>[,<nfs-options>]
root=dhcp root-path=nfs4:<server-ip>:<root-dir>[,<nfs-options>]
Note.png
root=dhcp alone directs initrd to look at the DHCP root-path where NFS options can be specified.
root=/dev/nfs nfsroot=[<server-ip>:]<root-dir>[,<nfs-options>]
Warning (medium size).png
Deprecated! Kernel Documentation/filesystems/nfsroot.txt defines this method. This is supported by dracut but not recommended.

iSCSI

root=iscsi:[<servername>]:[<protocol>]:[<port>]:[<LUN>]:<targetname>::
Note.png
Protocol defaults to "6", LUN defaults to "0". If the "servername" field is provided by BOOTP or DHCP, then that field is used in conjunction with other associated fields to contact the boot server in the Boot stage (Section 7). However, if the "servername" field is not provided, then the "targetname" field is then used in the Discovery Service stage in conjunction with other associated fields.RFC4173
root=??? iscsiroot=...::
root=??? iscsi_initiator= iscsi_target_name= iscsi_target_ip= iscsi_target_port= iscsi_target_group= iscsi_username= iscsi_password= iscsi_in_username= iscsi_in_password=::
root=??? iscsi_firmware::

NBD

root=nbd:<server>:<port>[:<fstype>][:<mountopts>]
Note.png
Mount nbd share from <server>.
root=dhcp
Note.png
root-path=nbd:<server>:<port>[:<fstype>][:<mountopts>]. root=dhcp alone directs initrd to look at the DHCP root-path where NBD options can be specified. This syntax is only usable in cases where you are directly mounting the volume as the rootfs.

Network

ip=[dhcp|on|any]
Note.png
Get ip from dhcp server from all interfaces.If root=dhcp, loop sequentially through all interfaces '(eth0, eth1, ...)' and use the first with a valid DHCP root-path.
ip=<interface>:[dhcp|on|any]
Note.png
Get ip from dhcp server on a specific interface.
ip=<client-IP-number>:<gateway-IP-number>:<netmask>:<client-hostname>:<interface>:[dhcp|on|any|]
Note.png
Explicit network configuration

Misc

rdblacklist=<modulename>
Note.png
TBD: do not load modulename.

Debug

rdinitdebug
Note.png
Drop to a shell, if the imitramfs fails.
rdinitdebug
Note.png
set -x for the dracut shell.
rdbreak=[pre-udev|pre-mount|mount|pre-pivot|]
Note.png
Drop the shell on defined breakpoint.
rdudevinfo
Note.png
Set udev to loglevel info.
rdudevdebug
Note.png
Set udev to loglevel debug.
rdnetdebug
Note.png
Debug network scripts in dracut.

Configuration in initrd

/conf/conf.d/* 
Note.png
Command line options can override values set here