[Dnsmasq-discuss] Question of DHCP conf through private instance

V Yegyanathan v.yegyanathan at gmail.com
Tue Jul 17 04:29:16 BST 2012


Hi.
I am new to this group and I have requirement were the ip addresses are
auto configured through dhcp and no config file changes.

I short, the following are the steps I tried with no fruitful results.
// create a bridge and associate a dnsmasq instance
sudo brctl addbr mgmtbr0
sudo ip addr add 10.0.4.1/24 dev mgmtbr0
sudo ifconfig mgmtbr0 up
sudo dnsmasq --strict-order --bind-interfaces
--pid-file=<some-dir>/dnsmasq.pid --conf-file= --listen-address 10.0.4.1
--except-interface=lo --dhcp-range 10.0.4.2,10.0.4.254 --dhcp-lease-max=253
--dhcp-no-override --interface=mgmtbr0
==
$ ifconfig mgmtbr0
mgmtbr0   Link encap:Ethernet  HWaddr ee:97:b7:9c:ce:58
          inet addr:10.0.4.1  Bcast:0.0.0.0  Mask:255.255.255.0
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)

// create a link and add to the bridge
$ sudo ip link add name  test1 dynamic on type veth peer name test2 dynamic
on
$ sudo ifconfig test1 up
$ sudo ifconfig test2 up
$ sudo brctl addif mgmtbr0 test1
$ ifconfig test1
test1     Link encap:Ethernet  HWaddr 26:10:69:f6:78:8f
          UP BROADCAST RUNNING MULTICAST DYNAMIC  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:1 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:0 (0.0 B)  TX bytes:46 (46.0 B)

===
I was expecting ip address assignment for the interface.
I also tried "$ sudo dhclient -v test1 ", but could not.

==
I was wondering how virbr0 and lxcbr0 host instances get their ip, but
could not.

Kindly help me to understand.
Thanks a lot,
vy
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.thekelleys.org.uk/pipermail/dnsmasq-discuss/attachments/20120717/00094d8f/attachment.html>


More information about the Dnsmasq-discuss mailing list