How to , and other stuff about linux, photo, php … A linux, photography blog. To remember some linux situation, and fix them quickly.

January 28, 2013

Centos 6 pecl install memcached error

Filed under: Linux — Tags: , , , — admin @ 5:50 pm

Today I try to install memcached on a server with centos 6. So basically when I hit
pecl install memcached
I get a lot of errors
checking for libmemcached location... configure: error: memcached support requires libmemcached 1.0.x. Use --with-libmemcached-dir= < DIR> to specify the prefix where libmemcached headers and library are located
ERROR: `/var/tmp/memcached/configure' failed

So if I try to install libmemcached by using
yum install libmemcached libmemcached-devel
I see that version of libmemcached will be smaller then 1.0.x

So to install it
cd /usr/local/src
wget https://launchpad.net/libmemcached/1.0/1.0.15/+download/libmemcached-1.0.15.tar.gz
tar -zxvf libmemcached-1.0.15.tar.gz
cd libmemcached-1.0.15
./configure
make
make install

After this try
pecl install memcached

For me this was the working version.

January 4, 2013

how to modify nginxcp vhost templates

Filed under: Linux — admin @ 1:52 pm

Hmm
Today I face a little problem. I install on a server nginxcp, and because I wanted varnish also, I have to modify nginx to run on other port then 80. So basically I modify zones every time after I have add them, but how to automate this.

After a little search and no answer I found the file that is responsibly for this.

So basically in /scripts/ you will find a new file called createvhosts.py

You have to modify here what you want to be keep into your zone automatically.
So to change the port from 80 to 81, I just have to modify this line
listen %s:80;
into
listen %s:81;

Please notice that are 2 modification that you have to do on that file.

If this help you please make a social bookmark for our site / page

Regards

Powered by WordPress