[CentOS] Manually mounting partitions in "linux rescue" mode

m.roth at 5-cent.us m.roth at 5-cent.us
Tue Aug 3 17:20:01 UTC 2010


Edward Diener wrote:
> On 8/3/2010 11:13 AM, Les Mikesell wrote:
>> On 8/3/2010 9:56 AM, Edward Diener wrote:
>>>
>>> I am at the shell prompt but in order to get grub to work, don't I need
>>> to mount my actual boot and root partitions for grub to know that
>>> (hd0,9) refers a valid boot partition when I tell grub:
>>>
>>> root (hd0,9)
>>> setup (hd0,9)
>>
>> No, grub doesn't need to have anything mounted.
>
> OK, thanks for the info.
>
>>  The sysimage mount and
>> chroot is most useful to get access to your usual tools in their usual
>> paths and to be able to edit the grub.conf file.  I've never tried to
>> boot from a partition that far into the disk, though.   I had enough
>> trouble back in the days when bios only knew 1024 cylinders that I've
>> always put a small /boot partition as the first thing on the disk even
>> though you shouldn't have to now.
>
> My problem was that once I did a chroot I did not have any /dev devices.
> Evidently grub does use this. Once I did:
>
> mount --bind /dev /mnt/sysimage/dev
>
> before doing:
>
> chroot /mnt/sysimage
>
> when I executed 'grub' it found the (hd0,9) partition.

"Executed grub"? Not chroot, then grub-install /dev/sda?
<snip>
       mark





More information about the CentOS mailing list