1
0
Fork 1
mirror of https://github.com/NixOS/nixpkgs.git synced 2024-11-27 08:01:14 +00:00
nixpkgs/tests/kexec.nix
Eelco Dolstra b825169404 Add kexec support
You can now do a fast reboot (bypassing the BIOS, which may take
several minutes on servers) by running ‘systemctl kexec’.

Unfortunately the QEMU test for this is unreliable due to a QEMU bug
(it randomly crashes with a message like ‘Guest moved used index from
8 to 0’), so it's commented out.
2013-09-16 17:42:13 +02:00

19 lines
349 B
Nix

# Test whether fast reboots via kexec work.
{ pkgs, ... }:
{
machine = { config, pkgs, ... }:
{ virtualisation.vlans = [ ]; };
testScript =
''
$machine->waitForUnit("multi-user.target");
$machine->execute("systemctl kexec &");
$machine->{connected} = 0;
$machine->waitForUnit("multi-user.target");
'';
}