Ubuntu Linux, ubuntu desktop, Linux operating system, ubuntu guide

Ubuntu 12.04 Boot error – Windows XP from Grub2 – cannot create /var/lib/os-prober/labels: Permission denied

by on Jun.11, 2012, under Ububtu 12.04, Ubuntu

In this issue machine  have the two hard drives. On one is Windows XP , on the other one is Xubuntu 12.04 .

Here the windows MBR is fine. I can boot my Windows partition by selecting that HD from the BIOS. Likewise the MBR on the other hard drive is fine and I can boot Xubuntu from grub. What I would like to do is to be able to chainload ntldr (I believe that’s the right terminology) from grub.

os-prober does not detect Windows – unless the partition is mounted but it can’t write anything anyway because it says it needs to be run as root. However sudo os-prober doesn’t seem to do anything at all, so that doesn’t help either. Always getting below error.

ERROR: you must be root ERROR: you must be root /usr/lib/os-probes/mounted/20microsoft: 47:
/usr/lib/os-probes/mounted/20microsoft:
cannot create /var/lib/os-prober/labels: Permission denied /dev/sda1:Microsoft Windows XP Home Edition:Windows:chain mkdir: cannot create directory `/var/lib/os-prober/mount': Permission denied

I have followed below steps for resolve the issue

Added the following to the lines below those already in /etc/grub.d/40_custom:
menuentry “Microsoft Windows XP Home Edition (on /dev/sda1)” –class windows –class os {
insmod part_msdos
insmod ntfs
set root=’(hd0,msdos1)’
search –no-floppy –fs-uuid –set=root 5E1C40441C401983
drivemap -s (hd0) ${root}
chainloader +1
}
Save the file and update-grub.

Reinstalled os-prober with the following:
sudo apt-get install --reinstall os-probe
:, , , , , , ,

Leave a Reply

Looking for something?

Use the form below to search the site:

Still not finding what you're looking for? Drop a comment on a post or contact us so we can take care of it!