Date: Wed, 21 Sep 2011 16:47:19 +0400 From: Sergey Kandaurov <pluknet@gmail.com> To: Devin Teske <devin.teske@fisglobal.com> Cc: Dave Robison <Dave.Robison@fisglobal.com>, FreeBSD amd64 <freebsd-amd64@freebsd.org> Subject: Re: 32-bit route(8) on amd64 host and jails Message-ID: <CAE-mSO%2B4KKWeC6-Z3UAi70bxxEUJL5gUD0phEfNzzkDMXrA3pg@mail.gmail.com> In-Reply-To: <714EF3C9-33B0-4EF5-B52C-1E95F7F432F9@fisglobal.com> References: <714EF3C9-33B0-4EF5-B52C-1E95F7F432F9@fisglobal.com>
next in thread | previous in thread | raw e-mail | index | archive | help
On 21 September 2011 06:40, Devin Teske <devin.teske@fisglobal.com> wrote: > I'm noticing that a 32-bit route(8) shows strange behaviour while running= under an amd64 kernel (regardless of whether in the base-host -- utilizing= /usr/lib32/libc.so.7 -- or in a jail and/or vimage -- 32-bit in nature; re= sults are same). > > Executable runs fine, but you can't (a) set the default route or (b) view= the default route (after successfully setting it with the amd64 build, of = course). > > ASIDE: This is under 8.1-RELEASE. > > When attempting to set the default route, you get the following... > > root@kps0a / # route add -net default 10.10.125.99 > route: writing to routing socket: Invalid argument > add net default: gateway 10.10.125.99: Invalid argument > > Meanwhile, using the amd64 version, no issues. > > When attempting to view the default route, you get the following... > > root@kps0a / # route -n get default > =A0 route to: default > destination: default > =A0 =A0 =A0 mask: default > =A0 =A0gateway: default > =A0 =A0 =A0flags: <UP,GATEWAY,DONE,STATIC> > =A0recvpipe =A0sendpipe =A0ssthresh =A0rtt,msec =A0 =A0mtu =A0 =A0 =A0 = =A0weight =A0 =A0expire > =A0 =A0 =A0 0 =A0 =A0 =A0 =A0 0 =A0 =A0 =A0 =A0 0 =A0 =A0 =A0 =A0 0 =A0 = =A0 =A0 =A0 0 =A0 =A0 =A0 =A0 0 =A0-1316570637 > > It's the "gateway: default" that's out of place. > Currently, FreeBSD has a poor shape of rtsocket freebsd32 compatibility, AFAIK only sysctl layer (sysctl_rtsock) is aware of it. That means when a 32bit app writes some data to a routing socket, kernel expects to receive it in the native ABI, and it doesn't work. --=20 wbr, pluknet
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CAE-mSO%2B4KKWeC6-Z3UAi70bxxEUJL5gUD0phEfNzzkDMXrA3pg>