### 1.安装 Apache --> httpd
```
[root@centos7 ~]#yum install httpd -y
[root@centos7 ~]#systemctl start httpd
[root@centos7 ~]#systemctl enable httpd
Created symlink from /etc/systemd/system/multi-user.target.wants/httpd.service to /usr/lib/systemd/system/httpd.service.
[root@centos7 ~]#echo apache test > /var/www/html/index.html
[root@centos7 ~]#cat /var/www/html/index.html
apache test
```
### 2.浏览器访问--> PC电脑
```
win+r #打开windows控制面板
cmd #进入控制台
ipconfig #查看VMnet8网卡的IP地址
以太网适配器 VMware Network Adapter VMnet8:
连接特定的 DNS 后缀 . . . . . . . :
本地链接 IPv6 地址. . . . . . . . : fe80::ff5e:808a:5a13:47ae%8
IPv4 地址 . . . . . . . . . . . . : 10.0.0.166
子网掩码 . . . . . . . . . . . . : 255.255.255.0
默认网关. . . . . . . . . . . . . : 10.0.0.1
```
**xshell***
```
[root@centos7 ~]#yum -y install firefox libglvnd-glx && yum -y groupinstall Fonts
**windows: Xmanager - Passive查看端口是0.0还是0.1**
```
### 3.查看 windows VMnet8 地址
```
[root@centos7 ~]#export DISPLAY=10.0.0.166:0.0
[root@centos7 ~]#firefox
```
**Mobaxterm CentOS**
```
1.yum install xorg-x11-xauth xorg-x11-fonts-* xorg-x11-font-utils xorg-x11-fonts-Type1 firefox mailx
2.exit
3.firefox
```