<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
  <meta content="text/html;charset=KOI8-R" http-equiv="Content-Type">
</head>
<body bgcolor="#ffffff" text="#000000">
Excellent. Thank you for the idea about buffering too.<br>
Chris :)<br>
<br>
Igor Sysoev wrote:
<blockquote cite="mid:20080820150248.GI2560@rambler-co.ru" type="cite">
  <pre wrap="">On Wed, Aug 20, 2008 at 09:53:08PM +0700, Chris Savery wrote:

  </pre>
  <blockquote type="cite">
    <pre wrap="">Just to answer my own question in last message,

Yes. That simple log file works. However, it writes 2 bytes per hit. One 
for the x and one for \n. Well, thats ok.

But can someone who really knows the internals tell me if a single x log 
format would be very fast on say 1000+ requests/second or if it would 
degrade how many thumbnails/second noticeably?
    </pre>
  </blockquote>
  <pre wrap=""><!---->
I suspect that on 1000 r/s you do not even see noticeable difference in top.

  </pre>
  <blockquote type="cite">
    <pre wrap="">Chris :)

Manlio Perillo wrote:
    </pre>
    <blockquote type="cite">
      <pre wrap="">Chris Savery ha scritto:
      </pre>
      <blockquote type="cite">
        <pre wrap="">Hello,

Is there a way to have hit counter variables that would save every 
hour or persist across restarts?

I'm working on a photography site that I expect to be serving a huge 
number of thumbnail (static) images. I don't need full logging of the 
thumbnails so I've turned if off for that location but it sure would 
be nice to keep some tracking of how many are served and perhaps at 
what rate. I thought maybe just a counter variable that increments on 
each hit in that location but it wouldn't be too useful unless it 
could save to file from time to time, or perhaps append a count to a 
file every hour so there is a time series log.

        </pre>
      </blockquote>
      <pre wrap="">
You can write an Nginx module that use, as an example, gdbm to store 
data, protected with a lock.



Manlio Perillo


      </pre>
    </blockquote>
  </blockquote>
  <pre wrap=""><!---->
  </pre>
</blockquote>
<br>
</body>
</html>