Messages in this thread | | | Date | Fri, 23 Jul 1999 18:10:02 +0200 | From | Francis GALIEGUE <> | Subject | Why doesn't the sync mount option REALLY work on floppies?? |
| |
All is in the question. After looking at the sync(2) manpage:
DESCRIPTION sync first commits inodes to buffers, and then buffers to disk.
it just looks that the sync option does the first step but not the second (because filesystem panics when I remove a rw,sync mounted floppy).
I'm writing a program to manage removable peripherals on a machine, and I want them to be as easy to manipulate as they are under Windows (don't yell). CDROM is no big deal but I'd expect the sync mount option to work!
Right now the only way I found is to call sync() at regular time intervals, but it's ugly and slows down the system when there's intensive I/O going on. The FDFLUSH ioctl makes VFS barf about "busy inodes on changed media" and doesn't solve the problem either...
At first I wanted to port supermount to 2.2, but lacked time (and moreover the VFS layer is gonna change - again - in 2.4.x), whereas my program works now - except for this. I'm about to add support for IDE ZIP drives too but I expect the same trouble to occur.
So, is there a solution to sync() only one device?
-- fg
"Unix doesn't have a monopoly on good ideas, it just owns most of them"
- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/
| |