Jump to content


Welcome to DBSTalk


Sign In 

Create Account
Welcome to DBSTalk. Our community covers all aspects of video delivery solutions including: Direct Broadcast Satellite (DBS), Cable Television, and Internet Protocol Television (IPTV). We also have forums to discuss popular television programs, home theater equipment, and internet streaming service providers. Members of our community include experts who can help you solve technical problems, industry professionals, company representatives, and novices who are here to learn.

Like most online communities you must register to view or post in our community. Sign-up is a free and simple process that requires minimal information. Be a part of our community by signing in or creating an account. The Digital Bit Stream starts here!
  • Reply to existing topics or start a discussion of your own
  • Subscribe to topics and forums and get email updates
  • Send private personal messages (PM) to other forum members
  • Customize your profile page and make new friends
 
Guest Message by DevFuse

Photo
- - - - -

How To: Copy and Replace Internal Hard Drive


  • This topic is locked This topic is locked
304 replies to this topic

Poll: I know that If I open my HR20 DVR (814 member(s) have cast votes)

I know that If I open my HR20 DVR

  1. I will void the remaining warrany and will violate the lease agreement if I do not own it. (420 votes [51.60%] - View)

    Percentage of vote: 51.60%

  2. I am not going to open my HR20 DVR. (394 votes [48.40%] - View)

    Percentage of vote: 48.40%

Vote

#121 OFFLINE   ntrance

ntrance

    Legend

  • Registered
  • 145 posts
Joined: Aug 18, 2006

Posted 16 December 2007 - 01:11 PM

I appreciate the advice, but I did a a power down before disconecting the drive. Even if that was an issue. What would I do about the HR20 original drive, I can't mount that one either. And I don't want to do anything that will mess that one up. I did the original method of copying the drive and that work with out a problem other than the freeze thing? I will try the xfs_repair option on this 200gb drive and see if it helps, but I'm very hesitant about trying it on the original HR20 drive.

I just want to confirm that you gracefully powered down the HR20 with the drive still connected as I described, and that you are not referring to powering down the external drive only. It wasn't clear to me what you meant. If that worked on an external drive, you would do the same boot up/power down procedure to the original HR20 drive by having no eSATA drive connected so you could resolve the errors on it as well. The original dd method worked fine for me too except for the freezing. You could dd the original drive to an intermediate drive, as long as it had enough capacity. Then, you could use the xfs_repair -L method on that drive without concern.

...Ads Help To Support This SIte...

#122 OFFLINE   buddy3000

buddy3000

    Cool Member

  • Registered
  • 17 posts
Joined: Nov 26, 2007

Posted 16 December 2007 - 01:16 PM

I just want to confirm that you gracefully powered down the HR20 with the drive still connected as I described, and that you are not referring to powering down the external drive only. It wasn't clear to me what you meant. If that worked on an external drive, you would do the same boot up/power down procedure to the original HR20 drive by having no eSATA drive connected so you could resolve the errors on it as well. The original dd method worked fine for me too except for the freezing. You could dd the original drive to an intermediate drive, as long as it had enough capacity. Then, you could use the xfs_repair -L method on that drive without concern.


That is correct, I did this on the 200gb and was able to mount it and there were no errors. I powered down the HR20 drive in the same manner and as I type I'm getting ready to check it for errors and see if I can mount it. If all goes well, my next step will be to delete the current partitions on the 720, reformat it in the HR20 then perform the same shut down on it and hopefully it will mount as well and I'll be on my way to a bigger and better HR20 :)

#123 OFFLINE   buddy3000

buddy3000

    Cool Member

  • Registered
  • 17 posts
Joined: Nov 26, 2007

Posted 16 December 2007 - 07:25 PM

That is correct, I did this on the 200gb and was able to mount it and there were no errors. I powered down the HR20 drive in the same manner and as I type I'm getting ready to check it for errors and see if I can mount it. If all goes well, my next step will be to delete the current partitions on the 720, reformat it in the HR20 then perform the same shut down on it and hopefully it will mount as well and I'll be on my way to a bigger and better HR20 :)


ntrance....You're the greatest!!! I'm up and running...at 73%, but with my recording schedule I'll be below 50% in no time. I'll keep you posted on what happens then. Thanks again!!!

#124 OFFLINE   InterMurph

InterMurph

    AllStar

  • Registered
  • 85 posts
Joined: Dec 18, 2007

Posted 19 December 2007 - 06:46 AM

Edit: this question was answered elsewhere. Since the original drive is unused, all I have to do is replace the drive, and the HR20 will initialize it. That's even better!

----

I am getting an HR20-700 tomorrow. I want to replace the internal drive with a 750GB drive I have purchased. Is it as simple as:

1) Putting the new 750GB disk into an eSata enclosure,
2) Connecting it to the HR20-700 and powering it on,
3) Letting the HR20-700 format the new disk,
4) Disconnecting the 750GB disk and removing it from the enclosure,
5) Powering down the HR20,
6) Removing the stock drive and replacing it with the 750GB drive?

Has anybody tried this? It seems like there's a chance that it could work.

Thanks.

#125 OFFLINE   P Smith

P Smith

    Mr. FixAnything

  • Registered
  • 19,746 posts
  • LocationBay Area
Joined: Jul 25, 2002

Posted 19 December 2007 - 10:40 AM

Yes, many ppl posted and used the procedure, but you select wrong thread.

Here we're discussing how preserve recordings when replacing internal HDD to new bigger HDD !

#126 OFFLINE   daniellee

daniellee

    Legend

  • Registered
  • 234 posts
Joined: Jun 15, 2006

Posted 20 December 2007 - 03:56 PM

Here is a step by step that worked for me.

First, all the credit goes the other posters in this thread – I am adding nothing new here.

Second, my goal was to add an external ESATA drive without losing my settings and access to my recordings – not to replace the internal HD in the HR20. I was able to position the HR20 close enough to the PC’s SATA & power connections so there was no need to remove the original drive from the HR20. I simply unplugged the power & SATA cables from the original internal HD and plugged in the power & SATA cables from the PC while leaving the original drive in place .

Step 1 – Let the HR20 format the new ESATA drive.

a) Shut down the HR20
B) Connect the ESATA drive & turn it on.
c) Restart the HR20
d) Confirm that the HR20 is now using the ESATA drive instead of the internal drive.

Step 2 - Perform a “graceful power down”

a) This is achieved by doing a menu reset and disconnecting the HR20’s power just at the point when all the LED lights go off. This is a crucial step – the linux mount commands will fail with a “Can’t read from Superblock” error if this step isn’t taken. It is imperative that both drives experience a “graceful power down” while connected to the HR20.
B) After the HR20 is powered off, turn off the ESATA drive and remove the bare drive from the ESATA enclosure.

Step 3 – Connect the drives to the PC & copy.

a) Get/burn a linux boot cd of KNOPPIX_V5.1.1CD-2007-01-04-EN
B) On the PC, connect the new drive to SATA0 and the original HR20 drive to SATA1 and boot up KNOPPIX linux.
c) You can use qtparted in system menu to verify which drive is which under linux. It is very important that you know the drive letter (a or b or whatever) that linux is assigning to each drive so that you get the sd(drive letter) right in the mount commands below. Normally with the new drive on SATA0 and the original HR20 drive on SATA1 linux will see the new drive as sda and the original HR20 drive as sdb - but you should check it to be sure.
d) Click the Terminal Icon to get a linux command line promp and enter the following commands (note: the part you type is underlined - I used a larger Courier font here to make it easier to see where spaces go).

knoppix@Knoppix:~$ sudo su root
root@Knoppix:/ramdisk/home/knoppix# mkdir /mnt/fap
root@Knoppix:/ramdisk/home/knoppix# mkdir /mnt/hr20
root@Knoppix:/ramdisk/home/knoppix# mount -t xfs -o rtdev=/dev/sda3 /dev/sda2 /mnt/fap
root@Knoppix:/ramdisk/home/knoppix# mount -t xfs -o rtdev=/dev/sdb3 /dev/sdb2 /mnt/hr20


(the next line will start the copying process and on my system took about 70 min. to complete)

root@Knoppix:/ramdisk/home/knoppix# xfsdump -J - /mnt/hr20 | xfsrestore -J - /mnt/fap

(after the dump/restore has finished enter…)

root@Knoppix:/ramdisk/home/knoppix# umount /mnt/hr20
root@Knoppix:/ramdisk/home/knoppix# umount /mnt/fap

Step 4 – Check it out

a) Shut down Knoppix linux and remove power from the PC
B) Return the new SATA drive to the ESATA enclosure and reconnect the original HR20’s HD power & SATA cables.
c) Close up everything, reconnect everything, turn on the ESATA drive and power-up the HR20.

Step 5 – Enjoy More DirecTV HDTV

------Edit 3/29/2008------

The steps listed above should be all you need if you have an HR20-700 but if you have any other HR2x model you will probably run into the “drive spin-up problem”. Apparently the 320GB drives in these models have to receive a spin-up command from the operating system via the SATA cable before they will spin-up. Most operating systems including KNOPPIX linux do not issue this command to the drives. But the GParted live CD does issues these commands and will spin-up the drive as it boots. Oddly enough, after booting, GParted does not recognize the drive but it will spin it up and that is what you need. The trick then becomes keeping the drive spinning as you shut down GParted and boot KNOPPIX. So here are the additional steps you will need to do before beginning step 3 above.

a) Get/burn a GParted live CD 0.3.4-11 (http://gparted.sourc....net/livecd.php)
B) After connecting the original and new drives to the PC boot the GParted live CD first (before proceeding with KNOPPIX). Notice that the original HR2x drive is spinning.
c) Close the GParted application by selecting the GParted|Quit menu. This will expose several desktop icons.
d) Double click the red shutdown icon and select “reboot” from the list. Your PC should not power down and you should not lose your “spin-up”.
e) Go ahead and let the PC reboot the GParted live CD again but this time stop at the GNU GRUB menu and swap out the GParted CD for the KNOPPIX CD.
f) Now press Ctrl-Alt-Del to reboot again – now using KNOPPIX. Through-out these steps the PC should not powered down and the HR2x’s drive should continue to spin.
g) Now you can continue with step 3 above.

------End Edit 3/29/2008------

I’m afraid that I cannot be of much help should you try this and have problems. I know very little about linux. As I said at the beginning, all the credit goes the other posters in the thread who did all the real work and made all the important discoveries. My only contribution has been to summarize their work and let you know that it worked for me.
-Danny

AU9S Slimline Dish -> SWM-16
(1) HR20-700, (1) HR20-100, (1) HR21-100, (1) HR21-200, (1) HR21-700 (all DECA network with internet connection)
See my kitchen wall cabinet setup here

#127 OFFLINE   ntrance

ntrance

    Legend

  • Registered
  • 145 posts
Joined: Aug 18, 2006

Posted 20 December 2007 - 05:03 PM

Here is a step by step that worked for me.

First, all the credit goes the other posters in this thread – I am adding nothing new here.


Very nice detailed procedure. Good work daniellee.

#128 OFFLINE   P Smith

P Smith

    Mr. FixAnything

  • Registered
  • 19,746 posts
  • LocationBay Area
Joined: Jul 25, 2002

Posted 20 December 2007 - 06:25 PM

Good writeup ! Thanks.

#129 OFFLINE   taw123

taw123

    Mentor

  • Registered
  • 34 posts
Joined: Sep 04, 2006

Posted 08 January 2008 - 01:05 AM

So I have an eSATA array that some how had become LOGICALLY corrupted (likely during a power failure though I have had a number in the past with no problems).

I am looking to clone from a working esata disk to my currupted array replacing the NON media partitions...

First question is this likely to work and do we now understand what is written where. Looks like consensus is that s3 is the media (in XFS raw), S1 is swap. Is that all that's stored on S1 (swap)? And it is indeed XFS? No config info (season passes, programing info etc?). Is the data there somehow specific to the drive? If not then I should be able to get the disk to someone who can read it and then copy (dd?) the contents from the new virgin disk to the old array and see if that then allows the only array again to boot with the DVR. if not step 2

Slice 2 is some pointer info in XFS format as well (based upon this thread). Can one copy from one disk to another or is the pointer info related to the media data? If so then I can't just copy from a "working" S2 disk to my array as the media and even SIZE of the Media slice are different.

This is my last hope as the DVR will boot fine w/o the array or with another eSATA disk so somehow it got corrupted and it has not been erased (or it would boot fine). Thank goodness the data is still likely there, I just need to "fix" it (logically). No disk hardware errors (raid 5+1 hot spare, yes I believe in bulit proofing) http://www.dbstalk.c...cons/icon10.gif

Hopeful someone can help with some hints. Then I have to find someone with a linux box to get the work done on. I'm a mac guy (work for apple) and don't have access to a machine I can likely boot a Live Linux disk from with eSATA drivers on my MacBook Pro. (I did dl Knoppix on the off chance it will boot on my Intel/MacBook Pro).

My one plea, if anyone lives out in the bay area and willing to help I drive and provide the alcohol :) Thanks fo any help folks can offer.
______________________________________________
Thomas Weyer email: weyer@mac.com

"Vision without action is daydream. Action without vision is nightmare."
-- Japanese proverb

#130 OFFLINE   ntrance

ntrance

    Legend

  • Registered
  • 145 posts
Joined: Aug 18, 2006

Posted 08 January 2008 - 04:45 AM

You could try creating a Virtual Machine on your Mac using VMware Fusion to run the Knoppix Live CD. You would probably also need a eSATA expansion card unless you already have an eSATA connection. I don't have a Mac though, so I can't try that out.

I don't think there is anything to be gained from copying partitions of a different eSATA to your corrupted one as they don't contain the data you are trying to save.

One thing you might want to consider is if you have access to equal or greater capacity eSATA storage solution, you can use the procedure documented in this thread to replicate your drive and use that to experiment on.

If you are able to get the virtual machine working, or if you find a friend with a suitable machine, you might want to try the xfs_check and possibly the xfs_repair commands.

#131 OFFLINE   ntrance

ntrance

    Legend

  • Registered
  • 145 posts
Joined: Aug 18, 2006

Posted 08 January 2008 - 05:17 AM

There is a linux Live CD with Macbook Pro support at:
http://www.mactel-li.../wiki/Main_Page
That might be easier than the virtual machine option.

#132 OFFLINE   taw123

taw123

    Mentor

  • Registered
  • 34 posts
Joined: Sep 04, 2006

Posted 08 January 2008 - 11:28 AM

[quote name='ntrance']You could try creating a Virtual Machine on your Mac using VMware Fusion to run the Knoppix Live CD. You would probably also need a eSATA expansion card unless you already have an eSATA connection. I don't have a Mac though, so I can't try that out. .[/QUOTE]

Actually as mentioned on a chance I downloaded Knoppix v5.1.1 cd 2007-01-04-EN. The live disk does boot my MacBook. It does seem to include the XFS support as claimed (tried just typing XFSdump and got the help page).

Here's what I am trying to do. I have an a small (500G) eSATA disk. I let the DVR format it and recorded 1 min of HD content to it (so I should have data on all slices right?).

My hope as I mentioned was to copy from good slices to the bad HD. I don't have enough space (2TB) to hold the entire media (Slice 3) partition from the drive I am trying to recover. However I don't see the difference in letting it format another HD and just copying the non-media partitions back. Is there something unique or drive type/size specific that is written at format time that I SHOULDN'T copy?

Here's though were it gets harder when you aren't Linux person.... I THINK it had tried to show in the ui 2 of the partitions from my good DVR disk (s2, s3). They are not however mounted. I confirmed this by doing a df. They are sdb2 & sdb3. I think sda is my internal HD since I saw a reference to bootcamp when I looked at it.

I however can not get the external to mount. I tried creating a mount point for it in /mnt not problem, but the actual mount command fails. I tried from the info placed here.

mount -t xfs -o rtdev=/dev/sdb2 /mnt/fap

I get an error. Just on a lark I tried the mount command and it obviously failed (said something about in use or not available). I know it's not already in use

Any suggestions?

Here is what I will try. I want to first make sure I can see and read all 3 partitions on the working/test disk. If this works then I run whatever repair tools folks might recommend on the TEST DISK.

Then I will bring the disk back to the DVD and confirm the recording is still present (this will I hope prove to me that the XFS tools don't HARM the DVR disk).

Next step for me would be to take ANOTHER test disk (exactly the same as external test disk 1), let it format on dvr, not record anything.

Then I will test my theory of copying slices to a disk and see if copying from the blank test disk to the test disk with 1 file still allow the test disk to boot with the media intact.

I will start with s1 first as I understand it the least and am assuming that it's the most portable. Anyone know what's truly in here? And how to get it to mount in linux. It doesn't even show in the UI.


[quote name='ntrance']I don't think there is anything to be gained from copying partitions of a different eSATA to your corrupted one as they don't contain the data you are trying to save.[/QUOTE]

Actually I don't want to copy the S1 and S2 FROM the corrupted HD. I want to copy GOOD S1 and S2's TO the corrupted HD as I don't have 2TB of space to hold my S3 and let the DVR reformat the whole thing. Aren't the S1 and S2 partitions all the same on all disks?

[quote name='ntrance']One thing you might want to consider is if you have access to equal or greater capacity eSATA storage solution, you can use the procedure documented in this thread to replicate your drive and use that to experiment on.[/QUOTE]

I would if I could, but I don't have the space and at the moment can't even mount all the partitions, but I am much closer now. I was hopeing to get this to work and offer to help anyone else who finds themeless in the same situation by typing up a simple instruction sheet. I am sure someone else somewhere will have the same prob and in this we increase our knowledge of the DVR FS.


QUOTE=ntrance;1375871]If you are able to get the virtual machine working, or if you find a friend with a suitable machine, you might want to try the xfs_check and possibly the xfs_repair commands.[/QUOTE]

Actually as I said I got the live disk to boot on my MacBook Pro. I just need to get the disks to mount and then start playing with the test HD and xfs commands. MAYBE that alone will work.... I hope!

Thanks for all the help.
______________________________________________
Thomas Weyer email: weyer@mac.com

"Vision without action is daydream. Action without vision is nightmare."
-- Japanese proverb

#133 OFFLINE   ntrance

ntrance

    Legend

  • Registered
  • 145 posts
Joined: Aug 18, 2006

Posted 08 January 2008 - 04:43 PM

Here's what I am trying to do. I have an a small (500G) eSATA disk. I let the DVR format it and recorded 1 min of HD content to it (so I should have data on all slices right?).


Just for future reference, you don't actually need to record anything. By the time you see live TV, the partitions are already created.

My hope as I mentioned was to copy from good slices to the bad HD. I don't have enough space (2TB) to hold the entire media (Slice 3) partition from the drive I am trying to recover. However I don't see the difference in letting it format another HD and just copying the non-media partitions back. Is there something unique or drive type/size specific that is written at format time that I SHOULDN'T copy?


Did you actually have 2TB worth of data already recorded? If not, it may still be possible to copy to the smaller eSATA disk.

Here's though were it gets harder when you aren't Linux person.... I THINK it had tried to show in the ui 2 of the partitions from my good DVR disk (s2, s3). They are not however mounted. I confirmed this by doing a df. They are sdb2 & sdb3. I think sda is my internal HD since I saw a reference to bootcamp when I looked at it.


Try the fdisk -l command as that should give you a list of all the attached hard drives. The DVR drive should be the one with three partitions. Please post the results of the command.

I however can not get the external to mount. I tried creating a mount point for it in /mnt not problem, but the actual mount command fails. I tried from the info placed here.

mount -t xfs -o rtdev=/dev/sdb2 /mnt/fap

I get an error. Just on a lark I tried the mount command and it obviously failed (said something about in use or not available). I know it's not already in use

Any suggestions?


Your mount command was incorrect. First you need to create the directory that you are going to use as the mount point:

mkdir /mnt/fap

Since my eSATA drive was FreeAgent Pro I named my mount point /mnt/fap, but you could name that anything you want. The real-time subvolume is actually the third partition, so assuming your DVR drive was sdb, you would use:

mount -t xfs -o rtdev=/dev/sdb3 /dev/sdb2 /mnt/fap

Here is what I will try. I want to first make sure I can see and read all 3 partitions on the working/test disk. If this works then I run whatever repair tools folks might recommend on the TEST DISK.

Then I will bring the disk back to the DVD and confirm the recording is still present (this will I hope prove to me that the XFS tools don't HARM the DVR disk).

Next step for me would be to take ANOTHER test disk (exactly the same as external test disk 1), let it format on dvr, not record anything.

Then I will test my theory of copying slices to a disk and see if copying from the blank test disk to the test disk with 1 file still allow the test disk to boot with the media intact.

I will start with s1 first as I understand it the least and am assuming that it's the most portable. Anyone know what's truly in here? And how to get it to mount in linux. It doesn't even show in the UI.


Before you even mount the drive I would suggest that you try:
xfs_check /dev/sd?2 (where ? is the appropriate letter based on what you learned from fdisk -l above)
This won't harm the drive, and may give some clues as to what the problem is. Then post the results here.

Actually I don't want to copy the S1 and S2 FROM the corrupted HD. I want to copy GOOD S1 and S2's TO the corrupted HD as I don't have 2TB of space to hold my S3 and let the DVR reformat the whole thing. Aren't the S1 and S2 partitions all the same on all disks?


There is nothing in partition 1 and 2 of any other drive that you want on your corrupted drive. Are you saying that you want the DVR to reformat your whole array leaving you with no recordings? If so, you could just use qtparted in system menu to delete all the partitions from the DVR drive, then the DVR will reformat it once you reattach it. For some reason I had assumed that you were trying to salvage something.

#134 OFFLINE   taw123

taw123

    Mentor

  • Registered
  • 34 posts
Joined: Sep 04, 2006

Posted 09 January 2008 - 12:20 AM

[quote name='ntrance']Just for future reference, you don't actually need to record anything. By the time you see live TV, the partitions are already created.[/QUOTE]

Only reason for the recording was to identify if the disk was not erased as the recording would be gone if the DVR reformats (just a check mark). I know the buffered data must be written to the RAW S3 partition, but thanks for the pointer to anyone else reading :)


[quote name='ntrance']Did you actually have 2TB worth of data already recorded? If not, it may still be possible to copy to the smaller eSATA disk. [/QUOTE]

I had 11% free so use it pretty close to 2TB of data. Is the data on that partition that "moveable that you can just address and copy files/programs?


[quote name='ntrance']Try the fdisk -l command as that should give you a list of all the attached hard drives. The DVR drive should be the one with three partitions. Please post the results of the command.[/QUOTE]

With my "test disk/non corrupted eSATA mule" I got

Device             Start        End             Blocks         ID              System    
/dev/sdb1              1        66             530113+         82       Linux Swap / Solaris
/dev/sdb2             67        67          157356667+         83       Linux
/dev/sdb3           2026       91201        716306220          83       Linux    

With my Corrupted disk I got similar data except of course for the media/S3 partition.

[quote name='ntrance']Your mount command was incorrect. First you need to create the directory that you are going to use as the mount point:

mkdir /mnt/fap
[/QUOTE]

Actually I did that but inthe interest of brevity I didn't include that in what I posted. I thought I mentioned creating the mount point. Idf no my mistake for not mentioning.


[quote name='ntrance']Just for future reference, you don't actually need to record anything. By the time you see live TV, the partitions are already created.[/QUOTE]

Only reason for the recording was to identify if the disk was not erased as the recording would be gone if the DVR reformats (just a check mark). I know the buffered data must be written to the RAW S3 partition, but thanks for the pointer to anyone else reading :)


[quote name='ntrance']Did you actually have 2TB worth of data already recorded? If not, it may still be possible to copy to the smaller eSATA disk. [/QUOTE]

I had 11% free so use it pretty close to 2TB of data. Is the data on that partition that "moveable that you can just address and copy files/programs?


[quote name='ntrance']Try the fdisk -l command as that should give you a list of all the attached hard drives. The DVR drive should be the one with three partitions. Please post the results of the command.[/QUOTE]

With my "test disk/non corrupted eSATA mule" I got

Device             Start        End             Blocks         ID              System    
/dev/sdb1              1        66             530113+         82       Linux Swap / Solaris
/dev/sdb2             67        67          157356667+         83       Linux
/dev/sdb3           2026       91201        716306220          83       Linux    

With my Corrupted disk I got similar data except of course for the media/S3 partition.

[quote name='ntrance']Since my eSATA drive was FreeAgent Pro I named my mount point /mnt/fap, but you could name that anything you want.
[/QUOTE]

Actually I did create the mount point but in the interest of brevity I didn't include the mkdir cmd. If I forgot to mention in my post I created the mount point my mistake. I know that much linux/unix (maybe a bit more from my TiVo days).... BTW I am also using a FAP as my test mule given others have said they work (again not that the name of the mount point matters)

[quote name='ntrance']The real-time subvolume is actually the third partition, so assuming your DVR drive was sdb, you would use:

mount -t xfs -o rtdev=/dev/sdb3 /dev/sdb2 /mnt/fap
[/QUOTE]

Actually I think you want:
mount -t xfs -o rtdev=/dev/sdb2 /dev/sdb2 /mnt/fap


When I try that I get:
/dev/sdb2 /dev/sdb2 already mounted or /mnt/fap busy



[quote name='ntrance']Before you even mount the drive I would suggest that you try:
xfs_check /dev/sd?2 (where ? is the appropriate letter based on what you learned from fdisk -l above)
This won't harm the drive, and may give some clues as to what the problem is. Then post the results here.[/QUOTE]

When I try that I get the following msg:
File system has valuable metadata changes in the log which need to be replayed.
Mount the File System to replay log and unmount it before re-runing XFS_check.
If you are unable to mount the file system use XFS_repair -L option to destroy the log
and attempt repair.  Destroy log may cause corruption please attempt to mount 
before doing this.

When I try the command on the S1 or S2 partitions I get an error about the file system (since it's not XFS perhaps):
Unexpected XFS SB Magic number........

QUOTE=ntrance;1377544]There is nothing in partition 1 and 2 of any other drive that you want on your corrupted drive.

Are you saying that you want the DVR to reformat your whole array leaving you with no recordings? If so, you could just use qtparted in system menu to delete all the partitions from the DVR drive, then the DVR will reformat it once you reattach it. For some reason I had assumed that you were trying to salvage something.[/QUOTE]


Certainly not wanting to erase the media saved (I know I can do that). Is all the programing data, recorded content and season passes all stored in S3? Are you really correct in saying there is NOTHING of value stored in the first 2 partitions? My assumption has been that a corruption on one or all of these partitions is keeping the DVR from booting and I had hoped to use another HD that DID work to replace the corrupt partitions (this is something similar to TiVo fixing if the kernel or other files were damaged outside the /var partition).

Thanks again for all the help. Learning more all the time and when I am do I should have a good FAQ for DVR disk repair for the form :) And hopefully a success story.
______________________________________________
Thomas Weyer email: weyer@mac.com

"Vision without action is daydream. Action without vision is nightmare."
-- Japanese proverb

#135 OFFLINE   P Smith

P Smith

    Mr. FixAnything

  • Registered
  • 19,746 posts
  • LocationBay Area
Joined: Jul 25, 2002

Posted 09 January 2008 - 01:06 AM

Be careful, second partition is the master of third and must be OK. There are a lot of files, some of them actually pointers to areas in 3rd.

{reading the thread will help you also, as the info posted here}

#136 OFFLINE   ntrance

ntrance

    Legend

  • Registered
  • 145 posts
Joined: Aug 18, 2006

Posted 09 January 2008 - 01:50 AM

I had 11% free so use it pretty close to 2TB of data. Is the data on that partition that "moveable that you can just address and copy files/programs?


Not that I know of yet. If you had used less than a quarter of the 2TB, I was just going to suggest you try copying the whole thing to the 500GB drive. I don't currently know of a way you can pick and choose what you want to copy.

With my "test disk/non corrupted eSATA mule" I got

Device             Start        End             Blocks         ID              System    
/dev/sdb1              1        66             530113+         82       Linux Swap / Solaris
/dev/sdb2             67        67          157356667+         83       Linux
/dev/sdb3           2026       91201        716306220          83       Linux    

With my Corrupted disk I got similar data except of course for the media/S3 partition.

mount -t xfs -o rtdev=/dev/sdb3 /dev/sdb2 /mnt/fap


Actually I think you want:
mount -t xfs -o rtdev=/dev/sdb2 /dev/sdb2 /mnt/fap


Based on your fdisk output, it appears you are using a 750GB drive, not a 500GB drive. The mount command I gave was correct as written since /dev/sdb3 is the real-time subvolume not /dev/sdb2.

When I try that I get the following msg:

File system has valuable metadata changes in the log which need to be replayed.
Mount the File System to replay log and unmount it before re-runing XFS_check.
If you are unable to mount the file system use XFS_repair -L option to destroy the log
and attempt repair.  Destroy log may cause corruption please attempt to mount 
before doing this.


Did you get that message on the 2TB array? Since something led you to believe that the drive is corrupt, you may feel that reattaching it to the DVR will cause a reformat. While reattaching the drive may take care of the problem, we'll assume that option isn't for you. You could try this command:
xfs_repair -L -r /dev/sdb3 /dev/sdb2
It has worked for me and another user.

Certainly not wanting to erase the media saved (I know I can do that). Is all the programing data, recorded content and season passes all stored in S3? Are you really correct in saying there is NOTHING of value stored in the first 2 partitions? My assumption has been that a corruption on one or all of these partitions is keeping the DVR from booting and I had hoped to use another HD that DID work to replace the corrupt partitions (this is something similar to TiVo fixing if the kernel or other files were damaged outside the /var partition).

I think P Smith provided an answer to that one for you.

#137 OFFLINE   taw123

taw123

    Mentor

  • Registered
  • 34 posts
Joined: Sep 04, 2006

Posted 09 January 2008 - 01:19 PM

Not that I know of yet. If you had used less than a quarter of the 2TB, I was just going to suggest you try copying the whole thing to the 500GB drive. I don't currently know of a way you can pick and choose what you want to copy.


NP, like I said I don't have the space to copy it and if I am able to fix it and mount it to copy then it should be ok to use rather then copy out to temp format and copy back. Don't see how the extra work would really help if S2&3 are linked and S1 is disposable/rewritten each boot (swap) right?


Based on your fdisk output, it appears you are using a 750GB drive, not a 500GB drive.



Correct the "test mule" is a 750 FAP. This is what I am using for all my testing and process refinement before touching the REAL disk. My guess is I will get if I am lucky one shot at fixing this disk, after "fixing" it I doubt I will be able to try again as the data will be permanently altered so I want to learn as much as possible on the forum and through my testing first. Also I though my testing using disposable data might help others as I am willing to try ANYTHING on the "mule" as it has now data of value.

The mount command I gave was correct as written since /dev/sdb3 is the real-time subvolume not /dev/sdb2.



Looks like you are right, that was my lack of how XFS/XFS raw works. I had done simple mounts with a single partition attached to a mount point. I guess I was trying to understand and not dutifully typing. Think its again the TiVo hacking in me that tells me and others understand what you do don't just type blind. I long ago joked (and it's true) Everything I know about Linux I learned from my TiVo.....

When I try your command I get an error:
Can't read superblock

I get this both on my good "test mule" and on the "corrupted" eSATA array.



Did you get that message on the 2TB array? Since something led you to believe that the drive is corrupt, .



Yes, I get the same superblock error msg on both disks. I assume the eSATA array is corrupt because the DVR will not boot with it attached. Remove the eSATA array and it boots internal fine. Attach the test mule and it boots off FAP fine. So the only part substituted is the array.


Uou may feel that reattaching it to the DVR will cause a reformat. While reattaching the drive may take care of the problem, we'll assume that option isn't for you.



Actually that's not the case. Attaching the array keeps the DVR from booting (hangs just before step 2) You SHOULD get the "cylon/knight rider" seeking back and forth of the DVR resolution blue LED, then it should flash the blue ring a couple times and then start step 2 (download data /sat sync showing % complete). Mine doesn't get that far with the disk attached. I have left it connected for hours on the chance that it was fixing but to no avail thus my posts here trying to resolve.


You could try this command:
xfs_repair -L -r /dev/sdb3 /dev/sdb2
It has worked for me and another user.



I tried connecting the test mule while still in the state I mentioned (bad superblock error, unmountable via Knoppix) to the DVR and it booted find (must have fsck'd at boot and cleaned up) All content was still present. Did an "orderly shutdown of the disk" (menu/restart remove power). Connected to Linux and same superblock error on disk. Tried your command to throw out the log, got a bunch of inode errors and a big warning about discarding the journal/log. Mounted the disk then fine looked around it saw files. Did

sync
umount /mnt/fap

Took the disk to DVR and booted that test mule fine. Then I tried to corrupt the test mule by recording to it and then powering it off in mid record. Bringing it over to the computer and repeating the steps. Same superblock error msg, rand the same xfs_repair. Same results mounted locally, and worked on DVR. I repeated this time again but didn't use the computer to fix. I let the DVR fix it on next reboot and all was well there also. So the POST/startup script seems to do a log replay/or clean up quite well for the FAP, just not for my eSATA array.

So my question sole question is, is there any way to get the log to replay on the computer? I really want to try that as I think it's my best chance to get the disk back to the way it was without corruption. My gut says that trowing out the journal is very dangerous. Once I do that on the eSATA array (xfs_repair -L -r /dev/sdb3 /dev/sdb2) there is no going back. Also is there anything I need/can to do to fix the swap partition. I am much more willing to experiment there as my data won't be harmed I hope :)

Well either way I am getting closer (less and less options). Thanks once again for the help. I should have a conclusion soon.
______________________________________________
Thomas Weyer email: weyer@mac.com

"Vision without action is daydream. Action without vision is nightmare."
-- Japanese proverb

#138 OFFLINE   ntrance

ntrance

    Legend

  • Registered
  • 145 posts
Joined: Aug 18, 2006

Posted 09 January 2008 - 07:12 PM

xfs_repair -L is my only recommendation at this point. Maybe someone else can come up with something else if you feel that is too risky. Good luck.

#139 OFFLINE   taw123

taw123

    Mentor

  • Registered
  • 34 posts
Joined: Sep 04, 2006

Posted 10 January 2008 - 11:24 PM

xfs_repair -L is my only recommendation at this point. Maybe someone else can come up with something else if you feel that is too risky. Good luck.


Well I took the plunge with the real disk..... it repaired (XFS_repair tossing the log). Then I mounted it and saw the disk... I though oh goodie.....

Then I sync and umount... Brought to the DVR and the same problem.... Hangs at the end of step 1 (just a couple more sec). The blue resolution LED does the cylon/knight rider seek once then sits... It should move back and forth based upon my test mule... So while I might have fixed the disk something is still corrupted that keeps it from booting and FORTUNATELY it sees enough there not to re-format.....

So now I am back to what the problem might be and how to fix? Sorry to keep hitting the group with this but I really do want that content.... I have an entire season I haven't had thime to watch and many other things on there....

Sitting here hoping for the best

--tom
______________________________________________
Thomas Weyer email: weyer@mac.com

"Vision without action is daydream. Action without vision is nightmare."
-- Japanese proverb

#140 OFFLINE   InterMurph

InterMurph

    AllStar

  • Registered
  • 85 posts
Joined: Dec 18, 2007

Posted 11 January 2008 - 10:45 AM

I am trying to replace the internal drive on my HR20-100, and I can't do it.

I can't do it because I don't have a Torx screwdriver long enough or thin enough to reach into the black tubes on the plastic holder that contain the screws that go through the motherboard and attach to the bottom of the case.

How is everybody else getting these two screws out?

Thanks.




spam firewall