systemd: Use the kernel modules from /run/booted-system
This prevents failures in systemd-modules-load.service like "Failed to lookup alias 'ipv6': Function not implemented".
This commit is contained in:
parent
4475294f57
commit
7a7d04af8a
@ -17,8 +17,8 @@ with pkgs.lib;
|
|||||||
text =
|
text =
|
||||||
''
|
''
|
||||||
#! ${pkgs.stdenv.shell}
|
#! ${pkgs.stdenv.shell}
|
||||||
export MODULE_DIR=/var/run/current-system/kernel-modules/lib/modules
|
export MODULE_DIR=/run/current-system/kernel-modules/lib/modules
|
||||||
|
|
||||||
# Fall back to the kernel modules used at boot time if the
|
# Fall back to the kernel modules used at boot time if the
|
||||||
# modules in the current configuration don't match the
|
# modules in the current configuration don't match the
|
||||||
# running kernel.
|
# running kernel.
|
||||||
@ -105,8 +105,8 @@ with pkgs.lib;
|
|||||||
|
|
||||||
environment.shellInit =
|
environment.shellInit =
|
||||||
''
|
''
|
||||||
export MODULE_DIR=/var/run/current-system/kernel-modules/lib/modules
|
export MODULE_DIR=/run/current-system/kernel-modules/lib/modules
|
||||||
'';
|
'';
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -178,5 +178,5 @@ fi
|
|||||||
# Start systemd.
|
# Start systemd.
|
||||||
echo "starting systemd..."
|
echo "starting systemd..."
|
||||||
PATH=/run/current-system/systemd/lib/systemd \
|
PATH=/run/current-system/systemd/lib/systemd \
|
||||||
MODULE_DIR=/run/current-system/kernel-modules/lib/modules \
|
MODULE_DIR=/run/booted-system/kernel-modules/lib/modules \
|
||||||
exec systemd --log-target=journal # --log-level=debug --log-target=console --crash-shell
|
exec systemd --log-target=journal # --log-level=debug --log-target=console --crash-shell
|
||||||
|
Loading…
Reference in New Issue
Block a user