Warning
This article is old, and some of the information may be outdated or no longer valid today.
If you have any questions or need to confirm any details, we recommend contacting our support team for up-to-date information and personalized assistance.
Vtiger CRM is an open-source CRM application forked from the SugarCRM project with the intention of creating a tool with functionality similar to Salesforce, but open source. Its free version offers a reporting tool, a customer portal, and an Outlook plugin, options found in the paid versions of other applications.
This article explains how to install Vtiger, first installing and configuring Apache with PHP and MySQL, with a Let's Encrypt certificate obtained using Certbot for the CRM website.
Official recommended requirements
- Operating system: Linux or Windows.
- Web server: Apache2.
- RAM: 4 GB or more.
- PHP compatibility: For the latest versions of Vtiger, 7.4+ or higher
- Processor: Frequency of one Ghz or higher.
- MySQL version: 5.2 or higher.
- PHP IMAP, PHP cURL & PHP XML.
More information about requirements is available in the official documentation; you can click here to review it.
Installing packages
First, update the repositories and install updates:
# apt update && apt upgradeNext, install the necessary packages:
# apt install mysql-server apache2 php-cli php-fpm php-common php-mbstring php-swiftmailer php-gd php-xml php-json php-gmp php-curl php-intl php-xmlrpc php-mysql php-imap php-mailparse certbot python3-certbot-apacheThen configure security for the database:
# mysql_secure_installationCreating the database
To create a database for Vtiger, we can run the following command:
# mysqladmin -u root --verbose create vtigerThen create a user (replace password with the desired password):
# mysql -u root --verbose -e "create user 'vtiger'@'localhost' identified by 'password';"
Finally, assign the user permissions on the database:
# mysql -u root --verbose -e "grant all on vtiger.* to 'vtiger'@'localhost' with grant option; flush privileges;"Obtaining and preparing Vtiger
First, download Vtiger from the official project in the sourceforge repository:
# wget https://sourceforge.net/projects/vtigercrm/files/vtiger%20CRM%207.5.0/Core%20Product/vtigercrm7.5.0.tar.gzYou can check the latest version at: https://sourceforge.net/projects/vtigercrm/files/
Then extract the downloaded file (installation of tar beforehand is included):
# apt install -y tar && tar -xf vtiger*.tar.gzFinally, create the web directory for the CRM and synchronize it with the extracted folder:
# mkdir /var/www/vtiger/ && rsync -rtv vtiger*/ /var/www/vtiger/ && chown -R www-data:www-data /var/www/vtigerConfiguring Apache and FPM
Create the site configuration file for Vtiger using an editor. For example, the nano editor:
# nano /etc/apache2/sites-available/vtiger.confAnd enter the following content (remember to change the example domain):
<VirtualHost *:80>
ServerName vtiger.ejemplo.com
ServerAdmin webmaster@localhost
DocumentRoot /var/www/vtiger
ErrorLog ${APACHE_LOG_DIR}/vtiger_error.log
CustomLog ${APACHE_LOG_DIR}/vtiger_access.log combined
</VirtualHost>
Save the changes, exit the editor, and enable the site:
# a2ensite vtigerNext, enable the relevant fpm configuration and enable the required modules:
# a2enconf php8.1-fpm && a2enmod proxy proxy_fcgiRestart or reload the Apache configuration to apply the changes:
# systemctl reload apache2And finally, obtain the certificate and configure it automatically with the Certbot script:
# certbot --redirect --apache -d vtiger.ejemplo.comRemember to replace the example domain with the one configured on the server.
Installing VTiger
Once everything is configured, open a browser and enter the site's URL. The start of the Vtiger installation wizard will appear:
Follow the wizard's instructions to complete the installation; if the following error appears when attempting to install it:
MySQL Server should be configured with:
sql_mode = ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION
NO_AUTO_CREATE_USER was removed in MySQL 8.0; if MySQL 8.0+ is used, this mode will cause an error
Run the following to modify the SQL mode in MySQL:
# echo 'sql_mode = ERROR_FOR_DIVISION_BY_ZERO' >> /etc/mysql/mysql.conf.d/mysqld.cnf && systemctl restart mysqlWe hope this article has helped you. If you still have questions about this or any other issue related to your servers on Clouding, email us at soporte@clouding.io. We're here to help! 😉