Where to start?
olli at lurza.secnetix.de
Tue Jan 23 10:10:46 UTC 2007
Vasil Dimov wrote:
> [discussion moved from freebsd-hackers@ to freebsd-geom@]
> Oliver Fromme wrote:
> > Vasil Dimov wrote:
> > > Mike Silbersack wrote:
> > > > Soeren Straarup wrote:
> > > > [...]
> > > > > I'm looking for a project.
> > > > [...]
> > > > I'd like to see the ability to run gjournal without reformatting.
> > > > If you could create a dummy file inside the filesystem, then use
> > > > that area for the journal, it might be possible. I'm sure that
> > > > would let a lot more people see if journalling is right for them.
> > >
> > > I am not sure about gjournal internals but what if a system crash
> > > occurs in the middle of a transaction and the fs gets corrupted and
> > > the data, necessary to fix it is in the journal, but you cannot
> > > access the journal because the file, which contains the journal,
> > > is on a corrupted fs?
> > I think you should still be able to mount the file system
> > read-only, even if it's not "clean", so there's no problem
> > locating the journal file. Particularly, note that the
> > journal file should probably be located in the root of the
> > file system, and it will have a constant size and should
> > be allocated from the start (i.e. it never grows nor
> > changes allocation), which means there is no way that its
> > meta data could be damaged.
> With gjournal not only the metadata is journaled but also the actual
> data (e.g. files' contents). So writes to the journal file (which is a
> "regular file" on the FS) should bypass the journaling stuff. Otherwise
> they will get journaled themselves and it will end up in an endless
Right. That's a point I forgot. The journal file would
be required to have its data be exempt from being journaled.
That's probably not trivial to implement, I'm afraid (but
I could be wrong).
> This thing still looks to me like roping your chest to your leg (instead
> of to an unmovable object) in order to avoid falling, but I might be
True, it's certainly not a clean nor efficient solution.
But Mike has a valid point that it would enable people to
turn on journaling on existing file systems, without the
need for repartitioning or adding a disk. It would be a
nice way to _quickly_ set up journaling, for testing
purposes, or simply for curiosity.
BTW, I think in Solaris you can also add journaling to an
existing UFS partition on the fly, without the need for
newfs or adding space. (Provided that there is enough
free space inside the existing file system, of course.)
Oliver Fromme, secnetix GmbH & Co. KG, Marktplatz 29, 85567 Grafing
Dienstleistungen mit Schwerpunkt FreeBSD: http://www.secnetix.de/bsd
Any opinions expressed in this message may be personal to the author
and may not necessarily reflect the opinions of secnetix in any way.
"To this day, many C programmers believe that 'strong typing'
just means pounding extra hard on the keyboard."
-- Peter van der Linden
More information about the freebsd-geom