kern/165769: IPv6 Initialization on external iface is too slow for
jail
Oleg Ginzburg
olevole at olevole.ru
Tue Mar 6 05:20:09 UTC 2012
>Number: 165769
>Category: kern
>Synopsis: IPv6 Initialization on external iface is too slow for jail
>Confidential: no
>Severity: serious
>Priority: low
>Responsible: freebsd-bugs
>State: open
>Quarter:
>Keywords:
>Date-Required:
>Class: sw-bug
>Submitter-Id: current-users
>Arrival-Date: Tue Mar 06 05:20:09 UTC 2012
>Closed-Date:
>Last-Modified:
>Originator: Oleg Ginzburg
>Release: 9.0-RELEASE, STABLE and 10.0-CURRENT
>Organization:
>Environment:
FreeBSD gizmo.my.domain 9.0-STABLE FreeBSD 9.0-STABLE #1: Thu Feb 23 21:52:05 MSK 2012 root at gizmo.my.domain:/usr/obj/usr/src/sys/G amd64
>Description:
I have found that at start JAIL creating IPv6 the address on the interface, inet6 stack isn't ready, therefore programs in automatic loading usually aren't capable to listen to a socket. It is reproduced on external interfaces (I tested on nfe and msk), but not for loopback.
Delay in 1 seconds between setup ip and jail start is enough.
good for lo0:
% ifconfig lo0 inet6 fd9c:8e81:4e64:a6e6::10/64 ; jail -c path=/ ip6.addr=fd9c:8e81:4e64:a6e6::10 command=nc -6 -l 1234
^C
% ifconfig lo0 inet6 fd9c:8e81:4e64:a6e6::10 -alias
good with delay:
% ifconfig msk0 inet6 fd9c:8e81:4e64:a6e6::10/64 ; sleep 1; jail -c path=/ ip6.addr=fd9c:8e81:4e64:a6e6::10 command=nc -6 -l 1234
^C
% ifconfig msk0 inet6 fd9c:8e81:4e64:a6e6::10 -alias
good wihtout jail:
% ifconfig msk0 ifdisabled
% ifconfig msk0 inet6 fd9c:8e81:4e64:a6e6::10/64 ; nc -6 -l 1234
^C
% ifconfig msk0 inet6 fd9c:8e81:4e64:a6e6::10/64
bind error:
% ifconfig msk0 inet6 fd9c:8e81:4e64:a6e6::10/64 ; jail -c path=/ ip6.addr=fd9c:8e81:4e64:a6e6::10 command=nc -6 -l 1234
% ifconfig msk0 inet6 fd9c:8e81:4e64:a6e6::10/64
bind error (In a case when ipv6 it is not initialized, delays in 1 second don't suffice):
% ifconfig msk0 inet6 ifdisabled
% ifconfig msk0 inet6 fd9c:8e81:4e64:a6e6::10/64 ; sleep 1 ; jail -c path=/ ip6.addr=fd9c:8e81:4e64:a6e6::10 command=nc -6 -l 1234
>How-To-Repeat:
ifconfig <ext_iface> inet6 <ipv6> && jail -c path=/ ip6.addr=<ipv6> command=nc -6 -l 1234
>Fix:
sorry
>Release-Note:
>Audit-Trail:
>Unformatted:
More information about the freebsd-bugs
mailing list