Jump to content

Memcache with socket instead of TCP/IP


Recommended Posts

Posted

So recently I found out that my host moved away from TCP/IP ports for their memcache, and went with a socket (apparently its faster). Basically I have a path to put in now. Will this work with IPB? I went ahead and put it in, uploaded the new constraints file to the root. Is there anyway to test to see if memcache is actually working? I just want to clarify that IPB will work like this, and if there is a way to actually see if it's functional. Thanks.

Posted

Hi :)

Just run from ssh:

echo stats | nc 127.0.0.1 11211

Then check the values:

STAT get_hits
STAT get_misses

to see if you have any hits and how many misses :)

Posted

You can download a GUI admin panel for memcached .php file and upload it to your public_html folder and then check hits/misses from the browser :)

Just google it and you will find a few options to download and test :)

Posted

Yes Brandon from support was super helpful, he even provided me screenshots to show it was being  cached. I just put in the full path  to the socket and made sure to upgrade the new script it generates to my root and it just worked. So apparently IPB uses both tcp/ip and sockets as well.

Posted

Solution from Marc:

You would add the following to your constants.php file instead 

define( 'CACHE_METHOD', 'Memcache' );
define( 'CACHE_CONFIG', '{"servers":["\\/some\\/path\\/here\\/memcached.sock"]}' );
define( 'CACHE_PAGE_TIMEOUT', 30 );

If you want to then ensure that caching is working correctly on your site, you can add this to your constants.php file temporarily, which will show you what is being cached

define( 'CACHING_LOG', true );

Archived

This topic is now archived and is closed to further replies.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...