Mahara is an open-source e-portfolio system. It can also be used as a social networking platform. Mahara is written in PHP and uses either PostgreSQL or MySQL database server to store its data.

Step1. Install packages

yum install httpd mariadb mariadb-server   

Step2. Start services

systemctl start httpd
systemctl enable httpd
systemctl status httpd
 
systemctl start mariadb
systemctl enable mariadb
systemctl status mariadb

Step3. Enable HTTP port on the firewall

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

Step4. Setup database

mysql_secure_installation

Step5. Create a database and user

mysql -u root -p
show databases;
Create database mahadb;
CREATE USER 'mahauser'@'%' IDENTIFIED BY 'redhat@123';
GRANT ALL PRIVILEGES ON mahadb.* TO 'mahauser'@'%';
select Host,User,Password from user;
FLUSH PRIVILEGES;
quit;
Bye

Step6. Install/configure PHP repository

yum install http://rpms.remirepo.net/enterprise/remi-release-7.rpm
yum install yum-utils
yum-config-manager --enable remi-php72

Step7. Install PHP packages

yum install php-mysql php-gd php-ldap php-xml php-xmlrpc php-mbstring php-mcrypt curl zlib libtool-ltdl php-pdo

Step8. Download the Mahara software

yum install wget unzip
wget https://launchpad.net/mahara/19.10/19.10.0/+download/mahara-19.10.0.zip

Step9. Unzip the file and move the file in HTML folder

unzip mahara-19.10.0.zip
mv mahara-19.10.0.zip /var/www/html

Step10. Create a duplicate file config.php in the location ” /var/www/html/mahara/htdocs/”for mahara.

cd /var/www/html/mahara/htdocs/
cp config-dist.php config.php

Step11. Configure config.php file

vi  config.php

$cfg-> dbtype   = ' mysql'  
$cfg-> dbhost   = ' localhost'  
$cfg-> dbport   = null 
$cfg-> dbname   = ' mahadb'  
$cfg-> dbuser   = ' mahauser'  
$cfg-> dbpass   = ' redhat@123'  
$cfg-> dataroot = ' /var/www/html/mahara/upload/'

Step10. Set permission

chown -R apache.apache /var/www/html/mahara
chmod -R 777 /var/www/html/mahara

Step11. Create a virtual host file

vi /etc/httpd/conf.d/mahara.conf 

<VirtualHost *:80>
     ServerAdmin localhost
     DocumentRoot "/var/www/html/mahara/"
     ServerName 192.168.33.51
     ErrorLog "/var/log/httpd/mahara-error_log"
     CustomLog "/var/log/httpd/mahara-access_log" combined

     <Directory "/var/www/html/mahara/">
         DirectoryIndex index.html index.php install.php
         Options FollowSymLinks
         AllowOverride All
         Require all granted
     </Directory>
</VirtualHost>

Step12. Start the service

systemctl start httpd 

Step13. Open the web browser

http://<server ip>/mahara

LEAVE A REPLY

Please enter your comment!
Please enter your name here