Because it is difficult to find and download the integrated server tool, and they have packaged a php program and other programs themselves, their own systems already have php and databases, and I can't take it anymore, finally, you have selected manual configuration. This is the whole process of manually deploying DiscuzX2.5 from the server program on Archlinux. Some configuration files are relatively long and must be edited.
Because it is difficult to find and download the integrated server tool, and they have packaged a php program and other programs themselves, their own systems already have php and databases, and I can't take it anymore, finally, you have selected manual configuration. This is the whole process of manually deploying DiscuzX2.5 from the server program on Archlinux. Some configuration files are relatively long and must be edited.
Because it is difficult to find and download the integrated server tool, and they have packaged a php program and other programs themselves, their own systems already have php and databases, and I can't take it anymore, finally, select manual configuration ......
This isArchlinux
Manually deploy DiscuzX2.5 from the server program.
Some configuration files are relatively long, so use search = when editing.
Environment preparation
- System: Linux 3.16.4-1-ARCH
- Servers and related software:
- Nginx 1.6.2-1
- Php 5.6.1-1
- Php-fpm 5.6.1-1
- Mariadb 10.0.14-2
- Discuz x2.5
Discuz is obtained here: http://www.discuz.net/thread-2744316-1-1.html.X2.5 UTF8 Simplified Chinese version
.
All other softwarepacman -S nginx php php-fpm mariadb
Install it.
Configure Nginx
Configuration file:/etc/nginx/nginx.conf
http { include mime.types; default_type application/octet-stream; #log_format main '$remote_addr - $remote_user [$time_local] "$request" ' # '$status $body_bytes_sent "$http_referer" ' # '"$http_user_agent" "$http_x_forwarded_for"'; #access_log logs/access.log main; sendfile on; #tcp_nopush on; #keepalive_timeout 0; keepalive_timeout 65; #gzip on; server { listen 80; server_name localhost; #charset koi8-r; #access_log logs/host.access.log main; root /usr/share/nginx/html; location / { index index.html index.htm index.php; #add_header Cache-Control privete; } location ~ \.php$ { fastcgi_pass unix:/run/php-fpm/php-fpm.sock; fastcgi_index index.php; include fastcgi.conf; }
Configure PHP
Configuration file:/etc/php/php.ini
open_basedir
Addingnginx
The root directory of the server (/usr/share/nginx/html/
). That is, the php program is told to parse the php file under that directory.
open_basedir = /usr/share/nginx/html/:/srv/http/:/home/:/tmp/:/usr/share/pear/:/usr/share/webapps/
Enable the following extensions. Remove the semicolon starting with that line.
extension=curl.soextension=gd.soextension=gettext.soextension=mysql.soextension=mysqli.soextension=pdo_mysql.so
Configure php-fpm
Configuration file:/etc/php/php-fpm.conf
Letlisten
In the nginx configurationfastcgi_pass
The values are consistent.
listen = /run/php-fpm/php-fpm.sock
Configure Database
Set Database root Password
mysql_secure_installation
Start the server
Note that all these commands require the root permission.
Start the server.
systemctl enable nginx.servicesystemctl enable mysqld.servicesystemctl enable php-fpm.service
Start the server
systemctl start nginx.servicesystemctl start mysqld.servicesystemctl start php-fpm.service
Install Discuz
Decompress the downloaded Discuz package andupload
Copy foldernginx
Under the Server Directory (/usr/share/nginx/html/
).
Open the browser and open http: // localhost/upload/install /.
If the world is peaceful and your configuration is normal, you should see the Dizcuz usage agreement page, click agree to enter the Installation Wizard, The Wizard will automatically detect the environment, if you encounterDirectory files
If you do not have permission or cannot find a directory, usechmod
Setnginx
Directory.
chmod -R a+rwx /usr/share/nginx/html/
Next, create a database. Most settings are as the name suggests.
Database username: root Database Password: the root password created when the database was previously configured
The next step is to install and ensure world peace.
Then, you will be asked if you have activated the Discuz cloud platform. Click the text on the right and you will not be able to activate it now. Then, the system automatically enters the forum.
Then you can play it as you like.