Commit Graph

3199 Commits (ddcdee9147b9d49eace7293cf60b7a7e4da959f4)

Author SHA1 Message Date
foopub c409108b04 Fix bad ls parsing
This used to cause some echo write/invalid argument errors. Simplest fix is to use readlink with -f for absolute path and -n to remove trailing newline. 
See previous discussion here:
https://github.com/void-linux/void-packages/issues/13024
2021-02-08 23:12:15 +01:00
Nicolas Chauvet 07c671cc51 feat(kernel-modules): add driver memory
External Memory Controller (EMC) drivers can be built as a module.

On Tegra, this allows tegra_drm to load faster and without deferred
probes, instead of waiting for the rootfs for the tegra*_emc dependencies.

Tested on jetson-tk1 and ac100.

Signed-off-by: Nicolas Chauvet <kwizart@gmail.com>
2021-02-08 21:15:48 +00:00
Jóhann B. Guðmundsson c3446a7ce0 feat(systemd-repart): introducing systemd-repart module
This modules introduces systemd-repart which can be used
to generate partition(s), via a simple systemd-repart
drop-in(s), which can be useful in wide varity of usecase.

feat(systemd-repart): adding module to spec file

feat(systemd-repart): removing unessary requirement on type unit

fix: spelling error
2021-02-08 20:32:16 +00:00
Jóhann B. Guðmundsson 7135c81931 feat(dbus-daemon): introducing the dbus-daemon module
Introdusing dbus-daemon which is based on but superseeds
the previous 06dbus implementation with various enhancements and fixes.

fix: adding new modules to rpm spec file

fix: missed an echo
2021-02-08 20:18:25 +01:00
Jóhann B. Guðmundsson 38cd8125f6 feat(dbus-broker): introducing the dbus-broker module
Introducing the dbus-broker module.
2021-02-08 20:18:25 +01:00
Jóhann B. Guðmundsson 791f392ca6 feat(dbus): introducing a meta module for dbus
We require a meta module to handle multiple modules
2021-02-08 20:18:25 +01:00
Harald Hoyer 6032ade3cc fix(network-legacy): silent check for leaseinfo
Reroute negative checks for leaseinfo to /dev/null to suppress:
```
ls: cannot access '/tmp/leaseinfo.ens2*': No such file or directory
```
2021-02-08 17:18:02 +01:00
Kairui Song e918f337b6 95nfs: fix rpc.statd installation
commit 5840c466d tried to make it create the right directory according
to the directory layout on current host, but added "$initdir" prefix
to the if statement by accident, so the installation code have no
effect now. Just fix it.
2021-02-08 12:20:48 +01:00
Anjali Kulkarni 4026cd3b01 feat(network-legacy): send dhcp in parallel on all devices
We can drastically improve boot times on some machines, or BM or VM
shapes, if we send DHCP requests in parallel on all interfaces
Add ip=single-dhcp as a kernel boot parameter, to send DHCP requests in
parallel on all interfaces. Thus, DHCP on each interface is overlapped
thereby reducing boot times for multiple interface machines.
This can help reduce the boot time by 1 minute per interface.
In addition, we may also save another 40 secs delay per interface, if
the link on which we try to send DHCP is in DOWN state. This can be
reduced by giving the following kernel command line parameter while
booting - rd.net.timeout.carrier=<timeout>.
Added manpage for ip=single-dhcp with the caveat that it does not
apply to Network Manager or SUSE wicked.

Signed-off-by: Anjali Kulkarni <anjali.k.kulkarni@oracle.com>
2021-02-05 11:11:22 +01:00
Mariusz Tkaczyk 30e49d5175 fix(mdraid): remove offroot
offroot is deprecated and can be safety removed.

Signed-off-by: Mariusz Tkaczyk <mariusz.tkaczyk@linux.intel.com>
2021-02-05 10:59:50 +01:00
Mariusz Tkaczyk 29e269a522 fix(mdraid): add grow continue service
During raid assembly mdadm will call mdadm-grow-continue.service if
reshape is in progress.
If service doesn't exist then it is done via fork and systemd will kill
it unconditionally after processing all events.

Add proper service to allow systemd to manage reshape correctly.

Signed-off-by: Mariusz Tkaczyk <mariusz.tkaczyk@linux.intel.com>
2021-02-05 10:59:50 +01:00
Peter Levine c35cbd2e56 fix(watchdog): replace return with echo 2021-02-03 12:23:57 +00:00
Jóhann B. Guðmundsson 939b7e11d5 feat(systemd-coredump): introducing systemd-coredump module
This pull request introduces systemd-coredump as a seperated
module and adds the systemdutilconfdir global variable.
2021-02-02 18:01:06 +00:00
Jóhann B. Guðmundsson bf1a2262ea fix(1007): adding shared keyring mode to type unit
Fixes: https://github.com/dracutdevs/dracut/issues/1007
2021-01-26 18:05:18 +00:00
Jóhann B. Guðmundsson 24ea839079 feat(systemd-sysusers): introducing systemd-sysuser module 2021-01-26 00:00:28 +00:00
Daniel Molkentin f824f52675 fix(1001): use efivars fs over the deprecated sysfs entries
sysfs efi vars has been dropped for non-x86 systems since kernel 5.10.
2021-01-25 14:58:11 +00:00
Javier Martinez Canillas 3c8ca29650 fix(kernel-network-modules): also install modules from mdio subdirectory
A recent change in Linux kernel v5.10 split the MDIO drivers from the PHY
subdirectory into a new MDIO subdirectory [0]. This caused MDIO drivers
to not be included in the initramfs.

Also include the modules of this new subdirectory to prevent this issue.

[0]: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=a9770eac511

Suggested-by: Peter Robinson <pbrobinson@gmail.com>
Signed-off-by: Javier Martinez Canillas <javierm@redhat.com>
2021-01-22 15:58:58 +01:00
Alexey Shabalin 21ee81bfbd fix(06dbus): do not hardcode path to dbus utils 2021-01-21 16:53:30 +00:00
Alexey Shabalin 7b3c6e1bb0 fix(06dbus): do not hardcode path to systemd unit
Use $systemdsystemunitdir instead /usr/lib/systemd/system.
2021-01-21 16:53:30 +00:00
Zoltán Böszörményi 911c2de9c3 fix(99squash): use kernel config instead of modprobe to check modules
Signed-off-by: Zoltán Böszörményi <zboszor@pr.hu>
2021-01-21 16:33:18 +00:00
Ondrej Mosnacek 951c6655f1 fix(90kernel-modules): install generic crypto modules with hostonly unset
Otherwise e.g. the xts(aes) implementation provided by the vmx_crypto
module (which does usually get included on ppc64le) fails to initialize
when xts is built as a module (CONFIG_CRYPTO_XTS=m), because it can't
instantiate the fallback generic xts(aes) implementation (needs the
generic xts module).

Signed-off-by: Ondrej Mosnacek <omosnace@redhat.com>
2021-01-21 12:20:22 +01:00
Jóhann B. Guðmundsson 66c27a6d85 chore(removal): eliminate bootchart module 2021-01-19 00:44:30 +01:00
Yang Liu 77630365ae fix(35network-manager): avoid restarting NetworkManager
On EL8.3 the NetworkManager keep restarting even if it exits successfully while waiting for Clevis to unlock. This patch ensures NetworkManager runs only once in initrd.
2021-01-15 11:18:24 +01:00
Daniel Molkentin 8cceee8059 Revert "Retrieve service, rpc and protcol entries via getent in hostonly mode"
The underlying issues this was trying to solve is to get a cheap
workaround for the fact that (open)SUSE with atomic support moved
/etc stock files to /usr/etc in order to improve compatibility. But
now that even nsswitch.conf moved, this is no longer enough. And it
might be more trouble to support once it's in an official release.

So let's rather drop it now.

This reverts commit e0524af2bf.
2020-12-14 12:44:00 +01:00
Lukas Nykryn 7c2521091f multipathd: fix the comparison
From shellcheck:
/usr/lib/dracut/modules.d/90multipath/multipathd.sh:3:32: warning[SC2039]: In POSIX sh, == in place of = is undefined.
/usr/lib/dracut/modules.d/90multipath/multipathd.sh:3:32: warning[SC2193]: The arguments to this comparison can never be equal.
2020-11-27 10:00:03 +01:00
Daniel Molkentin 6fee16eab0 06dbus: consider dbus-broker 2020-11-25 18:21:39 +01:00
Daniel Molkentin 209f157d2a 06dbus: Add busctl as a more useful tool 2020-11-25 18:21:39 +01:00
Daniel Molkentin f57b1b9368 06dbus: Include dbus or messagebus group and user, depending on distro 2020-11-25 18:21:39 +01:00
Daniel Molkentin 09eb4de3d4 35network-wicked: openSUSE Factory has reintroduced libexec 2020-11-25 18:21:39 +01:00
Daniel Molkentin 1517f4c504 35network-wicked: install ip utility anyway 2020-11-25 18:21:39 +01:00
Daniel Molkentin 983aee0ef1 35network-wicked: Run wicked early enough to unlock block devices 2020-11-25 18:21:39 +01:00
Daniel Molkentin 7825c32bd6 06dbus: Do not install superfluous services 2020-11-25 18:21:39 +01:00
Daniel Molkentin 5fc7c05321 40network: introduce wicked option 2020-11-25 18:21:39 +01:00
Daniel Molkentin ed7ce0d64f 35network-wicked: introduce wicked support module 2020-11-25 18:21:39 +01:00
Daniel Molkentin e1845955ff 06dbus: introduce dbus support 2020-11-25 18:21:39 +01:00
Kairui Song 8c8af8a2cd 95fcoe: don't install if there is no FCoE hostonly devices
When in hostonly mode, 95fcoe module will still be installed even there
is no FCoE hostonly device. So use the new block_is_fcoe helper to check
for hostonly device in hostonly mode, avoid installing unneccessary module.

Signed-off-by: Kairui Song <kasong@redhat.com>
2020-11-23 17:23:38 +01:00
Kairui Song 4339d47cf8 95fcoe: ensure needed modules are installed
If fcoe module is loaded, the initramfs will always try load libfcoe
and bnx2fc, so also ensure they are installed if needed.

Signed-off-by: Kairui Song <kasong@redhat.com>
2020-11-18 14:18:01 +01:00
Petr Pavlu 6685d99448 Prevent creating unexpected files on the host when running dracut
Library file modules.d/99base/dracut-lib.sh contains initialization code
that makes sure certain directories and links are created when a system
runs from the produced initramfs. This file is normally sourced only
from initramfs scripts. However, modules.d/99base/module-setup.sh
includes it also when an initramfs image is being created to gain access
to some of the functions in this library. This can result in creating
unexpected directories and links on the current root file system when
the dracut command is executed.

For instance, during a system installation when dracut is invoked to
create an initial initramfs, the target sysroot might not contain
directory /run/initramfs but have /var/log. This situation results in
the code in modules.d/99base/dracut-lib.sh creating an unexpected link
/var/log/log that points to /run/initramfs/log. This link is then also
present on the installed system.

The patch fixes the problem by skipping the described logic in
modules.d/99base/dracut-lib.sh when the PREFIX variable is non-empty
which indicates that a target initramfs is being prepared. The variable
is set by modules.d/99base/module-setup.sh prior to including
dracut-lib.sh.
2020-11-15 00:47:39 +01:00
Daniel Molkentin 5840c466dc 95nfs: /var/lib/nfs/statd/sm is /var/lib/nfs/sm on SUSE
Reference: boo#1177462
2020-11-14 19:28:56 +01:00
Daniel Molkentin e0524af2bf 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
2020-11-14 19:28:56 +01:00
Daniel Molkentin 1ec85e5232 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
2020-11-14 16:36:38 +01:00
Jonathan Lebon a23a4680e7 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.
2020-11-14 15:30:34 +01:00
David Tardon 0f89c0dff6 90multipath: install kpartx's 11-dm-parts.rules
This makes /dev/disk/by-uuid links point to the right device.
2020-11-14 15:15:13 +01:00
Jonathan Lebon 09804a4629 Revert "90crypt: ship initrd-cryptsetup.target"
This reverts commit 8f56daa8c3.

The addition of `initrd-cryptsetup.target` was reverted in systemd:
https://github.com/systemd/systemd/pull/17467
2020-11-05 14:22:52 +01:00
Kairui Song 831e310adf 90qemu-net: install less module for strict hostonly mode 2020-10-30 10:13:37 +01:00
Kairui Song 5698258d30 90qemu-net: in hostonly mode, only install if network is needed
Signed-off-by: Kairui Song <kasong@redhat.com>
2020-10-30 10:13:37 +01:00
Kairui Song 3b45c7e1a0 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>
2020-10-30 10:13:37 +01:00
Kairui Song 5817934936 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>
2020-10-30 10:13:37 +01:00
Kairui Song 6375d5d504 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>
2020-10-30 10:13:37 +01:00
Kairui Song 5a49fd3656 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>
2020-10-30 10:13:37 +01:00