Building the Website
Purchased Services


Building Process

Building the Database

Install the database.
- CentOS 6.5 64bit (40 GB) is used as the OS of the database node, and the MySQL version is 5.1.73.
- For CentOS 7 and later versions, MySQL is removed from the default program list. You need to run the sudo rpm -Uvh http://dev.mysql.com/get/mysql-community-release-el7-5.noarch.rpm command to manually download MySQL. After the download is complete, perform 2 to install the software.
- Log in to ECS discuz01 remotely and enter the username and password.
- Run the following command to deploy the MySQL database server, MySQL client, and all required libraries and files:
yum install -y mysql-server mysql mysql-devel
If the following information is displayed, the installation is successful.Complete!
Configure MySQL.
- Run the following command to start the MySQL service:
- Run the following command to set the administrator username and password. The password is self-defined. In this command, Huawei@123 is used an example.
mysqladmin -u root password 'Huawei@123'
- Run the following command and enter the password of user root to enter the database:
- Run the following command to use the database:
- Run the following command to query the user list:
This command and the following database commands must end with a semicolon (;).
- Run the following command to refresh the user list and allow all IP addresses to access the database:
- Run the following command to forcibly update the permissions: and allow ECSs in the same subnet to access the MySQL database using private IP addresses.
- Run the following command to exit the database:
- Run the following command to restart the MySQL service:
- Run the following command to enable the MySQL service to automatically start upon system boot:
- Run the following command to disable the firewall:
- Run the following command to permanently disable the firewall after restarting the ECS:
Setting Up the Web Environment

Install the web environment.
- Unbind the EIP from ECS discuz01 and bind it to ECS discuz02.



- Log in to ECS discuz02 remotely and enter the username and password. For details, see the operations for logging in to ECS discuz01.
- Run the following command to install the Apache server, PHP FastCGI manager, MySQL client, and MySQL database server:
yum install -y httpd php php-fpm mysql mysql-server php-mysql
If the following information is displayed, the installation is successful.Complete!
- Run the following command to reinstall the Apache server, PHP FastCGI manager, MySQL client, and MySQL database server:
yum reinstall -y httpd php php-fpm mysql mysql-server php-mysql
If the following information is displayed, the installation is successful.Complete!
Configure the web environment.
- Run the following command to start the httpd service:
- Run the following command to enable the httpd service to automatically start upon system boot:
- Run the following command to start the php-fpm service:
- Run the following command to enable the php-fpm service to automatically start upon system boot:
- Run the following command to disable the firewall:
- Run the following command to permanently disable the firewall after restarting the ECS:
- Run the following command to start the MySQL service:
- Run the following command to enable the MySQL service to start upon system boot.
- Enter http://EIP in a browser to query the default page of the ECS.

Deploying the Website Code

- Log in to ECS discuz02 remotely and run the following command to install the Discuz software: wget http://download.comsenz.com/DiscuzX/3.3/Discuz_X3.3_SC_UTF8.zip
- The recommended English version of Discuz X3.3 (UTF-8) is not free. Refer to the provided page for payment details.
- The software packages are only used to construct the forum. To deploy a commercial website, download the applications as needed.
- Run the following command to decompress the Discuz installation package:
- Run the following command to copy all files in the decompressed upload folder to the var/www/html directory:
cp -r upload/* /var/www/html
- Run the following command to grant write permissions to other users.
- Enter http://EIP in the address box and install Discuz following the guidance.
- Confirm the agreement and click I Agree.
- After the installation starts, check the installation environment and click Next.
- Set the running environment and click Next.
- Enter the database information and click Next to complete the installation.
- The database address is the private IP address of discuz01.
- The database password is the password of the database administrator account (username root) configured on discuz01.
- The administrator information is required.
Verifying the Website
In the browser address bar, enter http://EIP/forum.php. If the forum homepage is displayed, the website is successfully built.

Last Article: Purchasing Services
Next Article: Configuring Features


Did this article solve your problem?
Thank you for your score!Your feedback would help us improve the website.