From: David Woodhouse <dwmw2@infradead.org>
To: Sergei Sharonov <sergei.sharonov@halliburton.com>
Cc: linux-mtd@lists.infradead.org
Subject: Re: atomic file operations
Date: Thu, 24 Mar 2005 21:59:53 +0000 [thread overview]
Message-ID: <1111701594.6588.2.camel@localhost.localdomain> (raw)
In-Reply-To: <loom.20050323T212715-407@post.gmane.org>
On Wed, 2005-03-23 at 20:50 +0000, Sergei Sharonov wrote:
> I believe I saw a proposal to save small chunks as separate files,
> then append them as a temp file and rename temp file to real log
> file.
> The problems are (1) the log file is huge (2) rename is not atomic per
> your reply.
The important part of rename is atomic. If you have 'log_file', and then
you create 'log_file.new' and rename that to 'log_file', then there is
never an instant where 'log_file' does not exist; it goes directly from
pointing to one inode, to pointing to the other.
--
dwmw2
next prev parent reply other threads:[~2005-03-24 21:59 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-03-22 21:57 atomic file operations Sergei Sharonov
2005-03-23 9:39 ` Estelle HAMMACHE
2005-03-23 20:50 ` Sergei Sharonov
2005-03-24 10:11 ` Estelle HAMMACHE
2005-03-24 10:53 ` Artem B. Bityuckiy
2005-03-24 11:59 ` Estelle HAMMACHE
2005-03-24 12:17 ` Artem B. Bityuckiy
2005-03-24 17:28 ` Sergei Sharonov
2005-03-24 19:32 ` Artem B. Bityuckiy
2005-03-24 22:00 ` David Woodhouse
2005-03-25 8:18 ` Artem B. Bityuckiy
2005-03-24 21:59 ` David Woodhouse [this message]
2005-03-25 16:18 ` Sergei Sharonov
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=1111701594.6588.2.camel@localhost.localdomain \
--to=dwmw2@infradead.org \
--cc=linux-mtd@lists.infradead.org \
--cc=sergei.sharonov@halliburton.com \
/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