我正在尝试弄清楚如何在RNDIS Usb小工具上自动设置zeroconfig网络地址。
目前,当我插入设备时,在设备上我必须
$ modprobe g_ether
$ ifconfig usb0 up
$ avahi-autoipd usb0 &在主机上,我必须
$ avahi-autoipd usb0 &他们都会得到一个169.x.x.x的号码,我可以ping,但有时它不起作用。该设备没有NetworkManager,我们使用忙线盒启动,我将此作为一种可能的解决方案Static Host RNDIS IP by linux based USB Gadget device,但我更喜欢使用本地ip。
很久以前,我对如何设置脚本以便在接口可用时在/etc/network/ interface中运行进行了一些模糊的说明,但我很难再次找到它。
谢谢!
发布于 2014-04-18 04:42:45
我在/etc/network/interface中解决了这个问题
allow-hotplug usb0
iface usb* inet manual
up /usr/sbin/avahi-autoipd --force-bind -D $IFACE
down /usr/sbin/avahi-autoipd --kill $IFACEhttps://stackoverflow.com/questions/20149645
复制相似问题