Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Memcache addserver() on distributed servers

Status
Not open for further replies.

AcidReignX

Programmer
Feb 28, 2005
32
US
Hey everyone,

I've been using memcache recently (works like a charm, btw - really drops the CPU load), and I'm now setting up a load balancer for my distributed server network. With the addition of this server, I now really need to have the ability to use my memcache in various servers.

This tutorial: - explains pretty much exactly what I'm doing, which is simply this:

$MEMCACHE_SERVERS = array(
"10.10.10.10" # first_server
"10.10.10.11" # second_server
);

$memcache = new Memcache();

foreach($MEMCACHE_SERVERS as $server)
{
$memcache->addServer ( $server, 11211 );
}

And then using memcache from there. Now, when I use "localhost" instead of an IP address, it works perfectly. But the minute I use an IP address (even if that IP address is the same computer as the localhost), it won't connect any more.

Does anybody know what sort of issue this is? Am I just blocking out some sort of external whatchymacalit?
 
Possibly a packet filter? Try telnetting to port 11211 and see what you get.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top