I've been busy testing megacomet on an EC2 micro instance. Keep in mind this testing is pretty crummy, given the instance only has 600M memory and i'm running the fake-client-flooding app on the same box as the server. Anyway, i was able to get up to 50k connections open before things started getting slow. I'm not sure if i hit a configuration limit, or a memory limit, or what. Testing continues...

Anyway, here's the 'top' results, showing that 50k connections roughly means 16M memory usage:

 

top - 08:52:17 up 58 min,  2 users,  load average: 0.13, 0.16, 0.22
Tasks:  68 total,   1 running,  67 sleeping,   0 stopped,   0 zombie
Cpu(s):  0.0%us,  0.0%sy,  0.0%ni,100.0%id,  0.0%wa,  0.0%hi,  0.0%si,  0.0%st
Mem:    611212k total,   581608k used,    29604k free,     3760k buffers
Swap:        0k total,        0k used,        0k free,    25356k cached

  PID USER      PR  NI  VIRT  RES  SHR S %CPU %MEM    TIME+  COMMAND          
22542 root      20   0 10392 2020  116 S  0.0  0.3   0:01.47 megacomet         
22548 root      20   0 10400 2016  116 S  0.0  0.3   0:01.48 megacomet         
22544 root      20   0 10452 2004  108 S  0.0  0.3   0:01.49 megacomet         
22546 root      20   0 10392 1968  108 S  0.0  0.3   0:01.49 megacomet         
22543 root      20   0 10388 1908   60 S  0.0  0.3   0:01.48 megacomet         
22549 root      20   0 10396 1860   20 S  0.0  0.3   0:01.47 megacomet         
22545 root      20   0 10396 1840    0 S  0.0  0.3   0:01.47 megacomet         
22547 root      20   0 10392 1840    0 S  0.0  0.3   0:01.50 megacomet

 

And here's where i got the kernel tuning tips from:

http://www.metabrew.com/article/a-million-user-comet-application-with-mochiwe...

http://www.cs.wisc.edu/condor/condorg/linux_scalability.html

Thanks for reading! And if you want to get in touch, I'd love to hear from you: chris.hulbert at gmail.

Chris Hulbert

(Comp Sci, Hons - UTS)

iOS Developer (Freelancer / Contractor) in Australia.

I have worked at places such as Google, Cochlear, Assembly Payments, News Corp, Fox Sports, NineMSN, FetchTV, Coles, Woolworths, Trust Bank, and Westpac, among others. If you're looking for help developing an iOS app, drop me a line!

Get in touch:
[email protected]
github.com/chrishulbert
linkedin
my resume



 Subscribe via RSS