LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 02-17-2014, 01:04 AM   #1
thomasArthur
LQ Newbie
 
Registered: Feb 2014
Posts: 5

Rep: Reputation: 0
How do I get rid of a messed up LVM Hard Drive


Hi
I am Running ProxMox Ver 3.1 which runs on a minimal Debian Linux.
I wanted to add an other Hard drive to allow for backups. So onto the web and start reading, following the instructions, BUT I think somewhere between morning tea and the midnight snack, I goofed, I think on a couple of my back tracks I made a mess.
The drive I added is 1 TB SATA. but looking at trying to mount the LVM folder, which I thought was the whole drive, I either get access to 10GB or 100GB. When I try to delete, and start again It comes back and says I cannot remove the LVM because it is mounted, and when I try to unmount it says does not recognise the path.
I know I can just blow the whole lot away, including ProxMox and start again, but I would love to know what I have done.
Thanks
Tom
 
Old 02-17-2014, 01:08 AM   #2
chrism01
LQ Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Centos 6.8, Centos 5.10
Posts: 17,240

Rep: Reputation: 2324Reputation: 2324Reputation: 2324Reputation: 2324Reputation: 2324Reputation: 2324Reputation: 2324Reputation: 2324Reputation: 2324Reputation: 2324Reputation: 2324
Try the following cmds
Code:
lsblk

blkid

pvscan

vgscan

lvscan
That little lot should get you started
 
Old 02-17-2014, 01:47 AM   #3
thomasArthur
LQ Newbie
 
Registered: Feb 2014
Posts: 5

Original Poster
Rep: Reputation: 0
Hi Chris
Dropping you a quick thanks, Now I have it un mounted I should be able to get back to square one.
Thanks again.
Tom
 
Old 02-17-2014, 04:14 AM   #4
chrism01
LQ Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Centos 6.8, Centos 5.10
Posts: 17,240

Rep: Reputation: 2324Reputation: 2324Reputation: 2324Reputation: 2324Reputation: 2324Reputation: 2324Reputation: 2324Reputation: 2324Reputation: 2324Reputation: 2324Reputation: 2324
no worries
 
Old 02-17-2014, 11:15 PM   #5
thomasArthur
LQ Newbie
 
Registered: Feb 2014
Posts: 5

Original Poster
Rep: Reputation: 0
Hi Chris
Not sure if I continue here or start another thread.
I'm at the point now having recreated the LVM.
On PVscan it sees the VG "Back"
Only the volumes on the c0d0 drive show on lvscan
I get info on "Back" using vgdisplay.
I need to create a folder in "Back" using the complete drive.
Too many years with Windows and Dos????????
With reading till my eyes fallout. I cannot work out how to do this..
And I then need to mount it so I have access to the drive through ProxMox.
Screen captur below.....=====
Help
Tom
=================================================================
root@proxmox:~# lsblk
NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT
cciss!c0d0 104:0 0 931.5G 0 disk
├─cciss!c0d0p1 104:1 0 511M 0 part
└─cciss!c0d0p2 104:2 0 931G 0 part
├─pve-root (dm-0) 253:0 0 96G 0 lvm /
├─pve-swap (dm-2) 253:2 0 5G 0 lvm [SWAP]
└─pve-data (dm-3) 253:3 0 814G 0 lvm /var/lib/vz
cciss!c0d1 104:16 0 931.5G 0 disk
└─cciss!c0d1p1 104:17 0 931.5G 0 part
sr0 11:0 1 1024M 0 rom
root@proxmox:~# blkid
/dev/cciss/c0d0p1: UUID="87d40832-a64b-4886-8aa5-9ef7c75e2201" TYPE="ext3"
/dev/cciss/c0d0p2: UUID="RQ4TJ6-1v0W-VoqR-P3D9-rKmT-CwEn-7xzeHm" TYPE="LVM2_member"
/dev/cciss/c0d1p1: UUID="DP3gGo-9CcJ-dod5-rgjq-FluL-QaBi-sU00fZ" TYPE="LVM2_member"
/dev/mapper/pve-root: UUID="ff95ef22-b634-4f8d-92e3-66cf4eebcaa3" TYPE="ext3"
/dev/mapper/pve-swap: UUID="4c11b601-49db-469e-849e-0d54b39a90bb" TYPE="swap"
/dev/mapper/pve-data: UUID="f3ad8c2b-75c4-493d-8822-f7bf9a69dccd" TYPE="ext3"
root@proxmox:~# pvscan
PV /dev/cciss/c0d1p1 VG Back lvm2 [931.48 GiB / 931.48 GiB free]
PV /dev/cciss/c0d0p2 VG pve lvm2 [930.98 GiB / 16.00 GiB free]
Total: 2 [1.82 TiB] / in use: 2 [1.82 TiB] / in no VG: 0 [0 ]
root@proxmox:~# vgscan
Reading all physical volumes. This may take a while...
Found volume group "Back" using metadata type lvm2
Found volume group "pve" using metadata type lvm2
root@proxmox:~# lvscan
ACTIVE '/dev/pve/swap' [5.00 GiB] inherit
ACTIVE '/dev/pve/root' [96.00 GiB] inherit
ACTIVE '/dev/pve/data' [813.98 GiB] inherit
root@proxmox:~# vgdisplay Back -v
Using volume group(s) on command line
Finding volume group "Back"
--- Volume group ---
VG Name Back
System ID
Format lvm2
Metadata Areas 1
Metadata Sequence No 1
VG Access read/write
VG Status resizable
MAX LV 0
Cur LV 0
Open LV 0
Max PV 0
Cur PV 1
Act PV 1
VG Size 931.48 GiB
PE Size 4.00 MiB
Total PE 238458
Alloc PE / Size 0 / 0
Free PE / Size 238458 / 931.48 GiB
VG UUID Ok1Rej-JyZe-dC3S-yiID-Yror-ZVi2-FirRnQ

--- Physical volumes ---
PV Name /dev/cciss/c0d1p1
PV UUID DP3gGo-9CcJ-dod5-rgjq-FluL-QaBi-sU00fZ
PV Status allocatable
Total PE / Free PE 238458 / 238458

root@proxmox:~#
========================================================================

Last edited by thomasArthur; 02-17-2014 at 11:16 PM. Reason: Adding Screen shots.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Would you use old exteral hard drive or get rid of it, if it have virus? bobacker Linux - Newbie 17 01-09-2012 06:58 PM
[SOLVED] messed up hard drive with dd command Xombie216 Linux - Newbie 6 07-28-2011 12:26 PM
hard drive messed up with dd eddygrinder Slackware 8 03-10-2009 07:51 PM
Getting Rid Of Hard Drive? carlosinfl Linux - Hardware 20 01-17-2007 12:31 PM
Hard Drive Messed Up!! ricky333 Linux - Hardware 5 08-12-2005 11:31 PM


All times are GMT -5. The time now is 11:47 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration