nginx does not close the connection to backend pop3 server

Joe Wong joew at outblaze.com
Tue Jul 24 10:33:23 MSD 2007


Hi Igor,

Ok, the log has been sent to you directly in another mail.

- Joe

Igor Sysoev wrote:
> On Tue, Jul 24, 2007 at 10:16:03AM +0800, Joe Wong wrote:
>
>   
>> I am evaluating nginx pop3 proxy function and encounter 1 problem. Here 
>> is my setup:
>>
>> OS: RedHat FC7 2.6.21-1.3194.fc7 #1 SMP Wed May 23 22:35:01 EDT 2007 
>> i686 i686 i386 GNU/Linux
>> GCC: gcc version 4.1.2 20070502 (Red Hat 4.1.2-12)
>> Nginx version: 0.5.26
>> Config option: --with-debug --with-mail --with-select_module
>>
>> Nginx config:
>> daemon on;
>> user root;
>> worker_processes 10;
>>
>> error_log logs/error.log debug;
>> pid       logs/nginx.pid;
>>
>> #maximum total connections of each worker
>> events {
>>    worker_connections 100;
>> #    use select;
>>    debug_connection 127.0.0.1;
>> }
>>
>> mail {
>>    auth_http   localhost:8088/auth.php;
>>
>>    pop3_capabilities  "TOP"  "USER";
>>    pop3_auth          plain;
>>    imap_capabilities  "IMAP4rev1"  "UIDPLUS";
>>
>>    #pop3 configuration
>>    server {
>>        listen     110;
>>        protocol   pop3;
>>        proxy      on;
>>    }
>> }
>>
>>
>> Test case:
>> - A mailbox with message around 10M large
>> - Use telnet to port 110, issue the USER/PASS command to login
>> - Issue RETR 1 to download the 10M message
>> - Close the connection by pressing Ctrl-] then 'q' right after RETR 
>> command is issued
>>
>> At this time,  Netstat shows that the connection from nginx to the 
>> backend POP3 server remains connected.
>>
>> Now, I repeat the above test case with "use select" turns on in 
>> nginx.conf.  This time, I don't see the connection to backend pop3 
>> remains after my client connection to nginx is terminated in the middle. 
>> I suspect this is something to do with epoll call?
>>
>> I only did the test on POP3 proxy, not sure if it has the same behaviour 
>> on HTTP.
>>
>> Please let me know if you need more information.
>>     
>
> Could you create debug logs for epoll and select cases, and send them to me ?
>
>
>   

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://nginx.org/pipermail/nginx/attachments/20070724/1725cb2d/attachment.html>


More information about the nginx mailing list