You are not logged in.

#1 2011-08-13 06:05:20

viii
Member
Registered: 2011-08-13
Posts: 4

Can't boot after clean install [lvm on dm_crypt]

Hey all,

I've been trying to get a full-system encrypted install of Arch Linux on an old computer of mine for a while now, but I keep running into the same problem (Error 15: File not found) on reboot.

The full boot message is:

  Booting 'Arch Linux'

root (hd0,0)
 Filesystem type is ext2fs, partition type 0x83
kernel /vmlinuz26 root=/dev/mapper/cryptpool-root cryptdevice=/dev/sda2:dm_crypt ro

Error 15: File not found

Press any key to continue...

Any assistance would be appreciated.

Thank you.

Last edited by viii (2011-08-13 07:27:07)

Offline

#2 2011-08-13 06:58:10

tpowa
Developer
From: Lauingen , Germany
Registered: 2004-04-05
Posts: 2,322

Re: Can't boot after clean install [lvm on dm_crypt]

the kernel name is wrong, vmlinuz26 or vmlinuz-linux would be correct.

Offline

#3 2011-08-13 07:27:46

viii
Member
Registered: 2011-08-13
Posts: 4

Re: Can't boot after clean install [lvm on dm_crypt]

That was a typo, my apologies. I've updated the post.

Offline

#4 2011-08-13 07:35:40

viii
Member
Registered: 2011-08-13
Posts: 4

Re: Can't boot after clean install [lvm on dm_crypt]

For the install sequence, I followed the instructions located here. I chose to manually configure block devices in the manner suggested by the document (beginning at "For example, if you want"), except I created three logical volumes: one with size 2GiB at /swap, one with size 5GiB at /tmp, and one with size 145GiB at /.

After progressing to Configure Files, I edited /etc/rc.conf and set USELVM="yes". I edited /etc/mkinitcpio.conf's HOOKS line to load usbinput before encrypt.

I installed GRUB to /dev/sda

If there is any additional information I can provide that would be useful, please let me know.

Offline

#5 2011-08-14 00:33:03

KairiTech
Member
From: Toronto, Canada
Registered: 2011-06-04
Posts: 275

Re: Can't boot after clean install [lvm on dm_crypt]

netinstall seems to be broken for LVM and LUKS since the Linux 3.0 update. Use the core iso instead and whatever you do DO NOT upgrade to the 3.0 kernel. Doing that brakes my system. I admit I do have a complicated config but I'm able to boot if I use the core install and stay with the old kernel.

Breakage looks like it might be located in mkinitcpio not regenerating the initramfs after you edit the config.

Offline

#6 2011-08-15 08:15:57

Tallahassee
Member
From: Good old Germany
Registered: 2011-08-15
Posts: 4

Re: Can't boot after clean install [lvm on dm_crypt]

What a coincidence. I just happened to run into the same problem yesterday. The problem is simple, but it took me two hours to figure that out.
When you install arch the point “Install Packages” comes beforehand “Configure System”.
Here’s the deal: mkinitcpio will be executed *before* you have the chance to change the HOOKS-variables.

Solution:
All you have to do is to start over with the installation (don’t forget cryptsetup and vgchange, bla) then go through the whole procedure until you reach point 4 (Install Packages). Don’t start it, instead you switch to another terminal (Alt + F2) and login. Edit the mkinitcpio.conf and rc.conf file in /mnt/etc/ (*NOT* in /etc/) as required. After you configured the two files switch back to the installation (Alt + F1) and install the packages. Now it will build a kernel with all the hooks you need like encrypt and lvm2.

Please also note that the name of the kernel and initram-file has changed. If you configure grub you have to change the menu.lst accordingly since it will still use names like “vmlinuz”.
In your case the lines should look like this:
root (hd0,0)
kernel /vmlinuz-linux cryptdevice=/dev/sda2:dm_crypt root=/dev/mapper/cryptpool-root ro
initrd /initramfs-linux.img

After that you should be able to boot into your new system and continue installation.

Hope that helps.

Btw. maybe someone can use this info to fix the problem.

Offline

#7 2011-08-15 09:18:58

vacant
Member
From: downstairs
Registered: 2004-11-05
Posts: 816

Re: Can't boot after clean install [lvm on dm_crypt]

viii wrote:

I created three logical volumes: one with size 2GiB at /swap, one with size 5GiB at /tmp, and one with size 145GiB at /.

...

I installed GRUB to /dev/sda

Boot the installation CD again and mount /dev/sda1 to see if there is a vmlinuz26 there. You don't mention a separate /boot partition.

Offline

#8 2011-08-15 09:56:01

Tallahassee
Member
From: Good old Germany
Registered: 2011-08-15
Posts: 4

Re: Can't boot after clean install [lvm on dm_crypt]

vacant wrote:

Boot the installation CD again and mount /dev/sda1 to see if there is a vmlinuz26 there. You don't mention a separate /boot partition.

Even if he has /boot at /dev/sda1 he won't find it. The name of the kernel changed. It's now calles vmlinuz-linux.

Offline

#9 2011-08-15 10:05:19

vacant
Member
From: downstairs
Registered: 2004-11-05
Posts: 816

Re: Can't boot after clean install [lvm on dm_crypt]

Tallahassee wrote:

Even if he has /boot at /dev/sda1 he won't find it. The name of the kernel changed. It's now calles vmlinuz-linux.

Old names still work

http://www.archlinux.org/news/changes-t … filenames/

"To prevent you from breaking your system after the update, symlinks are created so that your bootloader configuration pointing to the old files will still work. However we recommend updating your bootloader configuration and deleting the symlinks afterwards"

Offline

#10 2011-08-15 11:04:27

Tallahassee
Member
From: Good old Germany
Registered: 2011-08-15
Posts: 4

Re: Can't boot after clean install [lvm on dm_crypt]

vacant wrote:

Old names still work

No doubt about it but I'm talking about the filename.
If you install from scratch you won't find a file named "vmlinuz" anymore.
My point is, if he looks for it - like you suggest - he might end up a little confused.
I'm not saying that you're wrong ; )

Offline

#11 2011-08-15 12:22:20

vacant
Member
From: downstairs
Registered: 2004-11-05
Posts: 816

Re: Can't boot after clean install [lvm on dm_crypt]

If he "looks for it like I suggest", there is no confusion. "ls" will include "vmlinuz26" if files are installed correctly on sda1.

a) OP understand symlinks ... and sees a symlink called vmlinuz26, in which case he can "find" the file with "ls -l".
b) OP doesn't understand symlinks ... and sees vmlinux26 is listed and carries on, as far as he's concerned he's found it.

BTW, installing from a core-install (we don't know) won't find vmlinuz-linux until OP manages to update.

Also

Tallahassee wrote:

If you configure grub you have to change the menu.lst accordingly since it will still use names like “vmlinuz”.

No, you don't have to. Care was taken to make sure either way would work. At some time in the future it will probably be deprecated in which case I'd expect an announcement.

Offline

#12 2011-08-15 18:20:55

viii
Member
Registered: 2011-08-13
Posts: 4

Re: Can't boot after clean install [lvm on dm_crypt]

Hey, OP here. Thanks for the replies smile

vacant wrote:

Boot the installation CD again and mount /dev/sda1 to see if there is a vmlinuz26 there. You don't mention a separate /boot partition.

The instructions I was following had me partition my hard drive into two partitions. I have a 128MB partition on /dev/sda1 (primary, bootable) and a 159something GB partition (primary) on /dev/sda2. When I was running the installer, it recommended I install grub to /dev/sda, not a partition, so I did. After booting from a liveCD, ls -la /mnt/boot showed a single directory lost+found with nothing inside. Should I have installed grub to /dev/sda1?

Tallahassee wrote:

Edit the mkinitcpio.conf and rc.conf file in /mnt/etc/ (*NOT* in /etc/) as required.

I looked in /mnt/ after setting up partitions but before running Select Packages and the only things in /mnt/ were the directories boot/ and tmp/, each of which had an empty directory lost+found/ and that's it. After running Select Packages (base package + openssl, openssh, ncurses) but before running Install Packages, a var/ directory appeared with the standard cache/ and lib/. At no point up to just before Install Packages was there a /mnt/etc/.

Thanks again.

Offline

#13 2011-08-15 19:01:31

lilsirecho
Veteran
Registered: 2003-10-24
Posts: 5,000

Re: Can't boot after clean install [lvm on dm_crypt]

Perhaps you misinterpret the .../mnt/etc... posted by another.

You probably have to generate the ..../mnt/etc... in the mnt directory by running ..cd /mnt....mkdir /mnt/etc.....

This will create the /mnt/etc while you are in the alternate mode.


Prediction...This year will be a very odd year!
Hard work does not kill people but why risk it: Charlie Mccarthy
A man is not complete until he is married..then..he is finished.
When ALL is lost, what can be found? Even bytes get lonely for a little bit!     X-ray confirms Iam spineless!

Offline

#14 2011-08-15 19:25:13

vacant
Member
From: downstairs
Registered: 2004-11-05
Posts: 816

Re: Can't boot after clean install [lvm on dm_crypt]

viii wrote:

The instructions I was following had me partition my hard drive into two partitions. I have a 128MB partition on /dev/sda1 (primary, bootable) and a 159something GB partition (primary) on /dev/sda2. When I was running the installer, it recommended I install grub to /dev/sda, not a partition, so I did. After booting from a liveCD, ls -la /mnt/boot showed a single directory lost+found with nothing inside. Should I have installed grub to /dev/sda1?

There are two parts to installing grub, (a) where the grub boot block goes - /dev/sda, (b) where the grub files (and  kernel, initrd) go - /dev/sda1

You are fine installing grub to /dev/sda but before that you need to tell the installer your partitions. You said you had /, /tmp and /swap but I think you also need to define /boot as /dev/sda1, that's the unencrypted partition where grub files and kernel go.

What happens when you boot is the BIOS looks for a boot block on the MBR*. It will find a grub boot block because you specified /dev/sda. The boot block will look for grub files  such as menu.lst on /dev/sda1. your menu.lst also points to the kernel and initrd on /dev/sda1. When the initrd loads, it contains modules to access your encrypted stuff.

(* If the MBR is empty, the BIOS will look on the first sectors of the partition marked as bootable for a boot block. So you could have nothing in your MBR, install grub to /dev/sda1 and mark the partition bootable.)

Offline

#15 2011-08-16 07:45:17

Tallahassee
Member
From: Good old Germany
Registered: 2011-08-15
Posts: 4

Re: Can't boot after clean install [lvm on dm_crypt]

viii wrote:

(...)I looked in /mnt/ after setting up partitions but before running Select Packages and the only things in /mnt/ were the directories boot/ and tmp/, each of which had an empty directory lost+found/ and that's it. After running Select Packages (base package + openssl, openssh, ncurses) but before running Install Packages, a var/ directory appeared with the standard cache/ and lib/. At no point up to just before Install Packages was there a /mnt/etc/.(...).

Yeah, I forgot. You have to install the packages once, after that you should find the files in /mnt/etc/. Then edit both files and run "Install Packages" again. You should then see that the hooks are being processed.

Offline

Board footer

Powered by FluxBB