Centos7配置网络并连接SSH

配置虚拟机连接方式

image-20250304190143080

设置NAT连接方式

子网ip设置为192.168.130.0。不一定是130.0,可以自定义

网关ip设置为192.168.130.2,必须130.xxx

image-20250304190228878

.

image-20250304190248715

配置ens33网卡信息

输入命令:

vi /etc/sysconfig/network-scripts/ifcfg-ens33

编辑ens33如下:

编辑后,按Esc,输入:wq保存ens33文件。

重启网络

systemctl restart network

获取ip地址

ip addr

通过FinalShell进行远程连接

image-20250304191232728

相关文章

开始在上面输入您的搜索词,然后按回车进行搜索。按ESC取消。

返回顶部