首页
学习
活动
专区
圈层
工具
发布
社区首页 >专栏 >VirtualBox 虚拟机设置上网和互通

VirtualBox 虚拟机设置上网和互通

作者头像
杨焱
发布于 2021-12-07 19:46:19
发布于 2021-12-07 19:46:19
1.5K0
举报
文章被收录于专栏:杨焱的专栏杨焱的专栏

发表于2020-05-292020-05-29 作者 wind

网络一设置使用NAT(用来上网)

网络二使用HostOnly 用来虚拟机和宿主主机互通

代码语言:javascript
复制
yangyan@debian:~$ cat /etc/network/interfaces
# This file describes the network interfaces available on your system
# and how to activate them. For more information, see interfaces(5).

source /etc/network/interfaces.d/*

# The loopback network interface
auto lo
iface lo inet loopback

# The primary network interfac
auto enp0s3
iface enp0s3 inet dhcp

auto enp0s8
iface enp0s8 inet static
address 192.168.56.11
netmask 255.255.255.0
gateway 192.168.56.1
本文参与 腾讯云自媒体同步曝光计划,分享自作者个人站点/博客。
原始发表:2020-05-29,如有侵权请联系 cloudcommunity@tencent.com 删除
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档