From: "Hua Zhong" <hzhong@cisco.com>
To: "Linux Kernel Mailing List" <linux-kernel@vger.kernel.org>
Subject: dirty buffers and umount/remount
Date: Tue, 11 Jun 2002 00:50:46 -0700 [thread overview]
Message-ID: <FEEFKBEFIEBONNKJABKDGEHIDNAA.hzhong@cisco.com> (raw)
Hi all:
I have a question that should be simple to answer.
When building a system I need to make sure that whenever user
wants to save configuration to nonvolatile storage (i.e., disk),
all dirty buffers are flushed to disk. Basically I do the following:
1) mount filesystem X from read-only to read-write.
2) save all configuration files to a directory A on X.
3) do a sync.
4) write a label file in A saying "this marks a successful save of
all the configuration files".
5) remount X as read-only.
The problem is that 3) takes quite long time to finish (even most files
in 2) are opened with O_SYNC).
I am wondering if 3) is necessary or not. When the filesystem is remounted
from rw to ro, are all dirty buffers related to it flushed to disk? How
about
umount?
The last related question: is the kdev field in the buffer head the physical
block device (i.e., /dev/hda) or the logical block device (i.e., /dev/hda7)?
Thanks a lot.
Hua
next reply other threads:[~2002-06-11 7:52 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-06-11 7:50 Hua Zhong [this message]
2002-06-11 8:12 ` Hua Zhong
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=FEEFKBEFIEBONNKJABKDGEHIDNAA.hzhong@cisco.com \
--to=hzhong@cisco.com \
--cc=linux-kernel@vger.kernel.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
all inboxes | Powered by JetHome®