2. 向你的 Debian 或者 ubuntu 操作系统描述你要添加的虚拟网络设备,编辑 /etc/network/interfaces:(请先备份)
sudo vim /etc/network/interfaces
在打开的文件后面添加下面的内容,将虚拟网络接口命名为 "tap0",指定该接口IP配置方法为手动,并指定使用该接口的用户(请用你的用户名替换其中的 "vboxuser"):
auto tap0
iface tap0 inet manual
up ifconfig $IFACE 0.0.0.0 up
down ifconfig $IFACE down
tunctl_user vboxuser