{"id":984,"date":"2013-11-29T15:30:19","date_gmt":"2013-11-29T23:30:19","guid":{"rendered":"http:\/\/blog.portnumber53.com\/?p=984"},"modified":"2013-11-29T15:30:19","modified_gmt":"2013-11-29T23:30:19","slug":"hosting-enabling-redis-class-on-mediatemples-gridserver-gs","status":"publish","type":"post","link":"https:\/\/blog.portnumber53.com\/index.php\/2013\/11\/29\/hosting-enabling-redis-class-on-mediatemples-gridserver-gs\/","title":{"rendered":"Hosting: Enabling Redis class on MediaTemple&#8217;s gridserver (gs)"},"content":{"rendered":"<p>Here&#39;s how I enabled access to a Redis server from my (GS) gridserver:<\/p>\n<p>1. Store your SITEID in a variable:<\/p>\n<pre>export SITEID=`pwd | awk -F\\\/ &#39;{ print $3 }&#39;`<\/pre>\n<p>&nbsp;<\/p>\n<p>2. Create a folder to store the redis.so module<\/p>\n<pre>mkdir \/home\/$SITEID\/data\/lib\nmkdir \/home\/$SITEID\/data\/lib\/php\/<\/pre>\n<p>&nbsp;<\/p>\n<p>3. Get the Redis PECL package (2.2.4 is the latest as of now)<\/p>\n<pre>wget http:\/\/pecl.php.net\/get\/redis-2.2.4.tgz<\/pre>\n<p>&nbsp;<\/p>\n<p>4. Uncompress it<\/p>\n<pre>tar -xvzf redis-2.2.4.tgz\ncd redis-2.2.4<\/pre>\n<p>&nbsp;<\/p>\n<p>5. Compile it. I&#39;ve set my (gs) to use PHP 5.5.5; change your accordingly<\/p>\n<pre>.\/configure --with-php-config=\/usr\/local\/php-5.5.5\/bin\/php-config\nmake<\/pre>\n<p>&nbsp;<\/p>\n<p>6. &quot;install&quot; the module<\/p>\n<pre>cp modules\/*.so \/home\/$SITEID\/data\/lib\/php<\/pre>\n<p>&nbsp;<\/p>\n<p>7. Add the following to your \/home\/SITEID\/etc\/php.ini<\/p>\n<pre>;PECL\nextension_dir=\/home\/97042\/data\/lib\/php\/\n;redisphp\nextension=redis.so<\/pre>\n<p>&nbsp;<\/p>\n<p>Check it:<\/p>\n<p>Visit http:\/\/SITEID.gridserver.com\/gs-bin\/phpinfo.php-latest<\/p>\n<p>&nbsp;<\/p>\n<p><a href=\"http:\/\/blog.portnumber53.com\/wp-content\/uploads\/2013\/11\/redis-2-2-4-module.png\"><img loading=\"lazy\" decoding=\"async\" alt=\"redis-2-2-4-module\" class=\"aligncenter size-full wp-image-985\" height=\"107\" src=\"http:\/\/blog.portnumber53.com\/wp-content\/uploads\/2013\/11\/redis-2-2-4-module.png\" width=\"638\" \/><\/a><\/p>\n<p>References<\/p>\n<ul>\n<li>https:\/\/kb.mediatemple.net\/questions\/1682\/Installing+PECL+extensions#gs<\/li>\n<li>https:\/\/github.com\/nicolasff\/phpredis\/issues\/42<\/li>\n<li>http:\/\/pecl.php.net\/package\/redis<\/li>\n<\/ul>\n","protected":false},"excerpt":{"rendered":"<p>Here&#39;s how I enabled access to a Redis server from my (GS) gridserver: 1. Store your SITEID in a variable: export SITEID=`pwd | awk -F\\\/ &#39;{ print $3 }&#39;` &nbsp; 2. Create a folder to store the redis.so module mkdir \/home\/$SITEID\/data\/lib mkdir \/home\/$SITEID\/data\/lib\/php\/ &nbsp; 3. Get the Redis PECL package&#8230; <a class=\"continue-reading-link\" href=\"https:\/\/blog.portnumber53.com\/index.php\/2013\/11\/29\/hosting-enabling-redis-class-on-mediatemples-gridserver-gs\/\"> Continue reading <span class=\"meta-nav\">&rarr; <\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[11],"tags":[32,167,235,259,270,272,288],"class_list":["post-984","post","type-post","status-publish","format-standard","hentry","category-hosting","tag-gs","tag-gridserver","tag-mediatemple","tag-nicolasffphpredis","tag-pecl","tag-php","tag-redis"],"_links":{"self":[{"href":"https:\/\/blog.portnumber53.com\/index.php\/wp-json\/wp\/v2\/posts\/984","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/blog.portnumber53.com\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/blog.portnumber53.com\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/blog.portnumber53.com\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/blog.portnumber53.com\/index.php\/wp-json\/wp\/v2\/comments?post=984"}],"version-history":[{"count":0,"href":"https:\/\/blog.portnumber53.com\/index.php\/wp-json\/wp\/v2\/posts\/984\/revisions"}],"wp:attachment":[{"href":"https:\/\/blog.portnumber53.com\/index.php\/wp-json\/wp\/v2\/media?parent=984"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blog.portnumber53.com\/index.php\/wp-json\/wp\/v2\/categories?post=984"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blog.portnumber53.com\/index.php\/wp-json\/wp\/v2\/tags?post=984"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}