CentOSLinuxTutorials

How To Install Simple Machines Forum on CentOS 7

Install Simple Machines Forum on CentOS 7

In this tutorial, we will show you how to install the Simple Machines Forum on  CentOS 7. For those of you who didn’t know, Simple Machines Forum (SMF) is a free, professional-grade software package that allows you to set up your own online community within minutes. It is open-source software that is written in PHP and uses a MySQL/MariaDB database. It provides many features and it is user-friendly.

This article assumes you have at least basic knowledge of Linux, know how to use the shell, and most importantly, you host your site on your own VPS. The installation is quite simple. I will show you the step-by-step installation Simple Machines Forum on CentOS 7.

Prerequisites

  • A server running one of the following operating systems: CentOS 7.
  • It’s recommended that you use a fresh OS install to prevent any potential issues.
  • SSH access to the server (or just open Terminal if you’re on a desktop).
  • A non-root sudo user or access to the root user. We recommend acting as a non-root sudo user, however, as you can harm your system if you’re not careful when acting as the root.

Install Simple Machines Forum on CentOS 7

Step 1. First of all, make sure that all packages are up to date.

yum -y update

Step 2. Install the LAMP server and include some PHP extensions.

yum install mysql-server httpd php php-mysql php-gd php-curl php-apc php-cli php-mbstring

Start service Apache and MySQL:

systemctl start mysqld
systemctl start httpd

Step 3. Configuring MySQL.

By default, MySQL is not hardened. You can secure MySQL using the mysql_secure_installation script. you should read and below each step carefully which will set a root password, remove anonymous users, disallow remote root login, and remove the test database and access to secure MySQL.

mysql_secure_installation

Next, we will need to log in to the MySQL console and create a database for the forum. Run the following command:

mysql -u root -p

This will prompt you for a password, so enter your MySQL root password and hit Enter. Once you are logged in to your database server you need to create a database for the Simple Machines Forum software:

CREATE DATABASE smf;
CREATE USER 'smf_user'@'localhost' IDENTIFIED BY 'YoUr_PaSsWoRd';
GRANT ALL PRIVILEGES ON `smf`.* TO 'smf_user'@'localhost';
FLUSH PRIVILEGES;

Step 4. Configure Apache web server for SMF.

cd /var/www/html/

Download the latest Simple Machines Forum on your server:

wget http://mirror.ord.simplemachines.org/downloads/smf_2-0-9_install.tar.gz
tar -zxvf smf_2-0-9_install.tar.gz

We will need to change some folders permissions:

chmod 777 attachments avatars cache Packages Smileys Themes

Step 5. Accessing the Simple Machines Forum.

SMF will be available on HTTP port 80 by default. Open your favorite browser and navigate to http://your-domain.com or http://server-ip-address. You should see the SMF installer:

Install Simple Machines Forum on CentOS 7

Congratulations! You have successfully installed the Simple Machines Forum. Thanks for using this tutorial for installing the Simple Machines Forum on CentOS 7 system. For additional help or useful information, we recommend you check the official SMF website.

VPS Manage Service Offer
If you don’t have time to do all of this stuff, or if this is not your area of expertise, we offer a service to do “VPS Manage Service Offer”, starting from $10 (Paypal payment). Please contact us to get the best deal!

r00t

r00t is a seasoned Linux system administrator with a wealth of experience in the field. Known for his contributions to idroot.us, r00t has authored numerous tutorials and guides, helping users navigate the complexities of Linux systems. His expertise spans across various Linux distributions, including Ubuntu, CentOS, and Debian. r00t's work is characterized by his ability to simplify complex concepts, making Linux more accessible to users of all skill levels. His dedication to the Linux community and his commitment to sharing knowledge makes him a respected figure in the field.
Back to top button