3 messages in ru.sysoev.nginxRe: X-LIGHTTPD-SID
FromSent OnAttachments
smileyJun 23, 2007 8:26 am 
Evan MillerJun 23, 2007 9:11 am 
smileyJun 23, 2007 9:18 am 
Actions with this message:
Paste this link in email or IM:
Paste this link in email or IM:
Atom feed for this thread
Paste this URL into your reader:
Subject:Re: X-LIGHTTPD-SIDActions...
From:smiley (smil@public.gmane.org)
Date:Jun 23, 2007 9:18:36 am
List:ru.sysoev.nginx

On Sat, 23 Jun 2007 17:12:14 +0100, Evan Miller
<emmiller+gman@public.gmane.org> wrote:

smiley <smileyrecords.tk@...> writes:

so therefore this script would send a test 10MB file to the client and the session_id would be logged into the access-log

this is an incredibly usefull feature as the logs can be parsed later to deduce how much bandwidth was used per session!

Try a variation on this:

log_format my_log_format "$bytes_sent $upstream_http_x_session_id" access_log /somewhere/access.log my_log_format

Then send the header from the PHP script as "X-Session-ID". Use proxy_hide_header if you wish to suppress X-Session-ID from the client.

thanks Evan for fast reply! im gonna run some tests now then make an article on a blog or on the nginx wiki detailing the setup, might come in usefull for someone else