View unanswered posts    View active topics

All times are UTC - 6 hours





Post new topic Reply to topic  [ 5 posts ] 
Print view Previous topic   Next topic  
Author Message
Search for:
PostPosted: Mon Jan 08, 2007 1:35 pm 
Offline
Joined: Thu Aug 03, 2006 6:15 am
Posts: 43
Location: College Station, TX
One of my LVM drives died and is in the process of being replaced.

Is there any way to recover data from the other drive or do I just need to format both of them and forget about it?

Also, If I end up reformatting, is there any way to automatically rebuild the /myth file structure?

_________________
Knoppmyth R5F27 on a Dell Dimension 8100
768 MB ram
GeForce 5200
Hauppauge WinTV-PVR-150
Lots of hdds


Last edited by jessebs on Fri Jan 12, 2007 3:41 pm, edited 1 time in total.


Top
 Profile  
 
 Post subject:
PostPosted: Mon Jan 08, 2007 1:44 pm 
Offline
Joined: Fri Nov 18, 2005 9:22 am
Posts: 777
Location: spencerport, ny (USA)
There isn't an easy way. It happened to me, and I started over.
:cry:


Top
 Profile  
 
 Post subject:
PostPosted: Mon Jan 08, 2007 4:08 pm 
Offline
Joined: Thu Aug 03, 2006 6:15 am
Posts: 43
Location: College Station, TX
I got my drive, so I formatted both, and ran

Code:
create_lvm.sh /dev/sda1 /dev/sdb1


which gave:

Code:
Creating /dev/vg/myth
  Physical volume "/dev/sda1" successfully created
  Physical volume "/dev/sdb1" successfully created
  /dev/vg: already exists in filesystem
  Volume group "vg" doesn't exist
  Invalid argument vg
  Error during parsing of command line.
Setting LVM to start on boot.
 System startup links for /etc/init.d/lvm already exist.


What can I do about the errors?

_________________
Knoppmyth R5F27 on a Dell Dimension 8100
768 MB ram
GeForce 5200
Hauppauge WinTV-PVR-150
Lots of hdds


Top
 Profile  
 
 Post subject:
PostPosted: Mon Jan 08, 2007 4:15 pm 
Offline
Joined: Thu Aug 03, 2006 6:15 am
Posts: 43
Location: College Station, TX
Easy fix

Code:
rm -rf /dev/vg


and then ran create_lvm.sh

_________________
Knoppmyth R5F27 on a Dell Dimension 8100
768 MB ram
GeForce 5200
Hauppauge WinTV-PVR-150
Lots of hdds


Top
 Profile  
 
 Post subject:
PostPosted: Fri Jan 12, 2007 3:40 pm 
Offline
Joined: Thu Aug 03, 2006 6:15 am
Posts: 43
Location: College Station, TX
These are the steps I took after one of my LVM drives failed and I got a replacement.

Note that I have it setup so that /myth spans the LVM drives, everything else is on a seperate disk.

There arent many steps here, but it took me a long time to figure some of this out, so I though I would make it easy on others.

I DID lose all my data on /myth, and I set up LVM using the create_lvm.sh script

This assumes that lvm spanned /dev/sda1 and dev/sda2. Change these values to meet your needs.

as root:

1. unmount the /myth directory
Code:
umount /myth


2. Run this command to remove the volume group created before.
Code:
rm -rf /dev/vg

3. Execute the steps in the LVM wiki - the mount command might not work
http://knoppmythwiki.org/index.php?page=LvmHowTo

3. Restore the /myth directory structure -- nice script I wrote - i saved it as rebuild_myth.sh in the /usr/local/sbin/ directory
Code:
#!/bin/bash

# Rebuild the /myth directory

# Jesse Bowes
# Created Jan 12, 2007

# Command to run on directories
CMD="mkdir -p"

# Reconstruct /myth directory structure
$CMD /myth/backup
$CMD /myth/gallery
$CMD /myth/game/nes
$CMD /myth/game/nes/roms
$CMD /myth/game/nes/screens
$CMD /myth/game/pc
$CMD /myth/game/pc/screens
$CMD /myth/game/snes
$CMD /myth/game/snes/roms
$CMD /myth/game/snes/screens
$CMD /myth/game/xmame
$CMD /myth/game/xmame/cabs
$CMD /myth/game/xmame/flyers
$CMD /myth/game/xmame/hiscores
$CMD /myth/game/xmame/history
$CMD /myth/game/xmame/roms
$CMD /myth/game/xmame/screens
$CMD /myth/music
$CMD /myth/tv
$CMD /myth/video/motion
$CMD /myth/video/.covers
$CMD /myth/tmp

#Give ownership to the mythtv user
chown -R mythtv /myth


4. Restore your data to /myth if you have it backed up somewhere.

5. Refill database
    Code:
    mythfilldatabase


6. Delete any previous recordings that were lost (they are still listed in the database)


I hope this helps.

Edit: This will be modified shortly as several hidden directories are missing

_________________
Knoppmyth R5F27 on a Dell Dimension 8100
768 MB ram
GeForce 5200
Hauppauge WinTV-PVR-150
Lots of hdds


Top
 Profile  
 

Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 5 posts ] 


All times are UTC - 6 hours




Who is online

Users browsing this forum: No registered users and 4 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Jump to:  
cron
Powered by phpBB® Forum Software © phpBB Group

Theme Created By ceyhansuyu