HP Visualize J210XC IRIX to HP-UX Migration Guide - Page 32

Disks and File Systems, HP-UX Reference, Physical Volume Management Tasks

Page 32 highlights

Disks and File Systems Basic Facts • A physical volume is a hard disk. To use LVM, a disk must be first initialized into a physical volume (also called an LVM disk). • Once you have initialized one or more physical volumes, assign them to one or more volume groups. • A given disk can only belong to one volume group. The maximum number of volume groups that can be created is determined by the configurable parameter maxvgs. • A volume group can contain from one to 255 physical volumes. • Disk space from the volume group is allocated into a logical volume, a distinct unit of usable disk space. A volume group can contain up to 255 logical volumes. The disk space within a logical volume can be used for swap, dump, raw data, or you can create a file system on it. • LVM divides each physical disk into addressable units called physical extents. Physical extent size is configurable at the time you form a volume group and applies to all disks in the volume group. By default, each physical extent has a size of 4 megabytes (MB). This value can be changed when you create the volume group to a value between 1MB and 256MB. • The basic allocation unit for a logical volume is called a logical extent. A logical extent is mapped to a physical extent; thus, if the physical extent size is 4MB, so is the logical extent size. The size of a logical volume is determined by the number of logical extents that have been configured. • Except for mirrored or striped logical volumes, each logical extent is mapped to one physical extent. For mirrored logical volumes, either two or three physical extents are mapped for each logical extent depending upon whether you are using single or double mirroring. For example, if one mirror copy exists, then each logical extent maps to two physical extents, one extent for the original and one for the mirror copy. • If a logical volume is to be used for root, primary swap, or dump, the physical extents must be contiguous. This means the physical extents must be allocated with no gaps on a single physical volume. On non-root disks, physical extents that correspond to contiguous logical extents within a logical volume can be non-contiguous on a physical volume or reside on entirely different disks. As a result, it becomes possible for a file system created within one logical volume to reside on more than one disk. Managing Logical Volumes Using SAM SAM enables you to perform most, but not all, LVM management tasks. Tasks that can be performed with SAM include: • Creating or removing volume groups • Adding or removing disks within volume groups • Creating, removing, or modifying logical volumes • Increasing the size of logical volumes • Creating or increasing the size of a file system in a logical volume • Setting up and modifying swap and dump logical volumes • Creating and modifying mirrored logical volumes These tasks can also be performed with HP-UX commands. Managing Logical Volumes Using HP-UX Commands The following tables give you general information on the commands you will need to use to perform a given task. Refer to the HP-UX Reference for detailed information (HP manuals are available either on documentation CDs supplied with the system or at http://docs.hp.com). Physical Volume Management Tasks TASK Changing the characteristics of a physical volume in a volume group Creating a physical volume for use in a volume group Displaying information about physical volumes in a volume group Moving data from one physical volume to another COMMAND pvchange pvcreate pvdisplay pvmove 27

  • 1
  • 2
  • 3
  • 4
  • 5
  • 6
  • 7
  • 8
  • 9
  • 10
  • 11
  • 12
  • 13
  • 14
  • 15
  • 16
  • 17
  • 18
  • 19
  • 20
  • 21
  • 22
  • 23
  • 24
  • 25
  • 26
  • 27
  • 28
  • 29
  • 30
  • 31
  • 32
  • 33
  • 34
  • 35
  • 36
  • 37
  • 38
  • 39
  • 40
  • 41
  • 42
  • 43
  • 44
  • 45
  • 46
  • 47
  • 48
  • 49
  • 50
  • 51
  • 52
  • 53
  • 54
  • 55
  • 56
  • 57
  • 58
  • 59
  • 60
  • 61
  • 62
  • 63
  • 64
  • 65
  • 66
  • 67
  • 68
  • 69
  • 70
  • 71
  • 72
  • 73
  • 74
  • 75
  • 76
  • 77
  • 78
  • 79
  • 80
  • 81
  • 82
  • 83
  • 84
  • 85
  • 86
  • 87
  • 88
  • 89
  • 90
  • 91
  • 92
  • 93
  • 94
  • 95
  • 96
  • 97
  • 98
  • 99
  • 100
  • 101
  • 102
  • 103
  • 104
  • 105
  • 106
  • 107
  • 108
  • 109
  • 110
  • 111
  • 112
  • 113
  • 114
  • 115
  • 116
  • 117
  • 118
  • 119
  • 120
  • 121
  • 122
  • 123
  • 124
  • 125

Disks and File Systems
27
Basic Facts
A
physical volume
is a hard disk. To use LVM, a disk must be first initialized into a physical volume
(also called an LVM disk).
Once you have initialized one or more physical volumes, assign them to one or more
volume groups
.
A given disk can only belong to one volume group. The maximum number of volume groups that can
be created is determined by the configurable parameter
maxvgs
.
A volume group can contain from one to 255 physical volumes.
Disk space from the volume group is allocated into a
logical volume
, a distinct unit of usable disk
space. A volume group can contain up to 255 logical volumes. The disk space within a logical volume
can be used for swap, dump, raw data, or you can create a file system on it.
LVM divides each physical disk into addressable units called
physical extents
. Physical extent size is
configurable at the time you form a volume group and applies to all disks in the volume group. By
default, each physical extent has a size of 4 megabytes (MB). This value can be changed when you
create the volume group to a value between 1MB and 256MB.
The basic allocation unit for a logical volume is called a
logical extent
. A logical extent is mapped to a
physical extent; thus, if the physical extent size is 4MB, so is the logical extent size. The size of a
logical volume is determined by the number of logical extents that have been configured.
Except for mirrored or striped logical volumes, each logical extent is mapped to one physical extent.
For mirrored logical volumes, either two or three physical extents are mapped for each logical extent
depending upon whether you are using single or double mirroring. For example, if one mirror copy
exists, then each logical extent maps to two physical extents, one extent for the original and one for the
mirror copy.
If a logical volume is to be used for
root
, primary swap, or dump, the physical extents must be
contiguous. This means the physical extents must be allocated with no gaps on a single physical
volume. On non-root disks, physical extents that correspond to contiguous logical extents within a
logical volume can be non-contiguous on a physical volume or reside on entirely different disks. As a
result, it becomes possible for a file system created within one logical volume to reside on more than
one disk.
Managing Logical Volumes Using SAM
SAM enables you to perform most, but not all, LVM management tasks. Tasks that can be performed with
SAM include:
Creating or removing volume groups
Adding or removing disks within volume groups
Creating, removing, or modifying logical volumes
Increasing the size of logical volumes
Creating or increasing the size of a file system in a logical volume
Setting up and modifying swap and dump logical volumes
Creating and modifying mirrored logical volumes
These tasks can also be performed with HP-UX commands.
Managing Logical Volumes Using HP-UX Commands
The following tables give you general information on the commands you will need to use to perform a
given task. Refer to the
HP-UX Reference
for detailed information
(HP manuals are available either on
documentation CDs supplied with the system or at http://docs.hp.com).
Physical Volume Management Tasks
T
ASK
C
OMMAND
Changing the characteristics of a physical volume in a volume group
pvchange
Creating a physical volume for use in a volume group
pvcreate
Displaying information about physical volumes in a volume group
pvdisplay
Moving data from one physical volume to another
pvmove