5.6.4. 使用 DHCP 的网络接口

第 5.5.1 节 “以太网 DHCP 连接” 准备系统后,在”/etc/network/interfaces“ 里面,按下面的内容创建配置条目后,网络接口的 DHCP 便配置好了。

  1. allow-hotplug eth0
  2. iface eth0 inet dhcp

当 Linux 内核检测到物理接口 eth0, allow-hotplug 节促使 ifup 启动接口,iface 促使 ifup 使用 DHCP 来配置接口。