<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 TRANSITIONAL//EN">
<HTML>
<HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; CHARSET=UTF-8">
<META NAME="GENERATOR" CONTENT="GtkHTML/3.16.3">
</HEAD>
<BODY>
<BR>
On Thu, 2010-03-18 at 14:36 +1100, Robert Mueller wrote:
<BLOCKQUOTE TYPE=CITE>
<PRE>
<FONT COLOR="#000000">> $user['user1'] = 10.1.1.1;</FONT>
<FONT COLOR="#000000">> $user['user2'] = 10.1.1.2;</FONT>
<FONT COLOR="#000000">> ----</FONT>
<FONT COLOR="#000000">> $user[user15000]=10.1.1.1;</FONT>
<FONT COLOR="#000000">> For 15k users this method becomes very heavy. There are too many httpd</FONT>
<FONT COLOR="#000000">> processes running that suck the resources on the machine. I want to</FONT>
<FONT COLOR="#000000">> store the userlist in a memcache and look it up through nginx.conf</FONT>
<FONT COLOR="#000000">> How do I do this ?</FONT>
<FONT COLOR="#000000">Don't use memcache, it's a *cache*, you want a *database*. So</FONT>
<FONT COLOR="#000000">just use a database to store the data, and look it up for each</FONT>
<FONT COLOR="#000000">user. eg.</FONT>
<FONT COLOR="#000000">mysql: <A HREF="http://php.net/manual/en/book.mysql.php">http://php.net/manual/en/book.mysql.php</A></FONT>
<FONT COLOR="#000000">bdb: <A HREF="http://www.oracle.com/technology/documentation/berkeley-db/db/programmer_reference/ext_php.html">http://www.oracle.com/technology/documentation/berkeley-db/db/programmer_reference/ext_php.html</A></FONT>
<FONT COLOR="#000000">Choose your favourite key/value db here...</FONT>
</PRE>
</BLOCKQUOTE>
But I thought a memcache lookup will be much more inexpenisve than connecting to a mysql db to do lookup for every cyrus connection<BR>
<BR>
Is that not true. <BR>
<BR>
<BR>
Thanks<BR>
Ram<BR>
<BR>
</BODY>
</HTML>