Finally, I found it. Now post the execution code. Hope to help everyone!
[Root@localhost ~]# Fdisk/dev/hda3
The number of cylinders for this disk is set to 3916.
There is no wrong with then, but this is larger than 1024,
And could in certain setups cause problems with:
1 software that runs in boot time (e.g., old versions of LILO)
2) booting and partitioning software from the other OSs
(e.g., DOS fdisk, OS/2 fdisk)
Command (M for help): P
disk/dev/hda4:32.2 GB, 32212254720 bytes
255 heads, Sectors/track, 3916 cylinders
Units = Cylinders of 16065 * 8225280 bytes
Disk identifier:0x000bc363
Device Boot Start End Blocks Id System
/DEV/HDA1 * 1 200781 Linux
/dev/hda2 1958 15526822+ 8e Linux LVM
/dev/hda3 1959 2610 5237190 8e Linux LVM
Command (M for help): N
Command Action
E Extended
P primary partition (1-4)
Selected Partition 4
The cylinder (2611-3916, default 2611):
Using Default Value 2611
Last cylinder or +size or +sizem or +sizek (2611-3916, default 3916):
Using Default Value 3916
Command (M for help): t
Partition number (1-4): 4
Hex code (type L to list codes): 8e
Changed system type of partition 4 to 8e (Linux LVM)
Command (M for help): P
disk/dev/hda:32.2 GB, 32212254720 bytes
255 heads, Sectors/track, 3916 cylinders
Units = Cylinders of 16065 * 8225280 bytes
Disk identifier:0x000bc363
Device Boot Start End Blocks Id System
/DEV/HDA1 * 1 200781 Linux
/dev/hda2 1958 15526822+ 8e Linux LVM
/dev/hda3 1959 2610 5237190 8e Linux LVM
/DEV/HDA4 2611 3916 10490445 8e Linux LVM
Command (M for help): W
The partition table has been altered!
Calling IOCTL () to re-read partition table.
Warning:re-reading the partition table failed with error 16:device or resource busy.
The kernel still uses the old table.
The new table is used at the next reboot.
Syncing disks.
(Note: It is recommended to restart the CentOS system)
[Root@localhost ~]# Pvcreate/dev/hda3
Physical volume "/dev/hda4″successfully created
[Root@localhost ~]# Vgextend Volgroup00/dev/hda3
Volume Group "volgroup00″successfully extended
[Root@localhost ~]# lvextend-l +100%free/dev/volgroup00/logvol00
Extending logical Volume LogVol00 to 28.25 GB
Logical Volume LogVol00 successfully resized
[Root@localhost ~]# lvresize-l +100%free/dev/volgroup00/logvol00
New size (904 extents) matches existing size (904 extents)
Lvresize:resize a Logical volume
Lvresize
[-a|--autobackup Y|n]
[--alloc Allocationpolicy]
[-d|--debug]
[-h|--help]
[-i|--stripes stripes [-i|--stripesize stripesize]]
{-l|–extents [+|-]logicalextentsnumber[%{vg|lv| Free}] |
-l|–size [+|-]logicalvolumesize[kkmmggttppee]}
[-n|--nofsck]
[-r|--resizefs]
[-t|--test]
[--type Volumetype]
[-v|--verbose]
[--version]
Logicalvolume[path] [Physicalvolumepath ...]
[Root@localhost ~]# Resize2fs/dev/volgroup00/logvol00
RESIZE2FS 1.40.2 (12-jul-2007)
FileSystem at/dev/volgroup00/logvol00 is mounted on/; On-line resizing required
Old desc_blocks = 2, new_desc_blocks = 2
Performing a on-line resize of/dev/volgroup00/logvol00 to 7405568 (4k) blocks.
The filesystem on/dev/volgroup00/logvol00 is now 7405568 blocks long.