Re: [HACKERS] The dangers of "-F"

From: Don Baccus <dhogaza(at)pacifier(dot)com>
To: Bruce Momjian <maillist(at)candle(dot)pha(dot)pa(dot)us>
Cc: pgsql-hackers(at)postgreSQL(dot)org
Subject: Re: [HACKERS] The dangers of "-F"
Date: 1999-06-23 05:43:48
Message-ID: 3.0.1.32.19990622224348.00e4a604@mail.pacifier.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

At 08:36 PM 6/22/99 -0400, Bruce Momjian wrote:

>>
>> Or does the fact that the backend loses control over the
>> order in which stuff is written (in other words, blocks
>> are written whenever and in what order Linux choses rather
>> than fsync'd a file at a time) mean that the kind of
>> inconsistency that might result is different? I.E.
>> log file written before datablocks are, that kind of
>> thing.

>Yes. It is not a problem that a give transaction aborts while it is
>being done because it couldn't have been marked as completed, but the
>previous transaction was marked as completed, and only some blocks could
>be on the disk.

OK, this was what I suspected, and of course is the intuitively
obvious scenario.

In other words, "-F" considered - and proven! - harmful :)

>I hope for every release. I tried to propose some solutions, but
>couldn't code it.

There was a bit of discussion about the cause of the problem
in this list earlier, so part of my re-raising it was an attempt
to encourage more discussion. Not that I know enough about the
code to be of any help, I'm afraid. When I first learned of
this problem (via my own experimentation) I dug around a bit
and it became clear that it wasn't obvious. I.E. the disk
cache knows about dirty/not dirty buffers and takes great
care to only flush dirty ones, that level of stuff. When I
heard that updating pg_log was apparently involved I realized
it was more of a higher-level than lower-level problem.

Sigh...

Or am I wrong?

- Don Baccus, Portland OR <dhogaza(at)pacifier(dot)com>
Nature photos, on-line guides, and other goodies at
http://donb.photo.net

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Don Baccus 1999-06-23 05:44:20 Re: [HACKERS] money data type and conversions
Previous Message Don Baccus 1999-06-23 05:43:45 Re: [HACKERS] The dangers of "-F"