Wednesday, August 27, 2014

How to install memcahe on a cpanel server

For CentOS 6 64 bit,

# rpm -Uvh epel-release-6-7.noarch.rpm
yum install memcached
vi /etc/sysconfig/memcached
# Running on Port 11211

# Start as memcached daemon

# Set max simultaneous connections to 1024

# Set Memory size to 2048 - 4GB(4096)

#Set server IP address

chkconfig --levels 235 memcached on
/etc/init.d/memcached start

Then, install PHP memcache

pecl install memcache
service httpd restart

Monday, August 25, 2014

Install and configure Postgresql in Centos

How to install and configure Postgresql in Centos

yum install postgresql postgresql-server
chkconfig postgresql on
service postgresql initdb
service postgresql start

Now Postgresql has been installed in your box.

From Windows client i need to connect with this postgresql server. For that i download and install  pgAdminIII

Before getting connect, we have to allow remote clients to get connection in the server

Login to the postgresql box
su - postgres
vi /var/lib/pgsql/data/postgresql.conf
Change the line "listen_address='localhost'" to listen_address='*'
Uncomment port 5432 

Also we have to mention the client IP to allow/trust in postgresql server

vi  /var/lib/pgsql/data/pg_hba.conf  
host all all md5
host all all md5

Restart the service.

Now i can connect to postgresql server from the windows client using the pgAdmin tool 

Thursday, August 14, 2014

Resolving alfresco to port 80

I need to change the default port of alfresco (http://ip:8080/share) to listen on port 80(http://ip/share)
My alfresco verion is 3.4 community edition
OS is windows 2008 R2

We need to edit two configuration files for listening alfresco from port 8080 to 80.

1. tomcat/shared/classes/alfresco/web-extension/share-config-custom.xml
    Change all ports from 8080 to the desired port
    Save file

2. tomcat/conf/server.xml
    Find the line having ajp
    Change the connector port from 8080 to 80
     Save file

Restart alfresco service.

Try to access http://ip/share
Login with your credentials.