9fans - fans of the OS Plan 9 from Bell Labs
 help / color / mirror / Atom feed
From: Geoff Collyer <geoff@collyer.net>
To: 9fans@cse.psu.edu
Subject: Re: [9fans] file server trouble
Date: Tue,  2 Apr 2002 15:06:49 -0800	[thread overview]
Message-ID: <20020402230659.0192919A26@mail.cse.psu.edu> (raw)

plan9pc/9pcfs.c contains

Startsb	startsb[] =
{
	"main",		2892792,
	0
};

The number is the block address of the first super block to consult
when performing a recovery.  For worms, this can be safely set to 2,
the address of the very first super block (SUPER_ADDR).  Larger values
are presumably optimisations, but this shouldn't matter much unless
you've actually got a jukebox.  emelie/9pcfs.c contains this instead:

Startsb	startsb[] =
{
	"main",		2,
	0
};

and that's probably what plan9pc/9pcfs.c should contain too.  2892792
looks like a left-over optimisation from some past file server.
clone/clone.c has yet a different (probably incorrect) value:

Startsb	startsb[] =
{
	"main",	3066839,
	0
};

So try using a value of 2.  Build & boot that kernel and try recover
again.  You can also override this value for the purpose of recovery
by setting conf.firstsb in localconfinit().  emelie/pc.c does this:

	conf.firstsb = 13219302;

and my copy of plan9pc/pc.c does this:

	conf.firstsb = 2;

but it looks like I added that.  I have done successful recovers with
firstsb == 2.  Out of paranoia, I also set

	conf.dumpreread = 1;	/* read and compare in dump copy */



             reply	other threads:[~2002-04-02 23:06 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-04-02 23:06 Geoff Collyer [this message]
  -- strict thread matches above, loose matches on Subject: below --
2002-04-03 20:28 forsyth
2002-04-03 20:08 anothy
2002-04-03 16:56 forsyth
2002-04-03 16:39 anothy
2002-04-02 23:18 Geoff Collyer
2002-04-02 22:10 anothy
2002-04-02 20:57 forsyth
2002-04-02 20:36 anothy

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=20020402230659.0192919A26@mail.cse.psu.edu \
    --to=geoff@collyer.net \
    --cc=9fans@cse.psu.edu \
    /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;
as well as URLs for NNTP newsgroup(s).