Managing Systems and Workgroups: A Guide for HP-UX System Administrators
Administering a System: Managing Disks and Files
Managing File Systems
Chapter 6612
Using HP-UX
Commands
When using lvextend to increase the size of the logical volume
container, this does not automatically increase the size of its contents.
When you first create a file system within a logical volume, the file
system assumes the same size as the logical volume. If you later increase
the size of the logical volume using the lvextend command, the file
system within does not know that its container has been enlarged. You
must explicitly tell it this using the extendfs command. (If you are
using JFS, see the Note below.)
NOTE If you are using JFS and you have the HP OnLineJFS product, run the
fsadm command to increase the size of a file system. See fsadm_vxfs (1M)
for information on syntax. Further information is also available in Disk
and File Management Tasks on HP-UX.
If you are using JFS but do not have HP OnLineJFS, use the steps below,
or, back up the file system and create a larger file system using newfs.
Sample Procedure to Increase the Size of a Logical Volume
Suppose the current size of a logical volume is 1024 MB (1 gigabyte).
Assuming the users of the file system within this logical volume have
consumed 95% of its current space and a new project is being added to
their work load, the file system will need to be enlarged. To increase the
size of the file system, follow these steps:
Step 1. Unmount the file system.
umount /dev/vg01/lvol1
Step 2. Increase the size of the logical volume.
/usr/sbin/lvextend -L 1200 /dev/vg01/lvol1
Note that the -L 1200 represents the new logical volume size in MB, not
the increment in size.
Step 3. Increase the file system capacity to the same size as the logical volume.
Notice the use of the character device file name.
extendfs /dev/vg01/rlvol1
Step 4. Remount the file system.
mount /dev/vg01/lvol1 /project