Genkernel

is Article description::a tool created by Gentoo used to automate the build process of the [[kernel and initramfs.]] Some of the general features include:


 * Configuring the kernel sources.
 * Building the compressed kernel and copying it to.
 * Creating an initramfs and copying it to.
 * Creating symlinks in.
 * Adding custom content to the initramfs such as encryption related files, boot splash images, extra modules, and more.
 * Configuring the bootloader to boot the newly created kernel and initramfs.

Emerge
Initiate the installation of genkernel:

Usage
The general form of genkernel invocation is as follows:

Options
The actual behavior of genkernel depends on a large variety of options, the majority of which can be set/unset in the file or passed via the  command on each invocation. Options passed over the command line take precedence over options defined in. The configuration file is very well documented, however some of the most commonly used options will be explored in this article. The goal is for the reader to be familiar with common genkernel invocations. For a more complete set of explanations refer to the comments in itself or to the output of.

Options acting on user interactivity
The configuration options listed below help the user decide how to interact with the configuration process. Users can even choose whether or not the configuration file created in the process should be saved. The following are considered primary configuration options:


 * Points to the Genkernel configuration file to use (defaults to ).
 * Points to the Genkernel configuration file to use (defaults to ).


 * Points to the kernel configuration file to use. To re-use the kernel configuration from the currently running kernel, it is possible to specify if it exists. By default, genkernel uses the config from the previous build of the same kernel version or a default kernel config if there isn't a previous config. Use the special value default to force usage of genkernel's generic kernel config.
 * Points to the kernel configuration file to use. To re-use the kernel configuration from the currently running kernel, it is possible to specify if it exists. By default, genkernel uses the config from the previous build of the same kernel version or a default kernel config if there isn't a previous config. Use the special value default to force usage of genkernel's generic kernel config.


 * Activates (or deactivates) the command (which invokes an interactive configuration menu) before building the kernel.
 * Activates (or deactivates) the command (which invokes an interactive configuration menu) before building the kernel.


 * Provides a kernel configuration utility which depends on the GTK libraries. The advantage of this option is that most users find it easier and clearer to configure the kernel using this tool, since it relies on the X-windowing system. The disadvantage of this option is that the X-windowing system is required to use it, so it will not work on the command line.
 * Provides a kernel configuration utility which depends on the GTK libraries. The advantage of this option is that most users find it easier and clearer to configure the kernel using this tool, since it relies on the X-windowing system. The disadvantage of this option is that the X-windowing system is required to use it, so it will not work on the command line.


 * Provides a kernel configuration utility which depends on the QT libraries. The advantage of this option is that most users find it easier and clearer to configure the kernel using this tool, since it relies on the X-windowing system. The disadvantage of this option is that the X-windowing system is needed to use it, so it will not work on the command line.
 * Provides a kernel configuration utility which depends on the QT libraries. The advantage of this option is that most users find it easier and clearer to configure the kernel using this tool, since it relies on the X-windowing system. The disadvantage of this option is that the X-windowing system is needed to use it, so it will not work on the command line.


 * Saves [or does not save] the kernel configuration to a file in the directory for later use.
 * Saves [or does not save] the kernel configuration to a file in the directory for later use.


 * Allows the modification of kernel's LOCALVERSION value which will affect kernel's and and initramfs' filename in and modules in  directory. This is especially helpful to build a new independent revision with its own kernel binary, initramfs and modules. The example above, with =sys-kernel/gentoo-sources-5.4.2, would create,  and  on  with default settings.
 * Allows the modification of kernel's LOCALVERSION value which will affect kernel's and and initramfs' filename in and modules in  directory. This is especially helpful to build a new independent revision with its own kernel binary, initramfs and modules. The example above, with =sys-kernel/gentoo-sources-5.4.2, would create,  and  on  with default settings.

Options acting on the resulting system
The configuration options listed here defines which features will or will not be enabled in the resulting kernel and initrd.


 * Activates (or deactivates) support for Fbsplash framebuffer splash in the genkernel-built initrd image. To override the default theme used by fbsplash, use  (where   is the title of one of the directories inside the  directory).
 * Activates (or deactivates) support for Fbsplash framebuffer splash in the genkernel-built initrd image. To override the default theme used by fbsplash, use  (where   is the title of one of the directories inside the  directory).


 * This option allows to select which splash screen resolutions will be supported in the initrd during the start-up of the system. This is useful for two reasons. First, to be able to select only the splash screen resolution(s) relevant to the system. Second, to avoid the unnecessary increase in the disk space required by initrd (since the initrd does not have to support resolutions that are irrelevant for the system's configuration.) However, the option is best omitted if the kernel is being compiled for an Installation CD; this allows splash support for all possible resolutions.
 * This option allows to select which splash screen resolutions will be supported in the initrd during the start-up of the system. This is useful for two reasons. First, to be able to select only the splash screen resolution(s) relevant to the system. Second, to avoid the unnecessary increase in the disk space required by initrd (since the initrd does not have to support resolutions that are irrelevant for the system's configuration.) However, the option is best omitted if the kernel is being compiled for an Installation CD; this allows splash support for all possible resolutions.


 * Force keymap selection during the boot sequence.
 * Force keymap selection during the boot sequence.


 * Enables keymap selection at boot (e.g. for LUKS container password input). The desired keymap can be passed in boot options as the value of  (name of the keymap file without .map). Available keymap files can be found in.
 * If the keymap you need is not available in genkernel you can convert one of the existing keymaps (available in ) using  . See  man page for details.
 * If the keymap you need is not available in genkernel you can convert one of the existing keymaps (available in ) using  . See  man page for details.


 * Includes support for storage using via Logical Volume Management (LVM2) from static binaries, if available to the system. Relevant (static) LVM2 binaries are compiled if they are unavailable. Be sure to install the package on the system  before enabling this option, then review the LVM article on the Gentoo wiki.
 * Includes support for storage using via Logical Volume Management (LVM2) from static binaries, if available to the system. Relevant (static) LVM2 binaries are compiled if they are unavailable. Be sure to install the package on the system  before enabling this option, then review the LVM article on the Gentoo wiki.


 * Includes support for DMRAID; the utility which creates RAID mappings using the kernel device-mapper subsystem. DMRAID discovers, activates, deactivates and displays properties of software RAID sets (ATARAID, for example) and contained DOS partitions.
 * Includes support for DMRAID; the utility which creates RAID mappings using the kernel device-mapper subsystem. DMRAID discovers, activates, deactivates and displays properties of software RAID sets (ATARAID, for example) and contained DOS partitions.


 * Includes support for Linux Unified Key Setup or LUKS. This will allow to use a device encrypted by LUKS which contains the root filesystem. On the bootloader, set that encrypted device as the value of, and   shall be the unencrypted device LUKS creates ( i.e /dev/mapper/root will be path to mount, and proper boot parameters line will look, like this:  ).
 * Includes support for Linux Unified Key Setup or LUKS. This will allow to use a device encrypted by LUKS which contains the root filesystem. On the bootloader, set that encrypted device as the value of, and   shall be the unencrypted device LUKS creates ( i.e /dev/mapper/root will be path to mount, and proper boot parameters line will look, like this:  ).


 * Adds support for disk label and UUID support to the initrd.
 * Adds support for disk label and UUID support to the initrd.


 * Adds support for iSCSI to the initrd.
 * Adds support for iSCSI to the initrd.


 * Adds support for Multipath to the initrd.
 * Adds support for Multipath to the initrd.


 * Specifies a user-created linuxrc — a script that is initialized during the start-up stage of the kernel, prior to the actual boot process. A default linuxrc script can be found in the directory. This script allows booting into a small, modularized kernel; it tries to load the minimum amount of drivers that are needed (as modules) by the system.
 * Specifies a user-created linuxrc — a script that is initialized during the start-up stage of the kernel, prior to the actual boot process. A default linuxrc script can be found in the directory. This script allows booting into a small, modularized kernel; it tries to load the minimum amount of drivers that are needed (as modules) by the system.


 * Overrides the default cache location used while compiling the kernel.
 * Overrides the default cache location used while compiling the kernel.


 * Specifies the location of the temporary directory used by genkernel while compiling the kernel.
 * Specifies the location of the temporary directory used by genkernel while compiling the kernel.


 * Includes support for the Unification File System in the initrd image.
 * Includes support for the Unification File System in the initrd image.


 * Detects whether or not the directory needs to be mounted on a separate partition. It will check  script for instructions on how to mount the boot partition on a file system (if needed).
 * Detects whether or not the directory needs to be mounted on a separate partition. It will check  script for instructions on how to mount the boot partition on a file system (if needed).


 * Creates an early cpio filled with microcode for Intel/AMD processors for Xen and Linux early microcode support
 * Creates an early cpio filled with microcode for Intel/AMD processors for Xen and Linux early microcode support

Options acting on the choice of the tools used for building
The following options are supported by genkernel, and are passed to the relevant applications while the kernel is being assembled. These options affect the compiling tools used for the kernel compilation process, albeit at a much lower level.


 * Specifies the compiler employed during the kernel compilation process.
 * Specifies the compiler employed during the kernel compilation process.


 * Specifies the linker employed during the kernel compilation process.
 * Specifies the linker employed during the kernel compilation process.


 * Specifies the assembler employed during the kernel compilation process.
 * Specifies the assembler employed during the kernel compilation process.


 * Specifies an alternative to the GNU make utility employed during the kernel compilation process.
 * Specifies an alternative to the GNU make utility employed during the kernel compilation process.


 * Specifies the compiler employed during the compilation of support utilities.
 * Specifies the compiler employed during the compilation of support utilities.


 * Specifies the linker employed during the compilation of support utilities.
 * Specifies the linker employed during the compilation of support utilities.


 * Specifies the assembler employed during the compilation of support utilities.
 * Specifies the assembler employed during the compilation of support utilities.


 * Specifies an alternative to the GNU make utility employed during the compilation of support utilities.
 * Specifies an alternative to the GNU make utility employed during the compilation of support utilities.


 * Specifies the number of concurrent threads that the make utility can implement while the kernel (and utilities) are being compiled. The variable  is a number to be freely chosen, although the most common values are obtained by adding one (1) to the number of cores used by the system, or just use the number of cores on the system. So, for a system with one core, most common option values are   or  ; a system with two cores most likely uses the   or   options, and so on. (A system with one processor that supports Hyper-Threading™ (HT) Technology can be assumed to have 2 cores, provided Symmetric Multi-Processing (SMP) support is enabled in the kernel.)
 * Specifies the number of concurrent threads that the make utility can implement while the kernel (and utilities) are being compiled. The variable  is a number to be freely chosen, although the most common values are obtained by adding one (1) to the number of cores used by the system, or just use the number of cores on the system. So, for a system with one core, most common option values are   or  ; a system with two cores most likely uses the   or   options, and so on. (A system with one processor that supports Hyper-Threading™ (HT) Technology can be assumed to have 2 cores, provided Symmetric Multi-Processing (SMP) support is enabled in the kernel.)

Options acting on the compilation process
The following options usually take effect during the actual compilation:


 * Specifies an alternative kernel source location, rather than the default location.
 * Specifies an alternative kernel source location, rather than the default location.


 * Specifies what alternative kernel configuration will be used, rather than the default file.
 * Specifies what alternative kernel configuration will be used, rather than the default file.


 * Specifies a prefix to the directory where kernel modules will be installed (default path is the directory.)
 * Specifies a prefix to the directory where kernel modules will be installed (default path is the directory.)


 * Activates (or deactivates) the command before compiling the kernel. The  command removes all object files and dependencies from the kernel's source tree.
 * Activates (or deactivates) the command before compiling the kernel. The  command removes all object files and dependencies from the kernel's source tree.


 * Activates (or deactivates) the command before kernel compilation. Like the  command listed above,  removes all object files and dependencies from the kernel's source tree. However, any previous configuration files (in  or ) will also be purged from the kernel's source tree. If it is undesirable that the kernel's  file keeps disappearing, be sure to disable this option!
 * Activates (or deactivates) the command before kernel compilation. Like the  command listed above,  removes all object files and dependencies from the kernel's source tree. However, any previous configuration files (in  or ) will also be purged from the kernel's source tree. If it is undesirable that the kernel's  file keeps disappearing, be sure to disable this option!


 * Issues the command, which attempts to collect configuration information for the system's architecture from a generic script in . This is a non-interactive process; no user input is entertained. Also, if   is used in conjunction with , the latter option is negated, resulting in the activation of the   option.
 * Issues the command, which attempts to collect configuration information for the system's architecture from a generic script in . This is a non-interactive process; no user input is entertained. Also, if   is used in conjunction with , the latter option is negated, resulting in the activation of the   option.


 * Calls the specified arguments (, in this case) after the kernel and the relevant modules have been built, but before building the initrd image. This may be useful when installing external modules in the initrd image by emerging the relevant item(s) with the callback feature, and then redefining a genkernel module group.
 * Calls the specified arguments (, in this case) after the kernel and the relevant modules have been built, but before building the initrd image. This may be useful when installing external modules in the initrd image by emerging the relevant item(s) with the callback feature, and then redefining a genkernel module group.


 * Activates (or deactivates) the command, which installs the new kernel image, configuration file, initrd image and system map onto the boot partition. Any compiled modules will be installed as well. By default genkernel will attempt mount  if it is on a separate partition before running the install command.
 * Activates (or deactivates) the command, which installs the new kernel image, configuration file, initrd image and system map onto the boot partition. Any compiled modules will be installed as well. By default genkernel will attempt mount  if it is on a separate partition before running the install command.


 * Refrains from copying any modules to the genkernel-created initrd image. This option is an exception to the rule about the  prefix; omission of this prefix creates an invalid genkernel option.
 * Refrains from copying any modules to the genkernel-created initrd image. This option is an exception to the rule about the  prefix; omission of this prefix creates an invalid genkernel option.


 * Copies all available modules to the genkernel-created initrd image.
 * Copies all available modules to the genkernel-created initrd image.


 * Creates the initrd image, prior to the kernel image (this hack currently applies only to PPC Pegasos systems).
 * Creates the initrd image, prior to the kernel image (this hack currently applies only to PPC Pegasos systems).

Debugging options
The use of debugging options during the kernel compilation process controls the amount of information reported, as well as the presentation of said data.


 * Controls the level of verbosity for information provided by genkernel. The variable  is an integer between 0 and 5. The level '0' represents minimal output, while '5' provides as much information as possible about genkernel's activities during the kernel compilation process.
 * Controls the level of verbosity for information provided by genkernel. The variable  is an integer between 0 and 5. The level '0' represents minimal output, while '5' provides as much information as possible about genkernel's activities during the kernel compilation process.


 * Ignores the value set by the  option (above) and sends all debugging data produced by genkernel to the specified output file. Outputs to  by default.
 * Ignores the value set by the  option (above) and sends all debugging data produced by genkernel to the specified output file. Outputs to  by default.


 * Activates (or deactivates) colored output of debugging information (reported by genkernel) using escape sequences.
 * Activates (or deactivates) colored output of debugging information (reported by genkernel) using escape sequences.


 * Activates (or deactivates) the full post-run cleanup for debug purposes.
 * Activates (or deactivates) the full post-run cleanup for debug purposes.

Actions
The action passed on the command line with the tells genkernel what action to perform. The following actions are supported:

Starting off
Although there are several ways to run genkernel, the least-intrusive approach recommended for most users is provided by. Here, a generic configuration which works well for most systems is used. As was mentioned earlier, this approach is not without drawbacks; most of the modules created are useless to the average user and may increase compile time. Below is an illustration of a more efficient approach, achieved by passing certain options to genkernel as root:

The above operation causes genkernel to create a kernel capable to open LUKS and LUKS2 encrypted volumes, compile and embed into initramfs, both kernel and initramfs will have to be manually installed. While preparing the kernel source tree, genkernel will refrain from cleaning out any preexisting object files present in the source tree. A menu-driven kernel configuration utility will be displayed that allows the user to select which modules will be built for the system.

Replacing  with the   option allows genkernel to automatically install the new kernel in the  directory, and will create symlinks if   is specified. Using the  option allows genkernel to mount the  partition automatically, if necessary.

Changing the kernel
The first thing that should be done is to allow the triggering of in the  file:

File management
While using genkernel, the user has to be aware of some aspects relating to kernel configuration and kernel image files management and the way the kernel sources are handled by the system.

Source files
After an, whenever new sources are available, a new kernel source directory is created under to host them. Normally, the active kernel sources directory is pointed to by the symlink.

The directory might look like this:

The symlink can be changed in different ways.


 * If the  USE is set the  symlink is automatically updated to point to the newly emerged sources.


 * If the  USE is not set, the user can change the destination of the symlink using the  followed by the  command.

genkernel will always (exclusively) use the sources pointed by the symlink.

Kernel configuration file
If a kernel compilation has already been run with the active kernel sources, there might be a file inside the directory that contains the kernel configuration that has been applied while creating the last bzImage of the kernel. This file is named, for example where   might be substituted with the system's architecture,   might be substituted with the package/version of the sources used, and   with the LOCALVERSION appended user value.

It is this file that is used as a starting configuration when running .

If it is the first time that genkernel is run with the new kernel sources, or if the previous result has not been saved, this file is substituted with a default configuration file that resides at where x86_64 is substituted with the actual architecture.

.

Saving the compiled configuration
If the  genkernel option is activated, either from the command line or inside, the compiled kernel configuration is saved (with the name given above) into the  directory. At the same time, the configuration is saved in the file in  directory but this file is not reused on the next  run.

Installing the kernel and initramfs into the directory
Specifying the  option when invoking genkernel, will ask genkernel to install the kernel image and the initramfs into the  directory. In order to run  a convenient manner, set the following in the  file:


 * The first parameter speaks for itself.


 * The second parameter tells genkernel to save the compiled kernel configuration into.


 * The last two options tell genkernel to automatically update the grub configuration. In practice, the following happens:
 * If a previous kernel image with the same name already exist, it is renamed by appending to its name. A symlink  is automatically created that points to it.
 * The new kernel takes the place of any kernel with the same name into . If it is the first time a kernel is compiled, a symlink kernel is automatically created that points to the new kernel.

After running, the directory might look like this:

extlinux
TODO

GRUB legacy
The symlinks presented above in the bootloader's configuration can be used so that, even if the new kernel is not bootable, the user can always boot on the old one.

To allow the kernel and intird provided by genkernel to run correctly, provide a minimum information in bootloader's configuration file:


 * Add  to the kernel parameters passed to the kernel image, where  points to the root partition (  is the number of the partition if a partition exists).
 * If splash is used, add a suitable mode line such as  to the parameters passed to the kernel and also add   or   depending on the verboseness required through the boot process.
 * Add the initrd information as required by the bootloader. Consult the Bootloader Configuration Chapter of the Gentoo Handbook for details on how to make the bootloader initrd-aware.

Here is how the file might look.

GRUB
TODO

systemd-boot
TODO

Preserving the working files
The genkernel application automatically saves new changes to the files. If previous changes are to be preserved, then the following actions need to be taken.


 * The first file to preserve is the kernel configuration file in If the source has not changed prior to the recompilation of the kernel, the previously used name for this file will be used. So copying the previous configuration file under a different name helps in preserving the information while keeping the file available as a starting point for a new configuration.


 * The second important thing is to preserve the already bootable kernel and initramfs images. The way to accomplish this depends on the context:
 * If the last kernel compiled is bootable, running will rename this kernel (and similarly initramfs) image to  and create a new . This mean that even if the new kernel is not bootable, users will always be able to boot the old one.
 * If the last kernel compiled is not bootable and sources haven't changed since the user compiled a bootable one, prior to running, first delete the new kernel image and remove the suffix from the last bootable one. Without this, if the newly compiled kernel is not bootable for the second time, the bootable  will be kicked out by the renaming of the non bootable , giving the user an unbootable system. Use the same reasoning for initramfs.

Using previous kernel configuration while changing the sources
The previous configuration can be used through the MENUCONFIG variable in as follows:

Checking that initramfs includes necessary modules/utilities before booting
Before booting the system, it might be wise checking that initramfs includes necessary utilities and modules. For example, to utilize remote unlock capabilities for a headless system using LUKS, ensure that kernel module for your network interface card, dropbear and cryptsetup is included.

Using lsinitrd
Since genkernel-4, created initramfs can be processed using from :

{{Cmd Image: /boot/initramfs-5.3.14-gentoo-r1-x86_64-wifitest2.img: 4,5M
 * lsinitrd /boot/initramfs-5.3.14-gentoo-r1-x86_64-wifitest2.img
 * collapse-output=true
 * output=

=
=========================================================== Version: Genkernel 4.0.1 (2019-12-16 00:48:10 UTC) Arguments: --boot-font=none --keymap --compress-initramfs --no-microcode-initramfs --ramdisk-modules --busybox --disklabel --no-btrfs --no-iscsi --no-multipath --no-dmraid --mdadm --lvm --no-unionfs --no-zfs --no-splash --no-strace --no-gpg --luks --no-firmware --firmware-dir=/lib/firmware --ssh --no-e2fsprogs --no-xfsprogs dracut modules:

=
=========================================================== drwxr-xr-x 16 root     root            0  Dec 16 01:49. drwxr-xr-x  2 root     root            0  Dec 16 01:49 bin lrwxrwxrwx  1 root     root            7  Dec 16 01:49 bin/ash -> busybox lrwxrwxrwx  1 root     root            7  Dec 16 01:49 bin/[ -> busybox -rwxr-xr-x  1 root     root      2351376  Dec 16 01:49 bin/busybox lrwxrwxrwx  1 root     root            7  Dec 16 01:49 bin/cat -> busybox lrwxrwxrwx  1 root     root            7  Dec 16 01:49 bin/cut -> busybox lrwxrwxrwx  1 root     root            7  Dec 16 01:49 bin/echo -> busybox lrwxrwxrwx  1 root     root            7  Dec 16 01:49 bin/mknod -> busybox lrwxrwxrwx  1 root     root            7  Dec 16 01:49 bin/mount -> busybox lrwxrwxrwx  1 root     root            7  Dec 16 01:49 bin/sh -> busybox lrwxrwxrwx  1 root     root            7  Dec 16 01:49 bin/uname -> busybox drwxr-xr-x  2 root     root            0  Dec 16 01:49 dev drwxr-xr-x  8 root     root            0  Dec 16 01:49 etc -rw-r--r--  1 root     root           24  Dec 16 01:49 etc/build_date -rw-r--r--  1 root     root           16  Dec 16 01:49 etc/build_id drwxr-xr-x  2 root     root            0  Dec 16 01:49 etc/dropbear -rw---  1 root     root          140  Dec 16 01:49 etc/dropbear/dropbear_ecdsa_host_key -rw---  1 root     root          806  Dec 16 01:49 etc/dropbear/dropbear_rsa_host_key prw-r--r--  1 root     root            0  Dec 16 01:49 etc/dropbear/fifo_root prw-r--r--  1 root     root            0  Dec 16 01:49 etc/dropbear/fifo_swap -rw-r--r--  1 root     root           97  Dec 16 01:49 etc/fstab -rw-r--r--  1 root     root           14  Dec 16 01:49 etc/group -rw-r--r--  1 root     root         3742  Dec 16 01:49 etc/initrd.defaults -rw-r--r--  1 root     root        69232  Dec 16 01:49 etc/initrd.scripts -rw-r--r--  1 root     root          441  Dec 16 01:49 etc/ld.so.cache -rw-r--r--  1 root     root           78  Dec 16 01:49 etc/ld.so.conf drwxr-xr-x  2 root     root            0  Dec 16 01:49 etc/ld.so.conf.d -rw-r--r--   1 root     root           81  Dec 16 01:49 etc/ld.so.conf.d/05gcc-x86_64-pc-linux-gnu.conf -rw-r--r--  1 root     root         2298  Dec 16 01:49 etc/localtime drwxr-xr-x  3 root     root            0  Dec 16 01:49 etc/lvm drwxr-xr-x  2 root     root            0  Dec 16 01:49 etc/lvm/cache -rw-r--r--  1 root     root        95231  Dec 16 01:49 etc/lvm/lvm.conf -rw-r--r--  1 root     root         2882  Dec 16 01:49 etc/mdadm.conf drwxr-xr-x  3 root     root            0  Dec 16 01:49 etc/mdev -rw-r--r--  1 root     root         1172  Dec 16 01:49 etc/mdev.conf drwxr-xr-x  2 root     root            0  Dec 16 01:49 etc/mdev/helpers -rwxr-xr-x  1 root     root          666  Dec 16 01:49 etc/mdev/helpers/nvme -rwxr-xr-x  1 root     root         1295  Dec 16 01:49 etc/mdev/helpers/storage-device drwxr-xr-x  2 root     root            0  Dec 16 01:49 etc/modprobe.d -rw-r--r--   1 root     root         1186  Dec 16 01:49 etc/modprobe.d/aliases.conf -rw-r--r--  1 root     root          122  Dec 16 01:49 etc/modprobe.d/i386.conf drwxr-xr-x  2 root     root            0  Dec 16 01:49 etc/modules -rw-r--r--  1 root     root           24  Dec 16 01:49 etc/modules/ataraid -rw-r--r--  1 root     root           21  Dec 16 01:49 etc/modules/block -rw-r--r--  1 root     root          180  Dec 16 01:49 etc/modules/crypto -rw-r--r--  1 root     root           26  Dec 16 01:49 etc/modules/dmraid -rw-r--r--  1 root     root           23  Dec 16 01:49 etc/modules/firewire -rw-r--r--  1 root     root          123  Dec 16 01:49 etc/modules/fs -rw-r--r--  1 root     root           86  Dec 16 01:49 etc/modules/hyperv -rw-r--r--  1 root     root           40  Dec 16 01:49 etc/modules/iscsi -rw-r--r--  1 root     root          437  Dec 16 01:49 etc/modules/lvm -rw-r--r--  1 root     root          194  Dec 16 01:49 etc/modules/mdadm -rw-r--r--  1 root     root           75  Dec 16 01:49 etc/modules/multipath -rw-r--r--  1 root     root          214  Dec 16 01:49 etc/modules/net -rw-r--r--  1 root     root           56  Dec 16 01:49 etc/modules/nvme -rw-r--r--  1 root     root          519  Dec 16 01:49 etc/modules/pata -rw-r--r--  1 root     root           83  Dec 16 01:49 etc/modules/pcmcia -rw-r--r--  1 root     root          158  Dec 16 01:49 etc/modules/sata -rw-r--r--  1 root     root          523  Dec 16 01:49 etc/modules/scsi -rw-r--r--  1 root     root          350  Dec 16 01:49 etc/modules/usb -rw-r--r--  1 root     root          133  Dec 16 01:49 etc/modules/virtio -rw-r--r--  1 root     root           15  Dec 16 01:49 etc/modules/waitscan -rw-r--r--  1 root     root           47  Dec 16 01:49 etc/passwd -rw-r-  1 root     root           22  Dec 16 01:49 etc/shadow -rw-r--r--  1 root     root           25  Dec 16 01:49 etc/shells -rwxr-xr-x  1 root     root        32331  Dec 16 01:49 init drwxr-xr-x  2 root     root            0  Dec 16 01:49 .initrd drwxr-xr-x  6 root     root            0  Dec 16 01:49 lib lrwxrwxrwx  1 root     root            3  Dec 16 01:49 lib32 -> lib lrwxrwxrwx  1 root     root            3  Dec 16 01:49 lib64 -> lib drwxr-xr-x  2 root     root            0  Dec 16 01:49 lib/console drwxr-xr-x  2 root     root            0  Dec 16 01:49 lib/dracut -rw-r--r--  1 root     root          312  Dec 16 01:49 lib/dracut/build-parameter.txt -rw-r--r--  1 root     root           42  Dec 16 01:49 lib/dracut/dracut-gk-version.info drwxr-xr-x  2 root     root            0  Dec 16 01:49 lib/keymaps lrwxrwxrwx  1 root     root            9  Dec 16 01:49 lib/keymaps/10.map -> croat.map lrwxrwxrwx  1 root     root            6  Dec 16 01:49 lib/keymaps/11.map -> cz.map lrwxrwxrwx  1 root     root            6  Dec 16 01:49 lib/keymaps/12.map -> de.map lrwxrwxrwx  1 root     root            6  Dec 16 01:49 lib/keymaps/13.map -> dk.map lrwxrwxrwx  1 root     root           10  Dec 16 01:49 lib/keymaps/14.map -> dvorak.map lrwxrwxrwx  1 root     root            6  Dec 16 01:49 lib/keymaps/15.map -> es.map lrwxrwxrwx  1 root     root            6  Dec 16 01:49 lib/keymaps/16.map -> et.map lrwxrwxrwx  1 root     root            6  Dec 16 01:49 lib/keymaps/17.map -> fi.map lrwxrwxrwx  1 root     root            6  Dec 16 01:49 lib/keymaps/18.map -> fr.map lrwxrwxrwx  1 root     root            6  Dec 16 01:49 lib/keymaps/19.map -> gr.map lrwxrwxrwx  1 root     root           10  Dec 16 01:49 lib/keymaps/1.map -> azerty.map lrwxrwxrwx  1 root     root            6  Dec 16 01:49 lib/keymaps/20.map -> hu.map lrwxrwxrwx  1 root     root            6  Dec 16 01:49 lib/keymaps/21.map -> il.map lrwxrwxrwx  1 root     root            6  Dec 16 01:49 lib/keymaps/22.map -> is.map lrwxrwxrwx  1 root     root            6  Dec 16 01:49 lib/keymaps/23.map -> it.map lrwxrwxrwx  1 root     root            6  Dec 16 01:49 lib/keymaps/24.map -> jp.map lrwxrwxrwx  1 root     root            6  Dec 16 01:49 lib/keymaps/25.map -> la.map lrwxrwxrwx  1 root     root            6  Dec 16 01:49 lib/keymaps/26.map -> lt.map lrwxrwxrwx  1 root     root            6  Dec 16 01:49 lib/keymaps/27.map -> mk.map lrwxrwxrwx  1 root     root            6  Dec 16 01:49 lib/keymaps/28.map -> nl.map lrwxrwxrwx  1 root     root            6  Dec 16 01:49 lib/keymaps/29.map -> no.map lrwxrwxrwx  1 root     root            6  Dec 16 01:49 lib/keymaps/2.map -> be.map lrwxrwxrwx  1 root     root            6  Dec 16 01:49 lib/keymaps/30.map -> pl.map lrwxrwxrwx  1 root     root            6  Dec 16 01:49 lib/keymaps/31.map -> pt.map lrwxrwxrwx  1 root     root            6  Dec 16 01:49 lib/keymaps/32.map -> ro.map lrwxrwxrwx  1 root     root            6  Dec 16 01:49 lib/keymaps/33.map -> ru.map lrwxrwxrwx  1 root     root            6  Dec 16 01:49 lib/keymaps/34.map -> se.map lrwxrwxrwx  1 root     root            6  Dec 16 01:49 lib/keymaps/35.map -> sf.map lrwxrwxrwx  1 root     root            6  Dec 16 01:49 lib/keymaps/36.map -> sg.map lrwxrwxrwx  1 root     root            8  Dec 16 01:49 lib/keymaps/37.map -> sk-y.map lrwxrwxrwx  1 root     root            8  Dec 16 01:49 lib/keymaps/38.map -> sk-z.map lrwxrwxrwx  1 root     root           11  Dec 16 01:49 lib/keymaps/39.map -> slovene.map lrwxrwxrwx  1 root     root            8  Dec 16 01:49 lib/keymaps/3.map -> bepo.map lrwxrwxrwx  1 root     root            7  Dec 16 01:49 lib/keymaps/40.map -> trf.map lrwxrwxrwx  1 root     root            6  Dec 16 01:49 lib/keymaps/41.map -> ua.map lrwxrwxrwx  1 root     root            6  Dec 16 01:49 lib/keymaps/42.map -> uk.map lrwxrwxrwx  1 root     root            6  Dec 16 01:49 lib/keymaps/43.map -> us.map lrwxrwxrwx  1 root     root           10  Dec 16 01:49 lib/keymaps/44.map -> wangbe.map lrwxrwxrwx  1 root     root            6  Dec 16 01:49 lib/keymaps/4.map -> bg.map lrwxrwxrwx  1 root     root            8  Dec 16 01:49 lib/keymaps/5.map -> br-a.map lrwxrwxrwx  1 root     root            8  Dec 16 01:49 lib/keymaps/6.map -> br-l.map lrwxrwxrwx  1 root     root            6  Dec 16 01:49 lib/keymaps/7.map -> by.map lrwxrwxrwx  1 root     root            6  Dec 16 01:49 lib/keymaps/8.map -> cf.map lrwxrwxrwx  1 root     root           11  Dec 16 01:49 lib/keymaps/9.map -> colemak.map -rw-r--r--  1 root     root         2823  Dec 16 01:49 lib/keymaps/azerty.map -rw-r--r--  1 root     root         2823  Dec 16 01:49 lib/keymaps/be.map -rw-r--r--  1 root     root         2823  Dec 16 01:49 lib/keymaps/bepo.map -rw-r--r--  1 root     root         2823  Dec 16 01:49 lib/keymaps/bg.map -rw-r--r--  1 root     root         2823  Dec 16 01:49 lib/keymaps/br-a.map -rw-r--r--  1 root     root         2823  Dec 16 01:49 lib/keymaps/br-l.map -rw-r--r--  1 root     root         2823  Dec 16 01:49 lib/keymaps/by.map -rw-r--r--  1 root     root         2823  Dec 16 01:49 lib/keymaps/cf.map -rw-r--r--  1 root     root         2823  Dec 16 01:49 lib/keymaps/colemak.map -rw-r--r--  1 root     root         2823  Dec 16 01:49 lib/keymaps/croat.map -rw-r--r--  1 root     root         2823  Dec 16 01:49 lib/keymaps/cz.map -rw-r--r--  1 root     root         2823  Dec 16 01:49 lib/keymaps/de.map -rw-r--r--  1 root     root         2823  Dec 16 01:49 lib/keymaps/dk.map -rw-r--r--  1 root     root         2823  Dec 16 01:49 lib/keymaps/dvorak.map -rw-r--r--  1 root     root         2823  Dec 16 01:49 lib/keymaps/es.map -rw-r--r--  1 root     root         2823  Dec 16 01:49 lib/keymaps/et.map -rw-r--r--  1 root     root         2823  Dec 16 01:49 lib/keymaps/fi.map -rw-r--r--  1 root     root         2823  Dec 16 01:49 lib/keymaps/fr.map -rw-r--r--  1 root     root         2823  Dec 16 01:49 lib/keymaps/gr.map -rw-r--r--  1 root     root         2823  Dec 16 01:49 lib/keymaps/hu.map -rw-r--r--  1 root     root         2823  Dec 16 01:49 lib/keymaps/il.map -rw-r--r--  1 root     root         2823  Dec 16 01:49 lib/keymaps/is.map -rw-r--r--  1 root     root         2823  Dec 16 01:49 lib/keymaps/it.map -rw-r--r--  1 root     root         2823  Dec 16 01:49 lib/keymaps/jp.map -rw-r--r--  1 root     root          518  Dec 16 01:49 lib/keymaps/keymapList -rw-r--r--  1 root     root         2823  Dec 16 01:49 lib/keymaps/la.map -rw-r--r--  1 root     root         2823  Dec 16 01:49 lib/keymaps/lt.map -rw-r--r--  1 root     root         2823  Dec 16 01:49 lib/keymaps/mk.map -rw-r--r--  1 root     root         2823  Dec 16 01:49 lib/keymaps/nl.map -rw-r--r--  1 root     root         2823  Dec 16 01:49 lib/keymaps/no.map -rw-r--r--  1 root     root         2823  Dec 16 01:49 lib/keymaps/pl.map -rw-r--r--  1 root     root         2823  Dec 16 01:49 lib/keymaps/pt.map -rw-r--r--  1 root     root         2823  Dec 16 01:49 lib/keymaps/ro.map -rw-r--r--  1 root     root         2823  Dec 16 01:49 lib/keymaps/ru.map -rw-r--r--  1 root     root         2823  Dec 16 01:49 lib/keymaps/se.map -rw-r--r--  1 root     root         2823  Dec 16 01:49 lib/keymaps/sf.map -rw-r--r--  1 root     root         2823  Dec 16 01:49 lib/keymaps/sg.map -rw-r--r--  1 root     root         2823  Dec 16 01:49 lib/keymaps/sk-y.map -rw-r--r--  1 root     root         2823  Dec 16 01:49 lib/keymaps/sk-z.map -rw-r--r--  1 root     root         2823  Dec 16 01:49 lib/keymaps/slovene.map -rw-r--r--  1 root     root         2823  Dec 16 01:49 lib/keymaps/trf.map -rw-r--r--  1 root     root         2823  Dec 16 01:49 lib/keymaps/ua.map -rw-r--r--  1 root     root         2823  Dec 16 01:49 lib/keymaps/uk.map -rw-r--r--  1 root     root         2823  Dec 16 01:49 lib/keymaps/us.map -rw-r--r--  1 root     root         2823  Dec 16 01:49 lib/keymaps/wangbe.map -rwxr-xr-x  1 root     root       169376  Dec 16 01:49 lib/ld-linux-x86-64.so.2 -rwxr-xr-x  1 root     root      1913648  Dec 16 01:49 lib/libc.so.6 -rwxr-xr-x  1 root     root        26800  Dec 16 01:49 lib/libnss_dns.so lrwxrwxrwx   1 root     root           13  Dec 16 01:49 lib/libnss_dns.so.2 -> libnss_dns.so -rwxr-xr-x   1 root     root        51536  Dec 16 01:49 lib/libnss_files.so lrwxrwxrwx   1 root     root           15  Dec 16 01:49 lib/libnss_files.so.2 -> libnss_files.so -rwxr-xr-x   1 root     root        88736  Dec 16 01:49 lib/libresolv.so.2 drwxr-xr-x  3 root     root            0  Dec 16 01:49 lib/modules drwxr-xr-x  3 root     root            0  Dec 16 01:49 lib/modules/5.3.14-gentoo-r1-x86_64-wifitest2 drwxr-xr-x  5 root     root            0  Dec 16 01:49 lib/modules/5.3.14-gentoo-r1-x86_64-wifitest2/kernel drwxr-xr-x  2 root     root            0  Dec 16 01:49 lib/modules/5.3.14-gentoo-r1-x86_64-wifitest2/kernel/crypto -rw-r--r--  1 root     root         7152  Dec 16 01:49 lib/modules/5.3.14-gentoo-r1-x86_64-wifitest2/kernel/crypto/algif_rng.ko drwxr-xr-x   6 root     root            0  Dec 16 01:49 lib/modules/5.3.14-gentoo-r1-x86_64-wifitest2/kernel/drivers drwxr-xr-x  3 root     root            0  Dec 16 01:49 lib/modules/5.3.14-gentoo-r1-x86_64-wifitest2/kernel/drivers/hid drwxr-xr-x  2 root     root            0  Dec 16 01:49 lib/modules/5.3.14-gentoo-r1-x86_64-wifitest2/kernel/drivers/hid/usbhid -rw-r--r--  1 root     root        66448  Dec 16 01:49 lib/modules/5.3.14-gentoo-r1-x86_64-wifitest2/kernel/drivers/hid/usbhid/usbhid.ko drwxr-xr-x   2 root     root            0  Dec 16 01:49 lib/modules/5.3.14-gentoo-r1-x86_64-wifitest2/kernel/drivers/md -rw-r--r--  1 root     root        19024  Dec 16 01:49 lib/modules/5.3.14-gentoo-r1-x86_64-wifitest2/kernel/drivers/md/dm-log.ko -rw-r--r--   1 root     root        27256  Dec 16 01:49 lib/modules/5.3.14-gentoo-r1-x86_64-wifitest2/kernel/drivers/md/dm-mirror.ko -rw-r--r--   1 root     root        49200  Dec 16 01:49 lib/modules/5.3.14-gentoo-r1-x86_64-wifitest2/kernel/drivers/md/dm-raid.ko -rw-r--r--   1 root     root        16536  Dec 16 01:49 lib/modules/5.3.14-gentoo-r1-x86_64-wifitest2/kernel/drivers/md/dm-region-hash.ko drwxr-xr-x   3 root     root            0  Dec 16 01:49 lib/modules/5.3.14-gentoo-r1-x86_64-wifitest2/kernel/drivers/net drwxr-xr-x  2 root     root            0  Dec 16 01:49 lib/modules/5.3.14-gentoo-r1-x86_64-wifitest2/kernel/drivers/net/intel drwxr-xr-x  2 root     root            0  Dec 16 01:49 lib/modules/5.3.14-gentoo-r1-x86_64-wifitest2/kernel/drivers/net/intel/e1000 -rw-r--r--  1 root     root        70480  Dec 16 01:49 lib/modules/5.3.14-gentoo-r1-x86_64-wifitest2/kernel/drivers/net/intel/e1000/e1000.ko drwxr-xr-x   6 root     root            0  Dec 16 01:49 lib/modules/5.3.14-gentoo-r1-x86_64-wifitest2/kernel/drivers/usb drwxr-xr-x  2 root     root            0  Dec 16 01:49 lib/modules/5.3.14-gentoo-r1-x86_64-wifitest2/kernel/drivers/usb/common -rw-r--r--  1 root     root         6584  Dec 16 01:49 lib/modules/5.3.14-gentoo-r1-x86_64-wifitest2/kernel/drivers/usb/common/usb-common.ko drwxr-xr-x   2 root     root            0  Dec 16 01:49 lib/modules/5.3.14-gentoo-r1-x86_64-wifitest2/kernel/drivers/usb/core -rw-r--r--  1 root     root       308944  Dec 16 01:49 lib/modules/5.3.14-gentoo-r1-x86_64-wifitest2/kernel/drivers/usb/core/usbcore.ko drwxr-xr-x   2 root     root            0  Dec 16 01:49 lib/modules/5.3.14-gentoo-r1-x86_64-wifitest2/kernel/drivers/usb/host -rw-r--r--  1 root     root        60416  Dec 16 01:49 lib/modules/5.3.14-gentoo-r1-x86_64-wifitest2/kernel/drivers/usb/host/ehci-hcd.ko -rw-r--r--   1 root     root        10616  Dec 16 01:49 lib/modules/5.3.14-gentoo-r1-x86_64-wifitest2/kernel/drivers/usb/host/ehci-pci.ko -rw-r--r--   1 root     root        46072  Dec 16 01:49 lib/modules/5.3.14-gentoo-r1-x86_64-wifitest2/kernel/drivers/usb/host/ohci-hcd.ko -rw-r--r--   1 root     root        35896  Dec 16 01:49 lib/modules/5.3.14-gentoo-r1-x86_64-wifitest2/kernel/drivers/usb/host/uhci-hcd.ko drwxr-xr-x   2 root     root            0  Dec 16 01:49 lib/modules/5.3.14-gentoo-r1-x86_64-wifitest2/kernel/drivers/usb/storage -rw-r--r--  1 root     root       126512  Dec 16 01:49 lib/modules/5.3.14-gentoo-r1-x86_64-wifitest2/kernel/drivers/usb/storage/usb-storage.ko drwxr-xr-x   3 root     root            0  Dec 16 01:49 lib/modules/5.3.14-gentoo-r1-x86_64-wifitest2/kernel/fs drwxr-xr-x  2 root     root            0  Dec 16 01:49 lib/modules/5.3.14-gentoo-r1-x86_64-wifitest2/kernel/fs/fat -rw-r--r--  1 root     root        95664  Dec 16 01:49 lib/modules/5.3.14-gentoo-r1-x86_64-wifitest2/kernel/fs/fat/fat.ko -rw-r--r--   1 root     root        16104  Dec 16 01:49 lib/modules/5.3.14-gentoo-r1-x86_64-wifitest2/kernel/fs/fat/msdos.ko -rw-r--r--   1 root     root        32434  Dec 16 01:49 lib/modules/5.3.14-gentoo-r1-x86_64-wifitest2/modules.alias -rw-r--r--  1 root     root        42356  Dec 16 01:49 lib/modules/5.3.14-gentoo-r1-x86_64-wifitest2/modules.alias.bin -rw-r--r--  1 root     root         8132  Dec 16 01:49 lib/modules/5.3.14-gentoo-r1-x86_64-wifitest2/modules.builtin -rw-r--r--  1 root     root        11529  Dec 16 01:49 lib/modules/5.3.14-gentoo-r1-x86_64-wifitest2/modules.builtin.bin -rw-r--r--  1 root     root        15196  Dec 16 01:49 lib/modules/5.3.14-gentoo-r1-x86_64-wifitest2/modules.dep -rw-r--r--  1 root     root        23748  Dec 16 01:49 lib/modules/5.3.14-gentoo-r1-x86_64-wifitest2/modules.dep.bin -rw-r--r--  1 root     root            0  Dec 16 01:49 lib/modules/5.3.14-gentoo-r1-x86_64-wifitest2/modules.devname -rw-r--r--  1 root     root         8320  Dec 16 01:49 lib/modules/5.3.14-gentoo-r1-x86_64-wifitest2/modules.order -rw-r--r--  1 root     root          117  Dec 16 01:49 lib/modules/5.3.14-gentoo-r1-x86_64-wifitest2/modules.softdep -rw-r--r--  1 root     root        24707  Dec 16 01:49 lib/modules/5.3.14-gentoo-r1-x86_64-wifitest2/modules.symbols -rw-r--r--  1 root     root        29469  Dec 16 01:49 lib/modules/5.3.14-gentoo-r1-x86_64-wifitest2/modules.symbols.bin lrwxrwxrwx  1 root     root            4  Dec 16 01:49 linuxrc -> init drwxr-xr-x  2 root     root            0  Dec 16 01:49 mnt drwxr-xr-x  2 root     root            0  Dec 16 01:49 proc drwxr-xr-x  3 root     root            0  Dec 16 01:49 root drwx--  2 root     root            0  Dec 16 01:49 root/.ssh -rw---  1 root     root          742  Dec 16 01:49 root/.ssh/authorized_keys drwxr-xr-x  2 root     root            0  Dec 16 01:49 run -rw-r--r--  1 root     root            0  Dec 16 01:49 run/utmp drwxr-xr-x  2 root     root            0  Dec 16 01:49 sbin -rwxr-xr-x  1 root     root      1105720  Dec 16 01:49 sbin/blkid -rwxr-xr-x  1 root     root      2813384  Dec 16 01:49 sbin/cryptsetup lrwxrwxrwx  1 root     root           19  Dec 16 01:49 sbin/dmsetup -> ../usr/sbin/dmsetup lrwxrwxrwx  1 root     root           19  Dec 16 01:49 sbin/dmstats -> ../usr/sbin/dmstats lrwxrwxrwx  1 root     root            7  Dec 16 01:49 sbin/init -> ../init lrwxrwxrwx  1 root     root           15  Dec 16 01:49 sbin/lvm -> ../usr/sbin/lvm -rwxr-xr-x  1 root     root      1510360  Dec 16 01:49 sbin/mdadm -rwxr-xr-x  1 root     root      1267904  Dec 16 01:49 sbin/mdmon drwxr-xr-x  2 root     root            0  Dec 16 01:49 sys drwxrwxrwt  2 root     root            0  Dec 16 01:49 tmp drwxr-xr-x  6 root     root            0  Dec 16 01:49 usr drwxr-xr-x  2 root     root            0  Dec 16 01:49 usr/bin lrwxrwxrwx  1 root     root           13  Dec 16 01:49 usr/bin/dropbearconvert -> dropbearmulti lrwxrwxrwx  1 root     root           13  Dec 16 01:49 usr/bin/dropbearkey -> dropbearmulti -rwxr-xr-x  1 root     root      1365144  Dec 16 01:49 usr/bin/dropbearmulti -rwxr-xr-x  1 root     root         2881  Dec 16 01:49 usr/bin/login-remote.sh lrwxrwxrwx   1 root     root           13  Dec 16 01:49 usr/bin/scp -> dropbearmulti drwxr-xr-x  2 root     root            0  Dec 16 01:49 usr/lib lrwxrwxrwx  1 root     root            3  Dec 16 01:49 usr/lib32 -> lib lrwxrwxrwx  1 root     root            3  Dec 16 01:49 usr/lib64 -> lib drwxr-xr-x  2 root     root            0  Dec 16 01:49 usr/sbin lrwxrwxrwx  1 root     root           11  Dec 16 01:49 usr/sbin/cache_check -> pdata_tools lrwxrwxrwx  1 root     root           11  Dec 16 01:49 usr/sbin/cache_dump -> pdata_tools lrwxrwxrwx  1 root     root           11  Dec 16 01:49 usr/sbin/cache_metadata_size -> pdata_tools lrwxrwxrwx  1 root     root           11  Dec 16 01:49 usr/sbin/cache_repair -> pdata_tools lrwxrwxrwx  1 root     root           11  Dec 16 01:49 usr/sbin/cache_restore -> pdata_tools lrwxrwxrwx  1 root     root           11  Dec 16 01:49 usr/sbin/cache_writeback -> pdata_tools -rwxr-xr-x  1 root     root      1262952  Dec 16 01:49 usr/sbin/dmsetup lrwxrwxrwx  1 root     root            7  Dec 16 01:49 usr/sbin/dmstats -> dmsetup lrwxrwxrwx  1 root     root           20  Dec 16 01:49 usr/sbin/dropbear -> ../bin/dropbearmulti lrwxrwxrwx  1 root     root           11  Dec 16 01:49 usr/sbin/era_check -> pdata_tools lrwxrwxrwx  1 root     root           11  Dec 16 01:49 usr/sbin/era_dump -> pdata_tools lrwxrwxrwx  1 root     root           11  Dec 16 01:49 usr/sbin/era_invalidate -> pdata_tools lrwxrwxrwx  1 root     root           11  Dec 16 01:49 usr/sbin/era_restore -> pdata_tools -rwxr-xr-x  1 root     root      2905416  Dec 16 01:49 usr/sbin/lvm -rwxr-xr-x  1 root     root      3061192  Dec 16 01:49 usr/sbin/pdata_tools -rwxr-xr-x  1 root     root          609  Dec 16 01:49 usr/sbin/resume-boot lrwxrwxrwx  1 root     root           11  Dec 16 01:49 usr/sbin/thin_check -> pdata_tools lrwxrwxrwx  1 root     root           11  Dec 16 01:49 usr/sbin/thin_delta -> pdata_tools lrwxrwxrwx  1 root     root           11  Dec 16 01:49 usr/sbin/thin_dump -> pdata_tools lrwxrwxrwx  1 root     root           11  Dec 16 01:49 usr/sbin/thin_ls -> pdata_tools lrwxrwxrwx  1 root     root           11  Dec 16 01:49 usr/sbin/thin_metadata_size -> pdata_tools lrwxrwxrwx  1 root     root           11  Dec 16 01:49 usr/sbin/thin_repair -> pdata_tools lrwxrwxrwx  1 root     root           11  Dec 16 01:49 usr/sbin/thin_restore -> pdata_tools lrwxrwxrwx  1 root     root           11  Dec 16 01:49 usr/sbin/thin_rmap -> pdata_tools lrwxrwxrwx  1 root     root           11  Dec 16 01:49 usr/sbin/thin_trim -> pdata_tools -rwxr-xr-x  1 root     root         3076  Dec 16 01:49 usr/sbin/unlock-luks drwxr-xr-x  3 root     root            0  Dec 16 01:49 usr/share drwxr-xr-x  2 root     root            0  Dec 16 01:49 usr/share/udhcpc -rwxr-xr-x  1 root     root         1098  Dec 16 01:49 usr/share/udhcpc/default.script drwxr-xr-x  3 root     root            0  Dec 16 01:49 var drwxr-xr-x  2 root     root            0  Dec 16 01:49 var/log -rw-r--r--  1 root     root            0  Dec 16 01:49 var/log/lastlog -rw-r--r--  1 root     root            0  Dec 16 01:49 var/log/wtmp lrwxrwxrwx  1 root     root            6  Dec 16 01:49 var/run -> ../run

=
=========================================================== }}

In the output above you see that for an Intel NIC, dropbear  and cryptsetup  is embedded.

Manual extraction
To extract a generated initramfs to inspect its content:

From an installation CD
The utility can build kernel and initrd images that provide support for network booting, or netbooting. With any luck, users should be able to netboot any recent computer into the environment provided by the Installation CD.

The magic lies in genkernel's linuxrc script: it will try to netmount the Installation CD using NFS. From there, the init scripts of the Installation CD can take over, as if the CD was present locally.

Building the kernel and initramfs with netboot support
To enable support for netbooting, include the following options while configuring the kernel:

First, the kernel image must include the drivers for the system's Network Interface Cards (NIC). Normally, drivers for such devices will be compiled as modules. However, it is essential (for netbooting) that such drivers are compiled directly into the kernel image and not as modules.

Secondly, it is suggested that IP: kernel level autoconfiguration is enabled as well as IP: DHCP support options. This avoids an unnecessary layer of complexity since the IP address and the NFS path to the Installation CD can be configured on a DHCP server. Of course, this means the kernel command line will remain constant for any machine — which is very important for etherbooting.

These options tell the kernel to send a DHCP request at bootup.

Additionally, enable SquashFS because most modern Gentoo Installation CDs require it. Support for SquashFS is not included with the generic kernel source tree. To enable SquashFS, apply the necessary patches to the generic kernel source or install gentoo-sources.

Once the compilation process is completed, create a compressed tarball (tar.gz) that contains the kernel's modules. This step is only necessary if the kernel version does not match the kernel image version on the Installation CD.

To create an archive containing all the modules:

Depending on the network boot mechanism, one of the following steps need to be followed:

To create an etherboot image:

To create an OpenBoot/SPARC64 TFTP image:

The file is the boot image.

Finally, copy this kernel to the TFTP server. The details are architecture-dependent and are beyond the scope of this guide. Please refer to the documentation for the specific platform of interest.

NFS setup
To setup a NFS share that contains the Installation CD, use the loop device to mount the ISO image and then copy the contents of the CD into the NFS share. As a nice extra, genkernel's initrd scripts will extract all tar.gz files located in the directory. All that needs to be done here is copy the archive to the  directory.

The following assumes that is an exported NFS share:

Now copy the file into :

DHCP setup
The netboot images will ask the DHCP server on the network for an IP as well as a  option. Both can be specified per host using a MAC address to identify machines:

Netbooting instructions
Netbooting itself is again very platform-specific. The important part is to specify the  and   parameters on the kernel command line, as this will bring up the network interface and tell the initrd scripts to mount the Installation CD via NFS. Here are some platform-specific tips.

For etherboot, insert the etherboot disk into the drive and reboot. The kernel command line was specified when the image was constructed. With Sparc64, press + at the boot prompt and then enter:

For PXE, setup pxelinux (part of syslinux), then create a along the lines of:

Introduction
If an initramfs is installed with genkernel, then take a look at the various boot options that can (or should) be defined in the bootloader configuration. The most common ones are added to this guide.

Loading LVM or software-RAID
If the system uses LVM or software-RAID, the initramfs has to be built using the  and   options. Do not forget to enable support during boot as well. This can be done using the dolvm and domdadm options.

Booting in single-user mode
If for some reason boot-up fails, rescuing the system by booting in the single-user mode is still possible. This will only load the really necessary services and then drop the user to a rescue (root) shell.

How do I rebuild external modules (such as xtables-addons, nvidia-drivers...) for new kernel?
By default, will call  when building a kernel to ensure that out-of-tree modules installed through the package manager are still present in new/rebuilt kernel. This feature can be toggled via  command-line argument or MODULEREBUILD in.

How do I run additional commands after kernel has been built?
provides a callback for that (before version 4, callback was used to rebuild external modules). See CMD_CALLBACK in for more details.

ERROR: compile_kernel: compile_generic failed to compile the "bzImage" target!
Check first. In most cases, a root cause will appear like:

In other words: The system has run out of disk space during compilation.

To guard against problems like this set  and   in  in which case  would fail early with a message like

Help! Something isn't working!
To report a problem, please always provide (sometimes it maybe necessary to compress that file before sharing or attaching to bugs) which will help developers a lot. Even if the command is run with  (default), the logfile will always contain complete output (no need to re-run with logging turned on) which will help developers to understand, reproduce and maybe fix a bug.