vgimport(1M) vgimport(1M)
NAME [Toc] [Back]
vgimport - import an LVM volume group onto the system
SYNOPSIS [Toc] [Back]
/usr/sbin/vgimport [-m mapfile] [-p] [-v] [-f infile] vg_name pv_path
...
/usr/sbin/vgimport -m mapfile -s -v vg_name
DESCRIPTION [Toc] [Back]
The vgimport command adds the specified volume group to the system.
The physical volumes, specified as pv_path ..., are scanned to obtain
the volume group information and logical volume information. This
command works much like vgcreate by requiring that the volume group
device directory and the group special file be created before the
command is executed (see vgcreate(1M)). The vg_name is added from the
/etc/lvmtab file, and the associated logical volume device files are
added to the system.
vgimport assumes that the volume group information has already been
created on the physical volumes.
This command is useful in conjunction with the vgexport command (see
vgexport(1M)), to move volume groups from one system to other systems
within a high availability cluster.
vgimport creates logical volume devices files under the vg_name
directory using the naming convention given in mapfile or using the
default naming convention used by the lvcreate command (see
lvcreate(1M)).
Sharable Option, Series 800 Only
In the second format of the command line shown in SYNOPSIS, the volume
group specified in the mapfile is shared.
vgimport does not activate the imported volume group due to the many
possible options at volume group activation time. To activate the
volume group once it has been successfully imported, use the vgchange
command (see vgchange(1M)).
Options and Arguments [Toc] [Back]
vgimport recognizes the following options and arguments:
pv_path The block device path names of a physical volume.
This argument is not used with the -s and related
options.
vg_name The path name of the volume group.
-m mapfile Specify the name of the file from which logical
volume names and numbers are to be read. This
Hewlett-Packard Company - 1 - HP-UX 11i Version 2: August 2003
vgimport(1M) vgimport(1M)
option is optional when used as in the first
command line format of the SYNOPSIS. If this
option is not specified, logical volume names are
created using the default naming convention lvolnn
where nn is the logical volume minor number. When
used with the -s option, the volume group
specified in the mapfile can be shared among the
exporting system and the importing systems.
-s Sharable option, Series 800 only. When the -s
option is specified, then the -p, -v, and -m
options must also be specified. The specified
mapfile is the same mapfile specified by using the
vgexport command also using the -p, -m, and -s
options. The mapfile is used to create the volume
groups on the importing systems.
-p Preview the actions to be taken but do not update
the /etc/lvmtab file or add the devices file.
This option is best used in conjunction with the
-v option.
-v Print verbose messages including names of the
logical volumes.
-f infile Import the set of pv_paths held in the infile into
the volume group. This option is used as an
alternative to specifying the pv_paths on the
command line. Each pv_path must appear on a new
line in the infile. This option may not be used
together with the -s option.
WARNINGS [Toc] [Back]
The following warnings should only apply to the -s option when
importing devices such as (NIKE) or disks with alternate path:
Since the -s option causes a search on the system for each disks with
the same vg_id. When vgimport reconstruct the newly imported volume
group entry in /etc/lvmtab file, the order of disks could be different
than it was before. And the following will happen:
The designated primary and alternate link might not be the same
as it was configured before.
Alternate links will be added to the importing volume group even
if they might not be configured in the volume group initially.
If the original primary path of a disks become an alternate path after
the newly imported volume group entry is created in /etc/lvmtab, the
order can be easily reverted by using vgreduce to remove the primary
path and then use vgextend to add the path back again.
Hewlett-Packard Company - 2 - HP-UX 11i Version 2: August 2003
vgimport(1M) vgimport(1M)
If additional alternate paths were added to the newly imported volume
group, use vgreduce to reduce any alternate paths that were added but
they were not needed.
ADDITIONAL WARNINGS [Toc] [Back]
Starting at 10.20, the vgimport command is supporting additional EMC
Symmetrix disk product functionality (see vgchgid(1M)). The vgimport
command will be enforcing a new rule such that the group of disks to
be imported must have the same EMC Symmetrix attributes. Clearly this
checking only applies if the disks involved in the operation are EMC
Symmetrix. Should the command find an incompatibility, a message of
the following type will be produced:
"Attempt to mix incompatible EMC Symmetrix disk types failed.
Physical volume /dev/dsk/cxtxdx is EMC BCV disk, but physical
volume /dev/dsk/cxtxdx is a standard disk. Please consult the
EMC Symmetrix documentation, if applicable".
If duplicate VGIDs (volume group id) were found in different types of
EMC Symmetrix disks during the vgimport -s operation, the above error
message will appear, and the command will fail. Please refer to
vgchgid(1M) on how to modify VGID on the EMC Symmetrix disk.
Note that EMC Symmetrix disks which do not have any of the additional
attributes can still be mixed with non-EMC disks in a single volume
group.
EXTERNAL INFLUENCES [Toc] [Back]
Environment Variables
LANG determines the language in which messages are displayed.
If LANG is not specified or is null, it defaults to "C" (see lang(5)).
If any internationalization variable contains an invalid setting, all
internationalization variables default to "C" (see environ(5)).
EXAMPLES [Toc] [Back]
Import the volume group /dev/vg01 that is located on physical disks
/dev/dsk/c0t1d0 and /dev/dsk/c0t3d0:
vgimport -v /dev/vg01 /dev/dsk/c0t1d0 /dev/dsk/c0t3d0
Activate the volume group following a successful import:
vgchange -a y vg01
Import the volume group /dev/vg01 using the mapfile, /tmp/vg01.mymap.
mymap was previously specified by the vgexport command on another
system. The volume group, /dev/vg01, is specified in mymap and will
be used by the importing system only:
Hewlett-Packard Company - 3 - HP-UX 11i Version 2: August 2003
vgimport(1M) vgimport(1M)
vgimport -v -m /tmp/vg01.mapfile /dev/vg01 \
/dev/dsk/c0t5d0 /dev/dsk/c0t7d0
Import the volume group /dev/vg02 using the mapfile, /tmp/vg02.mymap.
mymap was previously specified by the vgexport command on another
system. The volume group, /dev/vg02, is specified in mymap and will
be shared among the exporting system, this system, and other systems
importing the volume group as shared:
vgimport -v -s -m /tmp/vg02.mymap /dev/vg02
Import the volume group /dev/vg02 using the infile, /tmp/vg02.infile.
infile was previously specified by the vgexport command on another
system.
vgimport -v -f /tmp/vg02.infile /dev/vg02
SEE ALSO [Toc] [Back]
vgexport(1M), vgscan(1M).
Hewlett-Packard Company - 4 - HP-UX 11i Version 2: August 2003 [ Back ] |