Re: Re: New Linux xfs/reiser file systems

Tom Lane <tgl@sss.pgh.pa.us>

From: Tom Lane <tgl@sss.pgh.pa.us>
To: Hannu Krosing <hannu@tm.ee>
Cc: Lincoln Yeoh <lyeoh@pop.jaring.my>, mlw <markw@mohawksoft.com>, Thomas Swan <tswan@ics.olemiss.edu>, PostgreSQL-development <pgsql-hackers@postgresql.org>, Bruce Momjian <pgman@candle.pha.pa.us>
Date: 2001-05-06T16:03:41Z
Lists: pgsql-hackers
Hannu Krosing <hannu@tm.ee> writes:
> Even the IMHO hardest to solve problem
> - RENAME - can 
> probably be done in a transaction-safe manner by doing a
> link(oid.<newname>) in the 
> beginning and selective unlink(oid.<newname/oldname>) at commit time.

Nope.  Consider

	begin;
	rename a to b;
	rename b to a;
	end;

And don't tell me you'll solve this by ignoring failures from link().
That's a recipe for losing your data...

I would ask people who think they have a solution to please go back and
reread the very long discussions we have had on this point in the past.
Nobody particularly likes numeric filenames, but there really isn't any
other workable answer.

			regards, tom lane