<html><head></head><body><div dir="auto">I'd start with a vgscan and an lvscan before trying anything crazy.<br><br>VG names must be unique on a  system. That's always important to remember.<br></div><br><br><div class="gmail_quote"><div dir="auto">On June 20, 2024 12:40:00 PM EDT, Phil Turmel via Ale <ale@ale.org> wrote:</div><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
<pre class="k9mail"><div dir="auto">Probably.<br><br>Copies of the LVM metadata that you find in /etc/ also get written to part of the PV, near the beginning.  If you hex dump the first several megabytes you should find it.<br><br>( I've recovered from similar boo-boos this way.  You may find the offset for that backup documented somewhere. )<br><br>On 6/19/24 20:59, David Jackson via Ale wrote:<br></div><blockquote class="gmail_quote" style="margin: 0pt 0pt 1ex 0.8ex; border-left: 1px solid #729fcf; padding-left: 1ex;"><div dir="auto">The subject says it.  I was installing a new drive and installing a fresh<br>OS onto the new drive, then transporting the old files over to the new<br>drive and OS (ie, /home/dsj)<br><br>I had booted from an archlinux ISO, was doing a manual partition.  But then<br>I made a boo boo with the new Logical Volume Group and wanted to blow it<br>away to start over.<br><br>My new system was on nvme1n1 and I blew away the PV and LV info for nvme0n1<br>which contained the PV/LV  info for all my previous data.  Very sad senior<br>moment!<br><br>Now, since I booted from an arch ISO usb stick, the /etc/lvm/archive files<br>were in volatile memory, so I don't have a copy of them.  When I load up my<br>new system, which I eventually installed just fine (I'm writing this email<br>from that system), everything works great.  But I'd like to recover the old<br>system (that's probably still on nvme0n1 in the second partition, When I<br>boot from the new system on nvme1n1, I can look in /dev/disk/by-uuid/ and<br>see the old PV for nvme0n1 uuid I think:<br>2f1aede8-a033-4ec4-8c9f-290d7a7c3458<br><br>But there's no record for LVs or PVs on nvme0n1 anywhere in<br>/etc/lvm/archive.<br><br>Also, whenever I install Arch, I use a script that auto creates the same PV<br>and LV specs on the target drive.  The partition sizes won't have changed.<br><br>(Pretty much all the googling I've read assumes that a /etc/lvm/archive/<br>filename.vg exists somewhere. )<br><br>Is there any way I can restore the PV/LVG info on nvme0n1 with what I have<br>available?  Without the archive file?<br><br>Thanks!<br><br>Dave<br></div></blockquote><div dir="auto"><hr>Ale mailing list<br>Ale@ale.org<br><a href="https://mail.ale.org/mailman/listinfo/ale">https://mail.ale.org/mailman/listinfo/ale</a><br>See JOBS, ANNOUNCE and SCHOOLS lists at<br><a href="http://mail.ale.org/mailman/listinfo">http://mail.ale.org/mailman/listinfo</a><br></div></pre></blockquote></div></body></html>