没有默认路线继续?

我必须使用Ubuntu12.04完成无人参与的节点安装。 我在preseed文件中给出了以下选项

di netcfg/choose_interface select eth0 di netcfg/disable_dhcp boolean true di netcfg/dhcp_failed note di netcfg/dhcp_options select Configure network manually di netcfg/disable_autoconfig boolean true di netcfg/use_autoconfig boolean false di netcfg/network-manager boolean false di netcfg/no_default_route boolean true di netcfg/enable boolean true di netcfg/get_ipaddress string 192.168.1.103 di netcfg/get_netmask string 255.255.0.0 di netcfg/Confirm_static boolean true 

仍然迪问“没有默认路线继续吗?”,我不得不说YES manullay。 如何在配置网络时预先设置此项


即使设置默认网关和名称服务器仍然相同。

看起来您没有定义默认网关,您需要使用:

 di netcfg/get_gateway string 192.168.1.1 

当然上面命令中的ip地址只是一个guest虚拟机,你应该将它调整到网络的正确网关。

我无法测试它,但你很可能也会需要它:

 di netcfg/get_nameservers string 192.168.1.1 di netcfg/confirm_static boolean true 

第一个将设置dns,我不知道为什么或第二个是必要的,但它出现在文档中所以……