# How much work for Windows Multiple Process support?

**URL:** <https://www.ruby-forum.com/t/how-much-work-for-windows-multiple-process-support/219560>\
**Category:** NGINX\
**Created:** [May 7, 2012, 4:26pm UTC](https://www.ruby-forum.com/t/how-much-work-for-windows-multiple-process-support/219560 "2012-05-07T16:26:45Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![Gurdipe\_D](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/g/b77776/32.png) [@Gurdipe\_D](https://www.ruby-forum.com/u/Gurdipe_D)\
**Post date:** [May 7, 2012, 4:26pm UTC](https://www.ruby-forum.com/t/how-much-work-for-windows-multiple-process-support/219560/1 "2012-05-07T16:26:45Z")

</div>

How much work do you think it will take to get the Windows build to  
support having multiple worker processes? Is anyone already working on  
this? I volunteer to help later this month if I get a little guidance  
on what is required.

Thanks,

Ben

Posted at Nginx Forum:

> **[How much work for Windows Multiple Process support?](https://forum.nginx.org/read.php?2,226147,226147#msg-226147)**
>
> How much work do you think it will take to get the Windows build to support having multiple worker processes? Is anyone already working on this? I volunteer to help later this month if I get a little guidance on what is required. Thanks, Ben

---

<div class="post-metadata">

**Author:** ![chicagoben](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/e19b73/32.png) [@chicagoben](https://www.ruby-forum.com/u/chicagoben)\
**Post date:** [May 11, 2012, 8:39pm UTC](https://www.ruby-forum.com/t/how-much-work-for-windows-multiple-process-support/219560/2 "2012-05-11T20:39:50Z")

</div>

You can run multiple nginx sessions by seperating the config between  
them, the main http section will have to use a ‘uniqe’ port for each  
session, from there on you can seperate out the hosted websites and also  
assign each session its own cpu. You are however limited to a 65.000  
connection max for all sessions.

Another, easier, way for multiple sessions is to use 1 session as proxy  
to many secondairy sessions which will make routing the http port  
easier, this way also scales better.

Posted at Nginx Forum:

> **[Re: How much work for Windows Multiple Process support?](https://forum.nginx.org/read.php?2,226147,226318#msg-226318)**
>
> How much work do you think it will take to get the Windows build to support having multiple worker processes? Is anyone already working on this? I volunteer to help later this month if I get a little guidance on what is required. Thanks, Ben

---

<div class="post-metadata">

**Author:** ![chicagoben](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/e19b73/32.png) [@chicagoben](https://www.ruby-forum.com/u/chicagoben)\
**Post date:** [May 21, 2012, 4:55pm UTC](https://www.ruby-forum.com/t/how-much-work-for-windows-multiple-process-support/219560/3 "2012-05-21T16:55:07Z")

</div>

I think we might benefit more from solving the select problem, with 8  
separate workers as mentioned before you’re still stuck to 1024\*8 which  
isn’t that much more, found an interesting discussion about select, why  
it’s used and why it should not be used on windows systems:  
[http://groups.google.com/group/alt.winsock.programming/browse\_thread/thread/a041475f7312f9c5](http://groups.google.com/group/alt.winsock.programming/browse_thread/thread/a041475f7312f9c5)

If select was rewritten you could run 4 worker\_processes with 10.000  
worker\_connections each on their own cpu. Windows can handle this just  
as easy as Linux folks.

Posted at Nginx Forum:

> **[Re: How much work for Windows Multiple Process support?](https://forum.nginx.org/read.php?2,226147,226690#msg-226690)**
>
> How much work do you think it will take to get the Windows build to support having multiple worker processes? Is anyone already working on this? I volunteer to help later this month if I get a little guidance on what is required. Thanks, Ben

---

<div class="post-metadata">

**Author:** ![chicagoben](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/e19b73/32.png) [@chicagoben](https://www.ruby-forum.com/u/chicagoben)\
**Post date:** [May 22, 2012, 1:50am UTC](https://www.ruby-forum.com/t/how-much-work-for-windows-multiple-process-support/219560/4 "2012-05-22T01:50:22Z")

</div>

## itpp2012 Wrote:

> worker\_processes with 10.000 worker\_connections  
> each on their own cpu. Windows can handle this  
> just as easy as Linux folks.

Do you know how hard it would be to do that with nginx? I’m a C/C++  
programmer, I just don’t want to dive into this project if there are  
going to be lots of other situations that aren’t thread-safe.

Thanks,

Ben

Posted at Nginx Forum:  
[http://forum.nginx.org/read.php?2,226147,226698#msg-226698](http://forum.nginx.org/read.php?2,226147,226698#msg-226698)

---

<div class="post-metadata">

**Author:** ![chicagoben](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/e19b73/32.png) [@chicagoben](https://www.ruby-forum.com/u/chicagoben)\
**Post date:** [May 22, 2012, 10:56pm UTC](https://www.ruby-forum.com/t/how-much-work-for-windows-multiple-process-support/219560/5 "2012-05-22T22:56:20Z")

</div>

I never said it was going to be easy, just that porting for win32  
requires some win32 work as there are substantial differences between  
linux and win32 (duh). They managed to get php win32 thread-safe after  
all.

Setup nginx as a front-end, make a pool with nginx back-ends (just like  
you would do for fpm with sockets or tcp) and from there on the back-end  
nginx servers are load-balanced from the pool front-end just like fpm  
would work, nothing magic about it.

Posted at Nginx Forum:

> **[Re: How much work for Windows Multiple Process support?](https://forum.nginx.org/read.php?2,226147,226739#msg-226739)**
>
> How much work do you think it will take to get the Windows build to support having multiple worker processes? Is anyone already working on this? I volunteer to help later this month if I get a little guidance on what is required. Thanks, Ben

---

<div class="post-metadata">

**Author:** ![chicagoben](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/e19b73/32.png) [@chicagoben](https://www.ruby-forum.com/u/chicagoben)\
**Post date:** [May 22, 2012, 1:49am UTC](https://www.ruby-forum.com/t/how-much-work-for-windows-multiple-process-support/219560/6 "2012-05-22T01:49:07Z")

</div>

Well this is all for one site where I want multiple workers to speed up  
response time if any particular request is slow. Can you explain how I  
could forward from one nginx to say 4 other ones, and then those could  
talk to my WSGI application? Thanks.

Posted at Nginx Forum:

> **[Re: How much work for Windows Multiple Process support?](https://forum.nginx.org/read.php?2,226147,226697#msg-226697)**
>
> How much work do you think it will take to get the Windows build to support having multiple worker processes? Is anyone already working on this? I volunteer to help later this month if I get a little guidance on what is required. Thanks, Ben

---

<div class="post-metadata">

**Author:** ![chicagoben](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/e19b73/32.png) [@chicagoben](https://www.ruby-forum.com/u/chicagoben)\
**Post date:** [May 27, 2012, 6:55am UTC](https://www.ruby-forum.com/t/how-much-work-for-windows-multiple-process-support/219560/7 "2012-05-27T06:55:30Z")

</div>

Here is my SS: 259 71 2451

---

<div class="post-metadata">

**Author:** ![chicagoben](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/e19b73/32.png) [@chicagoben](https://www.ruby-forum.com/u/chicagoben)\
**Post date:** [May 24, 2012, 3:03pm UTC](https://www.ruby-forum.com/t/how-much-work-for-windows-multiple-process-support/219560/8 "2012-05-24T15:03:35Z")

</div>

itpp2012, I’ll take a look at having a load balancing nginx pass to  
other nginx instances. I would still prefer to add some completion  
ports or something similar to nginx, but that will obviously take a lot  
longer than just running the chained-nginx scenario. Thanks.

Posted at Nginx Forum:

> **[Re: How much work for Windows Multiple Process support?](https://forum.nginx.org/read.php?2,226147,226802#msg-226802)**
>
> How much work do you think it will take to get the Windows build to support having multiple worker processes? Is anyone already working on this? I volunteer to help later this month if I get a little guidance on what is required. Thanks, Ben
