How To Install Pligg CMS 2.0.x on an Ubuntu 12.04 VPS

Published on January 24, 2014

Abdul Khois

How To Install Pligg CMS 2.0.x on an Ubuntu 12.04 VPS

Status: Deprecated

This article covers a version of Ubuntu that is no longer supported. If you are currently operate a server running Ubuntu 12.04, we highly recommend upgrading or migrating to a supported version of Ubuntu:

Reason: Ubuntu 12.04 reached end of life (EOL) on April 28, 2017 and no longer receives security patches or updates. This guide is no longer maintained.

See Instead: This guide might still be useful as a reference, but may not work on other Ubuntu releases. If available, we strongly recommend using a guide written for the version of Ubuntu you are using. You can use the search functionality at the top of the page to find a more recent version.

About Pligg CMS

This tutorial will show how to install and configure Pligg CMS 2.0.x on an Ubuntu Server 12.04.x. Pligg CMS is an open source content management system that allows you to create an online community where users can submit articles, vote on them, and leave comments.

Pligg CMS was designed from the ground up as a way for a large number of contributors to submit and moderate content. Registered users, as well as visitors in some circumstances, are in control of the website’s content. Pligg CMS 2.0.x requires Linux, Apache, MySQL 5+, and PHP 5+.

The following is a step-by-step guide to installing and configure pligg CMS 2.0.x on an Ubuntu Server 12.04

Step 1 - Enable LAMP Server

First, Login to your VPS server using the ssh command

ssh username@ip_or_hostname

Before installing Pligg CMS 2.0.x, make sure you have installed LAMP server ( Linux, Apache, Mysql, PHP) on your virtual private server. If don’t have the LAMP server, you can install it by typing the following command in terminal:

sudo apt-get install lamp-server^

Or, you can read the tutorial on how to install LAMP on an Ubuntu Server here.

Step 2 - Download Pligg CMS 2.0.x

You can download Pligg CMS 2.0.x straight from githup with the wget command:

cd /var/www/
sudo wget https://github.com/Pligg/pligg-cms/releases/download/2.0.1/2.0.1.zip

Step 3 - Create the Pligg CMS Database and User

Now you need to switch gears for a moment and create a new MySQL directory for Pligg CMS. Go ahead and log into the MySQL Shell with the following command:

mysql -u root -p

Login using your MySQL root password, and then you need to create a pligg CMS database, a user in that database, and give that user a new password. Keep in mind that all MySQL commands must end with semi-colon (;)

Create database for pligg CMS. For my example, I’ll create the db name “dbpligg”


Create the new user. You can replace the database, name, and password with whatever you prefer:

CREATE USER pligguser@localhost;

Now, set password for username “pligguser”

SET PASSWORD FOR pligguser@localhost= PASSWORD("pL!g9p45sw0rd");

Finish up by granting all privileges to the new user (“pligguser”) with the following command:

GRANT ALL PRIVILEGES ON dbpligg.* TO pligguser@localhost IDENTIFIED BY 'pL!g9p45sw0rd';

Then refresh MySQL and sign out from MySQL shell



Step 4 - Setup the Pligg CMS 2.0.x Configuration

If you installing Pligg CMS 2.0.x on a fresh LAMP VPS, you need to rename/change file index.html to other name file. In example: I’ll change file index.html to index.html.origin

sudo mv /var/www/index.html /var/www/index.html.origin

Extract archive pligg 2.0.x using unzip command:

sudo unzip /var/www/2.0.1.zip -d /var/www/

Rename the /favicon.ico.default to /favicon.ico

sudo mv /var/www/favicon.ico.default /var/www/favicon.ico

Rename the /settings.php.default to /settings.php

sudo mv /var/www/settings.php.default /var/www/settings.php

Rename the /languages/lang_english.conf.default file to lang_english.conf.

sudo mv /var/www/languages/lang_english.conf.default /var/www/languages/lang_english.conf

Note: Apply to any other language file that you might use that are located in the /languages directory.

Rename the /libs/dbconnect.php.default file to dbconnect.php

sudo mv /var/www/libs/dbconnect.php.default /var/www/libs/dbconnect.php

Rename the directory /logs.default to /logs

sudo mv /var/www/logs.default /logs

Change permision to the following directories and files: admin/backup/, avatars/groups_uploaded/, avatars/user_uploaded/, cache/, languages/) to 777 cd /var/www

sudo chmod 777 admin/backup/ avatars/groups_uploaded/ avatars/user_uploaded/ cache/ languages/

Change permision the following file (/libs/dbconnect.php, /settings.php) to 666

sudo chmod 666 libs/dbconnect.php settings.php

Edit file settings.php, change $my_base_url = ‘http://localhost’; to $my_base_url = ‘http://your-domain.com’;

sudo nano /var/www/settings.php

Give ownership of the file and directory to the apache user.

sudo chown -R www-data:www-data /var/www/*
sudo usermod -a -G www-data username

Step 5 - Finish Installation, PliggCMS from Web Browser

Now from PC or laptop, open the your favorite web browser and navigate to: http://ip_or_domain/install/install.php. You can see the following screenshot is a step-by-step installation of Pligg CMS from web browser.

Select language

<p><img src=“https://assets.digitalocean.com/articles/Pligg_Ubuntu/1.png”></p>

<p>Click next step if you have already completed this in step 4</p>

<p><img src=“https://assets.digitalocean.com/articles/Pligg_Ubuntu/2.png”></p>

Enter your MySQL database settings

<p><img src=“https://assets.digitalocean.com/articles/Pligg_Ubuntu/3.png”></p>

Checking database connections

<p><img src=“https://assets.digitalocean.com/articles/Pligg_Ubuntu/4.png”></p>

Enter your admin account details

<p><img src=“https://assets.digitalocean.com/articles/Pligg_Ubuntu/5.png”></p>

Congratulations, Pligg CMS Installation is Complete!

<p><img src=“https://assets.digitalocean.com/articles/Pligg_Ubuntu/6.png”></p>

Login again to your VPS using the ssh command, then change permisision file “/libs/dbconnect.php” to 644

sudo chmod 644 /var/www/libs/dbconnect.php

Delete pligg installation folder with following command:

sudo rm -rf /var/www/install

Pligg CMS frontpage

<p><img src=“https://assets.digitalocean.com/articles/Pligg_Ubuntu/7.png”></p>

Now, Login to the admin area (yourdomain.com/admin/admin_index.php) using the username and password information you entered from the previous step.

<p><img src=“https://assets.digitalocean.com/articles/Pligg_Ubuntu/8.png”></p>

Once you log in you should be presented with more information about how to use Pligg CMS.

<div class=“author”>Submitted by: <a href=“abdul.khois@gmail.com”>Linux Scoop</a></div>

<meta itemprop=“alternateVersion” content=“https://www.digitalocean.com/community/tutorials/how-to-install-pligg-cms-2-0-x-on-an-ubuntu-14-04-vps”>

Thanks for learning with the DigitalOcean Community. Check out our offerings for compute, storage, networking, and managed databases.

Learn more about us

About the authors
Default avatar
Abdul Khois


Still looking for an answer?

Ask a questionSearch for more help

Was this helpful?

This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

Kamal Nasser
DigitalOcean Employee
DigitalOcean Employee badge
February 8, 2014

@dedichi: Either is fine. You can use whatever directory you like.

Thanks for the installation instructions. It really helped. BTW I had to change default in httpd.conf to point to /var/www from /var/www/html. Would you recommend rather installing pligg in /var/www/html instead?

Try DigitalOcean for free

Click below to sign up and get $200 of credit to try our products over 60 days!

Sign up

Join the Tech Talk
Success! Thank you! Please check your email for further details.

Please complete your information!

Featured on Community

Get our biweekly newsletter

Sign up for Infrastructure as a Newsletter.

Hollie's Hub for Good

Working on improving health and education, reducing inequality, and spurring economic growth? We'd like to help.

Become a contributor

Get paid to write technical tutorials and select a tech-focused charity to receive a matching donation.

Welcome to the developer cloud

DigitalOcean makes it simple to launch in the cloud and scale up as you grow — whether you're running one virtual machine or ten thousand.

Learn more
DigitalOcean Cloud Control Panel