NetBSD Problem Report #52733
From www@NetBSD.org Fri Nov 17 19:33:09 2017
Return-Path: <www@NetBSD.org>
Received: from mail.netbsd.org (mail.netbsd.org [199.233.217.200])
(using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
(Client CN "mail.NetBSD.org", Issuer "mail.NetBSD.org CA" (not verified))
by mollari.NetBSD.org (Postfix) with ESMTPS id 797307A188
for <gnats-bugs@gnats.NetBSD.org>; Fri, 17 Nov 2017 19:33:09 +0000 (UTC)
Message-Id: <20171117193308.AF5B57A1D6@mollari.NetBSD.org>
Date: Fri, 17 Nov 2017 19:33:08 +0000 (UTC)
From: jmcneill@invisible.ca
Reply-To: jmcneill@invisible.ca
To: gnats-bugs@NetBSD.org
Subject: vioif(4) does not work with VLANs unless in promiscuous mode
X-Send-Pr-Version: www-1.0
>Number: 52733
>Category: kern
>Synopsis: vioif(4) does not work with VLANs unless in promiscuous mode
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: kern-bug-people
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Fri Nov 17 19:35:00 +0000 2017
>Originator: Jared McNeill
>Release: 8.0_BETA
>Organization:
>Environment:
>Description:
The vioif(4) driver does not attempt to program the VLAN filter. As a result, communication is only possible when the interface is in promiscuous mode.
>How-To-Repeat:
Setup two VMs on VirtualBox 5.1.30 on an internal network.
On host A:
# ifconfig virtio0 up
# ifconfig vlan0 create
# ifconfig vlan0 vlan 1 vlanif virtio0
# ifconfig vlan0 inet 10.0.0.1 netmask 255.255.255.0 up
On host B:
# ifconfig virtio0 up
# ifconfig vlan0 create
# ifconfig vlan0 vlan 1 vlanif virtio0
# ifconfig vlan0 inet 10.0.0.2 netmask 255.255.255.0 up
Attempt to ping from host A to B will time out:
# ping 10.0.0.2
Start tcpdump on both sides:
# tcpdump -i virtio0
Attempt to ping from host A to B will succeed:
# ping 10.0.0.2
>Fix:
The FreeBSD driver configures a VLAN filter:
https://svnweb.freebsd.org/base/head/sys/dev/virtio/network/if_vtnet.c?view=markup&pathrev=313711#l3396
Not sure if configured VLAN IDs are accessible from the vlan(4) parent interface on NetBSD.
(Contact us)
$NetBSD: query-full-pr,v 1.39 2013/11/01 18:47:49 spz Exp $
$NetBSD: gnats_config.sh,v 1.8 2006/05/07 09:23:38 tsutsui Exp $
Copyright © 1994-2014
The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.