From mboxrd@z Thu Jan 1 00:00:00 1970 From: Julian Anastasov Date: Thu, 20 Dec 2001 12:46:40 +0000 Subject: Re: [LARTC] Trouble using "nexthop" Message-Id: List-Id: References: In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: lartc@vger.kernel.org Hello, On Tue, 4 Dec 2001, Whit Blauvelt wrote: > Hi, > > With a 2.2.20 kernel (and 2.2.19) and iproute2-ss991023, I'm having trouble > with nexthop syntax - or, I think the syntax is right according to examples, > but it's not working for me. For instance: > > ~# ip ro add default nexthop via 65.xx.yy.97 dev eth2 nexthop via 66.zz.ww.207 dev eth1 > RTNETLINK answers: Invalid argument Can you try to fix iproute2/ip/iproute.c:parse_nexthops() with change like this: --- iproute2/ip/iproute.c.orig Mon Aug 6 03:31:52 2001 +++ iproute2/ip/iproute.c Thu Dec 20 13:14:06 2001 @@ -620,6 +620,8 @@ } rtnh->rtnh_len = sizeof(*rtnh); rtnh->rtnh_ifindex = 0; + rtnh->rtnh_flags = 0; + rtnh->rtnh_hops = 0; rta->rta_len += rtnh->rtnh_len; parse_one_nh(rta, rtnh, &argc, &argv); rtnh = RTNH_NEXT(rtnh); This is for iproute2-2.4.7-now-ss010824.tar.gz. If you are using different version then make sure the fix resets all fields: rtnh_ifindex, rtnh_flags and rtnh_hops. Your problem is probably unexpected bits set in the rtnh_flags and refused from the kernel (probably fib_semantics.c:fib_check_nh or another place) Regards -- Julian Anastasov _______________________________________________ LARTC mailing list / LARTC@mailman.ds9a.nl http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://ds9a.nl/lartc/