SCF Advanced Search



Members
Stats
  • Total Posts: 40754
  • Total Topics: 14549
  • Online Today: 708
  • Online Ever: 51419
  • (01. January 2010., 10:27:49)









Author Topic: Recover your /home data with an Ubuntu CD USB Boot Disk from a ZFS partition  (Read 2539 times)

0 Members and 1 Guest are viewing this topic.

devnullius

  • SCF VIP Member
  • *****
  • Posts: 3611
  • KARMA: 157
  • Gender: Female
    • SCForum.info
I was lucky so I better write it down.

Linux sucks. I'm using Ubuntu 20.04 and it wouldn't boot any longer. Recovery console was too fast to catch so I booted with an installation USB.

Then the question is: how to mount my old hard disk and copy my /home/data to safety!

sudo su -

mkdir /home/myhome
zpool status

sudo zpool import rpool rpoolssd
--> you have to rename rpool to avoid conflicts, or so I think!

zpool status
Code: [Select]
Which gives for me:
pool: bpool
 state: ONLINE
  scan: scrub repaired 0B in 0 days 00:00:01 with 0 errors on Sat Aug  7 22:24:03 2021
config:

NAME                                    STATE     READ WRITE CKSUM
bpool                                   ONLINE       0     0     0
  c2124c91-6e47-ff42-85e7-3c1199be6f2b  ONLINE       0     0     0

errors: No known data errors

  pool: rpoolssd
 state: ONLINE
  scan: scrub repaired 0B in 0 days 01:52:25 with 0 errors on Sun Aug  8 00:16:27 2021
config:

NAME                                    STATE     READ WRITE CKSUM
rpoolssd                                ONLINE       0     0     0
  c6576671-0ca6-f14a-9633-088e41e229d4  ONLINE       0     0     0



zfs list -ro canmount,mountpoint,mounted,name rpoolssd
--> that gives, for me:
Code: [Select]
      on  /home/myhome                     no  rpoolssd/USERDATA/myhome_a3k59c
      on  /root                          no  rpoolssd/USERDATA/root_a3k59c

zfs set mountpoint=legacy rpoolssd

mount -t zfs rpoolssd/USERDATA/myhome_a3k59c /home/myhome
More information about bitcoin, altcoin & crypto in general? GO TO  j.gs/7385484/btc

Cuisvis hominis est errare, nullius nisi insipientis in errore persevare... So why not get the real SCForum employees to help YOUR troubled computer!!! SCF Remote PC Assist http://goo.gl/n1ONa9

Samker's Computer Forum - SCforum.info


devnullius

  • SCF VIP Member
  • *****
  • Posts: 3611
  • KARMA: 157
  • Gender: Female
    • SCForum.info
if you make yourself root (sudo su -), you have full rights to all the files. You can remove what you don't need, then make a backup of your freshly mounted zfs /home/myhome mountpoint as follows:

cd /home
Code: [Select]
tar -cpzf /media/ubuntu/hdd11/myhome.tar.gz --exclude=*tmp --exclude=myhome.tar.gz --exclude=.cache --exclude=.debug --exclude=.dbus --exclude=.gvfs --exclude=.local/share/gvfs-metadata --exclude=.local/share/Trash --exclude=.recently-used --exclude=.thumbnails --exclude=.xsession-errors --exclude=.Trash --exclude=.steam --exclude=Downloads --exclude=GitHub --exclude=Public --exclude=Steam --exclude=Templates --exclude="VirtualBox VMs" --warning=no-file-changed ./myhome/

With /media/ubuntu/hdd11 a disk I mounted with gnome's disks app.
More information about bitcoin, altcoin & crypto in general? GO TO  j.gs/7385484/btc

Cuisvis hominis est errare, nullius nisi insipientis in errore persevare... So why not get the real SCForum employees to help YOUR troubled computer!!! SCF Remote PC Assist http://goo.gl/n1ONa9

Hoa Dao

  • Guest
Your article is very good and useful, thank you for sharing, mig8 hopes that next time you will have more good articles to send to all readers.

Samker's Computer Forum - SCforum.info


 

With Quick-Reply you can write a post when viewing a topic without loading a new page. You can still use bulletin board code and smileys as you would in a normal post.

Name: Email:
Verification:
Type the letters shown in the picture
Listen to the letters / Request another image
Type the letters shown in the picture:
Second Anti-Bot trap, type or simply copy-paste below (only the red letters):www.scforum.info:

Enter your email address to receive daily email with 'SCforum.info - Samker's Computer Forum' newest content:

Terms of Use | Privacy Policy | Advertising