Install Vtiger CRM on Rocky Linux 8


In this tutorial, we are going to learn how to install and setup Vtiger CRM on Rocky Linux 8. CRM is an abbreviation for Custom Relationship Management. Vtiger CRM enables sales, support, and marketing teams to organize and collaborate to measurably improve customer experiences and business outcomes. In this tutorial, we are going to install the opensource version of Vtiger on Rocky Linux 8.

Install and Setup Vtiger CRM on Rocky Linux 8


System Requirements

Ensure that you have at least 2 CPU cores, at least 4GB RAM and enough disk space. (Vtiger recommends 250G for attachments)

Install and Setup LAMP Stack

Vtiger is a PHP based web application. As such, ensure that you install and setup LAMP stack before you can proceed. We have covered the installation and setup of LAMP stack on Rocky Linux 8 in our previous guide. You can follow the link below to setup LAMP stack.

Run system update

dnf update

Install Apache;

dnf install httpd

Install MariaDB on Rocky Linux by following the link below;

Install MariaDB 10.x on Rocky Linux 8

Install PHP 7.4 other required PHP modules;

dnf install epel-release
dnf install
dnf module reset php
dnf module enable php:remi-7.4
dnf install php php-imap php-curl php-xml php-mysql php-mbstring

Sample output;

Dependencies resolved.
 Package                              Architecture                 Version                                                         Repository                          Size
 php                                  x86_64                       7.4.20-1.el8.remi                                               remi-modular                       3.0 M
 php-common                           x86_64                       7.4.20-1.el8.remi                                               remi-modular                       1.2 M
 php-imap                             x86_64                       7.4.20-1.el8.remi                                               remi-modular                       102 k
 php-mbstring                         x86_64                       7.4.20-1.el8.remi                                               remi-modular                       529 k
 php-pecl-mysql                       x86_64                       1.0.0-0.23.20190415.d7643af.el8.remi.7.4                        remi-modular                        44 k
 php-xml                              x86_64                       7.4.20-1.el8.remi                                               remi-modular                       215 k
Installing dependencies:
 libc-client                          x86_64                       2007f-24.el8                                                    epel                               564 k
 libsodium                            x86_64                       1.0.18-2.el8                                                    epel                               162 k
 oniguruma5php                        x86_64                                                           remi-safe                          210 k
 php-json                             x86_64                       7.4.20-1.el8.remi                                               remi-modular                        77 k
 php-mysqlnd                          x86_64                       7.4.20-1.el8.remi                                               remi-modular                       260 k
 php-pdo                              x86_64                       7.4.20-1.el8.remi                                               remi-modular                       144 k
Installing weak dependencies:
 php-cli                              x86_64                       7.4.20-1.el8.remi                                               remi-modular                       4.6 M
 php-fpm                              x86_64                       7.4.20-1.el8.remi                                               remi-modular                       1.6 M
 php-opcache                          x86_64                       7.4.20-1.el8.remi                                               remi-modular                       336 k
 php-sodium                           x86_64                       7.4.20-1.el8.remi                                               remi-modular                        89 k

Transaction Summary
Install  16 Packages

Total download size: 13 M
Installed size: 55 M
Is this ok [y/N]: y

Configure PHP for Vtiger

Open the /etc/php.ini configuration file and make the following adjustments;

vim /etc/php.ini
memory_limit = 256M
max_execution_time = 60
log_errors = Off
display_errors = Off
short_open_tag = Off

Save and exit the file.

Create Database and Database User for Vtiger

Next, once the LAMP stack is in place, login to MySQL as administrative user.

mysql -u root -p

Note that we are using MariaDB 10.5 in this tutorial.

mysql -V
mysql  Ver 15.1 Distrib 10.5.10-MariaDB, for Linux (x86_64) using readline 5.1

Create Vtiger database and database user. Be sure to replace the names of the database and user.

create database vtiger default character set utf8 default collate utf8_general_ci;

Create database user and grant all privileges to Vtiger database user on the Vtiger database.

grant all on vtiger.* to [email protected] identified by '[email protected]';

Reload the privileges table and exit the database;

flush privileges;

Next, implement the following global configuration for MySQL;

echo -e '[mysqld]\nsql_mode = ""' >> /etc/my.cnf

Restart MariaDB;

systemctl restart mariadb

Download Vtiger Application Tarball

Navigate to Vtiger downloads page and the latest tarball for the opensource version of Vtiger.

dnf install wget

Extract and Install Vtiger CRM on Rocky Linux 8

Once the download is complete, extract the tarball to your preferred web root directory. Note the Vtiger is a ready to deploy application.

In this demo, we will use /var/www/vtigercrm as our default Vtiger CRM web root directory.

mkdir /var/www/vtigercrm
tar xzf vtigercrm7.2.0.tar.gz --strip-components=1 -C /var/www/vtigercrm/

Create Apache Web Configuration for Vtiger CRM

Since we are using Apache as our web server for the Vtiger CRM, you need to create the web configuration file to define how to access Vtiger from web as follows.

Paste the command below on the terminal to create the configuration file. Be sure to make the necessary changes.

cat > /etc/httpd/conf.d/vtigercrm.conf << EOL
<VirtualHost *:80>
     DocumentRoot /var/www/vtigercrm/

     <Directory /var/www/vtigercrm/>
        Options FollowSymlinks
        AllowOverride All
        Require all granted

     ErrorLog /var/log/httpd/vtigercrm_error.log
     CustomLog /var/log/httpd/vtigercrm_access.log combined

If you want, you can configure Vtiger CRM with SSL/TLS cerfiticates.

Set the ownership of the Vtiger CRM web root directory to Apache user;

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

Save and exit the configuration file above.

Check Apache configuration syntax;

httpd -t

If you get Syntax OK, proceed to restart Apache.

systemctl restart httpd

Finalize Vtiger CRM Setup from Browser

Open Apache on Firewalld to allow external access;

firewall-cmd --add-port=80/tcp --permanent
firewall-cmd --reload

Managing SELinux

Well, I personally don’t advise you to disable SELinux due to security reasons. If you have time to troubleshoot any would be SELinux issue, leave it running. Otherwise, for the purposes of the demo, we have set SELinux to run in permissive mode in this demo.

sudo setenforce 0

To completely set it to run permissively, run the command below and reboot the system;

sed -i 's/=enforcing/=permissive/' /etc/selinux/config
systemctl reboot

You can then access it via the address, http://server-IP-or-hostname.

On the welcome page, click Install button to go through the setup wizard.

Install and Setup Vtiger CRM on Rocky Linux 8

On the next page, accept the EULA and proceed.

On the Installation prerequisites, ensure that all pre-reqs are met. Otherwise fix them before you proceed.

On system configuration page, configure database connection details as defined above and setup your Vtiger CRM administrative account.

Click Next to review the system configuration settings.

On the Next page, select your Industry and click Next to proceed with installation.

Wait for the installation to complete. This might take some time.

Once the installation is done, Select the modules for the Vtiger features you would like to have.

Click Next and login to you Vtiger. Use the administrative credentials you set above.

Install and Setup Vtiger CRM

You can now add more widgets to your dashboard.

Great. That is all on how to install and setup Vtiger CRM on Rocky Linux 8. You can configure it further to your liking. Enjoy.

Further Reading

Install and Setup Vtiger CRM on Ubuntu 20.04

Install and Setup Vtiger CRM on Debian 10


Please enter your comment!
Please enter your name here