- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: How to Remove a Disk
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-30-2008 09:55 PM
08-30-2008 09:55 PM
i have rp8420 server,
How can I remove the disk "cxdxtx" to become unused?
and then remove the logical volume and then the volume group
thanks
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-30-2008 10:04 PM
08-30-2008 10:04 PM
Re: How to Remove a Disk
To remove a disk you need to make sure disk should not contain any data.
Means that all data should move to other set of disks if there are multiple disks in the VG or if you dont require to save data you can simply proceed to remove disk..
you will be needing some set of commands:
pvmove ----to move data to other disks(PVs)
lvremove if logical vol is to be removed
vgreduce ::: to remove disk from VG with other disks
IF there is a single disk in VG and you want to clean it up (provided no data to be backup) then
you can run vgexport volume group(Be careful while you run it in production env)
Go through man pages of above commands to know more.
Also provide complete detail in case you need command syntax also.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-30-2008 11:24 PM
08-30-2008 11:24 PM
Solutionhere i m providing some guideline. you decide according to your setup.
1)First move the data from one disk to another disk.
For eg.here we r moving the data c0t0d0 to c1t0d0
pvmove /dev/dsk/c0t0d0 /dev/dsk/c1t0d0
============================================
2) How to remove a Logical Volume
Note: the following example is using the volume group vg01 and the
logical volume lvhp
1) Backup all user data
2) Umount the filesystem
umount /home
3) remove the Logical volume
lvremove /dev/vg01/lvhp
==============================================================
3) How to remove a disk from a volume group
Note: the following example is using the disk c1t6d0 and the
volume group vg01
1) Make sure that the disk is not in use:
pvdisplay /dev/dsk/c1t6d0
Look at line starting with Allocated PE the number at the end
of the line should be 0. If it is not the disk is still in use.
2) Remove the disk
vgreduce /dev/vg01 /dev/dsk/c1t6d0
========================================================================
If you are using single pv in VG then u can export it to remove from vg.But it should be deactivate first.
#vgchange -a n vgname
#vgexport vgname
============================================================================
but u should rmember one thing when u r using the same PV for another VG then you
should use the -f option while creating the pv.
#pvcreate -f /dev/rdsk/c1t6d0
==========================================================================
while doing such type of activity u should take the backup first. Also go to man pages of every command. Dont do the blindley anything without understanding.Pls revert back if u have any doubts.
Regards
Prashant
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-30-2008 11:42 PM
08-30-2008 11:42 PM
Re: How to Remove a Disk
Backup the data
copy /etc/lvmtab
unmount filesystems
-umount /xxxxx
lvremove LVs
- lvremove /dev/vgxx/lvolxx
vgreduce (if there are more than one disk in the VG and you want to remove one by one)
-vgreduce /dev/vgxx /dev/dsk/cXtXdX
If the VG contains only one disk. Then you can use vgremove direclty on the VG after removing all the LVs.
-vgremove /dev/vgxx
(After that, tou can also use pvremove to remove LVM data structure from the disk
-pvremove /dev/rdsk/cXtXdX
check man pvremove). It can also be achived by pvcreate -f also.
Regards.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-30-2008 11:48 PM
08-30-2008 11:48 PM
Re: How to Remove a Disk
and very thanks But the disk i you want to remove, Contains data but i don't needed.
Any difference in this case.
thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-30-2008 11:50 PM
08-30-2008 11:50 PM
Re: How to Remove a Disk
pvmove source-disk destination-disk
And if you dont need data on that disk.
Then you can perform below tasks.
lvremove lvname vgname
vgreduce vgname disk name
vgremove vgname
pvremove diskname
Thanks
SKR
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-30-2008 11:51 PM
08-30-2008 11:51 PM
Re: How to Remove a Disk
Just go ahead and be very cautious when you type the device name of the disk. Make sure you use the correct device name.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-30-2008 11:53 PM
08-30-2008 11:53 PM
Re: How to Remove a Disk
If you do not want the data - typo
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-31-2008 12:08 AM
08-31-2008 12:08 AM