site_archiver@lists.apple.com Delivered-To: darwin-dev@lists.apple.com that's what sync(2) does. Shantonu On Nov 29, 2005, at 2:38 AM, mlists@ugsoft.de wrote: Thanks, _______________________________________________ Do not post admin requests to the list. They will be ignored. Darwin-dev mailing list (Darwin-dev@lists.apple.com) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/darwin-dev/site_archiver%40lists.appl... What information in particular do you not think is getting flushed to disk. And why in the world are you accessing the filesystem through the raw device instead of the mounted filesystem. Even if you sync (2), you're never going to get a coherent snapshot of the filesystem that is mounted read/write. In order to read _current_ HFS data from a mounted disk we need to flush the HFS cache to disk before we start to read. - Calling sync() does not do the job - data on disk is not updated with HFS cache. - Opening the disk with open("/dev/rdsk0s10", O_RDWR) or (open("/", O_RDWR) and calling fsync(diskfd) or ioctl(diskfd, DKIOCSYNCHRONIZECACHE) does not do it - data on disk is not updated with HFS cache. - Starting Disk Utility does the job - afterwards the HFS data on disk is updated with current information. Any idea how Disk Utility forces to flush the HFS cache to disk, and how we can do it in our code (without having to start Disk Utility ;-))? Uwe Gohlke _______________________________________________ Do not post admin requests to the list. They will be ignored. Darwin-dev mailing list (Darwin-dev@lists.apple.com) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/darwin-dev/ssen% 40opendarwin.org This email sent to ssen@opendarwin.org This email sent to site_archiver@lists.apple.com