10-18-2008
Well yes you can!!! Follow the below and that's it to change vg and lv as well..
Export the VG:
1. # umount /oldmountpoint
2. # vgchange –a n vgname
3. # vgexport –s –v –m /etc/lvmconf/vgname.map vgname
Rename the VG directory, edit LV names, and re-import:
1. # mkdir /dev/newvgname
2. # mknod /dev/newvgname/group c 64 0x010000 (Minor number example. Please ensure that it's unique)
3. # cp /etc/lvmconf/vgname.map /etc/lvmconf/newvgname.map
=>If you want to change your logical volume names, simply use the vi editor to modify the names in the map file.
4. # vi /etc/lvmconf/newvgname.map
VGID 0a0a0a0a0
1 newlvname
5. # vgimport –s –v –m /etc/lvmconf/newvgname.map newvgname
6. # vgchange –a y newvgname
7. # vgcfgbackup newvgname
8. # mv /oldmountpoint /newmountpoint
9. # vi /etc/fstab => add entry
10. # mount -a
-You're done!
Please let us know if you find any issues!
-DB
10 More Discussions You Might Find Interesting
1. News, Links, Events and Announcements
I had just updated - reinstalled - my RH9 to a Fedore Core 3.
I did not know about the Logical volumes that automatically combined partitions on drive 1 and 2 into one mounted volume. In my attempts to do something with the hdb2 partition - not knowing that it was already in use - I killed my... (2 Replies)
Discussion started by: gezi
2 Replies
2. UNIX for Advanced & Expert Users
Hello,
I have logical volume group of 50GB, in which I have 2 logical volumes, LogVol01 and LogVol02, both are of 10GB.
If I extend LogVol01 further by 10GB, then it keeps the extended copy after logical volume 2. I want to know where it keeps this information
Regards
Himanshu (3 Replies)
Discussion started by: ghimanshu
3 Replies
3. AIX
Does anyone have any simple methods for moving a current logical volume from one volume group to another? I do not wish to move the data from one physical volume to another. Basically, I want to "relink" the logical volume to exist in a different volume group. Any ideas? (2 Replies)
Discussion started by: krisw
2 Replies
4. AIX
Hi!
Can anyone help me on how I can do a basic check on the Unix filesystems / physical volumes and logical volumes?
What items should I check, like where do I look at in smit? Or are there commands that I should execute?
I need to do this as I was informed by IBM that there seems to be... (1 Reply)
Discussion started by: chipahoys
1 Replies
5. HP-UX
Hi,
Someone please help me with how i can unmount and remove all the files systems from a cluster. This is being shared by two servers that are active_standby. (3 Replies)
Discussion started by: joeli
3 Replies
6. AIX
Hello,
I am a french computer technician, and i speak English just a little.
On Aix 5.3, I encounter a name conflict logical volume on two volume group.
The first volume lvnode01 is OK in rootvg and mounted. It is also consistent in the ODM
root # lsvg -l rootvg |grep lvnode01 ... (10 Replies)
Discussion started by: dantares
10 Replies
7. UNIX for Dummies Questions & Answers
Hi,
I am new to unix. I am working on Red Hat Linux and side by side on AIX also. After reading the concepts of Storage, I am now really confused regarding the terminologies
1)Physical Volume
2)Volume Group
3)Logical Volume
4)Physical Partition
Please help me to understand these concepts. (6 Replies)
Discussion started by: kashifsd17
6 Replies
8. UNIX for Dummies Questions & Answers
hi,
I want to create a volume group of 200 GB and then create different file systems on that.
please help me out. Its becomes confusing when the PP calculating PP.
I don't understand this concept. (2 Replies)
Discussion started by: kamaldev
2 Replies
9. Ubuntu
Hello,
I'm running Ubuntu 12.04. I need to rename my root logical volume group and it's bootmanager/fstab accordingly.
Here is the output: I need to change the HP-TEST001 to PRODGROUP01. Please advice me.
root@PROD-02:/home# vgdisplay
--- Volume group ---
VG Name HP-TEST001
System ID... (2 Replies)
Discussion started by: moneynut
2 Replies
10. Red Hat
Hello Guys,
I want to create a file system dedicated for an application installation. But there is no space in volume group to create a new logical volume. There is enough space in other logical volume which is being mounted on /var.
I know we can use that logical volume and create a virtual... (2 Replies)
Discussion started by: vamshigvk475
2 Replies
LEARN ABOUT REDHAT
vgchange
VGCHANGE(8) System Manager's Manual VGCHANGE(8)
NAME
vgchange - change attributes of a volume group
SYNOPSIS
vgchange [-A|--autobackup {y|n}] [-a|--available {y|n}] [-d|--debug] [-h|--help] [-l|--logicalvolume MaxLogicalVolumes] [-v|--verbose]
[--version] [-x|--allocation {y|n}] [VolumeGroupName...]
DESCRIPTION
vgchange allows you to change the attributes of one or more volume groups. Its main purpose is to activate and deactivate VolumeGroupName,
or all volume groups if none is specified. Only active volume groups are subject to changes and allow access to their logical volumes.
During volume group activation, if vgchange recognizes snapshot logical volumes which were dropped because they ran out of space, it dis-
plays a message informing the administrator that such snapshots should be removed (see lvremove(8)).
OPTIONS
-A, --autobackup{y|n}
Controls automatic backup of metadata after the change. See vgcfgbackup (8). Default is yes.
-a, --available{y|n}
Controls the availability of the volume group for input/output. In other words: makes a volume group known/unknown to the kernel.
-d, --debug
Enables additional debugging output (if compiled with DEBUG).
-h, --help
Print a usage message on standard output and exit successfully.
-l, --logicalvolume MaxLogicalVolumes
Changes the maximum logical volume number of an existing inactive volume group.
-v, --verbose
Displays verbose runtime information about vgchange's activities.
--version
Displays tool and IOP version and exit successfully.
-x, --allocation{y|n}
Enables or disables the extension/reduction of this volume group with/by physical volumes.
EXAMPLES
To activate all known volume groups in the system:
vgchange -a y
To change the maximum number of logical volumes of inactive volume group vg00 to 128.
vgchange -l 128 /dev/vg00
DIAGNOSTICS
vgchange returns an exit code of 0 for success and > 0 for error:
1 error writing VGDA to physical volume(s)
2 error changing extensibility of volume group
3 error doing backup of VGDA
4 extension of MaxLogicalVolume would cause overlapped physical extents
5 error backup of volume group metadata
6 error copying volume group metadata to work file
7 error creating volume group directory and special files
8 error removing volume group directory and special files
95 driver/module not in kernel
96 invalid I/O protocol version
97 error locking logical volume manager
98 invalid lvmtab (run vgscan(8))
99 invalid command line
If volume groups can't be activated, run vgscan(8) and retry.
ENVIRONMENT VARIABLES
LVM_AUTOBACKUP
If this variable is set to "no" then the automatic backup of VG metadata is turned off.
LVM_VG_MAX_BACKUPS
This variable determines the backup history depth of kept VGDA copy files in /etc/lvmconf. It can be set to a positive number
between 0 and 999. The higher this number is, the more changes you can restore using vgcfgrestore(8).
SEE ALSO
lvm(8), vgcreate(8)
AUTHOR
Heinz Mauelshagen <Linux-LVM@Sistina.com>
Heinz Mauelshagen LVM TOOLS VGCHANGE(8)