]> git.ipfire.org Git - thirdparty/dracut.git/log
thirdparty/dracut.git
4 years agoconfigure: Find FTS library with --as-needed
A. Wilcox [Sun, 5 Apr 2020 09:52:19 +0000 (04:52 -0500)] 
configure: Find FTS library with --as-needed

When LDFLAGS contains ``-Wl,--as-needed``, the FTS library will be
ignored if it is specified before the .c source.

Signed-off-by: A. Wilcox <AWilcox@Wilcox-Tech.com>
Fixes: 62f27ee6f145 ("configure: find cflags and libs for fts on musl")
4 years agoDon't print when a module is explicitly omitted (by default)
Colin Walters [Fri, 16 Oct 2020 21:04:45 +0000 (21:04 +0000)] 
Don't print when a module is explicitly omitted (by default)

dracut builds today are fairly verbose to start, but on top of
that many of the messages tend to liberally use the
exclamation point `!` which calls attention to them.

I see these a lot when looking at rpm-ostree build logs
and it'd be nicer if we were quiet when there wasn't
an actual problem.

In this specific case, if the builder is explicitly adding
`--omit=foo`, there's no reason for us to say:

`dracut: dracut module 'foo' will not be installed, because it's in the list to be omitted!`

We already print the command line to start, so the information
is there.

Demote this message to debug.

4 years ago95nfs: /var/lib/nfs/statd/sm is /var/lib/nfs/sm on SUSE
Daniel Molkentin [Sat, 14 Nov 2020 15:10:55 +0000 (16:10 +0100)] 
95nfs: /var/lib/nfs/statd/sm is /var/lib/nfs/sm on SUSE

Reference: boo#1177462

4 years agoRetrieve service, rpc and protcol entries via getent in hostonly mode
Daniel Molkentin [Fri, 27 Mar 2020 13:22:37 +0000 (14:22 +0100)] 
Retrieve service, rpc and protcol entries via getent in hostonly mode

Sometimes, systems have more elaborate backends in nsswitch.conf,
the complexity of which we do not want in the initrd. SUSE systems
with atomic for instance, where those files may also reside in /usr/etc.

With this change, the unavaiable nsswitch.conf backends will be silently
ignored, and we still end up with all the information we need.

Reference: boo#1165366

4 years agoRemove uses of bash (and bash specific syntax) in runtime scripts
Daniel Molkentin [Mon, 19 Oct 2020 14:23:51 +0000 (16:23 +0200)] 
Remove uses of bash (and bash specific syntax) in runtime scripts

dracutinstall picks up interpreters and includes bash despite
the users' wishes or expectations, as modules should not require
bashisms at runtime.

Fixes #951

4 years ago90crypt: pull in remote-cryptsetup.target enablement
Jonathan Lebon [Thu, 12 Nov 2020 16:27:39 +0000 (11:27 -0500)] 
90crypt: pull in remote-cryptsetup.target enablement

This should've been part of #964. As mentioned there, the
`initrd-cryptsetup.target` approach was reverted in the end, and we went
back to relying in `remote-cryptsetup.target`:

https://github.com/systemd/systemd/pull/17467

So we do need to ship the enablement symlink for it.

4 years ago90multipath: install kpartx's 11-dm-parts.rules
David Tardon [Fri, 13 Nov 2020 09:45:59 +0000 (10:45 +0100)] 
90multipath: install kpartx's 11-dm-parts.rules

This makes /dev/disk/by-uuid links point to the right device.

4 years agoRevert "90crypt: ship initrd-cryptsetup.target"
Jonathan Lebon [Wed, 28 Oct 2020 13:13:34 +0000 (09:13 -0400)] 
Revert "90crypt: ship initrd-cryptsetup.target"

This reverts commit 8f56daa8c3c75b167823286553f223e5b46cd6ab.

The addition of `initrd-cryptsetup.target` was reverted in systemd:
https://github.com/systemd/systemd/pull/17467

4 years ago90qemu-net: install less module for strict hostonly mode
Kairui Song [Tue, 20 Oct 2020 09:52:03 +0000 (17:52 +0800)] 
90qemu-net: install less module for strict hostonly mode

4 years ago90qemu-net: in hostonly mode, only install if network is needed
Kairui Song [Tue, 20 Oct 2020 08:47:41 +0000 (16:47 +0800)] 
90qemu-net: in hostonly mode, only install if network is needed

Signed-off-by: Kairui Song <kasong@redhat.com>
4 years ago95nfs: Install less module if hostonly mode is strict
Kairui Song [Mon, 19 Oct 2020 14:11:23 +0000 (22:11 +0800)] 
95nfs: Install less module if hostonly mode is strict

For strict hostonly mode, only install currently loaded modules instead
of a bunch of driver that may not be needed.

Signed-off-by: Kairui Song <kasong@redhat.com>
4 years ago90kernel-modules: Install less modules for hostonly mode
Kairui Song [Tue, 20 Oct 2020 09:30:03 +0000 (17:30 +0800)] 
90kernel-modules: Install less modules for hostonly mode

Rearrange some module installation mode, install less modules for
hostonly mode.

Signed-off-by: Kairui Song <kasong@redhat.com>
4 years ago90kernel-modules: install block drivers more strictly
Kairui Song [Tue, 20 Oct 2020 08:44:40 +0000 (16:44 +0800)] 
90kernel-modules: install block drivers more strictly

For strict hostonly mode, only install block drivers needed for hostonly
devices.

Signed-off-by: Kairui Song <kasong@redhat.com>
4 years ago04watchdog-modules: Simplify install_kernel using new added helper
Kairui Song [Mon, 12 Oct 2020 07:28:40 +0000 (15:28 +0800)] 
04watchdog-modules: Simplify install_kernel using new added helper

The new added get_dev_modules helper can help simplify the driver
detection code by a lot.

Signed-off-by: Kairui Song <kasong@redhat.com>
4 years agodracut-init.sh: Add a helper for detect device kernel modules
Kairui Song [Mon, 12 Oct 2020 07:18:45 +0000 (15:18 +0800)] 
dracut-init.sh: Add a helper for detect device kernel modules

Use udevadm to detect the required kernel modules to load a given
device. udevadm will follow the device chain, help detect all required
parent device drivers as well.

Signed-off-by: Kairui Song <kasong@redhat.com>
4 years agodracut-functions.sh: Fix check_block_and_slaves_all
Kairui Song [Tue, 13 Oct 2020 08:17:11 +0000 (16:17 +0800)] 
dracut-functions.sh: Fix check_block_and_slaves_all

check_block_and_slaves_all $func $dev should return 0, if $func return 0
for any checked device. Currently if any device don't have any sub
device, 1 is returned instead.

So remove the sub device checking statement. Also remove the same
statement in check_block_and_slaves, the "[[ -f $_x/dev ]]" in the for
loop is enought to ensure sub device exists.

Signed-off-by: Kairui Song <kasong@redhat.com>
4 years ago90kernel-network-modules: Don't install iscsi related module
Kairui Song [Tue, 20 Oct 2020 09:33:08 +0000 (17:33 +0800)] 
90kernel-network-modules: Don't install iscsi related module

These modules are installed in 95iscsi, no need to repeat here.

4 years agoAdd a --hostonly-nics option
Kairui Song [Wed, 21 Oct 2020 08:18:07 +0000 (16:18 +0800)] 
Add a --hostonly-nics option

Currently when network is enabled, dracut will install all network
drivers that are currently loaded, but some time only one NIC is needed
for the initramfs.

So for strict hostonly mode, add a --hostonly-nics option, user can
provide a list of NICs to be enabled, and only needed drivers for
specifed NICs will be installed so save space.

Signed-off-by: Kairui Song <kasong@redhat.com>
4 years agoConfigure the runner for team interfaces
Rumbaut Thomas [Fri, 23 Oct 2020 10:38:04 +0000 (12:38 +0200)] 
Configure the runner for team interfaces

https://bugzilla.redhat.com/show_bug.cgi?id=1881463

5 years ago99squash: Check require module earlier, and properly
Kairui Song [Mon, 12 Oct 2020 07:23:30 +0000 (15:23 +0800)] 
99squash: Check require module earlier, and properly

Let 99squash fail earlier if required modules are not enabled or
missing, using the new added helper.

Signed-off-by: Kairui Song <kasong@redhat.com>
5 years agodracut-functions: add a helper to check if kernel module is available
Kairui Song [Tue, 20 Oct 2020 08:58:01 +0000 (16:58 +0800)] 
dracut-functions: add a helper to check if kernel module is available

It's like check_kernel_config, help to check if a kernel module is
enabled (cover built-in or compiled module case).

Signed-off-by: Kairui Song <kasong@redhat.com>
5 years ago90crypt: ship initrd-cryptsetup.target
Jonathan Lebon [Tue, 20 Oct 2020 20:41:00 +0000 (16:41 -0400)] 
90crypt: ship initrd-cryptsetup.target

This was added in https://github.com/systemd/systemd/pull/17149 and is
the designated cryptsetup target for all encrypted volumes that need to
be opened in the initrd.

So it effectively replaces `cryptsetup.target` and
`remote-cryptsetup.target` there. I've removed the latter since it was
added recently (by me) in #930, but kept `cryptsetup.target` since we've
been shipping it for a long time now.

5 years agoRevert "90crypt: pull in remote-cryptsetup.target enablement"
Jonathan Lebon [Tue, 20 Oct 2020 20:41:11 +0000 (16:41 -0400)] 
Revert "90crypt: pull in remote-cryptsetup.target enablement"

This reverts commit 7ea391b527eb19c572a750fe00f95d02a50beabf.

We've moved away from this in
https://github.com/systemd/systemd/pull/17149.

5 years agodmsquash-live/iso-scan: Provide an easy reference to iso-scan device.
Frederick Grose [Tue, 20 Oct 2020 00:39:37 +0000 (20:39 -0400)] 
dmsquash-live/iso-scan: Provide an easy reference to iso-scan device.

With commit 3c8c807, /run/initramfs/isoscan and /run/initramfs/live
mountpoints are unmounted upon rd.live.ram boots.  Save a link to
the iso-scan device in /run/initramfs/isoscandev to easily remount
the source, if desired.

5 years ago99memstrack: use /bin/bash
Daniel Molkentin [Mon, 12 Oct 2020 11:49:46 +0000 (13:49 +0200)] 
99memstrack: use /bin/bash

/usr/local/bin causes trouble for distros that do not use /usr/bin == /bin
/usr/bin/env likewise, plus the use of env is not needed here

5 years ago98dracut-systemd: don't wait for root device if remote cryptsetup active
Jonathan Lebon [Fri, 9 Oct 2020 23:44:35 +0000 (19:44 -0400)] 
98dracut-systemd: don't wait for root device if remote cryptsetup active

This is a plain and simple hack around dependency issues between dracut
and systemd.

When using Tang-pinned LUKS root devices, we want to rely on
`systemd-cryptsetup@.service` to unlock it. However, that service only
runs `After=remote-fs-pre.target`, while `dracut-initqueue.service` has
`Before=remote-fs-pre.target` (which makes sense because we don't want
to attempt networked root devices before networking is up).

However, the rootfs-generator here wants to make sure that the root
device exists *before* exiting the initqueue via an initqueue/finished
"devexists" hook. This will never work though because by design
`systemd-cryptsetup@.service`, which unlocks the root device, won't run
until after we exit.

So we have a dependency cycle:

    initqueue -> devexists hook -> root device ->
        systemd-cryptsetup@.service -> remote-fs-pre.target -> initqueue

There's no clean way to break this. The root issue is that there's no
way right now to split sequencing of systemd services across the
initqueue/online and initqueue/finished events because it's all bundled
in a single service. (The deeper root issue of course is that we have
two init systems. :) ).

Here we do a tactical fix: if there's a `systemd-cryptsetup@.service`
instance, let's assume it's for the root device and skip waiting for it
to show up if it depends on `remote-fs-pre.target`.

5 years agocryptroot-ask: unify /etc/crypttab and rd.luks.key
Đoàn Trần Công Danh [Sat, 3 Oct 2020 07:53:27 +0000 (14:53 +0700)] 
cryptroot-ask: unify /etc/crypttab and rd.luks.key

dracut feeds whatever it receives in password field of
crypttab(5) to `cryptsetup -d`, treating them as plain-text key file.

Meanwhile, dracut treats the key file from `rd.luks.key` differently,
by have some special rules to decrypt those key files that has extension of
`gpg` and `img`.

Let's begin to treat them the same.

This is a backward-incompatible change for those people
that uses plain-text key-file that has extension of `gpg` and `img`.
However, those setup is questionable to begin with.

5 years ago90kernel-modules: arm: add drivers/hwmon for arm/arm64
Nicolas Chauvet [Wed, 7 Oct 2020 13:39:23 +0000 (15:39 +0200)] 
90kernel-modules: arm: add drivers/hwmon for arm/arm64

In the case of the s805x the drivers/hwmon directory contains the
scpi_hwmon kernel module.
On a running system, lsmod would output the following dependencies:
 arm_scpi               24576  2 clk_scpi,scpi_hwmon

It means that if the clock driver is bundled in the initramfs it will
bring arm_scpi. But if scpi_hwmon is missing the scpi will be incomplete
and it can lead to crashes.

When the hwmon is bundled, no crash occurs

Signed-off-by: Nicolas Chauvet <kwizart@gmail.com>
5 years agorootfs-block: only write root argument for block device
Đoàn Trần Công Danh [Sat, 3 Oct 2020 07:23:26 +0000 (14:23 +0700)] 
rootfs-block: only write root argument for block device

Some filesystem (e.g. ZFS, and btrfs subvolumes) don't use block
devices. Should they be mounted as `/`, `find_root_block_device`
yields nothing, hence dracut will append this problematic argument
to kernel cmdline:

root=/dev/block

On a machine that employ root ZFS on LUKS, which was setup with
an OpenPGP-encrypted key file, this argument renders that machine
unbootable. Remove that `root=/dev/block` manually could boot the
machine.

Let check if that device is a block device before write down `root`
argument. This is consistent with the check for block device in
`find_block_device`.

Signed-off-by: Đoàn Trần Công Danh <congdanhqx@gmail.com>
5 years ago90crypt: pull in remote-cryptsetup.target enablement
Jonathan Lebon [Thu, 24 Sep 2020 01:15:52 +0000 (21:15 -0400)] 
90crypt: pull in remote-cryptsetup.target enablement

This is enabled upstream in
https://github.com/systemd/systemd/pull/17149.

5 years ago00systemd: add missing cryptsetup-related targets
Jonathan Lebon [Wed, 23 Sep 2020 20:18:18 +0000 (16:18 -0400)] 
00systemd: add missing cryptsetup-related targets

We want these in the initramfs. Things related to clevis and systemd's
`cryptsetup-generator` reference these targets.

5 years ago95nvmf: Implement 'fc,auto' commandline syntax
Hannes Reinecke [Mon, 28 Sep 2020 12:02:28 +0000 (14:02 +0200)] 
95nvmf: Implement 'fc,auto' commandline syntax

Add a 'fc,auto' commandline syntax for nvmf.discover to force
nvmf autodiscovery on FC-NVMe.

Signed-off-by: Hannes Reinecke <hare@suse.de>
5 years ago95nvmf: add nvmf-autoconnect script
Hannes Reinecke [Mon, 28 Sep 2020 11:39:07 +0000 (13:39 +0200)] 
95nvmf: add nvmf-autoconnect script

Add a script to run FC autoconnect.

Signed-off-by: Hannes Reinecke <hare@suse.de>
5 years ago95nvmf: Fixup FC connections
Hannes Reinecke [Mon, 28 Sep 2020 11:39:07 +0000 (13:39 +0200)] 
95nvmf: Fixup FC connections

D-Bus doesn't run in the initrd, so our usual trick of activating
custom systemd services from udev doesn't work.
So add a rule to create initqueue entries for each possible
connection.

Signed-off-by: Hannes Reinecke <hare@suse.de>
5 years ago95nvmf: add documentation
Hannes Reinecke [Mon, 28 Sep 2020 09:38:40 +0000 (11:38 +0200)] 
95nvmf: add documentation

Add documentation for 95nvmf module to dracut.cmdline

Signed-off-by: Hannes Reinecke <hare@suse.de>
5 years ago95nvmf: rework parameter handling
Hannes Reinecke [Mon, 28 Sep 2020 09:25:53 +0000 (11:25 +0200)] 
95nvmf: rework parameter handling

Always add the nvmf.discover parameters to /etc/nvme/discovery
when parsing the dracut commandline, and rely on NVMe autodiscovery
when no parameters are given.
And modify the syntax to use a comma ',' as a separator for nvmf.discover
as the semicolon ':' is already used for the FC-NVMe transport address format.

Signed-off-by: Hannes Reinecke <hare@suse.de>
5 years agodracut-install: fix edge-case regression with weak modules
Daniel Molkentin [Thu, 1 Oct 2020 15:12:26 +0000 (17:12 +0200)] 
dracut-install: fix edge-case regression with weak modules

This was introduced with 6dafdda4a6bdb8721133e4267553c5d86564f9e8, but
is actually caused by the fact that modules that have already been
installed cause dracut_install() to return without adding the module
to the hashmap. This can happen if an earlier-run dracut module chose
to install the same module. Now modprobe statements like:

softdep usb_storage post: uas
softdep uas pre: usb_storage

(which look weird, but are perfectly valid), cause
dracut_install() to enter an infinite recursion if and only if
at least one of the files has previously been installed by another
module.

Fix this by also adding already installed modules to the hashmap.

5 years agodracut-install: ignore bogus preload libs
David Tardon [Thu, 1 Oct 2020 12:08:38 +0000 (14:08 +0200)] 
dracut-install: ignore bogus preload libs

If there are any nonexistent libraries listed in /etc/ld.so.preload, ldd
prints error messages like:

ERROR: ld.so: object '/usr/lib64/libfoo.so.1' from /etc/ld.so.preload cannot be preloaded (cannot open shared object file): ignored.

This causes resolve_deps() to return error, which leads to symlinks
(like usr/bin/awk) not being copied into the initrd.

5 years agodracut.spec: Use make macros
Harald Hoyer [Fri, 2 Oct 2020 11:50:40 +0000 (13:50 +0200)] 
dracut.spec: Use make macros

https://fedoraproject.org/wiki/Changes/UseMakeBuildInstallMacro

5 years agodracut.spec: remove fedora pre 30 quirks
Harald Hoyer [Fri, 2 Oct 2020 11:40:00 +0000 (13:40 +0200)] 
dracut.spec: remove fedora pre 30 quirks

5 years ago50drm: Check drm_encoder_init along drm_crtc_init
Nicolas Chauvet [Sat, 26 Sep 2020 13:01:55 +0000 (15:01 +0200)] 
50drm: Check drm_encoder_init along drm_crtc_init

Some modules are involved in the display output without to rely on
drm_crtc_init.

This is the case for the meson_dw_hdmi. This module need to be included
into the initramfs in both hostonly and generic modes.

Signed-off-by: Nicolas Chauvet <kwizart@gmail.com>
5 years ago50drm: Include drm platform drivers in hostonly
Nicolas Chauvet [Sat, 26 Sep 2020 11:15:55 +0000 (13:15 +0200)] 
50drm: Include drm platform drivers in hostonly

On arm, many drm drivers are located in the plaform bus.

Adding the platform bus will allow drm drivers to be included in the
initramfs when using hostonly mode.

Signed-off-by: Nicolas Chauvet <kwizart@gmail.com>
5 years ago50drm: fix ambiguous redirects
Nicolas Chauvet [Sat, 26 Sep 2020 12:50:31 +0000 (14:50 +0200)] 
50drm: fix ambiguous redirects

If i contains a space, there is a need to protect the variable usage in some cases.

This will occurs when a next patch will enable platform bus with such case:
'/sys/bus/platform/devices/Fixed MDIO bus.0'

Signed-off-by: Nicolas Chauvet <kwizart@gmail.com>
5 years agoInclude devfreq drivers in initrd
Peter Robinson [Tue, 22 Sep 2020 11:01:17 +0000 (12:01 +0100)] 
Include devfreq drivers in initrd

Some SoCs now have drivers that user devfreq in early init and fail
if the drivers are missing so make sure we have them in the initrd.

Signed-off-by: Peter Robinson <pbrobinson@gmail.com>
5 years agodracut.spec: include the 04watchdog-modules module
Beniamino Galvani [Sun, 20 Sep 2020 07:44:08 +0000 (09:44 +0200)] 
dracut.spec: include the 04watchdog-modules module

Include the 04watchdog-modules module that was added in 39d90012a652
("04watchdog: split the watchdog module install").

5 years ago90crypt: make `rd.luks.key` usable with encrypted keydev.
Antz [Sat, 29 Aug 2020 12:54:19 +0000 (14:54 +0200)] 
90crypt: make `rd.luks.key` usable with encrypted keydev.

Introduce prefix `keysource:` for the values of `rd.luks.partuuid`,
`rd.luks.serial` and `rd.luks.uuid`.
If specified, ask for passphrase instead of waiting for keydevs to come
online.

5 years ago04watchdog: split the watchdog module install
Kairui Song [Wed, 9 Sep 2020 18:18:02 +0000 (02:18 +0800)] 
04watchdog: split the watchdog module install

In some cases, user only want to include the watchdog module, not the
wdctl or any other userspace helper. For example, systemd have a
RebootWatchdogSec option that use watchdog to prevent reboot hangs. And
it can help prevent machines hangs when reboot directly within the
initramfs stage. So split the module installation to a standlone module.

Also when watchdog-module get included, install driver for all loaded
watchdog instaed of only install driver for active watchdog. Both
watchdog and watchdog-module return 255 in check(), so it's enabled only
when manually included, the watchdog may get configured/activated later.

Signed-off-by: Kairui Song <kasong@redhat.com>
5 years agofix graphics startup failure with the rhgb paramter in CentOS8.2
GuoChuang [Mon, 24 Aug 2020 06:03:48 +0000 (14:03 +0800)] 
fix graphics startup failure with the rhgb paramter in CentOS8.2

5 years agodracut.cmdline.7.asc: fix typo
Beniamino Galvani [Mon, 13 Jul 2020 06:51:33 +0000 (08:51 +0200)] 
dracut.cmdline.7.asc: fix typo

5 years agoAdd --version to man page
Daniel Molkentin [Fri, 28 Aug 2020 15:12:27 +0000 (17:12 +0200)] 
Add --version to man page

5 years agodracut.sh: Add --version
Daniel Molkentin [Mon, 17 Aug 2020 13:46:17 +0000 (15:46 +0200)] 
dracut.sh: Add --version

5 years agoFix CoC URL
Jóhann B. Guðmundsson [Fri, 28 Aug 2020 17:57:45 +0000 (17:57 +0000)] 
Fix CoC URL

5 years agoFix Unicode and dracut install labeler
Jóhann B. Guðmundsson [Fri, 28 Aug 2020 17:36:35 +0000 (17:36 +0000)] 
Fix Unicode and dracut install labeler

5 years agoFix Unicode
Jóhann B. Guðmundsson [Fri, 28 Aug 2020 17:11:41 +0000 (17:11 +0000)] 
Fix Unicode

5 years agoAdding security policy
Jóhann B. Guðmundsson [Fri, 28 Aug 2020 16:21:08 +0000 (16:21 +0000)] 
Adding security policy

5 years agoAdding documentation template
Jóhann B. Guðmundsson [Fri, 28 Aug 2020 16:03:37 +0000 (16:03 +0000)] 
Adding documentation template

5 years agoAdding a feature request template
Jóhann B. Guðmundsson [Fri, 28 Aug 2020 16:02:40 +0000 (16:02 +0000)] 
Adding a feature request template

5 years agoAdding a bug report template
Jóhann B. Guðmundsson [Fri, 28 Aug 2020 16:02:20 +0000 (16:02 +0000)] 
Adding a bug report template

5 years agoDo not start inside container
Tomasz Paweł Gajc [Wed, 26 Aug 2020 09:19:24 +0000 (11:19 +0200)] 
Do not start inside container

Host should take care of good entropy pool
#791

5 years agoAdding a pull request template
Jóhann B. Guðmundsson [Fri, 28 Aug 2020 11:47:06 +0000 (11:47 +0000)] 
Adding a pull request template

5 years agoAdding code of conduct
Jóhann B. Guðmundsson [Fri, 28 Aug 2020 10:33:50 +0000 (10:33 +0000)] 
Adding code of conduct

5 years agodracut.sh: fix some indentation.
Érico Rolim [Sun, 23 Aug 2020 21:31:11 +0000 (18:31 -0300)] 
dracut.sh: fix some indentation.

Command level inside conditional and tab/space usage.

5 years agodracut.sh: fix errors pointed out by shellcheck.
Érico Rolim [Sun, 23 Aug 2020 21:15:32 +0000 (18:15 -0300)] 
dracut.sh: fix errors pointed out by shellcheck.

- use [ ] instead of calling test manually, as most of the script is
doing.

- use quotes in hostonly_cmdline blocks, specially when dealing with the
conf files, whose names are set by users/system administrators

- uefi_splash_image was being assigned set to `${dracutsysroot}...`, which
is a variable that doesn't exist.

- we don't want the conditional to run the output of fsfreeze as
commands. Instead, we just need to know if any of the fsfreeze commands
failed.

5 years agoDocument initqueue/online hook
Daniel Molkentin [Tue, 26 Nov 2019 11:29:47 +0000 (12:29 +0100)] 
Document initqueue/online hook

5 years ago01fips: turn info calls into fips_info calls
Daniel Molkentin [Mon, 6 Jul 2020 14:36:42 +0000 (16:36 +0200)] 
01fips: turn info calls into fips_info calls

systemd lets stdout go to journal only. Usually, this is desired
behavior to ensure that plymouth does not get disrupted.

However in the 01fips case, the system has to halt when the integrity
check fails to satisfy FIPS requirements. So the user will not be able
to inspect the journal.

As this is special to the fips module, we introduce a fips_info() which
works like info(), but deviates the output to stderr when running with
systemd.

Reference: bsc#1164076

5 years ago01fips: modprobe failures during manual module loading is not fatal
Daniel Molkentin [Mon, 6 Jul 2020 12:47:28 +0000 (14:47 +0200)] 
01fips: modprobe failures during manual module loading is not fatal

Users might see

"modprobe: FATAL: Module xyz not found in directory"

The output from modprobe is semantically wrong in this case and
confuses users. Keep the warning for debugging purposes, but reduce
the severeness.

It now reads "Module xyz not found in directory"

Reference: bsc#1169997

5 years ago95cifs: pass rootflags to mount
наб [Thu, 20 Aug 2020 15:36:30 +0000 (17:36 +0200)] 
95cifs: pass rootflags to mount

5 years ago95cifs: install new softdeps (sha512, gcm, ccm, aead2)
наб [Wed, 19 Aug 2020 19:24:17 +0000 (21:24 +0200)] 
95cifs: install new softdeps (sha512, gcm, ccm, aead2)

5 years agoRemove stratis module
mulhern [Wed, 19 Aug 2020 15:11:14 +0000 (11:11 -0400)] 
Remove stratis module

It is obsolete. An approach which does not start the daemon is being worked
on.

Signed-off-by: mulhern <amulhern@redhat.com>
5 years agodmsquash-live-root: Remove obsolete osmin.img processing.
Frederick Grose [Sun, 9 Aug 2020 04:23:54 +0000 (00:23 -0400)] 
dmsquash-live-root: Remove obsolete osmin.img processing.

osmin.img is no longer used by anaconda or generated by
livemedia-creator.  livecd-creator will soon drop it as well.
Removing this code will allow OverlayFS boots to proceed  when
osmin.img is present in the .iso image.

5 years ago95nvmf: fix typo in the example documentation
Daniel Molkentin [Tue, 11 Aug 2020 17:55:35 +0000 (19:55 +0200)] 
95nvmf: fix typo in the example documentation

5 years agoRemoving dracut entry not compat with new plugin
Jóhann B. Guðmundsson [Fri, 7 Aug 2020 19:16:46 +0000 (19:16 +0000)] 
Removing dracut entry not compat with new plugin

5 years agoNew label trigger file
Jóhann B. Guðmundsson [Fri, 7 Aug 2020 18:40:11 +0000 (18:40 +0000)] 
New label trigger file

5 years agoNew labels file
Jóhann B. Guðmundsson [Fri, 7 Aug 2020 18:39:46 +0000 (18:39 +0000)] 
New labels file

5 years ago.github: fix path to label workflow mapping file
Daniel Molkentin [Fri, 7 Aug 2020 16:54:43 +0000 (18:54 +0200)] 
.github: fix path to label workflow mapping file

5 years agoUpdate master-labels.yml
Jóhann B. Guðmundsson [Fri, 7 Aug 2020 16:17:45 +0000 (16:17 +0000)] 
Update master-labels.yml

Removing branches not sure if they work with the cron scheduler in workflow actions

5 years agoUpdate master-labels.yml
Jóhann B. Guðmundsson [Fri, 7 Aug 2020 15:57:07 +0000 (15:57 +0000)] 
Update master-labels.yml

Fixing bad intentation

5 years agoSwitching label triggers from pull requests to cron
Jóhann B. Guðmundsson [Fri, 7 Aug 2020 15:40:40 +0000 (15:40 +0000)] 
Switching label triggers from pull requests to cron

5 years agoAdding the labels trigger file for the RHEL-8 branch
Jóhann B. Guðmundsson [Thu, 6 Aug 2020 19:15:45 +0000 (19:15 +0000)] 
Adding the labels trigger file for the RHEL-8 branch

5 years agoAdding the labels trigger file for the RHEL-7 branch
Jóhann B. Guðmundsson [Thu, 6 Aug 2020 19:15:07 +0000 (19:15 +0000)] 
Adding the labels trigger file for the RHEL-7 branch

5 years agoAdding the labels trigger file for the RHEL-6 branch
Jóhann B. Guðmundsson [Thu, 6 Aug 2020 19:14:48 +0000 (19:14 +0000)] 
Adding the labels trigger file for the RHEL-6 branch

5 years agoAdding the labels trigger file for the Master branch
Jóhann B. Guðmundsson [Thu, 6 Aug 2020 19:13:33 +0000 (19:13 +0000)] 
Adding the labels trigger file for the Master branch

5 years agoAdding the labels file for the RHEL-8 branch
Jóhann B. Guðmundsson [Thu, 6 Aug 2020 19:11:58 +0000 (19:11 +0000)] 
Adding the labels file for the RHEL-8 branch

5 years agoAdding the labels file for the RHEL-7 branch
Jóhann B. Guðmundsson [Thu, 6 Aug 2020 19:10:51 +0000 (19:10 +0000)] 
Adding the labels file for the RHEL-7 branch

5 years agoAdding the labels file for the RHEL-6 branch
Jóhann B. Guðmundsson [Thu, 6 Aug 2020 19:10:26 +0000 (19:10 +0000)] 
Adding the labels file for the RHEL-6 branch

5 years agoAdding the labels file for master
Jóhann B. Guðmundsson [Thu, 6 Aug 2020 19:07:17 +0000 (19:07 +0000)] 
Adding the labels file for master

5 years agonet-lib.sh: support infiniband network mac addresses
Thomas Blume [Fri, 7 Aug 2020 06:39:26 +0000 (08:39 +0200)] 
net-lib.sh: support infiniband network mac addresses

Infiniband MAC addresses have 20 octets.

Reference: bsc#996146

5 years ago90lvm: do not add newline to cmdline
Daniel Molkentin [Wed, 5 Aug 2020 17:32:35 +0000 (19:32 +0200)] 
90lvm: do not add newline to cmdline

Fixes #862

5 years agoUEFI Mode: only write kernel cmdline to UEFI binary
mwberry [Sun, 31 May 2020 00:55:35 +0000 (17:55 -0700)] 
UEFI Mode: only write kernel cmdline to UEFI binary

The kernel command line was being written both into
/etc/cmdline.d/01-default.conf and the UEFI executable.
During boot, getcmdline would concatenate these two
resulting in all arguments being duplicated. Some
args, such as ip=, are sensitive to the number of
times they are specified.

5 years agoAllow $DRACUT_INSTALL to be not an absolute path
Mikhail Novosyolov [Fri, 27 Mar 2020 13:16:07 +0000 (16:16 +0300)] 
Allow $DRACUT_INSTALL to be not an absolute path

/usr/sbin/dracut-install is a symlink:
$ file /usr/sbin/dracut-install
/usr/sbin/dracut-install: symbolic link to ../lib/dracut/dracut-install

It resulted to "dracut-install not found" error:

+++ for p in $DRACUT_PATH
+++ [[ -L /sbin/dracut-install ]]
+++ [[ -x /sbin/dracut-install ]]
+++ for p in $DRACUT_PATH
+++ [[ -L /bin/dracut-install ]]
+++ [[ -x /bin/dracut-install ]]
+++ for p in $DRACUT_PATH
+++ [[ -L /usr/sbin/dracut-install ]]
+++ printf '%s\n' dracut-install
+++ return 0
++ DRACUT_INSTALL=dracut-install
++ [[ -n dracut-install ]]
++ [[ -n dracut-install ]]
++ DRINSTALLPARTS=0
++ for i in $DRACUT_INSTALL
++ DRINSTALLPARTS=1
++ [[ 1 = 1 ]]
++ [[ -x dracut-install ]]
++ dfatal 'dracut-install not found!'
++ set +x
dracut: dracut-install not found!

[ -x <not a path to file> ] is not correct and will always be false.
But actually it is available. Let's just allow it to be not an absolute path.
Maybe some other places can be improved to avoid DRACUT_INSTALL being not an absolute path.

Signed-off-by: Mikhail Novosyolov <m.novosyolov@rosalinux.ru>
5 years ago35network-legacy: simplify fallback dhcp setup
Thomas Blume [Wed, 22 Jul 2020 07:34:42 +0000 (09:34 +0200)] 
35network-legacy: simplify fallback dhcp setup

suppress redundant calls to network setup

combine code for "no ip option directed at our interface" and
"No ip lines default to dhcp"
correct evaluation of return code for creating did-setup files
fix application of "load_ipv6" call to ipv6 setup only

Reference: bsc#1173402

5 years agoChange the order of NFS servers during the boot
Denis Volkov [Tue, 4 Aug 2020 14:51:27 +0000 (19:51 +0500)] 
Change the order of NFS servers during the boot
NFS server provided by DHCP in next-server option has higher priority than DHCP-server itself

5 years agomatch simplified rd.zfcp format too
David Tardon [Tue, 4 Aug 2020 12:18:54 +0000 (14:18 +0200)] 
match simplified rd.zfcp format too

The simplified format was introduced by commit
c8aa1d949aecaf146b0a0e1ce269f69e6048dc5a .

5 years agomatch the whole string
David Tardon [Tue, 4 Aug 2020 12:16:19 +0000 (14:16 +0200)] 
match the whole string

5 years ago99squash: simplify the code
Kairui Song [Mon, 8 Jun 2020 16:41:24 +0000 (00:41 +0800)] 
99squash: simplify the code

The new dracutsysrootdir could be used to replace the shell function
required_in_root, so drop it and also simplify the code.

Signed-off-by: Kairui Song <kasong@redhat.com>
5 years ago99squash: improve pre-requirements check
Kairui Song [Mon, 8 Jun 2020 09:00:00 +0000 (17:00 +0800)] 
99squash: improve pre-requirements check

Check for systemd-initrd and squashfs-tools in check() to fail early if
it won't work.

Signed-off-by: Kairui Song <kasong@redhat.com>
5 years ago99squash: Don't hardcode the squash sub directories
Kairui Song [Mon, 8 Jun 2020 07:31:56 +0000 (15:31 +0800)] 
99squash: Don't hardcode the squash sub directories

Signed-off-by: Kairui Song <kasong@redhat.com>
5 years agodracut-initqueue: Print more useful info in case of timeout
Kairui Song [Fri, 2 Aug 2019 09:11:19 +0000 (17:11 +0800)] 
dracut-initqueue: Print more useful info in case of timeout

Currently when initqueue timeout, it span the console with
"dracut-initqueue timeout - starting timeout scripts", which isn't very
helpful as we still don't know what actually happened. Try to improve
this by print what is actually being waited.

Besides, only print "starting timeout scripts" when there are
actual timeout scripts to use.

Signed-off-by: Kairui Song <kasong@redhat.com>
5 years agomount-root.sh: fix writing fstab file with missing fsck flag
Norbert Lange [Mon, 6 Jul 2020 16:16:13 +0000 (18:16 +0200)] 
mount-root.sh: fix writing fstab file with missing fsck flag

if the kernel argument rootflags is set, then dracut will
not parse the rootfs fstab and rootfsck wil not be set.

if the filesystem can be fsck'ed then its unmounted,
and an entry to the local fstab is written, omitting the last
field.

mounting /sysroot using fstab will then fail.

This change makes sure that the filed is always written.

Signed-off-by: Norbert Lange <norbert.lange@andritz.com>
5 years ago99memstrack: Only start tracking service when rd.memdebug=4|5
Kairui Song [Wed, 10 Jun 2020 10:28:27 +0000 (18:28 +0800)] 
99memstrack: Only start tracking service when rd.memdebug=4|5

Currently systemd will always start the tracking service, it will
exit early if rd.memdebug<=3 so there is no issue here, but it
leave a message of: "Started Memstrack Anylazing Service.".
Better to avoid such message if it's not used.

Signed-off-by: Kairui Song <kasong@redhat.com>