How to Install and Configure OrangeHRM on Ubuntu 16.04


  1. A fresh Alibaba cloud Ubuntu 16.04 instance with minimum 2GB RAM.
  2. A static IP address is configured on the instance.
  3. A Root password is setup on the server.

Launch Alibaba Cloud ECS Instance

apt-get update -y

Install LEMP Server

apt-get install nginx mariadb-server -y
systemctl start nginx
systemctl start mysql
systemctl enable nginx
systemctl enable mysql
apt-get install software-properties-common -y
add-apt-repository ppa:ondrej/php
apt-get update -y
apt-get install php7.1-fpm php7.1-common php7.1-mbstring php7.1-ldap php7.1-zip php7.1-xmlrpc php7.1-soap php7.1-gd php7.1-xml php7.1-intl php7.1-mysql php7.1-cli php7.1-mcrypt php7.1-curl -y
nano /etc/php/7.1/fpm/php.ini
file_uploads = On
allow_url_fopen = On
memory_limit = 256M
upload_max_filesize = 150M
display_errors = Off
cgi.fix_pathinfo = 0
date.timezone = Asia/Kolkata

Configure Database

Change the password for root ? N
Remove anonymous users? Y
Disallow root login remotely? Y
Remove test database and access to it? Y
Reload privilege tables now? Y
mysql -u root -p
MariaDB [(none)]> CREATE DATABASE orangehrm_db;
MariaDB [(none)]> CREATE USER 'orangehrm'@'localhost' IDENTIFIED BY 'password';
MariaDB [(none)]> GRANT ALL ON orangehrmdb.* TO 'orangehrm'@'localhost' IDENTIFIED BY 'password' WITH GRANT OPTION;
MariaDB [(none)]> exit;

Install OrangeHRM

cp -r orangehrm-4.1 /var/www/html/orangehrm
chown -R www-data:www-data /var/www/html/orangehrm/
chmod -R 755 /var/www/html/orangehrm/

Configure Nginx for OrangeHRM

nano /etc/nginx/sites-available/orangehrm
server {
listen 80;
listen [::]:80;
root /var/www/html/orangehrm;
index index.php index.html index.htm;
client_max_body_size 100M; location / {
try_files $uri $uri/ /index.php?$uri&$args;
location ~ \.php$ {
include snippets/fastcgi-php.conf;
fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
include fastcgi_params;
ln -s /etc/nginx/sites-available/orangehrm /etc/nginx/sites-enabled/
nginx -t
nginx: the configuration file /etc/nginx/nginx.conf syntax is ok
nginx: configuration file /etc/nginx/nginx.conf test is successful
systemctl restart nginx

Access OrangeHRM Web Installation Wizard

Related Alibaba Cloud Products




Follow me to keep abreast with the latest technology news, industry insights, and developer trends. Alibaba Cloud website:

Love podcasts or audiobooks? Learn on the go with our new app.

Recommended from Medium

Application Design and Development: The Great Pittsburgh Baking Outlet

Setting up your own VPN Server Using OpenVPN

Sombra Network Post Launch News

Java 8 | One Dimensional Array

I’m not letting R anywhere near my geospatial raster data.

What Should Top Features be incorporated To Build a Successful Mobile App?

3 Python Tools Data Scientists Can Use for Production-Quality Code

Performance psychology and movies: ET.

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Alibaba Cloud

Alibaba Cloud

Follow me to keep abreast with the latest technology news, industry insights, and developer trends. Alibaba Cloud website:

More from Medium

How to Install Apache on CentOS8, and a Ubuntu machine.

Produce and consume messages from a Kafka topic using docker

How to install and host Jenkins in Tomcat Server (Windows)

Google Cloud Monitoring: Monitoring and Alerting on number of kubernetes pod replicas in GKE