From: Dale <rdalek1967@gmail.com>
To: gentoo-user@lists.gentoo.org
Subject: Re: [RESOLVED] [gentoo-user] zfs repair needed (due to fingers being faster than brain)
Date: Tue, 2 Mar 2021 12:15:40 -0600 [thread overview]
Message-ID: <a81590f3-1e42-8723-c33e-83d201925038@gmail.com> (raw)
In-Reply-To: <CAC_tCmqO0JxZyutHi5jb=Jtwj-2y-nK5uq8sYkZST1g4WyjmkA@mail.gmail.com>
John Blinka wrote:
> To all who replied to my distress signal,
>
> The repair turned out to be pretty painless. In two ways:
>
> First, getting quality advice from all of you sans the roasting I
> deserved ;), and
>
> Second, gdisk fixed the gpt header and partition table easily (details
> below). After that, I rebooted, zfs recognized the disk, and then it
> started a resilver automatically. It was done a few minutes later,
> and now everything’s back to normal.
>
> Gdisk noted that both the main gpt header and main partition table
> were damaged, but the backups were ok. I bypassed gdisk’s offer to
> use either the current gpt or to create a blank gpt, because I didn’t
> understand exactly what “current” or “blank” meant.
>
> Instead, I invoked the recovery & transformation menu with “r”. Then
> I used “b” to rebuild the damaged main gpt header with the good
> backup, followed by “c” to restore the partition table from the good
> backup. I then printed the partition table. It looked exactly like
> the partition tables on the other disks of the same make and model in
> the zfs pool (modulo what looked like a unique zfs partition name).
> That made me comfortable, so I wrote the changes to disk, rebooted,
> and found everything back to normal after the resilver.
>
> Appreciate all the help. Thanks!
>
> John
I think we all do things we need "roasting" for at some point. I once
did a rm -rfv and missed a few keys and tab completion didn't beep,
likely it shouldn't have either. Anyway, luckily I had enough left to
do a emerge -ek world and get it all back and it didn't reach /home. I
also cleaned my keyboard with my portable air tank after that. ;-)
I followed this thread in the hopes I might learn something. I think I
did. It seems that the normal routine stuff is done in the main menu
for Gdisk but recovery is done in another menu that is less obvious.
This is a good thing to know. While we hope none of us ever run into
this sort of thing, it is good to know just in case.
It's amazing how well some of the newer file systems can recover from
such things. Between the awesome file systems and Raid and maybe other
tools, most data losses can be avoided.
Neat thread. I don't use ZFS at this point but I learned something
about Gdisk.
Dale
:-) :-)
prev parent reply other threads:[~2021-03-02 18:15 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-03-01 22:25 [gentoo-user] zfs repair needed (due to fingers being faster than brain) John Blinka
2021-03-02 1:15 ` antlists
2021-03-02 2:30 ` Grant Taylor
[not found] ` <7407510.jJDZkT8p0M@robert-notebook>
2021-03-02 17:13 ` [RESOLVED] " John Blinka
2021-03-02 18:15 ` Dale [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=a81590f3-1e42-8723-c33e-83d201925038@gmail.com \
--to=rdalek1967@gmail.com \
--cc=gentoo-user@lists.gentoo.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox