vm 虚拟机搭建的centos 7通过xhell连接

1.系统安装不再赘述

安装参考连接

2.配置网络参数

2.1 网络适配器选择NAT模式

这里写图片描述

2.2 在VM中菜单栏点击编辑–>虚拟网络编辑,如图配置。需要主机子网ip的网段需要跟主机的的网段一样

这里写图片描述

2.3 在CentOS中 打开终端关闭防火墙

centos7 命令如下
systemctl start firewalld.service#启动firewall 
systemctl stop firewalld.service#停止firewall 
systemctl disable firewalld.service#禁止firewall开机启动

===================================================================
CentOS 6: 
1) 永久性生效,重启后不会复原 
开启: chkconfig iptables on 
关闭: chkconfig iptables off 
2) 即时生效,重启后复原 
开启: service iptables start 
关闭: service iptables stop 

2.4 查看 虚拟机中linux ip

这里写图片描述

3 打开xhell 登录 搞定收工

这里写图片描述

猜你喜欢

转载自blog.csdn.net/qg_zhang/article/details/79942842
今日推荐