From owner-freebsd-net@freebsd.org Sat Apr 28 05:49:58 2018 Return-Path: Delivered-To: freebsd-net@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 541BAFC13E6 for ; Sat, 28 Apr 2018 05:49:58 +0000 (UTC) (envelope-from ab.tariq90@gmail.com) Received: from mail-it0-x22d.google.com (mail-it0-x22d.google.com [IPv6:2607:f8b0:4001:c0b::22d]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id C615683AD0 for ; Sat, 28 Apr 2018 05:49:57 +0000 (UTC) (envelope-from ab.tariq90@gmail.com) Received: by mail-it0-x22d.google.com with SMTP id 19-v6so4284800itw.3 for ; Fri, 27 Apr 2018 22:49:57 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=C196ntBdMGRwZRJUJ/bj0ILXPJL/w4qqQU1Lyln53s4=; b=UvydqSG33gRimuTgplV57q6cMOwK2lU9BAidRu7jGNmceRjSwsuT3MxKaG++aGrlll L5D5WwEwFOkn0lT+cBJJqkrt3l7Ng1UDUl+4MiPtF74fVeob0Y7Zm0C0VxSuNqEgcJZS kOv3ot6RtsobQ5KJSfkkBJkdotHZhBfEcaPjctgQoT0W5xnnzRLpffB5m1jNKcE2k9K1 YscTtcIljoegWq6sJqa9jYmz8D6kE9N3BZihkHXUSRq5yzEGtRt8lKCbLEWJKuFgM+as J1Md8FdAdy48K9rhwgNtrLhuG0JQGo7r/JK8fQZw2bG45Gq0o2VrHSCOdOcf0G6F83Zg cjvg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=C196ntBdMGRwZRJUJ/bj0ILXPJL/w4qqQU1Lyln53s4=; b=DmcEqdGBGM30PyZOnV/Zi6LDNmbp3E9nYrRa8rbrzsgowmQO1qRkgabW25ADa0H1tp 5upwsBQ19UEjctgQF97ux7qgJNdV3xBumczWb6VYotsagSz6NDOvLTS6DU3V0ai4I4BT N5LzuPTmAUioPcV4C0D6JgJRY5pkFuIJF/d3X5sfNo5mf65oU7qiybJof/biElNjbCud kG9ciPiA6yPDMl4t9fVU1PYhEUpKBoaVLbCM2Ow2lr88QEsX/+wMT3zFGh+/bbmAM9IR GVgCFKKBuzpB/+sxqTCRU0RvtpHyJS0E4JIVYbf7MGUFxcLObT6fYWwSZB1F9ElXr2QL 4yBA== X-Gm-Message-State: ALQs6tBYCWcEDegzuOwadUMECHkmMgLubEr8gNyU23Bz65az01cnDimA Doz8NpOHPw6RxzpABMovYMhU4MQWdRqOv1MMp44EdQ== X-Google-Smtp-Source: AB8JxZo6KRsnWF0oF2RKpXRZQdAf7lOVZ5IeEK2aaBhIpbWmvf/bVMhWxlv5QcXGmaFemdxnk631IWeLvc1V4/gZNS0= X-Received: by 2002:a24:4e8d:: with SMTP id r135-v6mr4258287ita.143.1524894597218; Fri, 27 Apr 2018 22:49:57 -0700 (PDT) MIME-Version: 1.0 Received: by 2002:a02:4a93:0:0:0:0:0 with HTTP; Fri, 27 Apr 2018 22:49:56 -0700 (PDT) In-Reply-To: <5AE34CFA.7000207@grosbein.net> References: <5AE216DC.7010905@grosbein.net> <5AE33513.1000001@grosbein.net> <5AE34754.6040905@grosbein.net> <5AE34CFA.7000207@grosbein.net> From: Abdullah Tariq Date: Sat, 28 Apr 2018 10:49:56 +0500 Message-ID: Subject: Re: NETGRAPH- bridge vlans using netgraph help To: Eugene Grosbein Cc: "freebsd-net@freebsd.org" Content-Type: text/plain; charset="UTF-8" X-Content-Filtered-By: Mailman/MimeDel 2.1.25 X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 28 Apr 2018 05:49:58 -0000 So it is not possible to replicate behaviour of standard L2 switches using freebsd where we have different VLANs, access and trunk ports? On Fri, Apr 27, 2018 at 9:16 PM, Eugene Grosbein wrote: > 27.04.2018 22:57, Abdullah Tariq wrote: > > > And please do not top-post and reply to the list, not privately. > Thank you. > > > > sorry for that. > > > > > > They do but that's not what you need. You deal with untagged frames > on igb5, > > so do not create any vlan on top on igb5 but use it directly: > > ifconfig bridge10 create addm igb5 addm vlan3 up > > > > > > so if i need 2 ports with same vlan tags to communicate with each other > > i create 2 bridges > > ifconfig vlan2 create vlan 5 vlandev igb5 > > ifconfig vlan3 create vlan 5 vlandev igb6 > > ifconfig bridge10 create addm igb5 addm vlan3 up > > ifconfig bridge11 create addm igb6 addm vlan2 up > > > > is this the right way? > > No. If you have two ports that should carry untagged frames and form > single vlan > and this vlan has no other ports carrying tagged frames, then > this vlan effectively has *no* tag number, or better say, its tag number > does not matter. > > In that case, do not create any vlan interfaces for the vlan at all but > bridge ports directly: > > ifconfig bridge10 addm igb5 addm igb6 > > >