[Nix-dev] LVM troubles

Rickard Nilsson rickard.nilsson at telia.com
Mon Apr 22 12:04:58 CEST 2013


Den 2013-04-22 08:26:25 skrev Lluís Batlle i Rossell <viric at viric.name>:

> On Sun, Apr 21, 2013 at 07:29:22PM +0200, Rickard Nilsson wrote:
>> Hi,
>>
>> I noticed today that my NixOS system that uses LVM on top of mdadm RAID
>> doesn't boot. It seems the LVM volumes are not activated. The NixOS init
>> says something about "starting LVM" and then it immediately starts  
>> looking
>> for the root device, which fails. If I try booting an older generation
>> (nixos-0.2pre-d99fce2-930e4d5), it prints that it found a number of lvm
>> volumes before starting to scan for the root device.
>>
>> Has something changed regarding LVM in NixOS lately (the last two months
>> or so) which might cause this behavior? Do I need to add any extra  
>> kernel
>> module include something LVM-related in the initrd?
>
> I built my nixos yesterday, and all worked fine. I didn't notice any  
> change.
> Here I use root+nix over luks over lvm.
>
>> I realise now, that just doing "nixos-rebuild switch", and not rebooting
>> the system every once in a while, can be risky...
>
> Well, old generations did work, didn't they?

Yep, but it took me a while to find an old generation that worked. And when
the system got up it was heavily out-of-date from before the reboot.
Of course I could easily solve that with a "nixos-rebuild switch". Now I'm
going to try to see what differs between the booted and the running  
version,
with regards to initrd and kernel modules.

   / Rickard


More information about the nix-dev mailing list