Contents

How to install phpBB on Ubuntu 16.04

How to install phpBB on Ubuntu 16.04
How to install phpBB on Ubuntu 16.04
  phpBB is an open source bulletin board forum software which gives virtual space for discussion among the members of your website. It has a big variety of functionalities such as falt topic structure,sub-forums, forum-specific styles, user groups, group-based permissions, database query and template caching, support for PHP 7, and several database engines and a lot more. With phpBB’s extensive functionalities  we can create our own forum in a matter of minutes, the best part is that it’s completely free. In this guide, we are going to show you how to install phpBB on a Ubuntu 16.04 VPS. Step 1: Installing the LAMP stack. To begin, we will first have to login as root so we won’t need to type sudo in front of each command:
# sudo su
Ensure that the packages on your VPS are up to date.
# apt-get update
Next, execute the command below to install the LAMP stack with PHP 7:
# apt-get -y install apache2 mysql-server mysql-client libapache2-mod-php7.0 php7.0-mysql php7.0-gd imagemagick unzip
Step 2: Creating a database for phpBB Log in to the MYSQL server:
# mysql
Now, we will create an empty database for phpBB to use:
mysql> create database phpBB;
Next, we will create a database user, so make sure to replace the password randomgeneratedpassword with your own password:
mysql> create user 'phpBB_dbuser'@'localhost' identified by 'randomgeneratedpassword';
Give every privilege to the user on the phpBB database:
mysql> grant all privileges on phpBB.* to 'phpBB_dbuser'@'localhost';
Apply the privileges we’ve just given to the user on the server:
mysql> flush privileges;
Step 3: Installing phpBB Switch to Apache’s document root directory:
# cd /var/www/html
Now, remove Apache’s default file(Make sure to skip this step if you have other site’s contents in this directory and install phpBB in a different directory instead):
# rm -rf ./*
Download the latest phpBB version to your server (This was made when 3.2.0 was the latest version.)
# wget https://www.phpbb.com/files/release/phpBB-3.2.0.zip
Let’s now extract the phpBB to the current directory:
# unzip phpBB-3.2.0.zip
Remove the archive file so we don’t need it any more:
# rm phpBB-3.2.0.zip
Move the contents from the extracted directory to the current directory(If you have other site’s contents, skip this step and the next one, /var/www/html directory):
# mv ./phpBB3/* .
Remove the empty phpBB3 directory:
# rm -rf ./phpBB3
In case if you’ve got phpBB installed in a separate directory you may type in the following command if you’d like to rename the phpBB3 directory to something else like forum so phpBB is accessible at http://youdomain.com/forum:
# mv ./phpBB3 ./forum
Swap the owner to the www-data user for every file and sub-directory in /var/www/html:
# chown -R www-data:www-data /var/www/html/
If you have phpBB installed in a different directory, ensure to swap your working directory to this directory:
cd /var/www/html/your_phpBB_directory
Now, change your_phpBb_directory with the directory you put phpBB in: Grant the right permissions to the config file and the following directories:
# chmod 660 images/avatars/upload/ config.php

# chmod 770 store/ cache/ files/
Finishing the Installation Open your web browser of choice and point it to http://yourdomain.com/install or if you have phpBB installed in a different directory, http://yourdomain.com/your_PHPbb_directory/install. Press on the Install tab and click the install button.phpBB, you will be requested for some credentials, ensure that those credentials are swapped with your own:
Administrator username: admin

Contact email address: [email protected]

Administrator password: admin_test1234-
Confirm administrator password: same as above Press on Submit once you are finished. Make sure that your password is secured with at least 8 characters, 1 uppercase letter, 1 special character, and alphanumeric characters. You will be asked by phpBB for certain details about your database, here’s an example: Press on Submit once more. In this step, you will need to set up options according to your preference such as giving your domain name or whether you want to force SSL, and after this step, you should be taken to the SMTP configuration page, in case you don’t have an SMTP server you may leave this page as it is and press on Submit to proceed. Click on Install once again and wait for the installer to be done. Once the installer is done installing phpBB you can click the ‘Take me to the ACP link and set up your new phpBB installation.’ This is all, you will now have phpBB installed on your server.
Updated on 06 Mar 2018
0 Comments
Add a comment
Login for Comment