LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 05-03-2015, 01:48 PM   #46
vpp
Member
 
Registered: Apr 2015
Posts: 62

Original Poster
Rep: Reputation: Disabled

Thanks guys! I need to save these instructions, really helpful!

First of all, here's the output pvscan:
PV /dev/sda2 VG VolGroup00 lvm2 [232.69 GB / 32.00 MB free]
Total: 1 [232.69 GB] / in use: 1 [232.69 GB] / in no VG: 0 [0 ]

For me this appears LVM does not see the big SATA in any way.

Secondly, to follow the instruction of using pvcreate, I need to find out the uuid of that big SATA at the time it was in LVM or right now?

And thirdly, I need to check the BIOS options for SATA disks. At least this one is easy for me!

Thanks, at least there is a little hope now!
 
Old 05-03-2015, 02:32 PM   #47
T3RM1NVT0R
Senior Member
 
Registered: Dec 2010
Location: Internet
Distribution: Linux Mint, SLES, CentOS, Red Hat
Posts: 2,385

Rep: Reputation: 477Reputation: 477Reputation: 477Reputation: 477Reputation: 477
Quote:
For me this appears LVM does not see the big SATA in any way.
It saw the first time right? You mentioned that you moved that data to big SATA disk and that is what you are trying to recover. I am not sure what you mean by this?

Quote:
Secondly, to follow the instruction of using pvcreate, I need to find out the uuid of that big SATA at the time it was in LVM or right now?
I think this is the UUID for your big SATA disk:

Code:
pv1 {
id = "sb4SLy-laOq-JGaX-zctr-mtkJ-9Zfb-23gPUB"
device = "/dev/sda1" # Hint only
And thirdly, I need to check the BIOS options for SATA disks. At least this one is easy for me!

You are on your own here
 
Old 05-03-2015, 03:03 PM   #48
vpp
Member
 
Registered: Apr 2015
Posts: 62

Original Poster
Rep: Reputation: Disabled
I thought pvscan would mention the SATA disk, if it sees it. But of course, since it has been removed, why should the command mention it. It is just that I am not too familiar with these commands.

Ok, can I see the current uuid with some command?

I checked the BIOS and there two settings I am not sure...
"Extended IDE drive [Auto]"
"Access Mode [Auto]"

These are current settings. The other option is "Disabled".
 
Old 05-03-2015, 03:17 PM   #49
rknichols
Senior Member
 
Registered: Aug 2009
Distribution: CentOS
Posts: 4,716

Rep: Reputation: 2192Reputation: 2192Reputation: 2192Reputation: 2192Reputation: 2192Reputation: 2192Reputation: 2192Reputation: 2192Reputation: 2192Reputation: 2192Reputation: 2192
The UUID (which is the same as I posted in my instructions) comes from the archived VolGroup00 metadata that you posted (Thank you for that, BTW.) back in #10.

The partition does not currently have a UUID, since the PV header was wiped by pvremove. That is why you have to identify the device (very carefully) by its /dev/xxxx name. The UUID is just to tell pvcreate which entry to use from that metadata.

The BIOS settings in question would be for SATA ports. If those are on an add-on card rather than on the motherboard, then you would have to find out how to access the settings for that card.

Last edited by rknichols; 05-03-2015 at 03:22 PM.
 
Old 05-03-2015, 04:32 PM   #50
vpp
Member
 
Registered: Apr 2015
Posts: 62

Original Poster
Rep: Reputation: Disabled
Thanks! Splendid information! I was glad to find this after a relaxing stay in my sauna...

I suppose I have to arrange everything so that the device name would be the same as in that LVM config file in question?

How about when and if this pvcreate command succeeds, what is the next step to get the disk visible?

I went through all BIOS menus, but I didn't find anything else related to SATA interfaces.
 
Old 05-03-2015, 04:46 PM   #51
rknichols
Senior Member
 
Registered: Aug 2009
Distribution: CentOS
Posts: 4,716

Rep: Reputation: 2192Reputation: 2192Reputation: 2192Reputation: 2192Reputation: 2192Reputation: 2192Reputation: 2192Reputation: 2192Reputation: 2192Reputation: 2192Reputation: 2192
Quote:
Originally Posted by vpp View Post
I suppose I have to arrange everything so that the device name would be the same as in that LVM config file in question?
It doesn't matter, but you do have to use the current device in place of that red "{X}" in my instructions (along with the correct path to the archive file, of course). Whatever device you specify is going to get a PV header written to it, so be sure it's right. You will get a warning that the device does not currently have a PV header. Of course not -- you wiped it. Enter the requested uppercase "YES" at that prompt.
Quote:
How about when and if this pvcreate command succeeds, what is the next step to get the disk visible?
The next step would be the vgcfgrestore command that I gave:
Code:
vgcfgrestore --file /path/to/the/archive/file VolGroup00
The correct path to the archive file is the only thing you need to supply there.
 
1 members found this post helpful.
Old 05-03-2015, 04:50 PM   #52
vpp
Member
 
Registered: Apr 2015
Posts: 62

Original Poster
Rep: Reputation: Disabled
Superb!
Then I can try those commands right away!
 
Old 05-03-2015, 05:02 PM   #53
T3RM1NVT0R
Senior Member
 
Registered: Dec 2010
Location: Internet
Distribution: Linux Mint, SLES, CentOS, Red Hat
Posts: 2,385

Rep: Reputation: 477Reputation: 477Reputation: 477Reputation: 477Reputation: 477
Just to add, after running vgcfgrestore the lv will be in inactive state, you should run:

Code:
vgchange -ay VolGroup00
Once done check the output of lvs and mount the lv.

This is based on the testing I did yesterday.
 
1 members found this post helpful.
Old 05-03-2015, 05:09 PM   #54
vpp
Member
 
Registered: Apr 2015
Posts: 62

Original Poster
Rep: Reputation: Disabled
I am thrilled! Thanks guys!
Everything has worked so far!!

lvs shows now:
LV VG Attr LSize Origin Snap Move Log Copy% Convert
LogVol00 VolGroup00 -wi-ao 229.69G
LogVol01 VolGroup00 -wi-ao 2.97G
LogVol02 VolGroup00 -wi-a- 1.82T

Currently, the size of the volume is 82.3GB and nothing is visible. How to mount the LV?
 
Old 05-03-2015, 05:13 PM   #55
T3RM1NVT0R
Senior Member
 
Registered: Dec 2010
Location: Internet
Distribution: Linux Mint, SLES, CentOS, Red Hat
Posts: 2,385

Rep: Reputation: 477Reputation: 477Reputation: 477Reputation: 477Reputation: 477
Create new directory (just to make sure that you don't mount it on a directory containing stuff).

Code:
mkdir /newdisk
Code:
mount /dev/mapper/VolGroup00-LogVol02 /newdisk
 
1 members found this post helpful.
Old 05-03-2015, 05:20 PM   #56
vpp
Member
 
Registered: Apr 2015
Posts: 62

Original Poster
Rep: Reputation: Disabled
Due to my OS version, I need to supply also the file system type. Is it LVM specific in this case or ext3 as I remember having it?
 
Old 05-03-2015, 05:24 PM   #57
T3RM1NVT0R
Senior Member
 
Registered: Dec 2010
Location: Internet
Distribution: Linux Mint, SLES, CentOS, Red Hat
Posts: 2,385

Rep: Reputation: 477Reputation: 477Reputation: 477Reputation: 477Reputation: 477
If at the time of creating lv you have used ext3 then that is what you have to use. Command will look something like:

Code:
mount -t ext3 /dev/mapper/VolGroup00-LogVol02 /newdisk
 
Old 05-03-2015, 05:30 PM   #58
vpp
Member
 
Registered: Apr 2015
Posts: 62

Original Poster
Rep: Reputation: Disabled
Ok, now I again bumped against that same old issue of not being able to mount that disk:
mount: wrong fs type, bad option, bad superblock on /dev/mapper/VolGroup00-LogVol02,
missing codepage or helper program, or other error
In some cases useful info is found in syslog - try
dmesg | tail or so

dmesg says:
VFS: Can't find ext3 filesystem on dev dm-2.

As if the disk has anyway been written over in some phase...
 
Old 05-03-2015, 05:44 PM   #59
vpp
Member
 
Registered: Apr 2015
Posts: 62

Original Poster
Rep: Reputation: Disabled
Interestingly, pvscan already knows this:
PV /dev/sda2 VG VolGroup00 lvm2 [232.69 GB / 0 free]
PV /dev/sdb1 VG VolGroup00 lvm2 [1.82 TB / 0 free]
Total: 2 [2.05 TB] / in use: 2 [2.05 TB] / in no VG: 0 [0 ]

The old directory I used for this disk shows the initial volume size 82.3GB. Somehow I feel I am so close...
 
Old 05-03-2015, 05:49 PM   #60
T3RM1NVT0R
Senior Member
 
Registered: Dec 2010
Location: Internet
Distribution: Linux Mint, SLES, CentOS, Red Hat
Posts: 2,385

Rep: Reputation: 477Reputation: 477Reputation: 477Reputation: 477Reputation: 477
Check the filesystem on the lv using:

Code:
blkid /dev/mapper/VolGroup00-LogVol02
 
  


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
LVM issue circus78 Linux - Server 5 12-12-2014 01:32 AM
LVM issue call_krushna Linux - Virtualization and Cloud 0 10-30-2012 10:58 AM
LVM issue AndyD236 Linux - General 2 11-24-2009 07:26 AM
LVM Issue bondoq Linux - General 8 05-12-2009 09:35 AM
LVM issue pauloco Linux - Hardware 1 11-14-2006 11:13 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 04:10 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
Open Source Consulting | Domain Registration