Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 5 Mar 2006 11:43:44 -0700
From:      "Pat Maddox" <pergesu@gmail.com>
To:        "FreeBSD Questions" <freebsd-questions@freebsd.org>
Subject:   lighttpd does 26 req/s on a static file
Message-ID:  <810a540e0603051043j2364a682m7b8fd2d1820398e4@mail.gmail.com>

index | next in thread | raw e-mail

I'm getting 26 req/s on a static file.  Not sure why it's so slow, I
could really use some help.  Running lighty 1.4.10 on FreeBSD 6.0.
Server is a basically unused AMD Barton 3000+ with a gig of RAM, hosted
at a data center.

-bash-2.05b$ ab -c 9 -n 500 http://72.21.52.134/hello.html

Benchmarking 72.21.52.134 (be patient)
...
Finished 500 requests


Server Software:        lighttpd
Server Hostname:        72.21.52.134
Server Port:            80

Document Path:          /hello.html
Document Length:        13 bytes

Concurrency Level:      9
Time taken for tests:   19.78523 seconds
Complete requests:      500
Failed requests:        0
Write errors:           0
Total transferred:      119500 bytes
HTML transferred:       6500 bytes
Requests per second:    26.21 [#/sec] (mean)
Time per request:       343.413 [ms] (mean)
Time per request:       38.157 [ms] (mean, across all concurrent
requests)
Transfer rate:          6.08 [Kbytes/sec] received



Here's the lighty config:

server.modules              = (
                               "mod_access",
                               "mod_accesslog" )
server.document-root       = "/usr/local/www/data"
server.port                = 80
server.username            = "www"
server.groupname           = "clients"
server.pid-file            = "/var/run/lighttpd.pid"
server.tag                 = "lighttpd"
accesslog.filename         = "/var/log/lighttpd.access.log"
server.errorlog            = "/var/log/lighttpd.error.log"
server.indexfiles          = ( "index.php", "index.html",
                              "index.htm", "default.htm" )
url.access-deny            = ( "~", ".inc" )

mimetype.assign             = (
 ".html"         =>      "text/html",
 ".htm"          =>      "text/html",
)

weigon_ on #lighttpd had me run ktrace, and here's the part he found relevant
22.577040 CALL  accept(0x4,0xbfbfea40,0xbfbfea3c)
22.577583 CALL  close(0x8)
75740 lighttpd 22.577632 CALL  poll(0x806ec00,0x2,0x3e8)
75740 lighttpd 22.614031 RET   poll 1

So it's .5ms to handle a request, but 40ms waiting for the next
request.  I'm not entirely sure what any of this means.

Thanks for any help,
Pat


help

Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?810a540e0603051043j2364a682m7b8fd2d1820398e4>