thinking in geek tagline’s are so web2.0

Posted
8 November 2007 @ 6pm

Tagged
asp.net, memcached, web architecture

Multiple instances of memcached on win32

It seems like the win32 crowd is discovering memcached. I’ve got a couple of support queries about it over the last month or two and I thought I’d post an interesting one here:

“How can you run multiple instances of memcached on a single machine?”

There’s a couple of reasons why you’d want to do this. The most obvious is that you’ve got multiple clients being serviced on a single machine and you want to absolutely ensure that data is not leaking from one client to another.

If you want to setup multiple instances the once you’ve got the win32 port downloaded and unziped somewhere you need to use the following magic incantation:

sc create memcached2 binPath= “c:\memcached\memcached.exe -p 11111 -d runservice”

You can pass any other params you wish (e.g. amount of memory to use). To run multiple instances just install multiple services with different names/ports.

Note: “sc” is the command line tool for working with the win32 service control manager. It allows you to stop/start/create/delete and more - windows services. Check out it’s command line help by typing “sc” at the command line.


No Comments Yet


There are no comments yet. You could be the first!

Leave a Comment

Eric Evans on over-design and intrinsic complexity Enterprise plaforms - teaching new dogs old tricks