OT: (Way OT) PHP and MySQL concurrency control using MyISAM
wmoran at potentialtech.com
Wed Mar 26 06:09:27 PDT 2008
In response to Da Rock <rock_on_the_web at comcen.com.au>:
> I remember now exactly why I wanted MyISAM- you see the table locking is
> exactly what I need for the task. I just need to come up with a method
> to ensure what I send to the server does actually get written- or am I
> just being paranoid?
> The task I require needs to offer direct sequential access with no
> undoing of written data. And given the legality of the task based on
> these strict requirements, you can understand my paranoia.
Sounds to me that you want something more like a logfile, where you can
write a line of data, then fsync the file to guarantee that it's been
committed to disk. Of course, depending on how you'll need to access
this data later, this may not be the best approach.
I don't know the details of how MySQL does or does not guarantee that
your data is safely on disk, but I can say that PostgreSQL uses fsync
after each commit to ensure you're data can not be lost. From there,
it's up to the hardware, so ensure you have quality disks that don't
lie about caching, and you'll probably want a battery-backed RAID
controller and some sort of disk redundancy (i.e. RAID-10)
More information about the freebsd-questions