Re: failed to set IPv6 default route

2012-09-27 Thread Bjørn Mork
Dan Williams d...@redhat.com writes:
 On Mon, 2012-09-24 at 08:05 -0400, Gene Czarcinski wrote:

  ip  -6  route  add  default  via fill_IPv6_address_of_'router'  
 dev  eth0

 So that's essentially what NM is trying to do, actually, but NM is
 trying to do it with netlink (which is what /sbin/ip uses too actually)
 but apparently the netlink options we're adding aren't quite correct
 here.  They unfortunately change periodically when kernel changes
 happen.  -7 appears to be NLE_INVAL, which would indicate the kernel
 doesn't think the route we gave it is valid.  We'd have to dig a bit
 further down to figure out what that error actually is.

 Last time I had to do this, I had to rebuild /sbin/ip and make it print
 out the exact netlink packet it was sending to the kernel.  Then I had
 NM print out its packet and compared the two.  If only there was an
 easier way...

strace -f -s 1024 ip route add ...?  Or use libnl?
http://www.infradead.org/~tgr/libnl/

But I don't think the kernel APIs should change, so if that is really
the problem then we should fix it.


Bjørn
___
networkmanager-list mailing list
networkmanager-list@gnome.org
https://mail.gnome.org/mailman/listinfo/networkmanager-list


Re: failed to set IPv6 default route

2012-09-27 Thread Dan Williams
On Thu, 2012-09-27 at 12:55 +0200, Bjørn Mork wrote:
 Dan Williams d...@redhat.com writes:
  On Mon, 2012-09-24 at 08:05 -0400, Gene Czarcinski wrote:
 
   ip  -6  route  add  default  via fill_IPv6_address_of_'router'  
  dev  eth0
 
  So that's essentially what NM is trying to do, actually, but NM is
  trying to do it with netlink (which is what /sbin/ip uses too actually)
  but apparently the netlink options we're adding aren't quite correct
  here.  They unfortunately change periodically when kernel changes
  happen.  -7 appears to be NLE_INVAL, which would indicate the kernel
  doesn't think the route we gave it is valid.  We'd have to dig a bit
  further down to figure out what that error actually is.
 
  Last time I had to do this, I had to rebuild /sbin/ip and make it print
  out the exact netlink packet it was sending to the kernel.  Then I had
  NM print out its packet and compared the two.  If only there was an
  easier way...
 
 strace -f -s 1024 ip route add ...?  Or use libnl?
 http://www.infradead.org/~tgr/libnl/
 
 But I don't think the kernel APIs should change, so if that is really
 the problem then we should fix it.

I'd also used the tools from libnl's src/ directory and made them print
out the actual packets they sent, which is quite easy.  But since my
goal was to re-implement whatever /sbin/ip was doing using libnl code in
NM, I had to instrument /sbin/ip to figure that out.  Since /sbin/ip
always worked, but NM didn't, and the libnl src/ stuff couldn't quite do
it either.

But yeah, libnl has some pretty great debugging features.

Dan

___
networkmanager-list mailing list
networkmanager-list@gnome.org
https://mail.gnome.org/mailman/listinfo/networkmanager-list


Re: failed to set IPv6 default route

2012-09-24 Thread Gene Czarcinski

On 09/23/2012 08:56 AM, Gene Czarcinski wrote:
I have been doing some work trying to improve IPv6 dhcp support in 
NetworkManager.  This has involved a lot of (virtual) testing. One 
thing I began to notice is a lot of the following message appearing in 
syslog:


[nm-system.c:1121] nm_system_replace_default_ip6_route(): (p32p1): 
failed to set IPv6 default route: -7


The only way I have been able to get an IPv6 default route set is to 
use manual configuration and specify a gateway.  Everything else seems 
to produce this message.


OK, is this a bug or is there something about configuration I do not 
understand?




My question concerning if this is a bug stands.

However, I have been playing around (marvelous what you can do with some 
qemu/kvm/libvirt virtual guests when you do not care if things get 
really screwed up).  I thried using NetworkManager (the applet) to set a 
default route but nothing seemed to work except specifying the gateway 
when manually configuring IPv6.


I finally googled what appears to be (sort of) an answer. enter 
something like the following command line command:


ip  -6  route  add  default  via fill_IPv6_address_of_'router'  
dev  eth0


With that, ip -6 route' actually shows a good default and, even better, 
stuff starts to work.


IPv6 does not have a way of specifying a default route with dhp6 but, 
that does not mean that we can do something which will be good enough 
until those great folks in the IETF get things worked out.


We need something in the applet so that we can specify a default and 
then issue something like the above command.


Note:  I may be wrong and this can be done in the applet and set 
correctly ... if so, some kind of doc or change to the applet is needed 
to make this capability clear.


Sort-of OT question:  Why can't I specify additional name servers and 
search domains if I select IPV6 dhcp?


Gene
___
networkmanager-list mailing list
networkmanager-list@gnome.org
https://mail.gnome.org/mailman/listinfo/networkmanager-list


Re: failed to set IPv6 default route

2012-09-24 Thread Dan Williams
On Mon, 2012-09-24 at 08:05 -0400, Gene Czarcinski wrote:
 On 09/23/2012 08:56 AM, Gene Czarcinski wrote:
  I have been doing some work trying to improve IPv6 dhcp support in 
  NetworkManager.  This has involved a lot of (virtual) testing. One 
  thing I began to notice is a lot of the following message appearing in 
  syslog:
 
  [nm-system.c:1121] nm_system_replace_default_ip6_route(): (p32p1): 
  failed to set IPv6 default route: -7
 
  The only way I have been able to get an IPv6 default route set is to 
  use manual configuration and specify a gateway.  Everything else seems 
  to produce this message.
 
  OK, is this a bug or is there something about configuration I do not 
  understand?
 
 
 My question concerning if this is a bug stands.
 
 However, I have been playing around (marvelous what you can do with some 
 qemu/kvm/libvirt virtual guests when you do not care if things get 
 really screwed up).  I thried using NetworkManager (the applet) to set a 
 default route but nothing seemed to work except specifying the gateway 
 when manually configuring IPv6.
 
 I finally googled what appears to be (sort of) an answer. enter 
 something like the following command line command:
 
  ip  -6  route  add  default  via fill_IPv6_address_of_'router'  
 dev  eth0

So that's essentially what NM is trying to do, actually, but NM is
trying to do it with netlink (which is what /sbin/ip uses too actually)
but apparently the netlink options we're adding aren't quite correct
here.  They unfortunately change periodically when kernel changes
happen.  -7 appears to be NLE_INVAL, which would indicate the kernel
doesn't think the route we gave it is valid.  We'd have to dig a bit
further down to figure out what that error actually is.

Last time I had to do this, I had to rebuild /sbin/ip and make it print
out the exact netlink packet it was sending to the kernel.  Then I had
NM print out its packet and compared the two.  If only there was an
easier way...

Dan

 With that, ip -6 route' actually shows a good default and, even better, 
 stuff starts to work.
 
 IPv6 does not have a way of specifying a default route with dhp6 but, 
 that does not mean that we can do something which will be good enough 
 until those great folks in the IETF get things worked out.
 
 We need something in the applet so that we can specify a default and 
 then issue something like the above command.
 
 Note:  I may be wrong and this can be done in the applet and set 
 correctly ... if so, some kind of doc or change to the applet is needed 
 to make this capability clear.
 
 Sort-of OT question:  Why can't I specify additional name servers and 
 search domains if I select IPV6 dhcp?
 
 Gene
 ___
 networkmanager-list mailing list
 networkmanager-list@gnome.org
 https://mail.gnome.org/mailman/listinfo/networkmanager-list


___
networkmanager-list mailing list
networkmanager-list@gnome.org
https://mail.gnome.org/mailman/listinfo/networkmanager-list


Re: failed to set IPv6 default route

2012-09-24 Thread Gene Czarcinski

On 09/24/2012 12:30 PM, Dan Williams wrote:

On Mon, 2012-09-24 at 08:05 -0400, Gene Czarcinski wrote:

On 09/23/2012 08:56 AM, Gene Czarcinski wrote:

I have been doing some work trying to improve IPv6 dhcp support in
NetworkManager.  This has involved a lot of (virtual) testing. One
thing I began to notice is a lot of the following message appearing in
syslog:

[nm-system.c:1121] nm_system_replace_default_ip6_route(): (p32p1):
failed to set IPv6 default route: -7

The only way I have been able to get an IPv6 default route set is to
use manual configuration and specify a gateway.  Everything else seems
to produce this message.

OK, is this a bug or is there something about configuration I do not
understand?



My question concerning if this is a bug stands.

However, I have been playing around (marvelous what you can do with some
qemu/kvm/libvirt virtual guests when you do not care if things get
really screwed up).  I thried using NetworkManager (the applet) to set a
default route but nothing seemed to work except specifying the gateway
when manually configuring IPv6.

I finally googled what appears to be (sort of) an answer. enter
something like the following command line command:

  ip  -6  route  add  default  via fill_IPv6_address_of_'router'
dev  eth0

So that's essentially what NM is trying to do, actually, but NM is
trying to do it with netlink (which is what /sbin/ip uses too actually)
but apparently the netlink options we're adding aren't quite correct
here.  They unfortunately change periodically when kernel changes
happen.  -7 appears to be NLE_INVAL, which would indicate the kernel
doesn't think the route we gave it is valid.  We'd have to dig a bit
further down to figure out what that error actually is.

Last time I had to do this, I had to rebuild /sbin/ip and make it print
out the exact netlink packet it was sending to the kernel.  Then I had
NM print out its packet and compared the two.  If only there was an
easier way...


I am currently running 0.9.4.0 and in the process of updating to 0.9.7.0 
is see if that makes a difference.


Gene
___
networkmanager-list mailing list
networkmanager-list@gnome.org
https://mail.gnome.org/mailman/listinfo/networkmanager-list


Re: failed to set IPv6 default route

2012-09-24 Thread Gene Czarcinski

On 09/24/2012 01:05 PM, Gene Czarcinski wrote:

On 09/24/2012 12:30 PM, Dan Williams wrote:

On Mon, 2012-09-24 at 08:05 -0400, Gene Czarcinski wrote:

On 09/23/2012 08:56 AM, Gene Czarcinski wrote:

I have been doing some work trying to improve IPv6 dhcp support in
NetworkManager.  This has involved a lot of (virtual) testing. One
thing I began to notice is a lot of the following message appearing in
syslog:

[nm-system.c:1121] nm_system_replace_default_ip6_route(): (p32p1):
failed to set IPv6 default route: -7

The only way I have been able to get an IPv6 default route set is to
use manual configuration and specify a gateway.  Everything else seems
to produce this message.

OK, is this a bug or is there something about configuration I do not
understand?



My question concerning if this is a bug stands.

However, I have been playing around (marvelous what you can do with 
some

qemu/kvm/libvirt virtual guests when you do not care if things get
really screwed up).  I thried using NetworkManager (the applet) to 
set a

default route but nothing seemed to work except specifying the gateway
when manually configuring IPv6.

I finally googled what appears to be (sort of) an answer. enter
something like the following command line command:

  ip  -6  route  add  default  via fill_IPv6_address_of_'router'
dev  eth0

So that's essentially what NM is trying to do, actually, but NM is
trying to do it with netlink (which is what /sbin/ip uses too actually)
but apparently the netlink options we're adding aren't quite correct
here.  They unfortunately change periodically when kernel changes
happen.  -7 appears to be NLE_INVAL, which would indicate the kernel
doesn't think the route we gave it is valid.  We'd have to dig a bit
further down to figure out what that error actually is.

Last time I had to do this, I had to rebuild /sbin/ip and make it print
out the exact netlink packet it was sending to the kernel.  Then I had
NM print out its packet and compared the two.  If only there was an
easier way...


I am currently running 0.9.4.0 and in the process of updating to 
0.9.7.0 is see if that makes a difference.



I build and installed 0.9.7.0-1.git20120820 on real hardware. Does not 
appear to make any difference.


Should I bugzilla this?

Gene

___
networkmanager-list mailing list
networkmanager-list@gnome.org
https://mail.gnome.org/mailman/listinfo/networkmanager-list


Re: failed to set IPv6 default route

2012-09-24 Thread Gene Czarcinski

On 09/24/2012 02:49 PM, Gene Czarcinski wrote:

On 09/24/2012 01:05 PM, Gene Czarcinski wrote:

On 09/24/2012 12:30 PM, Dan Williams wrote:

On Mon, 2012-09-24 at 08:05 -0400, Gene Czarcinski wrote:

On 09/23/2012 08:56 AM, Gene Czarcinski wrote:

I have been doing some work trying to improve IPv6 dhcp support in
NetworkManager.  This has involved a lot of (virtual) testing. One
thing I began to notice is a lot of the following message 
appearing in

syslog:

[nm-system.c:1121] nm_system_replace_default_ip6_route(): (p32p1):
failed to set IPv6 default route: -7

The only way I have been able to get an IPv6 default route set is to
use manual configuration and specify a gateway. Everything else seems
to produce this message.

OK, is this a bug or is there something about configuration I do not
understand?



My question concerning if this is a bug stands.

However, I have been playing around (marvelous what you can do with 
some

qemu/kvm/libvirt virtual guests when you do not care if things get
really screwed up).  I thried using NetworkManager (the applet) to 
set a

default route but nothing seemed to work except specifying the gateway
when manually configuring IPv6.

I finally googled what appears to be (sort of) an answer. enter
something like the following command line command:

  ip  -6  route  add  default  via fill_IPv6_address_of_'router'
dev  eth0

So that's essentially what NM is trying to do, actually, but NM is
trying to do it with netlink (which is what /sbin/ip uses too actually)
but apparently the netlink options we're adding aren't quite correct
here.  They unfortunately change periodically when kernel changes
happen.  -7 appears to be NLE_INVAL, which would indicate the kernel
doesn't think the route we gave it is valid.  We'd have to dig a bit
further down to figure out what that error actually is.

Last time I had to do this, I had to rebuild /sbin/ip and make it print
out the exact netlink packet it was sending to the kernel. Then I had
NM print out its packet and compared the two.  If only there was an
easier way...


I am currently running 0.9.4.0 and in the process of updating to 
0.9.7.0 is see if that makes a difference.



I build and installed 0.9.7.0-1.git20120820 on real hardware. Does not 
appear to make any difference.


Should I bugzilla this?



At this point in time ... it works and I will not bugzilla naturally.

First thing is that it took 0.9.7.0.

Next I am using dhcp6 with dynamic DNS updating using dnsmasq as the 
server and it did not really work until I stopped NetworkManager, 
deleted the dhclient lease files, and then restarted NetworkManager.  
Old lease files can confuse things.



Gene
___
networkmanager-list mailing list
networkmanager-list@gnome.org
https://mail.gnome.org/mailman/listinfo/networkmanager-list