加入收藏 | 设为首页 | 会员中心 | 我要投稿 李大同 (https://www.lidatong.com.cn/)- 科技、建站、经验、云计算、5G、大数据,站长网!
当前位置: 首页 > 综合聚焦 > 服务器 > 安全 > 正文

LAMP搭建

发布时间:2020-12-15 18:18:13 所属栏目:安全 来源:网络整理
导读:命令代码(附加两张截图) 1 cd /etc/yum.repos.d 2 vi dvd.repo 3 cat /etc/hosts 4 cat /etc/hostname 5 vi /etc/hostname 6 hostname 7 login 8 vi /etc/hosts 9 ping pai 10 ls /opt 11 mkdir /opt/dvd 12 ls /opt 13 mount /dev/sr0 /opt/dvd 14 ls /op
命令代码(附加两张截图)
1 cd /etc/yum.repos.d
2 vi dvd.repo
3 cat /etc/hosts
4 cat /etc/hostname
5 vi /etc/hostname
6 hostname
7 login
8 vi /etc/hosts
9 ping pai
10 ls /opt
11 mkdir /opt/dvd
12 ls /opt
13 mount /dev/sr0 /opt/dvd
14 ls /opt/dvd
15 cd /etc/yum.repos.d
16 vi dvd.repo
17 yum clean all
18 yum list
19 iptables -F
20 iptables -X
21 iptables -L
22 setenforce 0
23 cd
24 yum install httpd httpd-devel mariadb-server mariadb-devel php php-mysql php-devel
25 systemctl restart {httpd,mariadb}
26 systemctl status httpd
27 systemctl status mariadb
28 mysqladmin -u root password 000000
29 mysql -uroot -p000000
30 ss -tnmlp | grep mysql
31 uname -r
32 ss -tnmlp | grep httpd
33 cd var/wwww/html/
34 cd var/www/html/
35 cd /var/www/html/
36 pwd
37 ls
38 mv /etc/httpd/conf.d/welcome.conf /etc/httpd/conf.d/welcome.confbak
39 ll /etc/httpd/conf.d
40 cd /var/www/html/
41 ls
42 cat /etc/httpd/conf/httpd.conf
43 pwd
44 vi index.php
45 mv /var/www/html/index.php /mnt/
46 ls /var/www/html/
47 cd
48 ls
49 yum install unzip
50 unzip Discuz-X3.1-SC-UTF8.zip -d /var/www/html/
51 unzip Discuz_X3.1_SC_UTF8.zip -d /var/www/html/
52 cd /var/www/html/
53 ls
54 cd upload
55 cp -rf /var/www/html
56 cp -rf
/var/www/html
57 cd /var/www/html/
58 ls
59 mysql -uroot -p
60 chown -R apache.apache /var/www/html



在浏览器输入 IP地址 打开


安装成功

登录

结束

(编辑:李大同)

【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容!

    推荐文章
      热点阅读