Ask your questions here.
Post a reply
fsmithred

- fsmithred
- Posts: 2101
- Joined: Wed Mar 09, 2011 9:13 pm

## Re: Refracta snapshot not working in qemu

Wed Oct 22, 2014 10:58 am

I think all you need to do is list the additional modules you want in etc/initramfs-tools/modules, and then run

Code:
  `update-initramfs -u`

Probably a good idea to make a backup copy of your initrd first. (I think update-initramfs has an option to do that for you.) Then make a new snapshot.
aquilarubra

- aquilarubra
- Posts: 39
- Joined: Wed Sep 10, 2014 7:07 am

## Re: Refracta snapshot not working in qemu

Thu Oct 23, 2014 6:40 am

Further observations. I found the same bug reported in many places. Somebody advised to load groups in initramfs prompt, then CTRL+D and boot resumes, but is was not my case. It continued to complain about the ehci-orion missing module.
modprobe ehci-orion in my running system says it is not found. Upon further investigation, I found that it was in Wheezy kernel (I found the .c file in linux-headers). It is no longer in sid. I wondered if there is another package to install, since it moved to a module and was then split into 2 different modules. So, no surprise that I could not update initramfs, since the module is absent in my system.
However, if I burn the CD and start from it, it works. So it is a specific virtualbox bug, which shown itself to the kernel with a particular architecture. I notice, with the CD boot, it asks me for the password and mounts my encrypted disk, knowing it is /dev/sdb6. I don't know where it mounts it, though, but it does.
So, it is a lvm2/grub issue. Somebody reported to solve this problem downgrading grub (the latest sid version has the issue). Somehow, grub caches erroneously that there is an encrypted disk to mount, even if etc/fstab is empty, and it looks for it during boot.
As a result of tests, something screwed up in my grub, so I cannot run further tests and will have to reinstall everything. Unfortunately, I have everything on an encrypted partition, except /boot. And when I try to reinstall grub from the livecd... it won't work, because the encrypted partition comes in the way... and I don't know how to tell grub that it has a linux system on the encrypted partition. So... it's a little messy to recover a system from an encrypted partition. But I can definitely access my files, no problem.
aquilarubra

- aquilarubra
- Posts: 39
- Joined: Wed Sep 10, 2014 7:07 am

## Re: Refracta snapshot not working in qemu

Thu Oct 23, 2014 8:03 am

I'm doing more tests after restoring my system.
Booting from the physical livecd (the same that has issues in virtualbox), it asks me to give the password for the encrypted volume. I gave it blank passwords a few times, and the system loaded anyway. So, it definitely works.
What appears is that the livecd tries anyway to find any encrypted volumes to open them (not to mount them). Then, it continues normally.
Now, the issue comes to Virtualbox. It seems it doesn't handle cryptsetup properly.
fsmithred

- fsmithred
- Posts: 2101
- Joined: Wed Mar 09, 2011 9:13 pm

## Re: Refracta snapshot not working in qemu

Thu Oct 23, 2014 2:05 pm

Have you tried changing the type of IDE controller you're using in vbox? Just a guess. I tried all three and didn't notice any difference, but I'm not dealing with encryption right now.
At boot, the live system looks for volumes labeled "persistence" (or other label if you specify it on the boot command). If it finds any, it mounts them at /lib/live/mount/persistence (I think that's right). I'm not sure if the newer versions of live-* can deal with encrypted partitions. I think dzz said that they do, but still don't handle encrypted loopback files. If I'm correct, that explains why it asks for the password. I get that behavior on a usb stick that has an extra encrypted partition that isn't used for persistence and isn't needed to boot. The initrd is patched to handle encrypted partitions and other things. When it asks for the password, I just hit ENTER and then answer "n" for no when it asks if I want to try again. That bypasses mounting it. If I give the password, I can't remember if it mounts or not. It might just open the luks volume. Have to try that later.
aquilarubra

- aquilarubra
- Posts: 39
- Joined: Wed Sep 10, 2014 7:07 am

## Re: Refracta snapshot not working in qemu

Thu Oct 23, 2014 2:08 pm

I think I found the solution.
Refracta snapshot resets correctly etc/fstab, which is empty. But... it leaves etc/crypttab, which in my case contains the indication of /dev/sdb6. Thus, at boot the livedvd searches for the encrypted volume and asks for the password.
In virtualbox, no /dev/sdb6 is present. Thus, it drops to a shell.
The issue is not related to the ehci-orion module. If you read the error, is says "Dropping to a shell" before complaining about the ehci-orion module.
I will create a new snapshot blanking before etc/crypttab and test it. If it works, you could implement this in refracta tools and it should work from encrypted partitions too.
aquilarubra

- aquilarubra
- Posts: 39
- Joined: Wed Sep 10, 2014 7:07 am

## Re: Refracta snapshot not working in qemu

Thu Oct 23, 2014 4:13 pm

With my last test, result did not change. However, I am sure it is etc/crypttab.
In my case, I also use disk-manager, which overrides standard grub behavior. So, also fstab-disk-manager-save and fstab-ntfs-config-save should be blanked out. I guess, since they are a copy of fstab, they are still telling the system that /dev/sdb6 exists.
Anyway, I found that CTRL+D allows boot to continue past the busybox prompt and the system loads just fine.
Post a reply
Jump to:

Powered by phpBB © phpBB Group.

phpBB Mobile / SEO by Artodia.