Hi, On Wed, May 11, 2011 at 01:04:16AM +0200, Thierry Boureille wrote: > I'm currently doing some tests after moving from connman-0.64 to > last release. Maybe I"m wrong but it seems that now ip v4 address is > not correctly released when changing configuration from dhcp to > manual. That leads to have multiple IP on interface (is it quite > similar to > http://lists.connman.net/pipermail/connman/2011-April/004699.html ?)
I am trying to track down what I belive is the same issue.
Immediately following boot, I have this:
# ip addr show dev eth0
2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state
UNKNOWN qlen 1000
link/ether 00:30:18:a2:be:24 brd ff:ff:ff:ff:ff:ff
inet 10.100.0.28/20 brd 10.100.15.255 scope global eth0
inet6 fe80::230:18ff:fea2:be24/64 scope link
valid_lft forever preferred_lft forever
Python:
>>> import dbus
>>> bus = dbus.SystemBus()
>>> svc = bus.get_object('net.connman',
'/profile/default/ethernet_003018a2be24_cable')
>>> svc.GetProperties(dbus_interface =
'net.connman.Service')['IPv4.Configuration']
dbus.Dictionary({dbus.String(u'Method'): dbus.String(u'dhcp',
variant_level=1)}, signature=dbus.Signature('sv'), variant_level=1)
>>> svc.SetProperty('IPv4.Configuration', dbus.Dictionary({'Method': 'dhcp'},
signature = 'ss'), dbus_interface = 'net.connman.Service')
Now, I get this:
# ip addr show dev eth0
2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state
UNKNOWN qlen 1000
link/ether 00:30:18:a2:be:24 brd ff:ff:ff:ff:ff:ff
inet 10.100.0.28/20 brd 10.100.15.255 scope global eth0
inet 10.100.0.21/20 brd 10.100.15.255 scope global secondary eth0
inet6 fe80::230:18ff:fea2:be24/64 scope link
valid_lft forever preferred_lft forever
Python:
>>> svc.SetProperty('IPv4.Configuration', dbus.Dictionary({'Method': 'dhcp'},
signature = 'ss'), dbus_interface = 'net.connman.Service')
Now, I get this:
# ip addr show dev eth0
2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state
UNKNOWN qlen 1000
link/ether 00:30:18:a2:be:24 brd ff:ff:ff:ff:ff:ff
inet 10.100.0.28/20 brd 10.100.15.255 scope global eth0
inet 10.100.0.21/20 brd 10.100.15.255 scope global secondary eth0
inet 10.100.0.30/20 brd 10.100.15.255 scope global secondary eth0
inet6 fe80::230:18ff:fea2:be24/64 scope link
valid_lft forever preferred_lft forever
So setting the IPv4.Configuration property causes an additional DHCP lease to be
acquired each time. I don't think we should be doing anything if the property
is set without actually changing the value. Certainly if we do anything at all
it should be to renew the current lease.
The additional issue is that it seems that we are trying to release the old
lease and then acquire a new one but the release isn't actually working. From
the logs (with CONNMAN_DHCP_DEBUG=1) I see that a DHCP release request is being
sent ("DHCP: sending DHCP release request"), and I do see "eth0 ip release"
debug messages, too, so I'm not sure what is going wrong.
Thanks,
Forest
--
Forest Bond
rapidrollout.com / alittletooquiet.net / pytagsfs.org
signature.asc
Description: Digital signature
_______________________________________________ connman mailing list [email protected] http://lists.connman.net/listinfo/connman
