Quentin McGaw
Quentin McGaw
Hi there, > I had an issues in running the script so I had to modify line 22 by adding $ in 2 locations as follows: > `TXID_BLOCKID=$(paste
The restore script should not fail at the `Finding all roots` level... In a terminal, try line by line and **stop as soon as one fails**: ```sh ROOTS_RAW=`btrfs-find-root "$DISK_TO_RECOVER" 2>...
Did you set `DISK_TO_RECOVER=/dev/vg1004/lv` before running any of these commands? Also what shell are you using? You can find that with `echo $SHELL` mine is `/bin/ash`
Oh my bad, the script was trying to `/bin/sh` which does not support the command `paste
Oops went too quick at changing, please try again with new fixes, [**new script**](https://raw.githubusercontent.com/qdm12/btrfs-recover-scripts/master/restore.sh)
Uh ok strange, please try with this script? ```sh #!/bin/ash printf "RESTORE SCRIPT\n" DISK_TO_RECOVER=/dev/mapper/cachedev_0 RESTORE_PATH=/volumeUSB1/usbshare RECENT_FILEPATH=/mypath/recentfile.txt # Find roots with transaction id printf "Finding all roots..." ROOTS_RAW=`btrfs-find-root "$DISK_TO_RECOVER" 2> /dev/null...
Are you sure there is `/bin/ash` at the top? If yes, try again the script above I have updated it
Are you trying to restore volume 1 or 7? Because there is the strange line ``` Searching for /volume7 in the roots block numbers ```
Maybe that's another device than `/dev/vg1004/lv`? Try checking `btrfs filesystem show` in your terminal
Try `btrfs subvolume list -a /dev/mapper/vg1004-lv`, you might need to remount your file system to do that however. See [https://btrfs.wiki.kernel.org/index.php/Manpage/btrfs-subvolume](https://btrfs.wiki.kernel.org/index.php/Manpage/btrfs-subvolume) EDIT: **Updated btrfs command**