Re: lseek/write
- From: ellis@xxxxxxx ()
- Date: Mon, 19 Nov 2007 05:57:47 -0000
In article <221607b8-04a5-47d4-b992-078a3db45d6e@xxxxxxxxxxxxxxxxxxxxxxxxxxx>,
golden <iang@xxxxxxxxxxxxx> wrote:
I have a question regarding disk IO performance. I would like to
understand why exactly writes to a disk are faster when I use
lseek as opposed to not using lseek.
Because seeking back to zero all the time means the writes get
written over before being flushed to disk.
I would imagine that the write keeps track of the pointer after
each write, but my test does not bear that out.
What "pointer" would that be? If you mean the current position in
the file, your lseek resets it to zero.
Ultimately, I am trying to determine why writes are faster to my
local disk than to my SAN storage (EMC w/ cache).
Perhaps because your SAN access is over a slow bus than the local
drive? EMC's cache isn't going to speed up getting the data from
your computer to the storage. It can only go as fast as the Fibre
Channel (or whatever else you use).
When I use the fsync, writes are slower to san.
Any reason you think they wouldn't be?
--
http://blameitonlove.com/
.
- References:
- lseek/write
- From: golden
- lseek/write
- Prev by Date: Re: Free Space Management
- Next by Date: Re: How to rename a partition
- Previous by thread: lseek/write
- Next by thread: Re: lseek/write
- Index(es):
Relevant Pages
|