LVS
lvs-users
Google
 
Web LinuxVirtualServer.org

multi-thread event-driven for KTCPVS

To: lvs-users@xxxxxxxxxxxxxxxxxxxxxx
Subject: multi-thread event-driven for KTCPVS
From: dragonfly@xxxxxxxxxxxx
Date: Fri, 4 Feb 2005 23:51:52 +0800
Hi,
    Recently I readed the kernel sources about sys_select() and
sys_poll() etc.I think it is good to use the mechanism in KTCPVS.With
this technique,all oprations which maybe be blocked can be removed.In
current KTCPVS implementation,A kernel thread only handle one
connection,until it done.It often be blocked to wait for responses from
client or responses from real server which bring system low
throughput.Especially,if someone connect the server then keep
silent,that means a DOS attack.Although in KTCPVS,set sysctl variable
'sysctl_ktcpvs_read_timeout' to avoid this case,but it is not
efficient enough.
    I made some changes to KTCPVS(0.0.18 release) to use multi-thread
event-driven architecture.In addtion,i use slab cache instead of kmalloc
to create and free 'tcp_vs_conn' object,for its
alloc and free have high frequency.I have done some tests,it seemed no
problem:).Details about data structure and all the codes can be
downloaded from 
http://dragon.linux-vs.org/~dragonfly/software/ktcpvs.rar.
Yeah,It is simple,but hope it useful:)
Discussions and advices are very welcome:)

regards
    


<Prev in Thread] Current Thread [Next in Thread>
  • multi-thread event-driven for KTCPVS, dragonfly <=