Fedora Linux Support Community & Resources Center
  #1  
Old 9th May 2008, 03:19 PM
daviddoria Offline
Registered User
 
Join Date: Oct 2007
Posts: 884
mount lvm from rescue?

I booted to rescue mode of the install cd. Then I ran
lvm vgscan

and it tells me "Reading all physical volumes. This may take a while..."

And goes back to a prompt without telling me anything. To make sure it didn't find anything i ran
lvm vgdisplay

and indeed nothing was displayed.

How can I mount my drive so I can get the data off??

Thanks!

Dave
Reply With Quote
  #2  
Old 9th May 2008, 05:05 PM
surkum Offline
Registered User
 
Join Date: Nov 2005
Posts: 57
Give try to a fedora live cd, It comes with system-config-lvm.
__________________
--
There are 10 kind of people around,
the ones who understand binary and the others.
Reply With Quote
  #3  
Old 9th May 2008, 05:33 PM
enter77 Offline
Registered User
 
Join Date: May 2008
Posts: 7
Try a
Code:
vgchange -a y [group name]
to activate the volume group first.
Reply With Quote
  #4  
Old 9th May 2008, 05:36 PM
daviddoria Offline
Registered User
 
Join Date: Oct 2007
Posts: 884
so assuming I didn't know it was called VolGrouop00 - which command would I have run to "see" it before trying to activate it with vgchange -a
Reply With Quote
  #5  
Old 9th May 2008, 05:56 PM
brunson Offline
Registered User
 
Join Date: Jun 2005
Location: Westminster, Colorado
Posts: 2,306
Code:
ebrunsonlx(~)$ sudo lvs
Password:
  LV       VG         Attr   LSize  Origin Snap%  Move Log Copy% 
  LogVol00 VolGroup00 -wi-ao 35.28G                              
  LogVol01 VolGroup00 -wi-ao  1.94G
For a brief summary of the commands available you can do this:
Code:
ebrunsonlx(~)$ lvm
lvm> help
  Available lvm commands:
  Use 'lvm help <command>' for more information
   
  dumpconfig      Dump active configuration
  formats         List available metadata formats
  help            Display help for commands
  lvchange        Change the attributes of logical volume(s)
  lvconvert       Change logical volume layout
  lvcreate        Create a logical volume
  lvdisplay       Display information about a logical volume
  lvextend        Add space to a logical volume
  lvmchange       With the device mapper, this is obsolete and does nothing.
  lvmdiskscan     List devices that may be used as physical volumes
  lvmsadc         Collect activity data
  lvmsar          Create activity report
  lvreduce        Reduce the size of a logical volume
  lvremove        Remove logical volume(s) from the system
  lvrename        Rename a logical volume
  lvresize        Resize a logical volume
  lvs             Display information about logical volumes
  lvscan          List all logical volumes in all volume groups
  pvchange        Change attributes of physical volume(s)
  pvresize        Resize physical volume(s)
  pvck            Check the consistency of physical volume(s)
  pvcreate        Initialize physical volume(s) for use by LVM
  pvdata          Display the on-disk metadata for physical volume(s)
  pvdisplay       Display various attributes of physical volume(s)
  pvmove          Move extents from one physical volume to another
  pvremove        Remove LVM label(s) from physical volume(s)
  pvs             Display information about physical volumes
  pvscan          List all physical volumes
  segtypes        List available segment types
  vgcfgbackup     Backup volume group configuration(s)
  vgcfgrestore    Restore volume group configuration
  vgchange        Change volume group attributes
  vgck            Check the consistency of volume group(s)
  vgconvert       Change volume group metadata format
  vgcreate        Create a volume group
  vgdisplay       Display volume group information
  vgexport        Unregister volume group(s) from the system
  vgextend        Add physical volumes to a volume group
  vgimport        Register exported volume group with system
  vgmerge         Merge volume groups
  vgmknodes       Create the special files for volume group devices in /dev
  vgreduce        Remove physical volume(s) from a volume group
  vgremove        Remove volume group(s)
  vgrename        Rename a volume group
  vgs             Display information about volume groups
  vgscan          Search for all volume groups
  vgsplit         Move physical volumes into a new volume group
  version         Display software and driver version information
__________________
Registered Linux User #4837
411th in line to get sued by Micro$oft
Quote:
Basically, to learn Unix you learn to understand and apply a small set of key ideas and achieve expertise by expanding both the set of ideas and your ability to apply them - Paul Murphy
Reply With Quote
  #6  
Old 9th May 2008, 07:23 PM
surkum Offline
Registered User
 
Join Date: Nov 2005
Posts: 57
Code:
/sbin/lvm vgchange -a y --ignorelockingfailure
, from /etc/rc.sysinit so I think it should work.
__________________
--
There are 10 kind of people around,
the ones who understand binary and the others.
Reply With Quote
  #7  
Old 10th May 2008, 02:52 PM
daviddoria Offline
Registered User
 
Join Date: Oct 2007
Posts: 884
the problem is still that

lvm lvs

doesn't show anything. And then hence

lvm vgchange

doesn't do anything.

Any other thoughts?
Reply With Quote
  #8  
Old 10th May 2008, 06:33 PM
daviddoria Offline
Registered User
 
Join Date: Oct 2007
Posts: 884
so i think somehow when i was in rescue mode messing with lvm i messed up the lvm setup. Now i have booted a live-cd and run system-config-lvm and lvm doesn't seem to be setup at all. Is all hope lost? Or is there some way I can mount the drive and get some data off?

Thanks,

Dave
Reply With Quote
  #9  
Old 10th May 2008, 06:52 PM
surkum Offline
Registered User
 
Join Date: Nov 2005
Posts: 57
I don't know for sure, but my experience tells me that messing with an lvm vg don't ends in good port. Lvm stores lv configuration into the vg, if you have messed up your vg is almost as lossing your partition table, take a look at this http://www.linuxjournal.com/article/8874 , perhaps it would help you.

another http://codeworks.gnomedia.com/archiv.../lvm_recovery/ .
__________________
--
There are 10 kind of people around,
the ones who understand binary and the others.
Reply With Quote
  #10  
Old 11th May 2008, 07:15 PM
daviddoria Offline
Registered User
 
Join Date: Oct 2007
Posts: 884
ahhh great - i haven't tried it yet but the dd command in the first link to read the "lvm table" at the beginning of the disk seems like it may be what i was looking for!

also, the second link doesn't seem to work for me..?

Thanks!

Dave
Reply With Quote
  #11  
Old 11th May 2008, 09:24 PM
surkum Offline
Registered User
 
Join Date: Nov 2005
Posts: 57
seems the site has just passed by, try google cache.
__________________
--
There are 10 kind of people around,
the ones who understand binary and the others.
Reply With Quote
  #12  
Old 12th May 2008, 02:02 PM
daviddoria Offline
Registered User
 
Join Date: Oct 2007
Posts: 884
The only plain text I see when I do
sudo dd if=/dev/sdc bs=512 count=255 skip=1 of=/home/dave/Desktop/lvm.tmp

is

GRUB loading, please wait...
^@internal error: the second sector of Stage 2 is unknown
Reply With Quote
  #13  
Old 12th May 2008, 02:24 PM
surkum Offline
Registered User
 
Join Date: Nov 2005
Posts: 57
actualy you should see nothing after issuing that command ,

well the interesting info is after that.. try:

Code:
sudo dd if=/dev/sdc bs=512 count=255 skip=1 of=/home/dave/Desktop/lvm.tmp

strings  /home/dave/Desktop/lvm.tmp > /home/dave/Desktop/lvm.tmp.txt

cat /home/dave/Desktop/lvm.tmp.txt
the information you ar looking if right after :
Code:
internal...
. and begins with
Code:
LABELONE 
LVM2
__________________
--
There are 10 kind of people around,
the ones who understand binary and the others.
Reply With Quote
  #14  
Old 12th May 2008, 02:43 PM
daviddoria Offline
Registered User
 
Join Date: Oct 2007
Posts: 884
haha of course i didn't see anything right away - i meant when i looked in the file lol

but i still don't see "internal..." - here is the entire output:

Code:
[dave@davedesktop Desktop]$ strings lvm.tmp 
pPf1
Loading stage1.5
Geom
Read
 Error
0.97
/boot/grub/stage2 /boot/grub/menu.lst
^_[]
t<<%t
_t 9u
[^_]
[^_]
[^_]
8WEV
[^_]
PARTu==EFI u6
[^_]
F(+F @
[^_]
8WEV
[^_]
Yteh
[^_]
[^_]
WVSSS
[^_]
[^_]
[^_]
tejR
[^_]
Error %u
ext2fs
GRUB loading, please wait...
internal error: the second sector of Stage 2 is unknown.
2$8)
KZ}{
p-I)
u".Cw
f(TX
2$8)
KZ}{
p-I)
u".Cw
f(TX
2$8)
KZ}{
p-I)
u".Cw
f(TX
2$8)
KZ}{
p-I)
u".Cw
f(TX
2$8)
KZ}{
p-I)
u".Cw
f(TX
2$8)
KZ}{
p-I)
u".Cw
f(TX
2$8)
KZ}{
p-I)
u".Cw
f(TX
2$8)
KZ}{
p-I)
u".Cw
f(TX
2$8)
KZ}{
p-I)
u".Cw
f(TX
2$8)
KZ}{
p-I)
u".Cw
f(TX
2$8)
KZ}{
p-I)
u".Cw
f(TX
2$8)
KZ}{
p-I)
u".Cw
f(TX
2$8)
KZ}{
p-I)
u".Cw
f(TX
2$8)
KZ}{
p-I)
u".Cw
f(TX
&tevU
E(cF
iVS,j
beIn
2$8)
KZ}{
p-I)
u".Cw
f(TX
2$8)
KZ}{
p-I)
u".Cw
f(TX
2$8)
KZ}{
p-I)
u".Cw
f(TX
2$8)
KZ}{
p-I)
u".Cw
f(TX
2$8)
KZ}{
p-I)
u".Cw
f(TX
2$8)
KZ}{
p-I)
u".Cw
f(TX
2$8)
KZ}{
p-I)
u".Cw
f(TX
2$8)
KZ}{
p-I)
u".Cw
f(TX
2$8)
KZ}{
p-I)
u".Cw
f(TX
2$8)
KZ}{
p-I)
u".Cw
f(TX
2$8)
KZ}{
p-I)
u".Cw
f(TX
2$8)
KZ}{
p-I)
u".Cw
f(TX
2$8)
KZ}{
p-I)
u".Cw
f(TX
2$8)
KZ}{
p-I)
u".Cw
f(TX
2$8)
KZ}{
p-I)
u".Cw
f(TX
2$8)
KZ}{
p-I)
u".Cw
f(TX
2$8)
KZ}{
p-I)
u".Cw
f(TX
2$8)
KZ}{
p-I)
u".Cw
f(TX
2$8)
KZ}{
p-I)
u".Cw
f(TX
2$8)
KZ}{
p-I)
u".Cw
f(TX
2$8)
KZ}{
p-I)
u".Cw
f(TX
2$8)
KZ}{
p-I)
u".Cw
f(TX
2$8)
KZ}{
p-I)
u".Cw
f(TX
2$8)
KZ}{
p-I)
u".Cw
f(TX
2$8)
KZ}{
p-I)
u".Cw
f(TX
2$8)
KZ}{
p-I)
u".Cw
f(TX
2$8)
KZ}{
p-I)
u".Cw
f(TX
2$8)
KZ}{
p-I)
u".Cw
f(TX
2$8)
KZ}{
p-I)
u".Cw
f(TX
2$8)
KZ}{
p-I)
u".Cw
f(TX
/boot
Reply With Quote
  #15  
Old 13th May 2008, 09:33 AM
surkum Offline
Registered User
 
Join Date: Nov 2005
Posts: 57
well that means the lvm header config is overwriten in the disk (it seem to me like a format pattern or the like your output)... bad luck, are you sure that the vg was on that disk?
__________________
--
There are 10 kind of people around,
the ones who understand binary and the others.
Reply With Quote
Reply

Tags
lvm, mount, rescue

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

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 On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
How do mount a harddisk from rescue CD? LinuxDanP Using Fedora 1 24th September 2009 07:08 PM
FC10: Unable to mount LV in rescue mode campbellm Using Fedora 3 23rd April 2009 08:20 PM
Trying to rescue Fedora 10 - unable to mount HD ajnin Using Fedora 1 4th March 2009 06:42 AM
Rescue Mode can't mount some of my system!! egtux Using Fedora 8 8th September 2007 12:48 PM
How to mount NFS volume from rescue shell pgg Using Fedora 1 10th December 2005 02:04 PM


Current GMT-time: 01:21 (Monday, 24-11-2014)

TopSubscribe to XML RSS for all Threads in all ForumsFedoraForumDotOrg Archive
logo

All trademarks, and forum posts in this site are property of their respective owner(s).
FedoraForum.org is privately owned and is not directly sponsored by the Fedora Project or Red Hat, Inc.

Privacy Policy | Term of Use | Posting Guidelines | Archive | Contact Us | Founding Members

Powered by vBulletin® Copyright ©2000 - 2012, vBulletin Solutions, Inc.

FedoraForum is Powered by RedHat
Harbin Photos on Instagram - Lancut Travel Photos on Instagram - Bom Despacho Travel Photos