From: KELEMEN Peter <Peter.Kelemen@cern.ch>
To: xfs@oss.sgi.com
Subject: [PATCH] xfs_repair: print superblock offsets and denial reasons
Date: Wed, 22 Oct 2008 20:36:36 +0200 [thread overview]
Message-ID: <20081022183636.GE20550@kyra> (raw)
Example output (without the scanning dots):
Phase 1 - find and verify superblock.
bad primary superblock - bad magic number !!!
attempting to find secondary superblock...
found candidate secondary superblock...
offset: 62498275328
reason: 16
unable to verify superblock, continuing...
found candidate secondary superblock...
offset: 156246212608
reason: 16
unable to verify superblock, continuing...
found candidate secondary superblock...
offset: 249994149888
reason: 16
unable to verify superblock, continuing...
found candidate secondary superblock...
offset: 343742087168
reason: 16
unable to verify superblock, continuing...
found candidate secondary superblock...
offset: 437490024448
reason: 16
unable to verify superblock, continuing...
found candidate secondary superblock...
offset: 531237961728
reason: 16
unable to verify superblock, continuing...
found candidate secondary superblock...
offset: 624985899008
reason: 16
unable to verify superblock, continuing...
found candidate secondary superblock...
offset: 718733836288
reason: 16
unable to verify superblock, continuing...
found candidate secondary superblock...
offset: 812481773568
reason: 16
unable to verify superblock, continuing...
found candidate secondary superblock...
offset: 906229710848
reason: 16
unable to verify superblock, continuing...
Sorry, could not find valid secondary superblock
Exiting now.
Signed-off-by: KELEMEN Peter <Peter.Kelemen@cern.ch>
Index: xfsprogs/repair/sb.c
===================================================================
RCS file: /cvs/xfs-cmds/xfsprogs/repair/sb.c,v
retrieving revision 1.22
diff -u -r1.22 sb.c
--- xfsprogs/repair/sb.c 8 Sep 2008 06:18:43 -0000 1.22
+++ xfsprogs/repair/sb.c 22 Oct 2008 18:13:26 -0000
@@ -96,6 +96,7 @@
int dirty;
int retval;
int bsize;
+ int reason; /* why sb cannot be verified */
do_warn(_("\nattempting to find secondary superblock...\n"));
@@ -140,6 +141,7 @@
continue;
do_warn(_("found candidate secondary superblock...\n"));
+ do_warn("offset: %Lu\n", off);
/*
* found one. now verify it by looking
@@ -149,12 +151,13 @@
rsb->sb_inprogress = 0;
clear_sunit = 1;
- if (verify_set_primary_sb(rsb, 0, &dirty) == XR_OK) {
+ if ((reason = verify_set_primary_sb(rsb, 0, &dirty)) == XR_OK) {
do_warn(
_("verified secondary superblock...\n"));
done = 1;
retval = 1;
} else {
+ do_warn("reason: %d\n", reason);
do_warn(
_("unable to verify superblock, continuing...\n"));
}
next reply other threads:[~2008-10-22 18:45 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-10-22 18:36 KELEMEN Peter [this message]
2008-10-22 23:41 ` [PATCH V2] xfs_repair: print superblock offsets and why they can't be verified KELEMEN Peter
2008-10-23 13:53 ` Eric Sandeen
2008-10-23 14:24 ` Eric Sandeen
2008-11-21 1:03 ` Barry Naujok
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=20081022183636.GE20550@kyra \
--to=peter.kelemen@cern.ch \
--cc=xfs@oss.sgi.com \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.