Thanks, but is there a reason WHY dnsmasq is not used for IPv6 by default?
odhcpd does much more than just ipv6 dhcp. In addition to dhcpv6 it provides all RA functionality -
accepts RAs (instead of default kernel built-in mechanism which is not used in openwrt),
can act as RA server and can do RA/NDP relaying (which is itself very specific function).
Its well integrated with openwrt's network management engine - netifd - and communicates with it directly via ubus interface. So, odhcpd is openwrt specific daemon written in C to meet all its specific needs. Initially devs wrote shell scripts for all the stuff and used well known commands and daemons but later they started to write native daemons because of increased stability and reliability.
Better question - why still dnsmasq used as dhcpv4 server. Odhcpd contain dhcpv4 code. May be because dnsmasq is more configurable and for older versions compatibility. Odhcpd is good thing for most uses but there're scenarios where its not enough flexible and radvd have to be used.
Is there any reason why would I need both?
Without ipv6 odhcpd can be safely disabled.
If you disable dnsmasq you will lose dns and dhcpv4.
Of course its possible to throw away standard openwrt management and use some daemons - bind, isc-dhcp server, radvd. But this way openwrt becomes something else - may be more simular to standard linux distros. You lose ability to control it properly via uci/luci/ubus/netifd and may encounter some conflicts between built-in management leftovers and external daemons which know nothing about openwrt. Also standard daemons take more resources and 32 mb of RAM can be too small for them all. They also may not fit to builtin flash.
(Last edited by bolvan on 20 Oct 2016, 18:40)