From: Ryusuke Konishi <ryusuke-sG5X7nlA6pw@public.gmane.org>
To: jir-hfpbi5WX9J54Eiagz67IpQ@public.gmane.org
Cc: reinoud-qavaossjCcEdnm+yROfE0A@public.gmane.org,
nop-Nqdcz63CPQY@public.gmane.org,
linux-nilfs-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
Subject: Re: [CFD] disk format fixing
Date: Mon, 10 May 2010 03:29:22 +0900 (JST) [thread overview]
Message-ID: <20100510.032922.158554882.ryusuke@osrg.net> (raw)
In-Reply-To: <87aas9hvm8.wl%jir-27yqGEOhnJbQT0dZR+AlfA@public.gmane.org>
On Mon, 10 May 2010 01:45:35 +0900, Jiro SEKIBA wrote:
> > As an alternative, I'm thinking to add a new state flag which
> > indicates segments are allocated physically continuously from
> > the super root to which super blocks point.
> >
> >
> > The aim of this flag is allowing nilfs to find out the latest segment
> > with bisection search.
> >
> > Envisioned changes are as follows:
> >
> > * add the new flag (for example, NILFS_INORDER_FS) for sbp->s_state.
> >
> > * set the flag if a new mount options is specified (for example
> > "-o bisect-root").
> >
> > * Do not update super block when the filesystem is unmounted, and keep
> > the state: s_state.NILFS_INORDER_FS = 1, s_state.NILFS_VALID_FS = 0.
> >
> > * Stop periodic update of super blocks if the flag is set.
> >
> > * If s_state.NILFS_VALID_FS = 0 && s_state.NILFS_INORDER_FS = 1 when
> > the filesystem is mounted, then do bisect search to find out the
> > latest segment.
>
> Here are the question, to do bisect search, you need to know the end of
> the segments to divide physically continuous blocks. Which is the
> end of the block for bisect? Is this going to be the physical partition end?
The end position is the segment immediately in front of the current
segment since disk space is typically used like a circular buffer.
> > * If a new segment is allocated discontinuously and a new super root
> > is created, then write out super blocks to catch up the position.
> >
> > * If GC breaks the series of physically continous segments, then
> > update super blocks to catch up the latest super root position.
> >
> > * Add a new option to cleanerd to pass the "-o bisect-root" mode
> > and let it select the rotational GC algorithm (current default).
> >
> > * If the "-o bisect-root" option is not specified, then use a
> > conventional algorithm and drop the NILFS_INORDER_FS flag.
>
> I prefer option name like "-o async_sb" or "-o no_sync_sb" or so.
> Because users would rather curious how to udpate super block than
> how to find the latest log.
Thanks for the comment. In a narrow sense, "no_sync_sb" is difficult
in this approach, so "few_sync_sb" or "async_sb" sounds better to me.
Anyway, I agree with your point.
> > This doesn't break forward compatibility, because the "next segment
> > chain" is still maintained and older implementations will ignore the
> > NILFS_INORDER_FS flag. Older implementations and the current grub2
> > module can find the latest super root though they incur penalty for
> > mount time.
> >
> > Another drawback of this approach is that it depends on garbage
> > collection algorithm, but at least at present, this seems not to
> > matter.
> >
> > How does that sound?
>
> It would be much better than scanning whole segments from
> boot loader point of view.
Yes, I believe it doesn't complicate boot loader so much.
Thanks,
Ryusuke Konishi
--
To unsubscribe from this list: send the line "unsubscribe linux-nilfs" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
next prev parent reply other threads:[~2010-05-09 18:29 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-05-03 15:54 [CFD] disk format fixing Jiro SEKIBA
[not found] ` <87aash3rrm.wl%jir-27yqGEOhnJbQT0dZR+AlfA@public.gmane.org>
2010-05-03 19:35 ` Jay Carlson
[not found] ` <7E6B7E93-FCB4-4E4C-AF4F-BEA8D8FE1F20-Nqdcz63CPQY@public.gmane.org>
2010-05-04 12:02 ` Reinoud Zandijk
[not found] ` <20100504120222.GA1132-bVHBekiX4bNgoMqBc1r0ESegHCQxtGRMHZ5vskTnxNA@public.gmane.org>
2010-05-04 14:01 ` Ryusuke Konishi
[not found] ` <20100504.230135.205087691.ryusuke-sG5X7nlA6pw@public.gmane.org>
2010-05-05 15:10 ` Jiro SEKIBA
[not found] ` <8739y675aa.wl%jir-27yqGEOhnJbQT0dZR+AlfA@public.gmane.org>
2010-05-05 18:23 ` Ryusuke Konishi
[not found] ` <20100506.032327.203276062.ryusuke-sG5X7nlA6pw@public.gmane.org>
2010-05-09 16:45 ` Jiro SEKIBA
[not found] ` <87aas9hvm8.wl%jir-27yqGEOhnJbQT0dZR+AlfA@public.gmane.org>
2010-05-09 18:29 ` Ryusuke Konishi [this message]
[not found] ` <20100510.032922.158554882.ryusuke-sG5X7nlA6pw@public.gmane.org>
2010-05-11 14:43 ` Jiro SEKIBA
2010-05-04 12:06 ` Reinoud Zandijk
[not found] ` <20100504120623.GB1132-bVHBekiX4bNgoMqBc1r0ESegHCQxtGRMHZ5vskTnxNA@public.gmane.org>
2010-05-05 15:19 ` Jiro SEKIBA
2010-05-04 14:38 ` Ryusuke Konishi
2010-05-16 14:42 ` Jiro SEKIBA
[not found] ` <87pr0v7vs8.wl%jir-27yqGEOhnJbQT0dZR+AlfA@public.gmane.org>
2010-05-16 17:25 ` Ryusuke Konishi
[not found] ` <20100517.022540.171394303.ryusuke-sG5X7nlA6pw@public.gmane.org>
2010-05-18 14:13 ` Jiro SEKIBA
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=20100510.032922.158554882.ryusuke@osrg.net \
--to=ryusuke-sg5x7nla6pw@public.gmane.org \
--cc=jir-hfpbi5WX9J54Eiagz67IpQ@public.gmane.org \
--cc=linux-nilfs-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=nop-Nqdcz63CPQY@public.gmane.org \
--cc=reinoud-qavaossjCcEdnm+yROfE0A@public.gmane.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