Filip Chabik

Born'n'raised in Wrocław, currently living, working and having fun in ❤️ Berlin. Vegetarian, atheist, skeptic and 🐈 lover. Dad & husband 👨‍👩‍👧

Share


Tags


Updating GRUB device.map file after adding a new disk

Recently I wrote about extending existing VG in LVM by adding new external hard disk on USB. Basically I covered the topic fully, although today during installa…

Filip ChabikFilip Chabik

Recently I wrote about extending existing VG in LVM by adding new external hard disk on USB. Basically I covered the topic fully, although today during installation of new kernel (2.6.39 from squeeze-backports) I encounter some errors. It took my awhile while I found out, that the most important one is GRUB related:

update-grub
Generating grub.cfg ...
/usr/sbin/grub-probe: error: Couldn't find PV pv1. Check your device.map.

GRUB2 can read some information from LVM partitions – GRUB-legacy didn’t  really care about disks in LVM, as he was unable to read from them.  Anyway, I figured that the problem is in grub.cfg and in device.map –  both files are located under /boot/grub. What’s the problem? Well, new  added to existing VG and used only to extend existing LVs disk wasn’t  recognized by GRUB (hence error message provided above). This error was  due to lack of disk information provided in device.map file. What’s the  solution? Pretty simple, actually:

mv /boot/grub/device.map /boot/grub/device.map.backup
grub-mkdevicemap
update-grub

That’s all! (:

Born'n'raised in Wrocław, currently living, working and having fun in ❤️ Berlin. Vegetarian, atheist, skeptic and 🐈 lover. Dad & husband 👨‍👩‍👧

View Comments