Simpler Navigation for Servers and Operating Systems
Completed: a much simpler Servers and Operating Systems section of the Community. We combined many of the older boards, so you won't have to click through so many levels to get at the information you need. Check the consolidated boards here as many sub-forums are now single boards.
Operating System - Tru64 Unix
Showing results for 
Search instead for 
Did you mean: 

How can i delete a volume group ?

Super Advisor

How can i delete a volume group ?

Hi ... i'm new on this .... i'd like to know who to delete a LVM ...
I know right now this commands for creating a LVM .. but .. how can i delete:
- a filesystem
- a logical volume
- a volume group

# Prepare the disk for LVM
pvcreate /dev/rdsk/c0t0d0
# Create the volume group
mkdir /dev/vgnn
mknod /dev/vgnn/group c 64 0xnn0000
vgcreate /dev/vgnn /dev/dsk/c0t0d0
# Create the logical volume
lvcreate -n lvol1 /dev/vg01
# Create the file system in the LV
mkfs -F vxfs /dev/vg01/lvol1
#sapdata9 /oracle/SP1/sapdata9


Ivan Ferreira
Honored Contributor

Re: How can i delete a volume group ?

To delete you need to:

- umount the filesystem:
umount /mount_point
- Youd don't need to delete previously the file system, just remove the logical volume:
lvremove /dev/vg01/lvol1
- Remove the volume group
vgremove /dev/vg01

Thats all.
Por que hacerlo dificil si es posible hacerlo facil? - Why do it the hard way, when you can do it the easy way?
Hein van den Heuvel
Honored Contributor

Re: How can i delete a volume group ?

The commands posted for create are HPUX commands. The question is posted in the Tru64 forum. Manuales has been posting question for both. Which one is it this time?
My guess is hpux.
In either case... RTFM!
Read The Fine (F&*^ing :-) Man pages.