httpd-modules-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Danie Qian" <>
Subject Re: process pool does not work
Date Tue, 15 May 2007 14:30:07 GMT

----- Original Message ----- 
From: "Zeus Capricorn" <>
To: <>
Sent: Tuesday, May 15, 2007 4:14 AM
Subject: process pool does not work

> Hi,folks.
>    i want to log the online user's ip in the apache memory and check it
> through a specific url.
>    first,I use ap_hook_process_connection to log the user's ip and the
> time,and i use ap_hook_handler to check the result.
>    in the callback function of ap_hook_process_connection,i allocate
> my_hash(a apr_hash_t) in the pool(c->base_server->process->pool) if 
> my_hash
> is NULL,and set the c->remote_ip as key,a point to the time now as value.
>    in the callback function of ap_hook_handler,i use apr_hash_next() to 
> get
> the value one by one.
>    it works not as what i supposed to do .every client which access my
> specific url can only see his own ip and time,not ALL the clients.
>    could someone help me ?should i use another pool,or something else?
>    thanks in advance.

You need to use IPC shared memory for all child processes to work on the 
same segment of physical memory. Someone posted a sample code in the archive 
in year 2004 and could be your good starting point.


View raw message