On Dienstag, 1. November 2016 21:28:43 CET johnzeng wrote: [..]
i run avahi-autoipd bat0 at two host only ( not run dhcpcd ) and run batctl gw_mode server and batctl gw_mode server 5mbit/1mbit at hostA,
batman-adv gateway (mode) is only about filtering DHCP packets from the client. They will (with enabled gw client mode + reachable gw server) packets only at the "best" DHCP server. So it will not do anything with your avahi packets.
The configuration of an DHCP server is not really something for this mailing list. There is more than one tutorial how to use dnsmasq or isc-dhcp-server
and run batctl gw_mode client and batctl gw_mode client 20 at hostB
This will not work. One of the devices has to be the one answering the DHCP requests (aka the "gw_mode server").
Kind regards, Sven