您现在的位置是:首页 > cms教程 > Discuz教程Discuz教程
LNMP安装discuz
盼儿2025-07-17Discuz教程已有人查阅
导读php7的yum源安装1.安装epel源2.php3.nginx4.mariadb5.discuz
php7的yum源
1.安装epel源
rpm -Uvh https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm
rpm -Uvh https://mirror.webtatic.com/yum/el7/webtatic-release.rpm
安装
yum -y install php72w php72w-cli php72w-fpm php72w-common php72w-devel
LNMP1.安装epel源
[root@localhost ~]# yum -y install epel-release
2.php
yum -y install libmcrypt-devel mhash-devel libxslt-devel libjpeg libjpeg-devel libpng libpng-devel freetype freetype-devel libxml2 libxml2-devel zlib zlib-devel
glibc glibc-devel glib2 glib2-devel bzip2 bzip2-devellibidn-devel opensslopenssl-devel libzip
yum -y install php php-mysql php-fpm php-gdphp-pecl-zendopcache
[root@localhost ~]# vim /etc/php-fpm.d/ .conf
user = nginx
group = nginx
[root@localhost php]# setfacl -m u:nginx:rwx session
3.nginx
[root@localhost ~]# yum install nginx -y
server {
listen 80;
server_name.lh.com;
location / {
root /usr/share/nginx/html;
index index.php index.html index.htm;
}
error_page 500 502 503 504 /50x.html;
location = /50x.html {
root /usr/share/nginx/html;
}
location ~ \.php$ {
root /usr/share/nginx/html;
fastcgi_pass 127.0.0.1:9000;
fastcgi_index index.php;
fastcgi_param SCRIPT_FILENAME /usr/share/nginx/html/$fastcgi_script_name;
include fastcgi_params;
}
}
[root@localhost conf.d]# mkdir /php/nginx/web/ -pv
[root@localhost web]# yum install lrzsz
[root@localhost web]# yum install unzip
[root@localhost nginx]# chown -R nginx:nginx web
4.mariadb
[root@localhost conf.d]# yum install mariadb-server mariadb
[root@localhost conf.d]# vim /etc/my.cnf
skip_name_resolve = on
innodb_file_per_table = on
[root@localhost conf.d]# systemctl start mariadb
MariaDB [(none)]> create database discuz default charset 'utf8';
MariaDB [(none)]> grant all on discuz.* to 'disuser'@'%' identified by 'khb123';
5.discuz
[root@localhost html]# git clone https://gitee.com/ComsenzDiscuz/DiscuzX.git
[root@localhost html]# cp -rf /php/nginx/discuz/DiscuzX/upload/* /usr/share/nginx/html/
[root@localhost html]# chown -R nginx:nginx /usr/share/nginx/html/
本文标签:
很赞哦! ()
相关教程
图文教程
Discuz!X2安装步骤教程
Discuz!X2安装:1. 解压Discuz_X2_SC_UTF8.zip到目录:D:\program Files\Discuz_X2_SC_UTF8。2. 安装serv-u后,在本地服务器建立一个用户
虚拟主机怎么搭建discuz论坛
3.在MySQL下创建个库,保存数据授予所有权限给用户:wangshaojun密码为:denny4.修改本地真机的DNS5.打开apache主配置文件,把虚拟主机的配置文件注释去掉
discuz缓存机制介绍
Discuz的缓存同样分了主动缓存和被动缓存。从功能上来说,主动缓存一般用到管理员对全站的设置,等等需要手动更新的地方,这些地方的数据都有一个特点
Discuz实现NT数据库读写分离的方法
目前在Discuz!NT这个产品中,数据库作为数据持久化工具,必定在并发访问频繁且负载压力较大的情况下成 为系统性能的‘瓶颈’。即使使用本地缓存等方式来解决频繁访问数据库的问
相关源码
-
(PC+WAP)红色驾校培训学车在线预约源码下载基于PbootCMS内核开发的驾校培训专用网站模板,深度适配驾驶培训行业展示需求。采用PC与移动端同步响应设计,单一后台统一管理内容数据,更换图文素材后可快速转变为其他行业网站。查看源码 -
(PC+WAP)蓝色五金机械设备营销型网站源码下载基于PbootCMS内核开发的营销型企业网站模板,为五金机械设备类企业打造,通过标准化数字展示提升客户转化率。模板采用模块化设计,可快速适配机床工具、建筑五金、阀门管件等细分领域。查看源码 -
(自适应多语言)WordPress开源主题MirageV资讯个人博客源码MirageV资讯类个人博客主题源码/WordPress主题/全开源MirageV 是一款开源的 WordPress 主题,支持自适应、暗黑模式、多语言等功能,查看源码 -
(自适应响应式)绿色环保材料设备科技类营销型网站pbootcms源码下载本模板基于PbootCMS开发,主要面向环保设备、环保材料及相关科技企业。采用HTML5+CSS3技术构建,具备响应式特性,确保在各类设备上均有良好展示效果。查看源码 -
(自适应)蓝色厨卫厨房水龙头阀门水槽设备源码下载基于PbootCMS内核开发,深度适配厨卫设备行业特性。通过精准的产品展示模块与水效标识专区设计,有效呈现五金件工艺细节。响应式布局确保从手机到平板都能展示金属质感与水流动态效果。查看源码 -
(PC+WAP)红色家装设计智能家居家具建材pbootcms网站源码下载本模板基于PbootCMS系统开发,为智能家居、家装设计及家具建材行业设计。采用现代化布局风格,突出家居设计行业特色,适合展示各类家居产品、设计方案和建材信息。查看源码
| 分享笔记 (共有 篇笔记) |
