summaryrefslogtreecommitdiffstats
path: root/package/busybox/udhcpc.script
Commit message (Collapse)AuthorAgeFilesLines
* busybox: udhcpc.script: fix resolv.conf handling with multiple interfacesPeter Korsgaard2013-06-261-3/+16
| | | | | | | | | | | | | | | | | | | | | When udhcpc is used on multiple network devices at the same time (or a mix of dhcp and fixed configuration), /etc/resolv.conf should contain the union of information from all the interfaces. Currently that's not the case. The udhcpc script simply overwrites resolv.conf with the information from the specific interface on each dhcp bound/renew event. Fix it by tagging lines with the interface they came from when added, and drop the affected lines on deconfig/renew. As /etc/resolv.conf is often a symlink to /tmp (and rootfs might be read only), special care has to be taken when it is updated. Notice that I'm not really aware of any official documentation requiring that '#' comments in /etc/resolv.conf must be supported, but atleast glibc and uClibc do. Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
* busybox: udhcpc.script: cleanupPeter Korsgaard2013-06-261-8/+3
| | | | | | | | | | | | | | | | ifconfig up is a no-op if the device is already running, so let's just do that unconditionally. Systems might have multiple network devices, and perhaps run udhcpc on another interface even when booted over nfs, so don't disable the per-interface deconfig based on the global nfsroot= setting on the kernel command line. If you don't want udhcpc to mess with kernel level IP autoconfiguration (E.G. for nfs boot), you should instead ensure udhcpc/ifup/ifplugd isn't started for that interface. Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
* busybox: use a single udhcpc script, with or without avahi-autoipdPeter Korsgaard2013-06-261-1/+20
| | | | | | | | | | | | | We're currently using two different udhcpc scripts, one in the busybox package and another in the avahi one, which calls avahi-autoipd on dhcp failures. The avahi one actually only does something differently from the default if avahi-autoipd is available, so let's just always use this one instead of the complicated logic about writing the file if not present / overwriting it afterwards. Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
* busybox: move udhcp script from skeleton to packageLionel Landwerlin2010-12-131-0/+39
Since udhcpc is part of busybox, it seems logical to move the udhcpc script from skeleton to busybox. [Peter: only install if not available in skeleton] Signed-off-by: Lionel Landwerlin <llandwerlin@gmail.com> Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>