1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Removing / Replacing / Copying Hard Drive of HR2* Receiver [Photo Tutorial]

Discussion in 'DIRECTV Tips and Resources' started by clambert, Oct 29, 2009.

  1. zackboll

    zackboll Cool Member

    14
    0
    Feb 20, 2010
    post 3
     
  2. zackboll

    zackboll Cool Member

    14
    0
    Feb 20, 2010
    post 4
     
  3. zackboll

    zackboll Cool Member

    14
    0
    Feb 20, 2010
    post 5

    should be able to post links now
     
  4. P Smith

    P Smith Mr. FixAnything

    22,143
    192
    Jul 25, 2002
    W.Mdtrn Sea
    I see hans1967 answered the question:

     
  5. zackboll

    zackboll Cool Member

    14
    0
    Feb 20, 2010
    After doing a little bit of homework apparently it is not really possible to resize xfs file systems online.

    Currently, i am just trying to create the partitions myself to see how that works.

    # Create partitions aligned of 4KiB boundaries
    parted /dev/sda
    unit kib
    mkpart primary xfs 36 530116
    mkpart primary xfs 530120 16269248
    mkpart primary xfs 16269252 1465138584

    # Create FS
    sudo mkfs.xfs -l logdev=/dev/sda1,size=134217728 -r rtdev=/dev/sda3 /dev/sda2

    #
    do xfsrestore and xfsdump steps from tutorial
     
  6. zackboll

    zackboll Cool Member

    14
    0
    Feb 20, 2010
    I am betting that you can just use an internal log device for the xfs partition. I ended up making partition 1 smaller, and modifying some of the parameters to make it look more like the filesysystem that the directv hd-dvr creates.

    mkfs.xfs -d agcount=16 -f -r rtdev=/dev/sda3,extsize=1048576 /dev/sda2
     
  7. P Smith

    P Smith Mr. FixAnything

    22,143
    192
    Jul 25, 2002
    W.Mdtrn Sea
    I missed your point(s) from your last post - what exactly you try to achieve ?
    Making manually formatting of new disk instead of allow do that by DVR's OS ? Because of the 4 KB sector size ?
     
  8. zackboll

    zackboll Cool Member

    14
    0
    Feb 20, 2010
    Yes, because when the DVR formats the disk, it does not make the partitions 4kiB aligned, so performance will be degraded.
     
  9. zackboll

    zackboll Cool Member

    14
    0
    Feb 20, 2010
    Ok, that did not work for me and the DVR reformatted.

    I am currently trying

    1.) leave partition 1 alone as-is mis-aligned (I am not sure what directv has on there)
    2.) delete partition 2 and 3 and make them 4kiB aligned
    3.) create filesystem

    sudo mkfs.xfs -d agcount=16 -i attr=0 -f -r rtdev=/dev/sda3,extsize=1048576 -l version=1 /dev/sda2

    (note I believe are the options supplied are necessary to make the partition compatible with older version of linux the hd-dvr is using)

    4.) run xfsdump | xfsrestore

    I will let you know how it works out after I am finished copying my old hard-drive.
     
  10. CCarncross

    CCarncross Hall Of Fame

    7,058
    60
    Jul 19, 2005
    Jackson
    I see what you are trying to do but personally I would have returned that EARS drive about 20 posts ago and gotten an EADS or EAVS model instead since they work right out of the box.
     
  11. P Smith

    P Smith Mr. FixAnything

    22,143
    192
    Jul 25, 2002
    W.Mdtrn Sea
    Let him do that experiment, we will know soon how it would be finished. Perhaps he is smart enough to fight with 'black box' - DTV's Linux flavor.
    If he will find a solution, that would benefit all prospective DVR owners.

    I would add to that tests - try to stick close to DVR partitioning as you could, usually ppl who wrote internal verification 'correct-incorrect', included tight control of sizes/boundaries/parameters of mkfs. If some bit is off - whole disk will be repartitioned and formatted.
     
  12. zackboll

    zackboll Cool Member

    14
    0
    Feb 20, 2010
    FYI, my previous post appears to have worked and my DVR is functioning with the EARS drive.

    I couldn't really return the drive where I bought it and I didn't really trust adding it to my MDADM raid as I don't really trust this early adoption drive. I suspect that in the coming months, we will begin to see less of the 512byte drives and more of the 4kib drives. Hope these posts are able to help someone out.
     
  13. zackboll

    zackboll Cool Member

    14
    0
    Feb 20, 2010
    I would not blame this on the writers of the internal partitioning scheme, this hard-drive does not report the correct sector size via hdparam which is why linux has trouble with this drive. I suppose a firmware update could fix this, though i doubt we will see this from WD and only the next gen will be correct.
     
  14. zackboll

    zackboll Cool Member

    14
    0
    Feb 20, 2010
    I have started to notice lagging in the Menu of the DVR. I think I am ready to give up and have ordered the WD 2TB EADS model. Perhaps I will create a partition on my EARS model to use as a spare drive in my mdadm raid.

    Does anyone know what directv puts on the first partition? I am going to try an experiment of 4kib aligning partition 1 (517 MB partition) when upgrading to my 2TB drive to see if that is causing the menu lags.

    From what I can gather, partition 2 is the xfs data partition and partition 3 is the real time device partition.
     
  15. P Smith

    P Smith Mr. FixAnything

    22,143
    192
    Jul 25, 2002
    W.Mdtrn Sea
    Part1 should be swap.
     
  16. zackboll

    zackboll Cool Member

    14
    0
    Feb 20, 2010
    ok, then this drive might just work. I have already aligned partition 2 and 3 by manually creating them. If I move partition 1 to start 1 sector later, it should also be 4 kib aligned. I am not sure what the RAM specs of the HR21 are, but this could explain the laggy menu, if it requires going to swap often.
     
  17. gmc9512

    gmc9512 Mentor

    38
    0
    Aug 19, 2006
    Need help please. I've tried the copy from my HR20-700 to a WD20EADS drive several times and get an error message at the same point every time. I don't have SATA 0 port on my pc so I used SATA 1 port which has the HDD to the computer and the next one on the board is SATA 2. Do I need to enter different command prompts if not using SATA 0? Gpart shows the devices properly. Here are some screen shots up to the error.
     

    Attached Files:

  18. P Smith

    P Smith Mr. FixAnything

    22,143
    192
    Jul 25, 2002
    W.Mdtrn Sea
    Post result of 'df' cmd after mounts.
    Also you mistyped the command "xfsdump -J - /mnt/hr20 | xfsrestore -J - /mnt/fap" - see those spaces after each "-J" parameter ?
     
  19. gmc9512

    gmc9512 Mentor

    38
    0
    Aug 19, 2006

    Thanks, I didn't see the extra spaces. It seems to be copying now...keeping my fingers crossed.
     

Share This Page