All of lore.kernel.org
 help / color / mirror / Atom feed
* [linux-lvm] OS (Debian Sarge) reinstall led to my lvm partitions being marked 82 "Linux swap!"
@ 2004-04-21  5:29 Mike Roark
  2004-04-21 15:35 ` Patrick Caulfield
  0 siblings, 1 reply; 2+ messages in thread
From: Mike Roark @ 2004-04-21  5:29 UTC (permalink / raw)
  To: linux-lvm

Hello,
    After having a failing boot drive on my storage box, I reinstalled 
Debian sarge from scratch on a fresh drive. The box had two lvm (1.0) 
volumes with some PEs for one of them on the failing disk, and the rest 
on other disks. In the installer I tried to only have it partition the 
new /dev/hda, and thought I was successful. However, once I got it up 
and running and tried to get the second, still intact, lvm volume 
working, I discovered that the partition type on all the other drives 
had changed to Linux swap!

Here's a snippet of an fdisk -l on one of my partitions now:

                                Device Boot      Start         End      
Blocks   Id  System
/dev/ide/host0/bus1/target0/lun0/part1               1       24792   
199141708+  82  Linux swap


Here is what it looked like before the reinstall:

                                Device Boot      Start         End      
Blocks   Id  System
/dev/ide/host0/bus1/target0/lun0/part1               1       24792   
199141708+  8e  Linux LVM


Interestingly, pvdisplay seems to somehow be able to see that there is 
lvm information on the drive:

biotron:~# pvdisplay /dev/hdc1
--- Physical volume ---
PV Name               /dev/ide/host0/bus1/target0/lun0/part1
VG Name               group_B
PV Size               189.92 GB [398283417 secs] / NOT usable 32.19 MB 
[LVM: 151 KB]
PV#                   1
PV Status             NOT available
Allocatable           yes (but full)
Cur LV                1
PE Size (KByte)       32768
Total PE              6076
Free PE               0
Allocated PE          6076
PV UUID               6he4J4-lpim-BHJG-334y-41DJ-Jz1n-lfMGA1


However, none of the lvm *scan utilities will find it, including vgscan. 
I'm assuming this is because of the partition type.

I'd welcome any suggestions about  whether or not it might be possible 
to fix it. Even when the drive was failing I was still able to 
successfully mount the intact lvm volume with no problem. It was only 
after the reinstall of Sarge that I had problems getting to it.

I'm tempted to try changing the partition type using fdisk or cfdisk, 
but I'd like to be certain that it will only change the partition type 
and not touch anything else before I try it, so I'm appealing here first 
for any lvm-ish wisdom that you can offer.

Unfortunately, the data on those drives was actually very precious (not 
just mp3s and warez). The two lvm volumes were rsynced to each other and 
were on separate disks and this was providing a simple measure of 
redundancy, but the initial hard drive failure took out one volume 
because there were PEs on the failed drive for it, and now this has 
taken out the other, so I'm in dire straits.

                 Thanks for any help,
                         Mike Roark

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [linux-lvm] OS (Debian Sarge) reinstall led to my lvm partitions being marked 82 "Linux swap!"
  2004-04-21  5:29 [linux-lvm] OS (Debian Sarge) reinstall led to my lvm partitions being marked 82 "Linux swap!" Mike Roark
@ 2004-04-21 15:35 ` Patrick Caulfield
  0 siblings, 0 replies; 2+ messages in thread
From: Patrick Caulfield @ 2004-04-21 15:35 UTC (permalink / raw)
  To: LVM general discussion and development

On Wed, Apr 21, 2004 at 12:29:55AM -0500, Mike Roark wrote:
> 
> I'm tempted to try changing the partition type using fdisk or cfdisk, 
> but I'd like to be certain that it will only change the partition type 
> and not touch anything else before I try it, so I'm appealing here first 
> for any lvm-ish wisdom that you can offer.


Just changing the partition type is perfectly safe - provided you don't change
any other partition parameters! if the partition type is wrong then LVM1 will
fail to recognise the VGs so that sounds like it is your problem.


-- 

patrick

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2004-04-21 15:35 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-04-21  5:29 [linux-lvm] OS (Debian Sarge) reinstall led to my lvm partitions being marked 82 "Linux swap!" Mike Roark
2004-04-21 15:35 ` Patrick Caulfield

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.