Friday, April 5, 2013

Increasing the /boot size in RHEL63 Guest

[root@osh ~]# sudo fdisk -l /dev/sdb

Disk /dev/sdb: 2147 MB, 2147483648 bytes
255 heads, 63 sectors/track, 261 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x8f8fb048

   Device Boot      Start         End      Blocks   Id  System
/dev/sdb1               1         261     2096451   83  Linux
[root@osh ~]#


[root@osh~]# mkfs.ext3 /dev/sdb1

[root@osh~]# mount -t ext3 /dev/sdb1 /boot1

[root@osh~]# cp -ar /boot/* /boot1/

Edit fstab to mount this /dev/sdb1 as /boot every time we boot.

grub> root (hd1,0)
root (hd1,0)
 Filesystem type is ext2fs, partition type 0x83
grub> setup (hd1)
setup (hd1)
 Checking if "/boot/grub/stage1" exists... no
 Checking if "/grub/stage1" exists... yes
 Checking if "/grub/stage2" exists... yes
 Checking if "/grub/e2fs_stage1_5" exists... yes
 Running "embed /grub/e2fs_stage1_5 (hd1)"...  26 sectors are embedded.
succeeded
 Running "install /grub/stage1 (hd1) (hd1)1+26 p (hd1,0)/grub/stage2 /grub/grub.conf"... succeeded
Done.
grub> quit 
quit
[root@osh ~]#grub-install --recheck /dev/sdb1

Probing devices to guess BIOS drives. This may take a long time.
Unknown partition table signature

Installation finished. No error reported.
This is the contents of the device map /boot/grub/device.map.
Check if this is correct or not. If any of the lines is incorrect,
fix it and re-run the script `grub-install'.

(fd0)    /dev/fd0
(hd0)    /dev/sda
(hd1)    /dev/sdb
(hd2)    /dev/sdc
(hd3)    /dev/sdd
(hd4)    /dev/sde

[root@osh ~]# reboot


No comments: