2024 Session II (c242)

This page can't be edited. | Page History
    Table of contents
    You are currently comparing two old versions - only when you are comparing against the latest version can you revert. Return to version archive.

    Combined revision comparison

    Comparing version 10:59, 19 Dec 2024 by jwagner with version 11:02, 19 Dec 2024 by jwagner.

    ...

    # Make a low level backup of the wiped disk
    root@mark6-08> cd /data/gmva2024_2/
    root@mark6-08> dd bs=1M if=/dev/sdb of=apex-module-disk1-wiped.raw status=progress
    root@mark6-08> chmod a-w apex-module-disk1-wiped.raw
    root@mark6-08> fdisk -lu apex-module-disk1-wiped.raw
     #        Start          End    Size  Type            Name
     1         2048  15627857919    7.3T  Microsoft basic MPIH%024_5
     2  15627857920  15628052479     95M  Microsoft basic MPIH%024_5m
    
    # Grab the XFS file system structure from an intact disk
    root@mark6-08> cd /data/gmva2024_2/
    root@mark6-08> losetup --read-only -o $((512*2048)) /dev/loop1 /dev/sdc
    root@mark6-08> xfs_metadump -g -f -o -w -a /dev/loop1 apex-module-disk2-intact.xfs_metadump
    root@mark6-08> losetup -D ; losetup -a
     
    # Transplant XFS structure from intact disk onto wiped-disk raw content
    root@fxmanager> cd /data/gmva2024_2/
    root@fxmanager> dd bs=512 if=apex-module-disk1-wiped.raw \
       of=recovery-attempt.fs skip=2048 count=$((15627857919-2048+1)) status=progress conv=notrunc
    root@fxmanager> dd status=progress conv=notrunc bs=512 count=1024 \
        seek=15627855872 if=/dev/zero of=recovery-attempt.fs  # appends a bit of 0x00 padding
    root@fxmanager> losetup -v -o 0 /dev/loop0 recovery-attempt.fs
    root@fxmanager> xfs_mdrestore -g apex-module-disk2-intact.xfs_metadump /dev/loop0
      2070 MB read
    root@fxmanager> mkdir cloop ; mount /dev/loop0 ./cloop/ -txfs -oro
      # success!
    oper@fxmanager> cd /data/gmva2024_2/ ; mkdir recovered_content
    oper@fxmanager> cp -anv ./cloop/data/*.vdif ./recovered_content/
    oper@fxmanager> mkdir recovered_GMVA_slot2
    oper@fxmanager> cp -anv ./cloop/data/*.vdif ./recovered_GMVA_slot2/
       
    # Restore content: init the half-wiped partitions, restore Mk6 metadata
    root@mark6-08> mkfs.xfs -f /dev/sdb1
    root@mark6-08> mkfs.xfs -f /dev/sdb2
    root@mark6-08> mount /dev/sdb2 /tmp ; cp -av /mnt/disks/.meta/1/2/* /tmp; umount /tmp
    #
    # 1) Add GMVA_slot2 data from new disk from post-GMVA APEX visit
    #     (could actuallythough could also use ./recovered_GMVA_slot2/, too, but did not get to proceed
    #     with the low-level recovery attempts until after the post-GMVA APEX visit :P)
    stop & start mk5daemon
    oper@mark6-08> sudo mount /mnt/disks/1/2/ -oremount,rw
    root@mark6-08> cp -anv /mnt/disks/3/1/GMVA_slot2_copy/* /mnt/disks/1/2/GMVA_slot2/
    # 2) Also add theAdd  'data' files from restored image
    oper@mark6-08> cp -anv /data/gmva2024_2/recovered_content/*.vdif /mnt/disks/1/2/data/
    oper@mark6-08> sudo mount /mnt/disks/1/2/ -oremount,ro

    ...

    Version from 10:59, 19 Dec 2024

    This revision modified by jwagner (Ban)

    ...

    # Make a low level backup of the wiped disk
    root@mark6-08> cd /data/gmva2024_2/
    root@mark6-08> dd bs=1M if=/dev/sdb of=apex-module-disk1-wiped.raw status=progress
    root@mark6-08> chmod a-w apex-module-disk1-wiped.raw
    root@mark6-08> fdisk -lu apex-module-disk1-wiped.raw
     #        Start          End    Size  Type            Name
     1         2048  15627857919    7.3T  Microsoft basic MPIH%024_5
     2  15627857920  15628052479     95M  Microsoft basic MPIH%024_5m
    
    # Grab the XFS file system structure from an intact disk
    root@mark6-08> cd /data/gmva2024_2/
    root@mark6-08> losetup --read-only -o $((512*2048)) /dev/loop1 /dev/sdc
    root@mark6-08> xfs_metadump -g -f -o -w -a /dev/loop1 apex-module-disk2-intact.xfs_metadump
    root@mark6-08> losetup -D ; losetup -a
     
    # Transplant XFS structure from intact disk onto wiped-disk raw content
    root@fxmanager> cd /data/gmva2024_2/
    root@fxmanager> dd bs=512 if=apex-module-disk1-wiped.raw \
       of=recovery-attempt.fs skip=2048 count=$((15627857919-2048+1)) status=progress conv=notrunc
    root@fxmanager> dd status=progress conv=notrunc bs=512 count=1024 \
        seek=15627855872 if=/dev/zero of=recovery-attempt.fs  # appends a bit of 0x00 padding
    root@fxmanager> losetup -v -o 0 /dev/loop0 recovery-attempt.fs
    root@fxmanager> xfs_mdrestore -g apex-module-disk2-intact.xfs_metadump /dev/loop0
      2070 MB read
    root@fxmanager> mkdir cloop ; mount /dev/loop0 ./cloop/ -txfs -oro
      # success!
    oper@fxmanager> cd /data/gmva2024_2/ ; mkdir recovered_content
    oper@fxmanager> cp -anv ./cloop/data/*.vdif ./recovered_content/
    oper@fxmanager> mkdir recovered_GMVA_slot2
    oper@fxmanager> cp -anv ./cloop/data/*.vdif ./recovered_GMVA_slot2/
       
    # Restore content: init the half-wiped partitions, restore Mk6 metadata
    root@mark6-08> mkfs.xfs -f /dev/sdb1
    root@mark6-08> mkfs.xfs -f /dev/sdb2
    root@mark6-08> mount /dev/sdb2 /tmp ; cp -av /mnt/disks/.meta/1/2/* /tmp; umount /tmp
    # Add GMVA_slot2 data from new disk from post-GMVA APEX visit
    # (though could also use ./recovered_GMVA_slot2/, but did not get to proceed
    # with the low-level recovery attempts until after the post-GMVA APEX visit :P)
    stop & start mk5daemon
    root@mark6-08> cp -anv /mnt/disks/3/1/GMVA_slot2_copy/* /mnt/disks/1/2/GMVA_slot2/
    # Add 'data' files from restored image
    oper@mark6-08> cp -anv /data/gmva2024_2/recovered_content/*.vdif /mnt/disks/1/2/data/

    ...

    Version as of 11:02, 19 Dec 2024

    This revision modified by jwagner (Ban)

    ...

    # Make a low level backup of the wiped disk
    root@mark6-08> cd /data/gmva2024_2/
    root@mark6-08> dd bs=1M if=/dev/sdb of=apex-module-disk1-wiped.raw status=progress
    root@mark6-08> chmod a-w apex-module-disk1-wiped.raw
    root@mark6-08> fdisk -lu apex-module-disk1-wiped.raw
     #        Start          End    Size  Type            Name
     1         2048  15627857919    7.3T  Microsoft basic MPIH%024_5
     2  15627857920  15628052479     95M  Microsoft basic MPIH%024_5m
    
    # Grab the XFS file system structure from an intact disk
    root@mark6-08> cd /data/gmva2024_2/
    root@mark6-08> losetup --read-only -o $((512*2048)) /dev/loop1 /dev/sdc
    root@mark6-08> xfs_metadump -g -f -o -w -a /dev/loop1 apex-module-disk2-intact.xfs_metadump
    root@mark6-08> losetup -D ; losetup -a
     
    # Transplant XFS structure from intact disk onto wiped-disk raw content
    root@fxmanager> cd /data/gmva2024_2/
    root@fxmanager> dd bs=512 if=apex-module-disk1-wiped.raw \
       of=recovery-attempt.fs skip=2048 count=$((15627857919-2048+1)) status=progress conv=notrunc
    root@fxmanager> dd status=progress conv=notrunc bs=512 count=1024 \
        seek=15627855872 if=/dev/zero of=recovery-attempt.fs  # appends a bit of 0x00 padding
    root@fxmanager> losetup -v -o 0 /dev/loop0 recovery-attempt.fs
    root@fxmanager> xfs_mdrestore -g apex-module-disk2-intact.xfs_metadump /dev/loop0
      2070 MB read
    root@fxmanager> mkdir cloop ; mount /dev/loop0 ./cloop/ -txfs -oro
      # success!
    oper@fxmanager> cd /data/gmva2024_2/ ; mkdir recovered_content
    oper@fxmanager> cp -anv ./cloop/data/*.vdif ./recovered_content/
    oper@fxmanager> mkdir recovered_GMVA_slot2
    oper@fxmanager> cp -anv ./cloop/data/*.vdif ./recovered_GMVA_slot2/
       
    # Restore content: init the half-wiped partitions, restore Mk6 metadata
    root@mark6-08> mkfs.xfs -f /dev/sdb1
    root@mark6-08> mkfs.xfs -f /dev/sdb2
    root@mark6-08> mount /dev/sdb2 /tmp ; cp -av /mnt/disks/.meta/1/2/* /tmp; umount /tmp
    #
    # 1) Add GMVA_slot2 data from new disk from post-GMVA APEX visit
    #    (could actually use ./recovered_GMVA_slot2/, too, but did not get to proceed
    #    with the low-level recovery attempts until after the post-GMVA APEX visit :P)
    stop & start mk5daemon
    oper@mark6-08> sudo mount /mnt/disks/1/2/ -oremount,rw
    root@mark6-08> cp -anv /mnt/disks/3/1/GMVA_slot2_copy/* /mnt/disks/1/2/GMVA_slot2/
    # 2) Also add the 'data' files from restored image
    oper@mark6-08> cp -anv /data/gmva2024_2/recovered_content/*.vdif /mnt/disks/1/2/data/
    oper@mark6-08> sudo mount /mnt/disks/1/2/ -oremount,ro

    ...