• Get In Touch
May 26, 2017

How to Install Zurmo CRM on CentOS 7

Want your very own server? Get our 1GB memory, Xeon V4, 25GB SSD VPS for £10.00 / month.
Get a Cloud Server

Zurmo is a free and open-source web-based customer relationship management application. It is written in PHP using jQuery, Yii Framework, and RedBeanPHP and it uses MySQL to store its database. Zurmo is easy to use and easy to customise. It provides numerous features such as Contact Management, Activity Management, Deal Tracking, Gamification, Reporting, Workflow, Marketing Automation, Product Management etc. It is responsive and available in many languages. Numerous businesses are already using the software.

In this tutorial, we will install Zurmo CRM on CentOS 7 server.

Requirements

Zurmo CRM does not require any special hardware requirements. It can be installed on servers with just 256MB of RAM. However, the recommended memory requirement is 512MB. All the required dependencies will be installed throughout the tutorial. You will need a minimal installation of CentOS 7 with root access on it. If you are logged in as a non-root user, you can run sudo -i to switch to root user.

Installing Zurmo

Before installing any package it is recommended that you update the packages and repository using the following command.

yum -y update

Once you have your system updated, you can proceed to install the LAMP stack. Start the LAMP installation by installing Apache web server and MariaDB, which is a fork of MySQL using the following command.

yum -y install httpd mariadb-server mariadb

Zurmo can be installed on any version of PHP greater than 5.3.3. But as PHP 5.3 has reached the end of life. We will install PHP 5.6 to obtain high performance and security. PHP 5.6 is not included in default YUM repository, hence you will need to add the Webtatic repository in your system. Webtatic repository requires EPEL repository to work. Run the following command to install EPEL repository.

yum -y install epel-release
yum -y update

Now install Webtatic repository using the following commands.

rpm -Uvh https://mirror.webtatic.com/yum/el7/webtatic-release.rpm
yum -y update

To install PHP 5.6 and all the required PHP modules, run the following command.

yum -y install php56w php56w-cli php56w-pcre php56w-spl php56w-ctype php56w-soap php56w-curl php56w-mbstring php56w-pecl-apcu php56w-pecl-memcache php56w-imap php56w-pdo php56w-pdo_mysql php56w-zip php56w-gd php56w-mcrypt php56w-ldap

Once you have PHP installed, you can check the version of PHP using the following command.

php -v

You should get output similar to this.

[root@liptan-pc ~]# php -v
PHP 5.6.30 (cli) (built: Jan 19 2017 22:31:39)
Copyright (c) 1997-2016 The PHP Group
Zend Engine v2.6.0, Copyright (c) 1998-2016 Zend Technologies

You will also need to make a change into PHP configuration file /etc/php.ini. Open /etc/php.ini using your favorite editor.

nano /etc/php.ini

If you do not have nano installed, you can install it using yum -y install nano. Scroll down to find the following lines.

[Date]
; Defines the default timezone used by the date functions
; http://php.net/date.timezone
;date.timezone =

Remove the semicolon from the start of the line and provide the appropriate time zone. For example

date.timezone = Asia/Kolkata

Now find the following lines and change the values according to instructions given.

upload_max_filesize = 2M    #Change the value to at least 20M
post_max_size = 8M            #Change the value to at least 20M
max_execution_time = 30        #Change the value to at least 300
zend.assertions = -1        #Change the value to 0

Save the file and exit from editor. Now start Apache web server and enable it to start at boot time using the following command.

systemctl start httpd
systemctl enable httpd

You will also need to install Memcached for caching the resources. Install Memcached using the following command.

yum -y install memcached

Now start and enable Memcached to automatically start at boot time.

systemctl enable memcached
systemctl start memcached

To start MariaDB and enable it to start at boot time using the following commands.

systemctl start mariadb
systemctl enable mariadb

Now run the following commands to secure your MySQL or MariaDB installation.

mysql_secure_installation

It will run a small script which asks you to provide the root password for MariaDB. As we have just installed MariaDB, the root password is not set, just press enter to proceed further. It will ask you if you want to set a root password for your MariaDB installation, choose y and set a strong password for the installation. It will also ask you for removing test databases and anonymous users. Most of the questions are self-explanatory and you should answer y to all the questions.

To create a database we will need to login to MySQL command line first. Run the following command for same.

mysql -u root -p

This will prompt you for the password, provide the root password of MySQL which you have set earlier. Now run the following query to create a new database for your Zurmo installation.

CREATE DATABASE zurmo_data;

The above query will create a database named zurmo_data. Make sure that you use semicolon at the end of each query as the query always ends with a semicolon. Once the database is created you can create a new user and grant all the permissions to the user for the database. Using root user is not recommended for the databases. To create a new database user, run the following query.

CREATE USER 'zurmo_user'@'localhost' IDENTIFIED BY 'StrongPassword';

The above query will create a user with username zurmo_user. Now provide the appropriate privileges to your database user over the database you have created. Run the following command.

GRANT ALL PRIVILEGES ON zurmo_data.* TO 'zurmo_user'@'localhost';

Now run the following command to immediately apply the changes on the database privileges.

FLUSH PRIVILEGES;

Exit from MySQL prompt using exit command.

As we have all the dependencies ready, we can now download the install package from Zurmo website.

cd /var/www
wget http://build.zurmo.com/downloads/zurmo-stable-3.2.1.57987acc3018.tar.gz

You can always find the link to the latest version of the application on Zurmo CRM download page. Now extract the archive using the following command.

tar -xvzf zurmo-stable-*.tar.gz

The above command will extract the package to a directory called zurmo. Now you will need to disable your SELinux. To temporary disable SELinux, run the following command.

setenforce 0

To completely disable the SELinux you will need to edit /etc/selinux/config file.

nano /etc/selinux/config

Find the following line:

SELINUX=enforcing

Change it to:

SELINUX=disabled

Now, you will need to provide the ownership of the application to web server user using the following command.

chown -R apache:apache /var/www/zurmo

You may also need to allow HTTP traffic on port 80 through the firewall if you are running one. Run the following commands for same.

firewall-cmd --zone=public --permanent --add-service=http
firewall-cmd --reload

Now create a virtual host for the Zurmo application. Run the following command for same.

nano /etc/httpd/conf.d/crm.yourdomain.com.conf

Paste the following lines into the file.

<VirtualHost *:80>
    ServerAdmin me@liptanbiswas.com
    DocumentRoot "/var/www/zurmo/app"
    ServerName crm.yourdomain.com
    ServerAlias www.crm.yourdomain.com
    <Directory "/var/www/zurmo/app">
        Options Indexes FollowSymLinks
        AllowOverride All
        Require all granted
    </Directory>
    ErrorLog "/var/log/httpd/crm.yourdomain.com-error_log"
    CustomLog "/var/log/httpd/crm.yourdomain.com-access_log" combined
</VirtualHost>

Replace crm.yourdomain.com with any domain or sub-domain you want to use to access the application. Save the file and exit from the editor. Run the following command to restart your Apache server.

systemctl restart httpd

Now complete the installation using a web browser, go to the following link using your favourite web browser.

http://crm.yourdomain.com

You will be welcomed by the following page.

HP_NO_IMG/data/uploads/users/96ef1f90-83ed-46f0-9b58-aa6ee50a1451/381446566.png” alt=”” />

Click on Click to start button to go to the next step of installation. In this step, the installer will check if your system meets all the requirements needed to install the software. If you have followed the tutorial correctly, you should have all the requirements satisfied.

HP_NO_IMG/data/uploads/users/96ef1f90-83ed-46f0-9b58-aa6ee50a1451/976023131.png” alt=”” />

Click Continue button to proceed to the next step. You will need to fill out some information required for installation.

HP_NO_IMG/data/uploads/users/96ef1f90-83ed-46f0-9b58-aa6ee50a1451/339156085.png” alt=”” />

Use the default value in Database Hostname and Port. Leave the Database Admin Username and Password blank. Provide the name of the database you have created earlier in Database Name and select the Remove Existing Data check box. Provide the username and password of the database and also provide a new Superuser password. Leave the default value in Memcache hostname and port. Select the checkbox for demo data installation accordingly. Leave the default value in Host Info and Script URL. Once done click Install button. If everything is correct, the installer will automatically start to write the database. Once done, you will see the following screen.

HP_NO_IMG/data/uploads/users/96ef1f90-83ed-46f0-9b58-aa6ee50a1451/1732052568.png” alt=”” />

Click on Sign in button and login with username super and the super user password you provided before installation. You will be logged into the dashboard which will look like shown below.

HP_NO_IMG/data/uploads/users/96ef1f90-83ed-46f0-9b58-aa6ee50a1451/879031469.png” alt=”” />

Conclusion

In this tutorial, we learned how to install Zurmo on CentOS 7. You can now successfully deploy the Zurmo application to manage the relationships with your customers, which will increase the revenue generated.

Want your very own server? Get our 1GB memory, Xeon V4, 25GB SSD VPS for £10.00 / month.
Get a Cloud Server

Share this Article!

Related Posts

Node.js Authentication – A Complete Guide with Passport and JWT

Node.js Authentication – A Complete Guide with Passport and JWT

Truth be told, it’s difficult for a web application that doesn’t have some kind of identification, even if you don’t see it as a security measure in and of itself. The Internet is a kind of lawless land, and even on free services like Google’s, authentication ensures that abuses will be avoided or at least […]

Node.js and MongoDB: How to Connect MongoDB With Node

Node.js and MongoDB: How to Connect MongoDB With Node

MongoDB is a document-oriented NoSQL database, which was born in 2007 in California as a service to be used within a larger project, but which soon became an independent and open-source product. It stores documents in JSON, a format based on JavaScript and simpler than XML, but still with good expressiveness. It is the dominant […]

Using MySQL with Node.js: A Complete Tutorial

Using MySQL with Node.js: A Complete Tutorial

Although data persistence is almost always a fundamental element of applications, Node.js has no native integration with databases. Everything is delegated to third-party libraries to be included manually, in addition to the standard APIs. Although MongoDB and other non-relational databases are the most common choice with Node because if you need to scale an application, […]

Node.Js Vs Django: Which Is the Best for Your Project

Node.Js Vs Django: Which Is the Best for Your Project

Django and NodeJs are two powerful technologies for web development, both have great functionality, versatile applications, and a great user interface. Both are open source and can be used for free. But which one fits your project best? NodeJs is based on JavaScript, while Django is written in Python. These are two equally popular technologies […]

Nodejs Vs PHP:  Which Works Best?

Nodejs Vs PHP: Which Works Best?

Before getting into the “battle” between Node.js and PHP we need to understand why the issue is still ongoing. It all started with the increased demand for smartphone applications, their success forcing developers to adapt to new back-end technologies that could handle a multitude of simultaneous requests. JavaScript has always been identified as a client-side […]