[libvirt-users] Renaming a LVM LV (where is vol-edit??)

Hello, I'm using a LVM storage pool. I renamed a guest and I would like to change the LV name to match to avoid future confusion. How do i do this? There is no vol-edit command (fully updated RHEL6). Thanks, Dax Kelson

On 05/22/2012 04:04 PM, Dax Kelson wrote:
Hello,
I'm using a LVM storage pool. I renamed a guest and I would like to change the LV name to match to avoid future confusion.
How do i do this? There is no vol-edit command (fully updated RHEL6).
I agree that 'vol-edit' (or even a subset 'vol-rename') would be nice, but someone has to code it up. Meanwhile, you can use 'vol-create-from' or 'vol-clone' to create a new volume based on the old one with identical contents but the new name, then delete the old one; but this is obviously storage-intensive compared to just renaming things. Your short-term workaround may unfortunately be limited to doing things manually with lvm commands. -- Eric Blake eblake@redhat.com +1-919-301-3266 Libvirt virtualization library http://libvirt.org

On Tue, May 22, 2012 at 4:09 PM, Eric Blake <eblake@redhat.com> wrote:
Your short-term workaround may unfortunately be limited to doing things manually with lvm commands.
To help others, this is the procedure I used: 1. Stop guest 2. lvrename <VGname> <LVoldname> <LVnewname> 3. virsh pool-refresh <PoolName> 4. virsh edit guestname (LVoldname -> LVnewname) 5. Start guest Thanks to Eric Blake for the pool-refresh tip. Dax Kelson Guru Labs
participants (2)
-
Dax Kelson
-
Eric Blake