dnstop

package: dnstop

title: dnstop(8)

text:
# dnstop(8)

## NAME
dnstop — displays various tables of DNS traffic on your network

## SYNOPSIS
dnstop

[-46apsQR] [-b expression] [-i address] [-f filter] [-r interval] [device] [savefile]

## DESCRIPTION
dnstop is a small tool to listen on device or to parse the file savefile and collect and print statistics on the local network's DNS traffic. You must have read access to /dev/bpf*.

## COMMAND LINE OPTIONS
The options are as follows:

-4

count only messages with IPv4 addresses

-6

count only messages with IPv6 addresses

-Q

count only DNS query messages

-R

count only DNS reply messages

-a

anonymize addresses

-b expression

BPF filter expression

(default: udp port 53)

-i address

ignore select addresses

-p

Do not put the interface into promiscuous mode.

-r

Redraw interval (seconds).

-l level

keep counts on names up to level domain name levels. For example, with -l 2 (the default), dnstop will keep two tables: one with top-level domain names, and another with second-level domain names. Increasing the level provides more details, but also requires more memory and CPU.

-f

input filter name The "unknown-tlds" filter includes only queries for TLDs that are bogus. Useful for identifying hosts/servers that leak queries for things like "localhost" or "workgroup."

The "A-for-A" filter includes only A queries for names that are already IP addresses. Certain Microsoft Windows DNS servers have a known bug that forward these queries.

The "rfc1918-ptr" filter includes only PTR queries for addresses in RFC1918 space. These should never leak from inside an organization.

The "refused" filter, when used with the -R option, tells dnstop to count only replies with rcode REFUSED.

-n name

Only count messages within the domain name

-P

Print "progress" messages on stderr when in non-interactive mode.

-B buckets

Use buckets hash table buckets.

-X

Do not tabulate the sources + query name counters. This can significantly reduce memory usage on busy servers and large savefiles.

savefile

a captured network trace in pcap format

device

ethernet device (ie fxp0)

## RUN TIME OPTIONS
While running, the following options are available to alter the display:

s

display the source address table

d

display the destination address table

t

display the breakdown of query types seen

r

display the breakdown of response codes seen

o

display the breakdown of opcodes seen

1

show 1st level query names

2

show 2nd level query names

3

show 3rd level query names

4

show 4th level query names

5

show 5th level query names

6

show 6th level query names

7

show 7th level query names

8

show 8th level query names

9

show 9th level query names

!

show sources + 1st level query names

@

show sources + 2nd level query names

\#

show sources + 3rd level query names

$

show sources + 4th level query names

%

show sources + 5th level query names

^

show sources + 6th level query names

&

show sources + 7th level query names

*

show sources + 8th level query names

(

show sources + 9th level query names

^R

reset the counters

^X

exit the program

space

redraw

?

help

## NON-INTERACTIVE MODE
If stdout is not a tty, dnstop runs in non-interactive mode. In this case, you must supply a savefile for reading, instead of capturing live packets. After reading the entire savefile, dnstop prints the top 50 entries for each table.

## HOW MESSAGES ARE COUNTED
By default dnstop examines only query messages and ignores replies. In this case the response code table is meaningless and will likely show 100% "Noerror."

If you supply (only) the -R command line option, dnstop examines replies and ignores queries. This allows you to see meaningful response code values, as well as all the other tables. In this case all the query attributes (such as type and name) are taken from the Question section of the reply.

Note, however, that it is common for a stream of DNS messages to contain more queries than replies. This could happen, for example, if the server is too busy to respond to every single query, or if the server is designed to ignore malformed query messages. Therefore, you might want to examine both queries and replies by giving both -R and -Q command line options. In this case, only the response code counts are taken from the replies and all other attributes are taken from the queries.

## AUTHORS
Duane Wessels (wessels@measurement-factory.com)

Mark Foster (mark@foster.cc)

Jose Nazario (jose@monkey.org)

Sam Norris <@ChangeIP.com>

Max Horn <@quendi.de>

John Morrissey <jwm@horde.net>

Florian Forster <octo@verplant.org>

Dave Plonka <plonka@cs.wisc.edu>

http://dnstop.measurement-factory.com/

## BUGS
Does not support TCP at this time.


dnstracer

package: dnstracer

title: dnstracer(8)

text:
# dnstracer(8)

## NAME
dnstracer - trace a chain of DNS servers to the source

## SYNOPSIS
dnstracer [options] name

## DESCRIPTION
dnstracer determines where a given Domain Name Server (DNS) gets its information from, and follows the chain of DNS servers back to the servers which know the data.

Options are:

-c

Disable local caching.

-C

Enable negative caching.

-o

Enable overview of received answers at the end.

-q queryclass

Change the query-class, default is A. You can either specify a number of the type (if you're brave) or one of the following strings: a, aaaa, a6, soa, cname, hinfo, mx, ns, txt and ptr.

-r retries

Number of retries for DNS requests, default 3.

-s server

DNS server to use for the initial request, default is aquired from the system. If a dot is specified (.), A.ROOT-SERVERS.NET will be used.

-v

Be verbose on what sent or received.

-4

Use only IPv4 servers, don't query IPv6 servers (only available when IPv6 support hasn't been disabled)

-S sourceaddress

Use this as source-address for the outgoing packets.

## HOW IT WORKS
It sends the specified name-server a non-recursive request for the name.

Non-recursive means: if the name-server knows it, it will return the data requested. If the name-server doesn't know it, it will return pointers to name-servers that are authoritive for the domain part in the name or it will return the addresses of the root name-servers.

If the name server does returns an authoritative answer for the name, the next server is queried. If it returns an non-authoritative answer for the name, the name servers in the authority records will be queried.

The program stops if all name-servers are queried.

Make sure the server you're querying doesn't do forwarding towards other servers, as dnstracer is not able to detect this for you.

It detects so called lame servers, which are name-servers which has been told to have information about a certain domain, but don't have this information.

## EXAMPLES
Search for the A record of www.mavetju.org on your local nameserver:

dnstracer www.mavetju.org

Search for the MX record of mavetju.org on the root-nameservers:

dnstracer "-s" . "-q" mx mavetju.org

Search for the PTR record (hostname) of 212.204.230.141:

dnstracer "-q" ptr 141.230.204.212.in-addr.arpa

And for IPv6 addresses:

dnstracer "-q" ptr "-s" . "-o" 2.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.6.4.0.2.0.0.0.0.8.b.0.e.f.f.3.ip6.int

## SEE ALSO
ntptrace(8), traceroute(8), dig(1)

## AUTHOR
Edwin Groothuis, edwin@mavetju.org (http://www.mavetju.org)

See http://www.mavetju.org/contacts.php for mailing-lists.


dockerd

package: docker-cli

title: dockerd(8)

summary: Enable daemon mode

text:
# dockerd(8)

## NAME
dockerd - Enable daemon mode

## SYNOPSIS
dockerd [--add-runtime[=[]]] [--allow-nondistributable-artifacts[=[]]] [--api-cors-header=[=API-CORS-HEADER]] [--authorization-plugin[=[]]] [-b|--bridge[=BRIDGE]] [--bip[=BIP]] [--cgroup-parent[=[]]] [--config-file[=path]] [--containerd[=SOCKET-PATH]] [--data-root[=/var/lib/docker]] [-D|--debug] [--default-cgroupns-mode[=host]] [--default-gateway[=DEFAULT-GATEWAY]] [--default-gateway-v6[=DEFAULT-GATEWAY-V6]] [--default-address-pool[=DEFAULT-ADDRESS-POOL]] [--default-network-opt[=DRIVER=OPT=VALUE]] [--default-runtime[=runc]] [--default-ipc-mode=MODE] [--default-shm-size[=64MiB]] [--default-ulimit[=[]]] [--dns[=[]]] [--dns-opt[=[]]] [--dns-search[=[]]] [--exec-opt[=[]]] [--exec-root[=/var/run/docker]] [--experimental[=false]] [--fixed-cidr[=FIXED-CIDR]] [--fixed-cidr-v6[=FIXED-CIDR-V6]] [-G|--group[=docker]] [-H|--host[=[]]] [--help] [--http-proxy[""]] [--https-proxy[""]] [--icc[=true]] [--init[=false]] [--init-path[=""]] [--insecure-registry[=[]]] [--ip[=0.0.0.0]] [--ip-forward[=true]] [--ip-masq[=true]] [--iptables[=true]] [--ipv6] [--isolation[=default]] [-l|--log-level[=info]] [--label[=[]]] [--live-restore[=false]] [--log-driver[=json-file]] [--log-opt[=map[]]] [--mtu[=0]] [--max-concurrent-downloads[=3]] [--max-concurrent-uploads[=5]] [--max-download-attempts[=5]] [--no-proxy[""]] [--node-generic-resources[=[]]] [-p|--pidfile[=/var/run/docker.pid]] [--raw-logs] [--registry-mirror[=[]]] [-s|--storage-driver[=STORAGE-DRIVER]] [--seccomp-profile[=SECCOMP-PROFILE-PATH]] [--selinux-enabled] [--shutdown-timeout[=15]] [--storage-opt[=[]]] [--swarm-default-advertise-addr[=IP|INTERFACE]] [--tls] [--tlscacert[= /.docker/ca.pem]] [--tlscert[= /.docker/cert.pem]] [--tlskey[= /.docker/key.pem]] [--tlsverify] [--userland-proxy[=true]] [--userland-proxy-path[=""]] [--userns-remap[=default]] [--validate]

## DESCRIPTION
dockerd is used for starting the Docker daemon (i.e., to command the daemon to manage images, containers etc). So dockerd is a server, as a daemon.

To run the Docker daemon you can specify dockerd. You can check the daemon options using dockerd --help. Daemon options should be specified after the dockerd keyword in the following format.

dockerd [OPTIONS]

## OPTIONS
--add-runtime=[]

Runtimes can be registered with the daemon either via the configuration file or using the --add-runtime command line argument.

The following is an example adding 2 runtimes via the configuration:

```
{
	"default-runtime": "runc",
	"runtimes": {
		"runc": {
			"path": "runc"
		},
		"custom": {
			"path": "/usr/local/bin/my-runc-replacement",
			"runtimeArgs": [
				"--debug"
			]
		}
	}
}
```

This is the same example via the command line:

```
$ sudo dockerd --add-runtime runc=runc --add-runtime custom=/usr/local/bin/my-runc-replacement
```

Note: defining runtime arguments via the command line is not supported.

--allow-nondistributable-artifacts=[]

Push nondistributable artifacts to the specified registries.

List can contain elements with CIDR notation to specify a whole subnet.

This option is useful when pushing images containing nondistributable

artifacts to a registry on an air-gapped network so hosts on that network can

pull the images without connecting to another server.

Warning: Nondistributable artifacts typically have restrictions on how

and where they can be distributed and shared. Only use this feature to push

artifacts to private registries and ensure that you are in compliance with

any terms that cover redistributing nondistributable artifacts.

--api-cors-header=""

Set CORS headers in the Engine API. Default is cors disabled. Give urls like

" ⟨http://foo⟩, ⟨http://bar⟩, ...". Give "*" to allow all.

--authorization-plugin=""

Set authorization plugins to load

-b, --bridge=""

Attach containers to a pre-existing network bridge; use 'none' to disable

container networking

--bip=""

Use the provided CIDR notation address for the dynamically created bridge

(docker0); Mutually exclusive of -b

--cgroup-parent=""

Set parent cgroup for all containers. Default is "/docker" for fs cgroup

driver and "system.slice" for systemd cgroup driver.

--config-file="/etc/docker/daemon.json"

Specifies the JSON file path to load the configuration from. Default is

/etc/docker/daemon.json.

--containerd=""

Path to containerd socket.

--data-root=""

Path to the directory used to store persisted Docker data such as

configuration for resources, swarm cluster state, and filesystem data for

images, containers, and local volumes. Default is /var/lib/docker.

-D, --debug=true|false

Enable debug mode. Default is false.

--default-cgroupns-mode="host|private"

Set the default cgroup namespace mode for newly created containers. The argument

can either be host or private. If unset, this defaults to host on cgroup v1,

or private on cgroup v2.

--default-gateway=""

IPv4 address of the container default gateway; this address must be part of

the bridge subnet (which is defined by -b or --bip)

--default-gateway-v6=""

IPv6 address of the container default gateway

--default-address-pool=""

Default address pool from which IPAM driver selects a subnet for the networks.

Example: base=172.30.0.0/16,size=24 will set the default

address pools for the selected scope networks to {172.30.[0-255].0/24}

--default-network-opt=DRIVER=OPT=VALUE

Default network driver options

--default-runtime="runtime"

Set default runtime if there're more than one specified by --add-runtime.

--default-ipc-mode="private|shareable"

Set the default IPC mode for newly created containers. The argument

can either be private or shareable.

--default-shm-size=size

Set the daemon-wide default shm size for containers. Default is 64MiB.

--default-ulimit=[]

Default ulimits for containers.

--dns=""

Force Docker to use specific DNS servers.

--dns-opt=""

DNS options to use.

--dns-search=[]

DNS search domains to use.

--exec-opt=[]

Set runtime execution options. See RUNTIME EXECUTION OPTIONS.

--exec-root=""

Path to use as the root of the Docker execution state files. Default is

/var/run/docker.

--experimental=""

Enable the daemon experimental features.

--fixed-cidr=""

IPv4 subnet for fixed IPs (e.g., 10.20.0.0/16); this subnet must be nested in

the bridge subnet (which is defined by -b or --bip).

--fixed-cidr-v6=""

IPv6 subnet for global IPv6 addresses (e.g., 2a00:1450::/64)

-G, --group=""

Group to assign the unix socket specified by -H when running in daemon mode.

use '' (the empty string) to disable setting of a group. Default is docker.

-H, --host=[unix:///var/run/docker.sock]: tcp://[host:port] to bind or unix://[/path/to/socket] to use.

The socket(s) to bind to in daemon mode specified using one or more

tcp://host:port, unix:///path/to/socket, fd://* or fd://socketfd.

--help

Print usage statement

--http-proxy""

Proxy URL for HTTP requests unless overridden by NoProxy.

--https-proxy""

Proxy URL for HTTPS requests unless overridden by NoProxy.

--icc=true|false

Allow unrestricted inter-container and Docker daemon host communication. If

disabled, containers can still be linked together using the --link option

(see docker-run(1)). Default is true.

--init

Run an init process inside containers for signal forwarding and process

reaping.

--init-path

Path to the docker-init binary.

--insecure-registry=[]

Enable insecure registry communication, i.e., enable un-encrypted and/or

untrusted communication.

List of insecure registries can contain an element with CIDR notation to

specify a whole subnet. Insecure registries accept HTTP and/or accept HTTPS

with certificates from unknown CAs.

Enabling --insecure-registry is useful when running a local registry.

However, because its use creates security vulnerabilities it should ONLY be

enabled for testing purposes. For increased security, users should add their

CA to their system's list of trusted CAs instead of using

--insecure-registry.

--ip=""

Default IP address to use when binding container ports. Default is 0.0.0.0.

--ip-forward=true|false

Enables IP forwarding on the Docker host. The default is true. This flag

interacts with the IP forwarding setting on your host system's kernel. If

your system has IP forwarding disabled, this setting enables it. If your

system has IP forwarding enabled, setting this flag to false

has no effect.

This setting will also enable IPv6 forwarding if you have both

--ip-forward=true and --fixed-cidr-v6 set. Note that this may reject

Router Advertisements and interfere with the host's existing IPv6

configuration. For more information, consult the documentation about

"Advanced Networking - IPv6".

--ip-masq=true|false

Enable IP masquerading for bridge's IP range. Default is true.

--iptables=true|false

Enable Docker's addition of iptables rules. Default is true.

--ipv6=true|false

Enable IPv6 support. Default is false. Docker will create an IPv6-enabled

bridge with address fe80::1 which will allow you to create IPv6-enabled

containers. Use together with --fixed-cidr-v6 to provide globally routable

IPv6 addresses. IPv6 forwarding will be enabled if not used with

--ip-forward=false. This may collide with your host's current IPv6

settings. For more information consult the documentation about

"Advanced Networking - IPv6".

--isolation="default"

Isolation specifies the type of isolation technology used by containers.

Note that the default on Windows server is process, and the default on

Windows client is hyperv. Linux only supports default.

-l, --log-level="debug|info|warn|error|fatal"

Set the logging level. Default is info.

--label="[]"

Set key=value labels to the daemon (displayed in docker info)

--live-restore=false

Enable live restore of running containers when the daemon starts so that they

are not restarted. This option is applicable only for docker daemon running

on Linux host.

--log-driver="json-file|syslog|journald|gelf|fluentd|awslogs|splunk|etwlogs|gcplogs|none"

Default driver for container logs. Default is json-file.

Warning: docker logs command works only for json-file logging driver.

--log-opt=[]

Logging driver specific options.

--mtu=0

Set the containers network mtu. Default is 0.

--max-concurrent-downloads=3

Set the max concurrent downloads. Default is 3.

--max-concurrent-uploads=5

Set the max concurrent uploads. Default is 5.

--max-download-attempts=5

Set the max download attempts for each pull. Default is 5.

--no-proxy="""

Comma-separated values specifying hosts that should be excluded from proxying.

--node-generic-resources=[]

Advertise user-defined resource. Default is [].

Use this if your swarm cluster has some nodes with custom

resources (e.g: NVIDIA GPU, SSD, ...) and you need your services to land on

nodes advertising these resources.

Usage example: --node-generic-resources "NVIDIA-GPU=UUID1"

--node-generic-resources "NVIDIA-GPU=UUID2"

-p, --pidfile="path"

Path to use for daemon PID file. Default is /var/run/docker.pid.

--raw-logs

Output daemon logs in full timestamp format without ANSI coloring. If this

flag is not set, the daemon outputs condensed, colorized logs if a terminal

is detected, or full ("raw") output otherwise.

--registry-mirror=<scheme>://<host>

Prepend a registry mirror to be used for image pulls. May be specified

multiple times.

-s, --storage-driver=""

Force the Docker runtime to use a specific storage driver.

--seccomp-profile=""

Path to seccomp profile.

--selinux-enabled=true|false

Enable selinux support. Default is false.

--shutdown-timeout=seconds

Set the shutdown timeout value in seconds. Default is 15.

--storage-opt=[]

Set storage driver options. See STORAGE DRIVER OPTIONS.

--swarm-default-advertise-addr=IP|INTERFACE

Set default address or interface for swarm to advertise as its

externally-reachable address to other cluster members. This can be a

hostname, an IP address, or an interface such as eth0. A port cannot be

specified with this option.

--tls=true|false

Use TLS; implied by --tlsverify. Default is false.

--tlscacert= /.docker/ca.pem

Trust certs signed only by this CA.

--tlscert= /.docker/cert.pem

Path to TLS certificate file.

--tlskey= /.docker/key.pem

Path to TLS key file.

--tlsverify=true|false

Use TLS and verify the remote (daemon: verify client, client: verify daemon).

Default is false.

--userland-proxy=true|false

Rely on a userland proxy implementation for inter-container and

outside-to-container loopback communications. Default is true.

--userland-proxy-path=""

Path to the userland proxy binary.

--userns-remap=default|uid:gid|user:group|user|uid

Enable user namespaces for containers on the daemon. Specifying "default"

will cause a new user and group to be created to handle UID and GID range

remapping for the user namespace mappings used for contained processes.

Specifying a user (or uid) and optionally a group (or gid) will cause the

daemon to lookup the user and group's subordinate ID ranges for use as the

user namespace mappings for contained processes.

--validate

Validate daemon configuration and exit.

## STORAGE DRIVER OPTIONS
Docker uses storage backends (known as "storage drivers" in the Docker internals) to create writable containers from images. Many of these backends use operating system level technologies and can be configured.

Specify options to the storage backend with --storage-opt flags. The backends that currently take options are zfs and btrfs. Options for zfs start with zfs., and options for btrfs start with btrfs..

## ZFS options

### zfs.fsname
Set zfs filesystem under which docker will create its own datasets. By default docker will pick up the zfs filesystem where docker graph (/var/lib/docker) is located.

Example use: dockerd -s zfs --storage-opt zfs.fsname=zroot/docker

## Btrfs options

### btrfs.min_space
Specifies the minimum size to use when creating the subvolume which is used for containers. If user uses disk quota for btrfs when creating or running a container with --storage-opt size option, docker should ensure the size cannot be smaller than btrfs.min_space.

Example use: docker daemon -s btrfs --storage-opt btrfs.min_space=10G

## Access authorization
Docker's access authorization can be extended by authorization plugins that your organization can purchase or build themselves. You can install one or more authorization plugins when you start the Docker daemon using the --authorization-plugin=PLUGIN_ID option.

```
dockerd --authorization-plugin=plugin1 --authorization-plugin=plugin2,...
```

The PLUGIN_ID value is either the plugin's name or a path to its specification file. The plugin's implementation determines whether you can specify a name or path. Consult with your Docker administrator to get information about the plugins available to you.

Once a plugin is installed, requests made to the daemon through the command line or Docker's Engine API are allowed or denied by the plugin. If you have multiple plugins installed, each plugin, in order, must allow the request for it to complete.

For information about how to create an authorization plugin, see access authorization plugin ⟨https://docs.docker.com/engine/extend/plugins_authorization/⟩ section in the Docker extend section of this documentation.

## RUNTIME EXECUTION OPTIONS
You can configure the runtime using options specified with the --exec-opt flag. All the flag's options have the native prefix. A single native.cgroupdriver option is available.

The native.cgroupdriver option specifies the management of the container's cgroups. You can only specify cgroupfs or systemd. If you specify systemd and it is not available, the system errors out. If you omit the native.cgroupdriver option,cgroupfs is used on cgroup v1 hosts, systemd is used on cgroup v2 hosts with systemd available.

This example sets the cgroupdriver to systemd:

```
$ sudo dockerd --exec-opt native.cgroupdriver=systemd
```

Setting this option applies to all containers the daemon launches.

## HISTORY
Sept 2015, Originally compiled by Shishir Mahajan ⟨shishir.mahajan@redhat.com⟩ based on docker.com source material and internal work.


apt-cudf-get

title: apt-cudf-get(8)

summary: wrapper for calling apt\-get with external solvers

text:
# apt-cudf-get(8)

## NAME
apt-cudf-get - wrapper for calling apt-get with external solvers

## SYNOPSIS
apt-cudf-get [arguments]

## DESCRIPTION
apt-cudf-get is a wrapper that allows one to invoke apt-get with external solvers while ignoring apt's pinning.

All options are passed on to apt-get.

Normally, apt uses so-called pinning to select a candidate version of a package in case there are several versions available. This also holds when calling apt-get with external solvers. However, when it is not possible to find a solution under this constraint, it may be useful to relax pinning and to allow the external solver to choose among all available versions of packages in order to satisfy dependencies, not only those that are selected by the pinning. This is precisely what apt-cudf-get does.

Note that, when using an external solver, the proposed solution may contain any available version of the packages that are given as arguments to install on the command line without specifying a version qualifier.

For example

```
    apt-cudf-get --solver aspcud install ocaml
```

may propose to install any available version of ocaml, while

```
    apt-cudf-get --solver aspcud install ocaml=4.01.0
```

will only propose to install ocaml in version 4.01.0

## AUTHOR
Pietro Abate and Roberto Di Cosmo

## BUGS
Not all types of arguments to apt are correctly treated by this wrapper, in particular not the +pkg and -pkg shorthands for installation and removal requests.

## SEE ALSO
apt-get(8), apt-cudf(1), apt-cudf.conf(5), update-cudf-solvers(8), README.cudf-solvers <file:///usr/share/doc/apt-cudf/README.cudf-solvers>, README.Debian <file:///usr/share/doc/apt-cudf/README.Debian>


fatlabel

package: dosfstools

title: fatlabel(8)

text:
# fatlabel(8)

## NAME
fatlabel - set or get MS-DOS filesystem label or volume ID

## SYNOPSIS
fatlabel [OPTIONS] DEVICE [NEW]

## DESCRIPTION
fatlabel will display or change the volume label or volume ID on the MS-DOS filesystem located on DEVICE. By default it works in label mode. It can be switched to volume ID mode with the option -i or --volume-id.

If NEW is omitted, then the existing label or volume ID is written to the standard output. A label can't be longer than 11 bytes and should be in all upper case for best compatibility. An empty string or a label consisting only of white space is not allowed. A volume ID must be given as a hexadecimal number (no leading "0x" or similar) and must fit into 32 bits.

## OPTIONS
-i, --volume-id

Switch to volume ID mode.

-r, --reset

Remove label in label mode or generate new ID in volume ID mode.

-c PAGE, --codepage=PAGE

Use DOS codepage PAGE to encode/decode label. By default codepage 850 is used.

-h, --help

Display a help message and terminate.

-V, --version

Show version number and terminate.

## COMPATIBILITY and BUGS
For historic reasons FAT label is stored in two different locations: in the boot sector and as a special volume label entry in the root directory. MS-DOS 5.00, MS-DOS 6.22, MS-DOS 7.10, Windows 98, Windows XP and also Windows 10 read FAT label only from the root directory. Absence of the volume label in the root directory is interpreted as empty or none label, even if boot sector contains some valid label.

When Windows XP or Windows 10 system changes a FAT label it stores it only in the root directory — letting boot sector unchanged. Which leads to problems when a label is removed on Windows. Old label is still stored in the boot sector but is removed from the root directory.

dosfslabel prior to the version 3.0.7 operated only with FAT labels stored in the boot sector, completely ignoring a volume label in the root directory.

dosfslabel in versions 3.0.7–3.0.15 reads FAT labels from the root directory and in case of absence, it fallbacks to a label stored in the boot sector. Change operation resulted in updating a label in the boot sector and sometimes also in the root directory due to the bug. That bug was fixed in dosfslabel version 3.0.16 and since this version dosfslabel updates label in both location.

Since version 4.2, fatlabel reads a FAT label only from the root directory (like MS-DOS and Windows systems), but changes a FAT label in both locations. In version 4.2 was fixed handling of empty labels and labels which starts with a byte 0xE5. Also in this version was added support for non-ASCII labels according to the specified DOS codepage and were added checks if a new label is valid.

It is strongly suggested to not use dosfslabel prior to version 3.0.16.

## DOS CODEPAGES
MS-DOS and Windows systems use DOS (OEM) codepage for encoding and decoding FAT label. In Windows systems DOS codepage is global for all running applications and cannot be configured explicitly. It is set implicitly by option Language for non-Unicode programs available in Regional and Language Options via Control Panel. Default DOS codepage for fatlabel is 850. See following mapping table between DOS codepage and Language for non-Unicode programs:

Codepage

Language

437

English (India), English (Malaysia), English (Republic of the Philippines), English (Singapore), English (South Africa), English (United States), English (Zimbabwe), Filipino, Hausa, Igbo, Inuktitut, Kinyarwanda, Kiswahili, Yoruba

720

Arabic, Dari, Persian, Urdu, Uyghur

737

Greek

775

Estonian, Latvian, Lithuanian

850

Afrikaans, Alsatian, Basque, Breton, Catalan, Corsican, Danish, Dutch, English (Australia), English (Belize), English (Canada), English (Caribbean), English (Ireland), English (Jamaica), English (New Zealand), English (Trinidad and Tobago), English (United Kingdom), Faroese, Finnish, French, Frisian, Galician, German, Greenlandic, Icelandic, Indonesian, Irish, isiXhosa, isiZulu, Italian, K'iche, Lower Sorbian, Luxembourgish, Malay, Mapudungun, Mohawk, Norwegian, Occitan, Portuguese, Quechua, Romansh, Sami, Scottish Gaelic, Sesotho sa Leboa, Setswana, Spanish, Swedish, Tamazight, Upper Sorbian, Welsh, Wolof

852

Albanian, Bosnian (Latin), Croatian, Czech, Hungarian, Polish, Romanian, Serbian (Latin), Slovak, Slovenian, Turkmen

855

Bosnian (Cyrillic), Serbian (Cyrillic)

857

Azeri (Latin), Turkish, Uzbek (Latin)

862

Hebrew

866

Azeri (Cyrillic), Bashkir, Belarusian, Bulgarian, Kyrgyz, Macedonian, Mongolian, Russian, Tajik, Tatar, Ukrainian, Uzbek (Cyrillic), Yakut

874

Thai

932

Japanese

936

Chinese (Simplified)

949

Korean

950

Chinese (Traditional)

1258

Vietnamese

## SEE ALSO
fsck.fat(8), mkfs.fat(8)

## HOMEPAGE
The home for the dosfstools project is its GitHub project page.

## AUTHORS
dosfstools were written by Werner Almesberger, Roman Hodek, and others. Current maintainers are Andreas Bombe and Pali Rohár.


fsck.fat

title: fsck.fat(8)

summary: check and repair MS-DOS FAT filesystems

text:
# fsck.fat(8)

## NAME
fsck.fat - check and repair MS-DOS FAT filesystems

## SYNOPSIS
fsck.fat [OPTIONS] DEVICE

## DESCRIPTION
fsck.fat verifies the consistency of MS-DOS filesystems and optionally tries to repair them.

The following filesystem problems can be corrected (in this order):

- FAT contains invalid cluster numbers. Cluster is changed to EOF.

- File's cluster chain contains a loop. The loop is broken.

- Bad clusters (read errors). The clusters are marked bad and they are removed from files owning them. This check is optional.

- Directories with a large number of bad entries (probably corrupt). The directory can be deleted.

- Files . and .. are non-directories. They can be deleted or renamed.

- Directories . and .. in root directory. They are deleted.

- Bad filenames. They can be renamed.

- Duplicate directory entries. They can be deleted or renamed.

- Directories with non-zero size field. Size is set to zero.

- Directory . does not point to parent directory. The start pointer is adjusted.

- Directory .. does not point to parent of parent directory. The start pointer is adjusted.

- . and .. are not the two first entries in a non-root directory. The entries are created, moving occupied slots if necessary.

- Start cluster number of a file is invalid. The file is truncated.

- File contains bad or free clusters. The file is truncated.

- File's cluster chain is longer than indicated by the size fields. The file is truncated.

- Two or more files share the same cluster(s). All but one of the files are truncated. If the file being truncated is a directory file that has already been read, the filesystem check is restarted after truncation.

- File's cluster chain is shorter than indicated by the size fields. The file is truncated.

- Volume label in root directory or label in boot sector is invalid. Invalid labels are removed.

- Volume label in root directory and label in boot sector are different. Volume label from root directory is copied to boot sector.

- Clusters are marked as used but are not owned by a file. They are marked as free.

Additionally, the following problems are detected, but not repaired:

•

Invalid parameters in boot sector

When fsck.fat checks a filesystem, it accumulates all changes in memory and performs them only after all checks are complete. This can be disabled with the -w option.

Two different variants of the FAT filesystem are supported. Standard is the FAT12, FAT16 and FAT32 filesystems as defined by Microsoft and widely used on hard disks and removable media like USB sticks and SD cards. The other is the legacy Atari variant used on Atari ST.

There are some minor differences in Atari format: Some boot sector fields are interpreted slightly different, and the special FAT entries for end-of-file and bad cluster can be different. Under MS-DOS 0xfff8 is used for EOF and Atari employs 0xffff by default, but both systems recognize all values from 0xfff8–0xffff as end-of-file. MS-DOS uses only 0xfff7 for bad clusters, where on Atari values 0xfff0–0xfff7 are for this purpose (but the standard value is still 0xfff7).

## OPTIONS
-a

Automatically repair the filesystem. No user intervention is necessary. Whenever there is more than one method to solve a problem, the least destructive approach is used.

-A

Select using the Atari variation of the FAT filesystem if that isn't active already, otherwise select standard FAT filesystem. This is selected by default if mkfs.fat is run on 68k Atari Linux.

-b

Make read-only boot sector check.

-c PAGE

Use DOS codepage PAGE to decode short file names. By default codepage 850 is used.

-d PATH

Delete the specified file. If more than one file with that name exist, the first one is deleted. This option can be given more than once.

-f

Salvage unused cluster chains to files. By default, unused clusters are added to the free disk space except in auto mode (-a).

-F NUM

Specify FAT table NUM for filesystem access. By default value 0 is assumed and then the first uncorrupted FAT table is chosen. Uncorrupted means that FAT table has valid first cluster. If default value 0 is used and all FAT tables are corrupted then fsck.fat gives up and does not try to repair FAT filesystem. If non-zero NUM value is specified then fsck.fat uses FAT table NUM for repairing FAT filesystem. If FAT table NUM has corrupted first cluster then fsck.fat will repair it. In any case, if FAT filesystem has more FAT tables then repaired content of chosen FAT table is copied to other FAT tables. To repair corrupted first cluster it is required to call fsck.fat with non-zero NUM value.

-l

List path names of files being processed.

-n

No-operation mode: non-interactively check for errors, but don't write anything to the filesystem.

-p

Same as -a, for compatibility with other *fsck.

-r

Interactively repair the filesystem. The user is asked for advice whenever there is more than one approach to fix an inconsistency. This is the default mode and the option is only retained for backwards compatibility.

-S

Consider short (8.3) file names with spaces in the middle to be invalid, like previous versions of this program did. While such file names are not forbidden by the FAT specification, and were never treated as errors by Microsoft file system checking tools, many DOS programs are unable to handle files with such names. Using this option can make them accessible to these programs.

Short file names which start with a space are considered invalid regardless of this option's setting.

Previous versions of this program exceptionally treated EA DATA. SF and WP ROOT. SF as valid short names; using this option does not preserve that exception.

-t

Mark unreadable clusters as bad.

-u PATH

Try to undelete the specified file. fsck.fat tries to allocate a chain of contiguous unallocated clusters beginning with the start cluster of the undeleted file. This option can be given more than once.

-U

Consider lowercase volume and boot label as invalid and allow only uppercase characters. Such labels are forbidden by the FAT specification, but they are widely used by Linux tools. Moreover MS-DOS and Windows systems do not have problems to read them. Therefore volume and boot labels with lowercase characters are by default permitted.

-v

Verbose mode. Generates slightly more output.

-V

Perform a verification pass. The filesystem check is repeated after the first run. The second pass should never report any fixable errors. It may take considerably longer than the first pass, because the first pass may have generated long list of modifications that have to be scanned for each disk read.

--variant TYPE

Create a filesystem of variant TYPE. Acceptable values are standard and atari (in any combination of upper/lower case). See above under DESCRIPTION for the differences.

-w

Write changes to disk immediately.

-y

Same as -a (automatically repair filesystem) for compatibility with other fsck tools.

--help

Display help message describing usage and options then exit.

## EXIT STATUS
0

No recoverable errors have been detected.

1

Recoverable errors have been detected or fsck.fat has discovered an internal inconsistency.

2

Usage error. fsck.fat did not access the filesystem.

## FILES
fsck0000.rec, fsck0001.rec, ...

When recovering from a corrupted filesystem, fsck.fat dumps recovered data into files named fsckNNNN.rec in the top level directory of the filesystem.

## BUGS

- Does not remove entirely empty directories.

- Should give more diagnostic messages.

- Undeleting files should use a more sophisticated algorithm.

## SEE ALSO
fatlabel(8), mkfs.fat(8)

## HOMEPAGE
The home for the dosfstools project is its GitHub project page.

## AUTHORS
dosfstools were written by Werner Almesberger, Roman Hodek, and others. Current maintainers are Andreas Bombe and Pali Rohár.


mkfs.fat

title: mkfs.fat(8)

summary: create an MS-DOS FAT filesystem

text:
# mkfs.fat(8)

## NAME
mkfs.fat - create an MS-DOS FAT filesystem

## SYNOPSIS
mkfs.fat [OPTIONS] DEVICE [BLOCK-COUNT]

## DESCRIPTION
mkfs.fat is used to create a FAT filesystem on a device or in an image file. DEVICE is the special file corresponding to the device (e.g. /dev/sdXX) or the image file (which does not need to exist when the option -C is given). BLOCK-COUNT is the number of blocks on the device and size of one block is always 1024 bytes, independently of the sector size or the cluster size. Therefore BLOCK-COUNT specifies size of filesystem in KiB unit and not in the number of sectors (like for all other mkfs.fat options). If omitted, mkfs.fat automatically chooses a filesystem size to fill the available space.

Two different variants of the FAT filesystem are supported. Standard is the FAT12, FAT16 and FAT32 filesystems as defined by Microsoft and widely used on hard disks and removable media like USB sticks and SD cards. The other is the legacy Atari variant used on Atari ST.

In Atari mode, if not directed otherwise by the user, mkfs.fat will always use 2 sectors per cluster, since GEMDOS doesn't like other values very much. It will also obey the maximum number of sectors GEMDOS can handle. Larger filesystems are managed by raising the logical sector size. An Atari-compatible serial number for the filesystem is generated, and a 12 bit FAT is used only for filesystems that have one of the usual floppy sizes (720k, 1.2M, 1.44M, 2.88M), a 16 bit FAT otherwise. This can be overridden with the -F option. Some PC-specific boot sector fields aren't written, and a boot message (option -m) is ignored.

## OPTIONS
-a

Normally, for any filesystem except very small ones, mkfs.fat will align all the data structures to cluster size, to make sure that as long as the partition is properly aligned, so will all the data structures in the filesystem. This option disables alignment; this may provide a handful of additional clusters of storage at the expense of a significant performance degradation on RAIDs, flash media or large-sector hard disks.

-A

Select using the Atari variation of the FAT filesystem if that isn't active already, otherwise select standard FAT filesystem. This is selected by default if mkfs.fat is run on 68k Atari Linux.

-b SECTOR-OF-BACKUP

Selects the location of the backup boot sector for FAT32. Default depends on number of reserved sectors, but usually is sector 6. If there is a free space available after the backup boot sector then backup of the FAT32 info sector is put after the backup boot sector, usually at sector 7. The backup must be within the range of reserved sectors. Value 0 completely disables creating of backup boot and info FAT32 sectors.

-c

Check the device for bad blocks before creating the filesystem.

-C

Create the file given as DEVICE on the command line, and write the to-be-created filesystem to it. This can be used to create the new filesystem in a file instead of on a real device, and to avoid using dd in advance to create a file of appropriate size. With this option, the BLOCK-COUNT must be given, because otherwise the intended size of the filesystem wouldn't be known. The file created is a sparse file, which actually only contains the meta-data areas (boot sector, FATs, and root directory). The data portions won't be stored on the disk, but the file nevertheless will have the correct size. The resulting file can be copied later to a floppy disk or other device, or mounted through a loop device.

-D DRIVE-NUMBER

Specify the BIOS drive number to be stored in the FAT boot sector. For hard disks and removable medias it is usually 0x80–0xFF (0x80 is first hard disk C:, 0x81 is second hard disk D:, ...), for floppy devices or partitions to be used for floppy emulation it is 0x00–0x7F (0x00 is first floppy A:, 0x01 is second floppy B:).

-f NUMBER-OF-FATS

Specify the number of file allocation tables in the filesystem. The default is 2.

-F FAT-SIZE

Specifies the type of file allocation tables used (12, 16 or 32 bit). If nothing is specified, mkfs.fat will automatically select between 12, 16 and 32 bit, whatever fits better for the filesystem size.

-g HEADS/SECTORS-PER-TRACK

Specify HEADS and SECTORS-PER-TRACK numbers which represents disk geometry of DEVICE. Both numbers are stored into the FAT boot sector. Number SECTORS-PER-TRACK is used also for aligning the total count of FAT sectors. By default disk geometry is read from DEVICE itself. If it is not available then LBA-Assist Translation and translation table from the SD Card Part 2 File System Specification based on total number of disk sectors is used.

-h NUMBER-OF-HIDDEN-SECTORS

Specify the number of so-called hidden sectors, as stored in the FAT boot sector: this number represents the beginning sector of the partition containing the file system. Normally this is an offset (in sectors) relative to the start of the disk, although for MBR logical volumes contained in an extended partition of type 0x05 (a non-LBA extended partition), a quirk in the MS-DOS implementation of FAT requires it to be relative to the partition's immediate containing Extended Boot Record. Boot code and other software handling FAT volumes may also rely on this field being set up correctly; most modern FAT implementations will ignore it. By default, if the DEVICE is a partition block device, mkfs.fat uses the partition offset relative to disk start. Otherwise, mkfs.fat assumes zero. Use this option to override this behaviour.

-i VOLUME-ID

Sets the volume ID of the newly created filesystem; VOLUME-ID is a 32-bit hexadecimal number (for example, 2e24ec82). The default is a number which depends on the filesystem creation time.

-I

Ignore and disable safety checks. By default mkfs.fat refuses to create a filesystem on a device with partitions or virtual mapping. mkfs.fat will complain and tell you that it refuses to work. This is different when using MO disks. One doesn't always need partitions on MO disks. The filesystem can go directly to the whole disk. Under other OSes this is known as the superfloppy format. This switch will force mkfs.fat to work properly.

-l FILENAME

Read the bad blocks list from FILENAME.

-m MESSAGE-FILE

Sets the message the user receives on attempts to boot this filesystem without having properly installed an operating system. The message file must not exceed 418 bytes once line feeds have been converted to carriage return-line feed combinations, and tabs have been expanded. If the filename is a hyphen (-), the text is taken from standard input.

-M FAT-MEDIA-TYPE

Specify the media type to be stored in the FAT boot sector. This value is usually 0xF8 for hard disks and is 0xF0 or a value from 0xF9 to 0xFF for floppies or partitions to be used for floppy emulation.

--mbr[=y|yes|n|no|a|auto]

Fill (fake) MBR table with disk signature one partition which starts at sector 0 (includes MBR itself) and spans whole disk device. It is needed only for non-removable disks used on Microsoft Windows systems and only when formatting whole unpartitioned disk. Location of the disk signature and partition table overlaps with the end of the first FAT sector (boot code location), therefore there is no additional space usage. Default is auto mode in which mkfs.fat put MBR table only for non-removable disks when formatting whole unpartitioned disk.

-n VOLUME-NAME

Sets the volume name (label) of the filesystem. The volume name can be up to 11 characters long. Supplying an empty string, a string consisting only of white space or the string "NO NAME" as VOLUME-NAME has the same effect as not giving the -n option. The default is no label.

--codepage=PAGE

Use DOS codepage PAGE to encode label. By default codepage 850 is used.

-r ROOT-DIR-ENTRIES

Select the minimal number of entries available in the root directory. The default is 112 or 224 for floppies and 512 for hard disks. Note that this is minimal number and it may be increased by mkfs.fat due to alignment of structures. See also mkfs.fat option -a.

-R NUMBER-OF-RESERVED-SECTORS

Select the minimal number of reserved sectors. With FAT32 format at least 2 reserved sectors are needed, the default is 32. Otherwise the default is 1 (only the boot sector). Note that this is minimal number and it may be increased by mkfs.fat due to alignment of structures. See also mkfs.fat option -a.

-s SECTORS-PER-CLUSTER

Specify the number of disk sectors per cluster. Must be a power of 2, i.e. 1, 2, 4, 8, ... 128.

-S LOGICAL-SECTOR-SIZE

Specify the number of bytes per logical sector. Must be a power of 2 and greater than or equal to 512, i.e. 512, 1024, 2048, 4096, 8192, 16384, or 32768. Values larger than 4096 are not conforming to the FAT file system specification and may not work everywhere.

-v

Verbose execution.

--offset SECTOR

Write the filesystem at a specific sector into the device file. This is useful for creating a filesystem in a partitioned disk image without having to set up a loop device.

--variant TYPE

Create a filesystem of variant TYPE. Acceptable values are standard and atari (in any combination of upper/lower case). See above under DESCRIPTION for the differences.

--help

Display option summary and exit.

--invariant

Use constants for normally randomly generated or time based data such as volume ID and creation time. Multiple runs of mkfs.fat on the same device create identical results with this option. Its main purpose is testing mkfs.fat.

## BUGS
mkfs.fat can not create boot-able filesystems. This isn't as easy as you might think at first glance for various reasons and has been discussed a lot already. mkfs.fat simply will not support it ;)

## SEE ALSO
fatlabel(8), fsck.fat(8)

## HOMEPAGE
The home for the dosfstools project is its GitHub project page.

## AUTHORS
dosfstools were written by Werner Almesberger, Roman Hodek, and others. Current maintainers are Andreas Bombe and Pali Rohár.


dpkg-fsys-usrunmess

package: dpkg

title: dpkg-fsys-usrunmess(8)

summary: undoes the merged\-/usr\-via\-aliased\-dirs mess

text:
# dpkg-fsys-usrunmess(8)

## NAME
dpkg-fsys-usrunmess - undoes the merged-/usr-via-aliased-dirs mess

## SYNOPSIS
dpkg-fsys-usrunmess [option...]

## DESCRIPTION
dpkg-fsys-usrunmess is a tool to fix up filesystems that have been installed anew with recent installers with unfortunate defaults or migrated to the broken merged /usr via aliased directories layout, which is not supported by dpkg. See the dpkg FAQ.

Note: In Debian its tech-ctte has decreed that on the release after bookworm the non-usrmerged layout is not going to be supported, and thus some of its maintainers might not fix issues or intentionally remove non-usrmerged support, so you will need decide and pick your poison.

The program will perform the following overall actions:

- Check whether the system needs to be switched, otherwise do nothing,

- Check for dpkg database consistency and otherwise abort.

- Generate and install a regression prevention package, if requested on the command-line or otherwise on the prompt.

- Get the list of files and alternatives that need to be restored.

- Look for untracked kernel modules files that need to be moved too.

- Create a shadow hierarchy under /.usrunmess, by creating the directories symlinks or hardlinking or copying the files as needed.

- Prompt for confirmation before proceeding, if requested on the command-line.

- Lock the dpkg database.

- Mark all packages as half-configured to force running maintainer scripts that might need to recreate files.

- Replace the aliased directories with the shadow ones, by creating a backup of the old symlinked directories and renaming the shadow ones over.

- Relabel MAC information for directories and symlinks if necessary.

- Remove backup symlinks.

- Remove old moved objects, but defer directory removal.

- Remove old deferred directories that are not referenced by dpkg-query.

- Remove shadow root directory.

- Register a policy-rc.d to disallow service actions, which means that services might need to be restarted afterwards, ideally via a reboot.

- Reconfigure all packages.

- Unregister the policy-rc.d and restore the alternatives state.

Note: When running the program from some shells such as bash(1) or zsh(1), after executing it, you might need to request the shell to forget all remembered executable locations with for example "hash -r".

Note: Some directories might linger after the migration in case they contain untracked files. A list is printed once the script has finished for further investigation.

Warning: Note that this operation has the potential to render the system unusable or broken in case of a sudden crash or reboot, unexpected state of the system, or possible bugs in the script. Be prepared with recovery media and consider doing backups beforehand.

## OPTIONS
-p, --prompt

Prompt at the time of no return, so that the debug output or the shadow hierarchy can be evaluated before proceeding.

--prevention

--no-prevention

Enables or disables generating and installing a regression prevention package into the system. If no option has been specified, the action to take will be prompted. The generated package contains the Protected field set to yes to protect against accidental removal of the package.

-n, --no-act

--dry-run

This option enables the dry-run mode, where no destructive action takes place, only the preparatory part.

-?, --help

Show the usage message and exit.

--version

Show the version and exit.

## ENVIRONMENT
DPKG_USRUNMESS_NOACT

This setting defines whether to enable dry-run mode.

## SEE ALSO
<https://wiki.debian.org/Teams/Dpkg/FAQ#broken-usrmerge>.


dracut

package: dracut

title: dracut(8)

summary: low\-level tool for generating an initramfs/initrd image

text:
# dracut(8)

## NAME
dracut - low-level tool for generating an initramfs/initrd image

## SYNOPSIS
dracut [OPTION...] [<image> [<kernel version>]]

## DESCRIPTION
Create an initramfs <image> for the kernel with the version <kernel version>. If <kernel version> is omitted, then the version of the actual running kernel is used. If <image> is omitted or empty, depending on bootloader specification, the default location can be /efi/<machine-id>/<kernel-version>/initrd, /boot/<machine-id>/<kernel-version>/initrd, /boot/efi/<machine-id>/<kernel-version>/initrd, /lib/modules/<kernel-version>/initrd or /boot/initramfs-<kernel-version>.img.

dracut creates an initial image used by the kernel for preloading the block device modules (such as IDE, SCSI or RAID) which are needed to access the root filesystem, mounting the root filesystem and booting into the real system.

At boot time, the kernel unpacks that archive into RAM disk, mounts and uses it as initial root file system. All finding of the root device happens in this early userspace.

Initramfs images are also called "initrd".

For a complete list of kernel command line options see dracut.cmdline(7).

If you are dropped to an emergency shell, while booting your initramfs, the file /run/initramfs/rdsosreport.txt is created, which can be saved to a (to be mounted by hand) partition (usually /boot) or a USB stick. Additional debugging info can be produced by adding rd.debug to the kernel command line. /run/initramfs/rdsosreport.txt contains all logs and the output of some tools. It should be attached to any report about dracut problems.

## USAGE
To create a initramfs image, the most simple command is:

```
# dracut
```

This will generate a general purpose initramfs image, with all possible functionality resulting of the combination of the installed dracut modules and system tools. The image, depending on bootloader specification, can be /efi/<machine-id>/<kernel-version>/initrd, /boot/<machine-id>/<kernel-version>/initrd, /boot/efi/<machine-id>/<kernel-version>/initrd, /lib/modules/<kernel-version>/initrd or /boot/initramfs-<kernel-version>.img and contains the kernel modules of the currently active kernel with version <kernel-version>.

If the initramfs image already exists, dracut will display an error message, and to overwrite the existing image, you have to use the --force option.

```
# dracut --force
```

If you want to specify another filename for the resulting image you would issue a command like:

```
# dracut foobar.img
```

To generate an image for a specific kernel version, the command would be:

```
# dracut foobar.img 2.6.40-1.rc5.f20
```

A shortcut to generate the image at the default location for a specific kernel version is:

```
# dracut --kver 2.6.40-1.rc5.f20
```

If you want to create lighter, smaller initramfs images, you may want to specify the --hostonly or -H option. Using this option, the resulting image will contain only those dracut modules, kernel modules and filesystems, which are needed to boot this specific machine. This has the drawback, that you can’t put the disk on another controller or machine, and that you can’t switch to another root filesystem, without recreating the initramfs image. The usage of the --hostonly option is only for experts and you will have to keep the broken pieces. At least keep a copy of a general purpose image (and corresponding kernel) as a fallback to rescue your system.

### Inspecting the Contents
To see the contents of the image created by dracut, you can use the lsinitrd tool.

```
# lsinitrd | less
```

To display the contents of a file in the initramfs also use the lsinitrd tool:

```
# lsinitrd -f /etc/ld.so.conf
include ld.so.conf.d/*.conf
```

### Adding dracut Modules
Some dracut modules are turned off by default and have to be activated manually. You can do this by adding the dracut modules to the configuration file /etc/dracut.conf or /etc/dracut.conf.d/myconf.conf. See dracut.conf(5). You can also add dracut modules on the command line by using the -a or --add option:

```
# dracut --add module initramfs-module.img
```

To see a list of available dracut modules, use the --list-modules option:

```
# dracut --list-modules
```

### Omitting dracut Modules
Sometimes you don’t want a dracut module to be included for reasons of speed, size or functionality. To do this, either specify the omit_dracutmodules variable in the dracut.conf or /etc/dracut.conf.d/myconf.conf configuration file (see dracut.conf(5)), or use the -o or --omit option on the command line:

```
# dracut -o "multipath lvm" no-multipath-lvm.img
```

### Adding Kernel Modules
If you need a special kernel module in the initramfs, which is not automatically picked up by dracut, you have the use the --add-drivers option on the command line or the drivers variable in the /etc/dracut.conf or /etc/dracut.conf.d/myconf.conf configuration file (see dracut.conf(5)):

```
# dracut --add-drivers mymod initramfs-with-mymod.img
```

### Boot parameters
An initramfs generated without the "hostonly" mode, does not contain any system configuration files (except for some special exceptions), so the configuration has to be done on the kernel command line. With this flexibility, you can easily boot from a changed root partition, without the need to recompile the initramfs image. So, you could completely change your root partition (move it inside a md raid with encryption and LVM on top), as long as you specify the correct filesystem LABEL or UUID on the kernel command line for your root device, dracut will find it and boot from it.

The kernel command line can also be provided by the dhcp server with the root-path option. See the section called “Network Boot”.

For a full reference of all kernel command line parameters, see dracut.cmdline(7).

To get a quick start for the suitable kernel command line on your system, use the --print-cmdline option:

```
# dracut --print-cmdline

 root=UUID=8b8b6f91-95c7-4da2-831b-171e12179081 rootflags=rw,relatime,discard,data=ordered rootfstype=ext4
```

Specifying the root Device

This is the only option dracut really needs to boot from your root partition. Because your root partition can live in various environments, there are a lot of formats for the root= option. The most basic one is root=<path to device node>:

```
root=/dev/sda2
```

Because device node names can change, dependent on the drive ordering, you are encouraged to use the filesystem identifier (UUID) or filesystem label (LABEL) to specify your root partition:

```
root=UUID=19e9dda3-5a38-484d-a9b0-fa6b067d0331
```

or

```
root=LABEL=myrootpartitionlabel
```

To see all UUIDs or LABELs on your system, do:

```
# ls -l /dev/disk/by-uuid
```

or

```
# ls -l /dev/disk/by-label
```

If your root partition is on the network see the section called “Network Boot”.

Keyboard Settings

If you have to input passwords for encrypted disk volumes, you might want to set the keyboard layout and specify a display font.

A typical german kernel command line would contain:

```
rd.vconsole.font=eurlatgr rd.vconsole.keymap=de-latin1-nodeadkeys rd.locale.LANG=de_DE.UTF-8
```

Setting these options can override the setting stored on your system, if you use a modern init system, like systemd.

Blacklisting Kernel Modules

Sometimes it is required to prevent the automatic kernel module loading of a specific kernel module. To do this, just add rd.driver.blacklist=<kernel module name>, with <kernel module name> not containing the .ko suffix, to the kernel command line. For example:

```
rd.driver.blacklist=mptsas rd.driver.blacklist=nouveau
```

The option can be specified multiple times on the kernel command line.

Speeding up the Boot Process

If you want to speed up the boot process, you can specify as much information for dracut on the kernel command as possible. For example, you can tell dracut, that you root partition is not on a LVM volume or not on a raid partition, or that it lives inside a specific crypto LUKS encrypted volume. By default, dracut searches everywhere. A typical dracut kernel command line for a plain primary or logical partition would contain:

```
rd.luks=0 rd.lvm=0 rd.md=0 rd.dm=0
```

This turns off every automatic assembly of LVM, MD raids, DM raids and crypto LUKS.

Of course, you could also omit the dracut modules in the initramfs creation process, but then you would lose the possibility to turn it on on demand.

### Injecting custom Files
To add your own files to the initramfs image, you have several possibilities.

The --include option let you specify a source path and a target path. For example

```
# dracut --include cmdline-preset /etc/cmdline.d/mycmdline.conf initramfs-cmdline-pre.img
```

will create an initramfs image, where the file cmdline-preset will be copied inside the initramfs to /etc/cmdline.d/mycmdline.conf. --include can only be specified once.

```
# mkdir -p rd.live.overlay/etc/cmdline.d
# mkdir -p rd.live.overlay/etc/conf.d
# echo "ip=dhcp" >> rd.live.overlay/etc/cmdline.d/mycmdline.conf
# echo export FOO=testtest >> rd.live.overlay/etc/conf.d/testvar.conf
# echo export BAR=testtest >> rd.live.overlay/etc/conf.d/testvar.conf
# tree rd.live.overlay/
rd.live.overlay/
`-- etc

    |-- cmdline.d

    |   `-- mycmdline.conf

    `-- conf.d

        `-- testvar.conf
# dracut --include rd.live.overlay / initramfs-rd.live.overlay.img
```

This will put the contents of the rd.live.overlay directory into the root of the initramfs image.

The --install option let you specify several files, which will get installed in the initramfs image at the same location, as they are present on initramfs creation time.

```
# dracut --install 'strace fsck.ext4 ssh' initramfs-dbg.img
```

This will create an initramfs with the strace, fsck.ext4 and ssh executables, together with the libraries needed to start those. The --install option can be specified multiple times.

### Network Boot
If your root partition is on a network drive, you have to have the network dracut modules installed to create a network aware initramfs image.

If you specify ip=dhcp on the kernel command line, then dracut asks a dhcp server about the ip address for the machine. The dhcp server can also serve an additional root-path, which will set the root device for dracut. With this mechanism, you have static configuration on your client machine and a centralized boot configuration on your TFTP/DHCP server. If you can’t pass a kernel command line, then you can inject /etc/cmdline.d/mycmdline.conf, with a method described in the section called “Injecting custom Files”.

Reducing the Image Size

To reduce the size of the initramfs, you should create it with by omitting all dracut modules, which you know, you don’t need to boot the machine.

You can also specify the exact dracut and kernel modules to produce a very tiny initramfs image.

For example for a NFS image, you would do:

```
# dracut -m "nfs network base" initramfs-nfs-only.img
```

Then you would boot from this image with your target machine and reduce the size once more by creating it on the target machine with the --host-only option:

```
# dracut -m "nfs network base" --host-only initramfs-nfs-host-only.img
```

This will reduce the size of the initramfs image significantly.

## TROUBLESHOOTING
If the boot process does not succeed, you have several options to debug the situation.

### Identifying your problem area
1.Remove 'rhgb' and 'quiet' from the kernel command line

2.Add 'rd.shell' to the kernel command line. This will present a shell should dracut be unable to locate your root device

3.Add 'rd.shell rd.debug log_buf_len=1M' to the kernel command line so that dracut shell commands are printed as they are executed

4.The file /run/initramfs/rdsosreport.txt is generated, which contains all the logs and the output of all significant tools, which are mentioned later.

If you want to save that output, simply mount /boot by hand or insert an USB stick and mount that. Then you can store the output for later inspection.

### Information to include in your report
All bug reports

In all cases, the following should be mentioned and attached to your bug report:

•The exact kernel command-line used. Typically from the bootloader configuration file (e.g. /boot/grub2/grub.cfg) or from /proc/cmdline.

•A copy of your disk partition information from /etc/fstab, which might be obtained booting an old working initramfs or a rescue medium.

•Turn on dracut debugging (see the debugging dracut section), and attach the file /run/initramfs/rdsosreport.txt.

•If you use a dracut configuration file, please include /etc/dracut.conf and all files in /etc/dracut.conf.d/*.conf

Network root device related problems

This section details information to include when experiencing problems on a system whose root device is located on a network attached volume (e.g. iSCSI, NFS or NBD). As well as the information from the section called “All bug reports”, include the following information:

•Please include the output of

```
# /sbin/ifup <interfacename>
# ip addr show
```

### Debugging dracut
Configure a serial console

Successfully debugging dracut will require some form of console logging during the system boot. This section documents configuring a serial console connection to record boot messages.

1.First, enable serial console output for both the kernel and the bootloader.

2.Open the file /boot/grub2/grub.cfg for editing. Below the line 'timeout=5', add the following:

```
serial --unit=0 --speed=9600
terminal --timeout=5 serial console
```

3.Also in /boot/grub2/grub.cfg, add the following boot arguments to the 'kernel' line:

```
console=tty0 console=ttyS0,9600
```

4.When finished, the /boot/grub2/grub.cfg file should look similar to the example below.

```
default=0
timeout=5
serial --unit=0 --speed=9600
terminal --timeout=5 serial console
title Fedora (2.6.29.5-191.fc11.x86_64)

  root (hd0,0)

  kernel /vmlinuz-2.6.29.5-191.fc11.x86_64 ro root=/dev/mapper/vg_uc1-lv_root console=tty0 console=ttyS0,9600

  initrd /dracut-2.6.29.5-191.fc11.x86_64.img
```

5.More detailed information on how to configure the kernel for console output can be found at http://www.faqs.org/docs/Linux-HOWTO/Remote-Serial-Console-HOWTO.html#CONFIGURE-KERNEL.

6.Redirecting non-interactive output

Note

You can redirect all non-interactive output to /dev/kmsg and the kernel will put it out on the console when it reaches the kernel buffer by doing

```
# exec >/dev/kmsg 2>&1 </dev/console
```

Using the dracut shell

dracut offers a shell for interactive debugging in the event dracut fails to locate your root filesystem. To enable the shell:

1.Add the boot parameter 'rd.shell' to your bootloader configuration file (e.g. /boot/grub2/grub.cfg)

2.Remove the boot arguments 'rhgb' and 'quiet' A sample /boot/grub2/grub.cfg bootloader configuration file is listed below.

```
default=0
timeout=5
serial --unit=0 --speed=9600
terminal --timeout=5 serial console
title Fedora (2.6.29.5-191.fc11.x86_64)

  root (hd0,0)

  kernel /vmlinuz-2.6.29.5-191.fc11.x86_64 ro root=/dev/mapper/vg_uc1-lv_root console=tty0 rd.shell

  initrd /dracut-2.6.29.5-191.fc11.x86_64.img
```

3.If system boot fails, you will be dropped into a shell as seen in the example below.

```
No root device found
Dropping to debug shell.
#
```

4.Use this shell prompt to gather the information requested above (see the section called “All bug reports”).

Accessing the root volume from the dracut shell

From the dracut debug shell, you can manually perform the task of locating and preparing your root volume for boot. The required steps will depend on how your root volume is configured. Common scenarios include:

•A block device (e.g. /dev/sda7)

•A LVM logical volume (e.g. /dev/VolGroup00/LogVol00)

•An encrypted device (e.g. /dev/mapper/luks-4d5972ea-901c-4584-bd75-1da802417d83)

•A network attached device (e.g. netroot=iscsi:@192.168.0.4::3260::iqn.2009-02.org.example:for.all)

The exact method for locating and preparing will vary. However, to continue with a successful boot, the objective is to locate your root volume and create a symlink /dev/root which points to the file system. For example, the following example demonstrates accessing and booting a root volume that is an encrypted LVM Logical volume.

1.Inspect your partitions using parted

```
# parted /dev/sda -s p
Model: ATA HTS541060G9AT00 (scsi)
Disk /dev/sda: 60.0GB
Sector size (logical/physical): 512B/512B
Partition Table: msdos
Number  Start   End     Size    Type      File system  Flags
1      32.3kB  10.8GB  107MB   primary   ext4         boot
2      10.8GB  55.6GB  44.7GB  logical                lvm
```

2.You recall that your root volume was a LVM logical volume. Scan and activate any logical volumes.

```
# lvm vgscan
# lvm vgchange -ay
```

3.You should see any logical volumes now using the command blkid:

```
# blkid
/dev/sda1: UUID="3de247f3-5de4-4a44-afc5-1fe179750cf7" TYPE="ext4"
/dev/sda2: UUID="Ek4dQw-cOtq-5MJu-OGRF-xz5k-O2l8-wdDj0I" TYPE="LVM2_member"
/dev/mapper/linux-root: UUID="def0269e-424b-4752-acf3-1077bf96ad2c" TYPE="crypto_LUKS"
/dev/mapper/linux-home: UUID="c69127c1-f153-4ea2-b58e-4cbfa9257c5e" TYPE="ext4"
/dev/mapper/linux-swap: UUID="47b4d329-975c-4c08-b218-f9c9bf3635f1" TYPE="swap"
```

4.From the output above, you recall that your root volume exists on an encrypted block device. Following the guidance disk encryption guidance from the Installation Guide, you unlock your encrypted root volume.

```
# UUID=$(cryptsetup luksUUID /dev/mapper/linux-root)
# cryptsetup luksOpen /dev/mapper/linux-root luks-$UUID
Enter passphrase for /dev/mapper/linux-root:
Key slot 0 unlocked.
```

5.Next, make a symbolic link to the unlocked root volume

```
# ln -s /dev/mapper/luks-$UUID /dev/root
```

6.With the root volume available, you may continue booting the system by exiting the dracut shell

```
# exit
```

Additional dracut boot parameters

For more debugging options, see dracut.cmdline(7).

Debugging dracut on shutdown

To debug the shutdown sequence on systemd systems, you can rd.break on pre-shutdown or shutdown.

To do this from an already booted system:

```
# mkdir -p /run/initramfs/etc/cmdline.d
# echo "rd.debug rd.break=pre-shutdown rd.break=shutdown" > /run/initramfs/etc/cmdline.d/debug.conf
# touch /run/initramfs/.need_shutdown
```

This will give you a dracut shell after the system pivot’ed back in the initramfs.

## OPTIONS
--kver <kernel version>

Set the kernel version. This enables to specify the kernel version, without specifying the location of the initramfs image. For example:

```
# dracut --kver 3.5.0-0.rc7.git1.2.fc18.x86_64
```

-f, --force

Overwrite existing initramfs file.

<output file> --rebuild

Append the current arguments to those with which the input initramfs image was built. This option helps in incrementally building the initramfs for testing. If optional <output file> is not provided, the input initramfs provided to rebuild will be used as output file.

-a, --add <list of dracut modules>

Add a space-separated list of dracut modules to the default set of modules. This parameter can be specified multiple times.

Note

If the list has multiple arguments, then you have to put these in quotes. For example:

```
# dracut --add "module1 module2"  ...
```

--force-add <list of dracut modules>

Force to add a space-separated list of dracut modules to the default set of modules, when -H is specified. This parameter can be specified multiple times.

Note

If the list has multiple arguments, then you have to put these in quotes. For example:

```
# dracut --force-add "module1 module2"  ...
```

-o, --omit <list of dracut modules>

Omit a space-separated list of dracut modules. This parameter can be specified multiple times.

Note

If the list has multiple arguments, then you have to put these in quotes. For example:

```
# dracut --omit "module1 module2"  ...
```

-m, --modules <list of dracut modules>

Specify a space-separated list of dracut modules to call when building the initramfs. Modules are located in /usr/lib/dracut/modules.d. This parameter can be specified multiple times. This option forces dracut to only include the specified dracut modules. In most cases the "--add" option is what you want to use.

Note

If the list has multiple arguments, then you have to put these in quotes. For example:

```
# dracut --modules "module1 module2"  ...
```

-d, --drivers <list of kernel modules>

Specify a space-separated list of kernel modules to exclusively include in the initramfs. The kernel modules have to be specified without the ".ko" suffix. This parameter can be specified multiple times.

Note

If the list has multiple arguments, then you have to put these in quotes. For example:

```
# dracut --drivers "kmodule1 kmodule2"  ...
```

--add-drivers <list of kernel modules>

Specify a space-separated list of kernel modules to add to the initramfs. The kernel modules have to be specified without the ".ko" suffix. This parameter can be specified multiple times.

Note

If the list has multiple arguments, then you have to put these in quotes. For example:

```
# dracut --add-drivers "kmodule1 kmodule2"  ...
```

--force-drivers <list of kernel modules>

See add-drivers above. But in this case it is ensured that the drivers are tried to be loaded early via modprobe.

Note

If the list has multiple arguments, then you have to put these in quotes. For example:

```
# dracut --force-drivers "kmodule1 kmodule2"  ...
```

--omit-drivers <list of kernel modules>

Specify a space-separated list of kernel modules not to add to the initramfs. The kernel modules have to be specified without the ".ko" suffix. This parameter can be specified multiple times.

Note

If the list has multiple arguments, then you have to put these in quotes. For example:

```
# dracut --omit-drivers "kmodule1 kmodule2"  ...
```

--filesystems <list of filesystems>

Specify a space-separated list of kernel filesystem modules to exclusively include in the generic initramfs. This parameter can be specified multiple times.

Note

If the list has multiple arguments, then you have to put these in quotes. For example:

```
# dracut --filesystems "filesystem1 filesystem2"  ...
```

-k, --kmoddir <kernel directory>

Specify the directory, where to look for kernel modules.

--fwdir <dir>[:<dir>...]++

Specify additional directories, where to look for firmwares. This parameter can be specified multiple times.

--libdirs <list of directories>

Specify a space-separated list of directories to look for libraries to include in the generic initramfs. This parameter can be specified multiple times.

Note

If the list has multiple arguments, then you have to put these in quotes. For example:

```
# dracut --libdirs "dir1 dir2"  ...
```

--kernel-cmdline <parameters>

Specify default kernel command line parameters.

--kernel-only

Only install kernel drivers and firmware files.

--no-kernel

Do not install kernel drivers and firmware files.

--early-microcode

Combine early microcode with ramdisk.

--no-early-microcode

Do not combine early microcode with ramdisk.

--print-cmdline

Print the kernel command line for the current disk layout.

--mdadmconf

Include local /etc/mdadm.conf file.

--nomdadmconf

Do not include local /etc/mdadm.conf file.

--lvmconf

Include local /etc/lvm/lvm.conf file.

--nolvmconf

Do not include local /etc/lvm/lvm.conf file.

--fscks <list of fsck tools>

Add a space-separated list of fsck tools, in addition to dracut.conf's specification; the installation is opportunistic (non-existing tools are ignored).

Note

If the list has multiple arguments, then you have to put these in quotes. For example:

```
# dracut --fscks "fsck.foo barfsck"  ...
```

--nofscks

Inhibit installation of any fsck tools.

--strip

Strip binaries in the initramfs (default).

--aggressive-strip

Strip more than just debug symbol and sections, for a smaller initramfs build. The --strip option must also be specified.

--nostrip

Do not strip binaries in the initramfs.

--hardlink

Hardlink files in the initramfs (default).

--nohardlink

Do not hardlink files in the initramfs.

--prefix <dir>

Prefix initramfs files with the specified directory.

--noprefix

Do not prefix initramfs files (default).

-h, --help

Display help text and exit.

--debug

Output debug information of the build process.

-v, --verbose

Increase verbosity level (default is info(4)).

--version

Display version and exit.

-q, --quiet

Decrease verbosity level (default is info(4)).

-c, --conf <dracut configuration file>

Specify configuration file to use. Default: /etc/dracut.conf

--confdir <configuration directory>

Specify configuration directory to use. Default: /etc/dracut.conf.d

--tmpdir <temporary directory>

Specify temporary directory to use. Default: /var/tmp

-r, --sysroot <sysroot directory>

Specify the sysroot directory to collect files from. This is useful to create the initramfs image from a cross-compiled sysroot directory. For the extra helper variables, see ENVIRONMENT below. Default: empty

--sshkey <sshkey file>

SSH key file used with ssh-client module.

--logfile <logfile>

Logfile to use; overrides any setting from the configuration files. Default: /var/log/dracut.log

-l, --local

Activates the local mode. dracut will use modules from the current working directory instead of the system-wide installed modules in /usr/lib/dracut/modules.d. This is useful when running dracut from a git checkout.

-H, --hostonly

Host-only mode: Install only what is needed for booting the local host instead of a generic host and generate host-specific configuration.

Warning

If chrooted to another root other than the real root device, use "--fstab" and provide a valid /etc/fstab.

-N, --no-hostonly

Disable host-only mode.

--hostonly-mode <mode>

Specify the host-only mode to use. <mode> could be one of "sloppy" or "strict". In "sloppy" host-only mode, extra drivers and modules will be installed, so minor hardware change won’t make the image unbootable (e.g. changed keyboard), and the image is still portable among similar hosts. With "strict" mode enabled, anything not necessary for booting the local host in its current state will not be included, and modules may do some extra job to save more space. Minor change of hardware or environment could make the image unbootable. Default: sloppy

--hostonly-cmdline

Store kernel command line arguments needed in the initramfs.

--no-hostonly-cmdline

Do not store kernel command line arguments needed in the initramfs.

--no-hostonly-default-device

Do not generate implicit host devices like root, swap, fstab, etc. Use "--mount" or "--add-device" to explicitly add devices as needed.

--hostonly-i18n

Install only needed keyboard and font files according to the host configuration (default).

--no-hostonly-i18n

Install all keyboard and font files available.

--hostonly-nics <list of nics>

Only enable listed NICs in the initramfs. The list can be empty, so other modules can install only the necessary network drivers.

--persistent-policy <policy>

Use <policy> to address disks and partitions. <policy> can be any directory name found in /dev/disk (e.g. "by-uuid", "by-label"), or "mapper" to use /dev/mapper device names (default).

--fstab

Use /etc/fstab instead of /proc/self/mountinfo.

--add-fstab <filename>

Add entries of <filename> to the initramfs /etc/fstab.

--mount "<device> <mountpoint> <filesystem type> [<filesystem options> [<dump frequency> [<fsck order>]]]"

Mount <device> on <mountpoint> with <filesystem type> in the initramfs. <filesystem options>, <dump options> and <fsck order> can be specified, see fstab manpage for the details. The default <filesystem options> is "defaults". The default <dump frequency> is "0". The default <fsck order> is "2".

--mount "<mountpoint>"

Like above, but <device>, <filesystem type> and <filesystem options> are determined by looking at the current mounts.

--add-device <device>

Bring up <device> in initramfs, <device> should be the device name. This can be useful in host-only mode for resume support when your swap is on LVM or an encrypted partition. [NB --device can be used for compatibility with earlier releases]

-i, --include <SOURCE> <TARGET>

Include the files in the SOURCE directory into the TARGET directory in the final initramfs. If SOURCE is a file, it will be installed to TARGET in the final initramfs. This parameter can be specified multiple times.

-I, --install <file list>

Install the space separated list of files into the initramfs.

Note

If the list has multiple arguments, then you have to put these in quotes. For example:

```
# dracut --install "/bin/foo /sbin/bar"  ...
```

--install-optional <file list>

Install the space separated list of files into the initramfs, if they exist.

--gzip

Compress the generated initramfs using gzip. This will be done by default, unless another compression option or --no-compress is passed. Equivalent to "--compress=gzip -9".

--bzip2

Compress the generated initramfs using bzip2.

Warning

Make sure your kernel has bzip2 decompression support compiled in, otherwise you will not be able to boot. Equivalent to "--compress=bzip2 -9".

--lzma

Compress the generated initramfs using lzma.

Warning

Make sure your kernel has lzma decompression support compiled in, otherwise you will not be able to boot. Equivalent to "--compress=lzma -9 -T0".

--xz

Compress the generated initramfs using xz.

Warning

Make sure your kernel has xz decompression support compiled in, otherwise you will not be able to boot. Equivalent to "--compress=xz --check=crc32 --lzma2=dict=1MiB -T0".

--lzo

Compress the generated initramfs using lzop.

Warning

Make sure your kernel has lzo decompression support compiled in, otherwise you will not be able to boot. Equivalent to "--compress=lzop -9".

--lz4

Compress the generated initramfs using lz4.

Warning

Make sure your kernel has lz4 decompression support compiled in, otherwise you will not be able to boot. Equivalent to "--compress=lz4 -l -9".

--zstd

Compress the generated initramfs using Zstandard.

Warning

Make sure your kernel has zstd decompression support compiled in, otherwise you will not be able to boot. Equivalent to "--compress=zstd -15 -q -T0".

--compress <compressor>

Compress the generated initramfs using the passed compression program. If you pass it just the name of a compression program, it will call that program with known-working arguments. If you pass a quoted string with arguments, it will be called with exactly those arguments. Depending on what you pass, this may result in an initramfs that the kernel cannot decompress. The default value can also be set via the INITRD_COMPRESS environment variable.

--squash-compressor <compressor>

Compress the squashfs image using the passed compressor and compressor specific options for mksquashfs. You can refer to mksquashfs manual for supported compressors and compressor specific options. If squash module is not called when building the initramfs, this option will not take effect.

--no-compress

Do not compress the generated initramfs. This will override any other compression options.

--reproducible

Create reproducible images.

--no-reproducible

Do not create reproducible images.

--list-modules

List all available dracut modules.

-M, --show-modules

Print included module’s name to standard output during build.

--keep

Keep the initramfs temporary directory for debugging purposes.

--printsize

Print out the module install size.

--profile

Output profile information of the build process.

--ro-mnt

Mount / and /usr read-only by default.

-L, --stdlog <level>

[0-6] Specify logging level (to standard error).

```
          0 - suppress any messages

          1 - only fatal errors

          2 - all errors

          3 - warnings

          4 - info

          5 - debug info (here starts lots of output)

          6 - trace info (and even more)
```

--regenerate-all

Regenerate all initramfs images at the default location with the kernel versions found on the system. Additional parameters are passed through.

-p, --parallel

Try to execute tasks in parallel. Currently only supported with --regenerate-all (build initramfs images for all kernel versions simultaneously).

--noimageifnotneeded

Do not create an image in host-only mode, if no kernel driver is needed and no /etc/cmdline/*.conf will be generated into the initramfs.

--loginstall <directory>

Log all files installed from the host to <directory>.

--uefi

Instead of creating an initramfs image, dracut will create an UEFI executable, which can be executed by an UEFI BIOS. The default output filename is <EFI>/EFI/Linux/linux-$kernel$-<MACHINE_ID>-<BUILD_ID>.efi. <EFI> might be /efi, /boot or /boot/efi depending on where the ESP partition is mounted. The <BUILD_ID> is taken from BUILD_ID in /usr/lib/os-release or if it exists /etc/os-release and is left out, if BUILD_ID is non-existent or empty.

--no-uefi

Disables UEFI mode.

--no-machineid

Affects the default output filename of --uefi and will discard the <MACHINE_ID> part.

--uefi-stub <file>

Specifies the UEFI stub loader, which will load the attached kernel, initramfs and kernel command line and boots the kernel. The default is $prefix/lib/systemd/boot/efi/linux<EFI-MACHINE-TYPE-NAME>.efi.stub.

--uefi-splash-image <file>

Specifies the UEFI stub loader’s splash image. Requires bitmap (.bmp) image format.

--kernel-image <file>

Specifies the kernel image, which to include in the UEFI executable. The default is /lib/modules/<KERNEL-VERSION>/vmlinuz or /boot/vmlinuz-<KERNEL-VERSION>.

--sbat <parameters>

Specifies the SBAT parameters, which to include in the UEFI executable. By default the default SBAT string added is "sbat,1,SBAT Version,sbat,1, https://github.com/rhboot/shim/blob/main/SBAT.md".

--enhanced-cpio

Attempt to use the dracut-cpio binary, which optimizes archive creation for copy-on-write filesystems by using the copy_file_range(2) syscall via Rust’s io::copy(). When specified, initramfs archives are also padded to ensure optimal data alignment for extent sharing. To retain reflink data deduplication benefits, this should be used alongside the --no-compress and --nostrip parameters, with initramfs source files, --tmpdir staging area and destination all on the same copy-on-write capable filesystem.

## ENVIRONMENT
INITRD_COMPRESS

sets the default compression program. See --compress.

DRACUT_LDCONFIG

sets the ldconfig program path and options. Optional. Used for --sysroot. Default: ldconfig

DRACUT_LDD

sets the ldd program path and options. Optional. Used for --sysroot. Default: ldd

DRACUT_TESTBIN

sets the initially tested binary for detecting library paths. Optional. Used for --sysroot. In the cross-compiled sysroot, the default value (/bin/sh) is unusable, as it is an absolute symlink and points outside the sysroot directory. Default: /bin/sh

DRACUT_INSTALL

overrides path and options for executing dracut-install internally. Optional. Can be used to debug dracut-install while running the main dracut script. Default: dracut-install

Example: DRACUT_INSTALL="valgrind dracut-install"

DRACUT_COMPRESS_BZIP2, DRACUT_COMPRESS_LBZIP2, DRACUT_COMPRESS_LZMA, DRACUT_COMPRESS_XZ, DRACUT_COMPRESS_GZIP, DRACUT_COMPRESS_PIGZ, DRACUT_COMPRESS_LZOP, DRACUT_COMPRESS_ZSTD, DRACUT_COMPRESS_LZ4, DRACUT_COMPRESS_CAT

overrides for compression utilities to support using them from non-standard paths. Default values are the default compression utility names to be found in PATH.

DRACUT_ARCH

overrides the value of uname -m. Used for --sysroot. Default: empty (the value of uname -m on the host system)

SYSTEMD_VERSION

overrides systemd version. Used for --sysroot.

SYSTEMCTL

overrides the systemctl binary. Used for --sysroot.

NM_VERSION

overrides the NetworkManager version. Used for --sysroot.

DRACUT_INSTALL_PATH

overrides PATH environment for dracut-install to look for binaries relative to --sysroot. In a cross-compiled environment (e.g. Yocto), PATH points to natively built binaries that are not in the host’s /bin, /usr/bin, etc. dracut-install still needs plain /bin and /usr/bin that are relative to the cross-compiled sysroot. Default: PATH

DRACUT_INSTALL_LOG_TARGET

overrides DRACUT_LOG_TARGET for dracut-install. It allows running dracut-install* to run with different log target that dracut** runs with. Default: DRACUT_LOG_TARGET

DRACUT_INSTALL_LOG_LEVEL

overrides DRACUT_LOG_LEVEL for dracut-install. It allows running dracut-install* to run with different log level that dracut** runs with. Default: DRACUT_LOG_LEVEL

## FILES
/var/log/dracut.log

logfile of initramfs image creation

/tmp/dracut.log

logfile of initramfs image creation, if /var/log/dracut.log is not writable

/etc/dracut.conf

see dracut.conf5

/etc/dracut.conf.d/*.conf

see dracut.conf5

/usr/lib/dracut/dracut.conf.d/*.conf

see dracut.conf5

### Configuration in the initramfs
/etc/conf.d/

Any files found in /etc/conf.d/ will be sourced in the initramfs to set initial values. Command line options will override these values set in the configuration files.

/etc/cmdline

Can contain additional command line options. Deprecated, better use /etc/cmdline.d/*.conf.

/etc/cmdline.d/*.conf

Can contain additional command line options.

## AVAILABILITY
The dracut command is part of the dracut package and is available from https://github.com/dracutdevs/dracut

## AUTHORS
Harald Hoyer

Victor Lowther

Amadeusz Żołnowski

Hannes Reinecke

Daniel Molkentin

Will Woods

Philippe Seewer

Warren Togami

## SEE ALSO
dracut.cmdline(7) dracut.conf(5) lsinitrd(1)


dracut-cmdline.service

title: dracut-cmdline.service(8)

text:
# dracut-cmdline.service(8)

## NAME
dracut-cmdline.service - runs the dracut hooks to parse the kernel command line

## SYNOPSIS
dracut-cmdline.service

## DESCRIPTION
This service runs all the dracut hooks to parse the kernel command line in the initramfs.

## AUTHORS
Harald Hoyer

## SEE ALSO
dracut.bootup(7) dracut(8)


dracut-initqueue.service

title: dracut-initqueue.service(8)

text:
# dracut-initqueue.service(8)

## NAME
dracut-initqueue.service - runs the dracut main loop to find the real root

## SYNOPSIS
dracut-initqueue.service

## DESCRIPTION
This service runs all the main loop of dracut in the initramfs to find the real root.

## AUTHORS
Harald Hoyer

## SEE ALSO
dracut.bootup(7) dracut(8)


dracut-mount.service

title: dracut-mount.service(8)

text:
# dracut-mount.service(8)

## NAME
dracut-mount.service - runs the dracut hooks after /sysroot is mounted

## SYNOPSIS
dracut-mount.service

## DESCRIPTION
This service runs all dracut hooks after the real root is mounted on /sysroot.

## AUTHORS
Harald Hoyer

## SEE ALSO
dracut.bootup(7) dracut(8)


dracut-pre-mount.service

title: dracut-pre-mount.service(8)

text:
# dracut-pre-mount.service(8)

## NAME
dracut-pre-mount.service - runs the dracut hooks before /sysroot is mounted

## SYNOPSIS
dracut-pre-mount.service

## DESCRIPTION
This service runs all dracut hooks before the real root is mounted on /sysroot.

## AUTHORS
Harald Hoyer

## SEE ALSO
dracut.bootup(7) dracut(8)


dracut-pre-pivot.service

title: dracut-pre-pivot.service(8)

text:
# dracut-pre-pivot.service(8)

## NAME
dracut-pre-pivot.service - runs the dracut hooks before switching root

## SYNOPSIS
dracut-pre-pivot.service

## DESCRIPTION
This service runs all dracut hooks before the system switched to the real root.

## AUTHORS
Harald Hoyer

## SEE ALSO
dracut.bootup(7) dracut(8)


dracut-pre-trigger.service

title: dracut-pre-trigger.service(8)

text:
# dracut-pre-trigger.service(8)

## NAME
dracut-pre-trigger.service - runs the dracut hooks before udevd is triggered

## SYNOPSIS
dracut-pre-trigger.service

## DESCRIPTION
This service runs all dracut hooks before udevd is triggered in the initramfs.

## AUTHORS
Harald Hoyer

## SEE ALSO
dracut.bootup(7) dracut(8)


dracut-pre-udev.service

title: dracut-pre-udev.service(8)

text:
# dracut-pre-udev.service(8)

## NAME
dracut-pre-udev.service - runs the dracut hooks before udevd is started

## SYNOPSIS
dracut-pre-udev.service

## DESCRIPTION
This service runs all dracut hooks before udevd is started in the initramfs.

## AUTHORS
Harald Hoyer

## SEE ALSO
dracut.bootup(7) dracut(8)


dracut-shutdown.service

title: dracut-shutdown.service(8)

summary: unpack the initramfs to /run/initramfs

text:
# dracut-shutdown.service(8)

## NAME
dracut-shutdown.service - unpack the initramfs to /run/initramfs

## SYNOPSIS
dracut-shutdown.service

## DESCRIPTION
This service unpacks the initramfs image to /run/initramfs. systemd pivots into /run/initramfs at shutdown, so the root filesystem can be safely unmounted.

The following steps are executed during a shutdown:

•systemd switches to the shutdown.target

•systemd starts /lib/systemd/system/shutdown.target.wants/dracut-shutdown.service

•dracut-shutdown.service executes /usr/lib/dracut/dracut-initramfs-restore which unpacks the initramfs to /run/initramfs

•systemd finishes shutdown.target

•systemd kills all processes

•systemd tries to unmount everything and mounts the remaining read-only

•systemd checks, if there is a /run/initramfs/shutdown executable

•if yes, it does a pivot_root to /run/initramfs and executes ./shutdown. The old root is then mounted on /oldroot. /usr/lib/dracut/modules.d/99shutdown/shutdown.sh is the shutdown executable.

•shutdown will try to umount every /oldroot mount and calls the various shutdown hooks from the dracut modules

This ensures, that all devices are disassembled and unmounted cleanly.

To debug the shutdown process, you can get a shell in the shutdown procedure by injecting "rd.break=pre-shutdown rd.shell" or "rd.break=shutdown rd.shell".

```
# mkdir -p /run/initramfs/etc/cmdline.d
# echo "rd.break=pre-shutdown rd.shell" > /run/initramfs/etc/cmdline.d/debug.conf
# touch /run/initramfs/.need_shutdown
```

In case the unpack of the initramfs fails, dracut-shutdown-onfailure.service executes to make sure switch root doesn’t happen, since it would result in switching to an incomplete initramfs.

## AUTHORS
Harald Hoyer

## SEE ALSO
dracut(8)


dracut-catimages

package: dracut-tools

title: dracut-catimages(8)

text:
# dracut-catimages(8)

## NAME
dracut-catimages - creates initial ramdisk image by concatenating images

## SYNOPSIS
dracut-catimages [OPTION...] <initramfs base image> [<image>...]

## DESCRIPTION
dracut-catimages creates an initial ramdisk image by concatenating several images from the command line and /boot/dracut/*.img

## OPTIONS
-f, --force

overwrite existing initramfs file.

-i, --imagedir

Directory with additional images to add (default: /boot/dracut/)

-o, --overlaydir

Overlay directory, which contains additional files that will be used to create an additional image

--nooverlay

Do not use the overlay directory

--noimagedir

Do not use the additional image directory

-h, --help

display help text and exit.

--debug

output debug information of the build process

-v, --verbose

verbose output during the build process

## FILES
/boot/dracut/*.img

images to work with

## AUTHORS
Harald Hoyer

## AVAILABILITY
The dracut-catimages command is part of the dracut package and is available from https://github.com/dracutdevs/dracut

## SEE ALSO
dracut(8)


package: drbd-utils

title: drbd-8.4(8)

summary: The start and stop script for DRBD

text:
# drbd-8.4(8)

## NAME
drbd - The start and stop script for DRBD

## SYNOPSIS
/etc/init.d/drbd [resource] {{start} | {stop} | {status} | {reload} | {restart} | {force-reload}}

## INTRODUCTION
The /etc/init.d/drbd script is used to start and stop drbd on a system V style init system.

In order to use /etc/init.d/drbd you must define a resource, a host, and any other configuration options in the drbd configuration file. See /etc/drbd.conf for details. If resource is omitted, then all of the resources listed in the config file are configured.

This script might ask you “Do you want to abort waiting for other server and make this one primary?”

Only answer this question with “yes” if you are sure that it is impossible to repair the other node.

## VERSION
This document was revised for version 8.4.11 of the DRBD distribution.

## AUTHOR
Written by Philipp Reisner <philipp.reisner@linbit.com> and Lars Ellenberg <lars.ellenberg@linbit.com>.

## REPORTING BUGS
Report bugs to <drbd-user@lists.linbit.com>.

## COPYRIGHT
Copyright 2001-2008 LINBIT Information Technologies, Philipp Reisner, Lars Ellenberg. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

## SEE ALSO
drbd.conf(5), drbdsetup(8)drbdadm(8)DRBD Homepage[1]

## NOTES
1.

DRBD Homepage

http://www.drbd.org/


title: drbd-9.0(8)

summary: The start and stop script for DRBD

text:
# drbd-9.0(8)

## NAME
drbd - The start and stop script for DRBD

## SYNOPSIS
/etc/init.d/drbd {start | stop | status | reload | restart | force-reload}

## INTRODUCTION
The /etc/init.d/drbd script is used to start and stop drbd on a system V style init system.

When using a cluster resource manger such as Pacemaker, DRBD should usually not be started by the init system, but should typically be exclusively controlled by the cluster manager. You should not use, and disable, the init script in this case. chmod -x /etc/init.d/drbd has proven most effective for this.

In order to use /etc/init.d/drbd, define a drbd configuration. See drbd.conf(5) for details.

## VERSION
This document was revised for version 9.0.0 of the DRBD distribution.

## AUTHOR
Written by Philipp Reisner <philipp.reisner@linbit.com> and Lars Ellenberg <lars.ellenberg@linbit.com>.

## REPORTING BUGS
Report bugs to <drbd-user@lists.linbit.com>.

## COPYRIGHT
Copyright 2001-2014 LINBIT Information Technologies, Philipp Reisner, Lars Ellenberg. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

## SEE ALSO
drbd.conf(5), drbdsetup(8), drbdadm(8), DRBD Homepage[1]

## NOTES
1.

DRBD Homepage

http://www.drbd.org/