Date: Fri, 29 Apr 2022 07:53:44 +0000 From: Benoit Chesneau <benoitc@enki-multimedia.eu> To: Benoit Chesneau <benoitc@enki-multimedia.eu> Cc: "freebsd-net@FreeBSD.org" <freebsd-net@FreeBSD.org> Subject: Re: issue with ng_vlan nomatch connected to the bridge Message-ID: <j44mtirKHBUgP4TydIcaleS1-QIIvoQIwsfD2Zt3hQM6Lx9VG0MhvRT3UmKKqxs7mGsPDizYkGkxx4slcEDFfPTvtl-QA9wAdXcz34FpmtQ=@enki-multimedia.eu> In-Reply-To: <zMe2JfLExuczF03sEZkLmiCi1GggVG_ijqz3VacZOGKLKxh_HpD85kbeGou42NruF2jMvSg1mGuLJc84YGGSn65jhgN4TYc7exW9ozI1aVE=@enki-multimedia.eu> References: <WCMWeElRlitmBpR68L1E5-wTHGnQNMUx6ugOY-UW9qx3arF63kTS7g2P6Rzxyq1BiLZLu9DRbKylaHSvi9hBWjN-fuT35KD_KyXwq7Sx2BI=@enki-multimedia.eu> <zMe2JfLExuczF03sEZkLmiCi1GggVG_ijqz3VacZOGKLKxh_HpD85kbeGou42NruF2jMvSg1mGuLJc84YGGSn65jhgN4TYc7exW9ozI1aVE=@enki-multimedia.eu>
next in thread | previous in thread | raw e-mail | index | archive | help
[-- Attachment #1 --]
> To quickly test, I created an interface added to the bridge that get its IP from DHCP: The IP is correctly given by the DHCP server, but I can't ping from the same server (the router with the DHCP server) to this device.
>
> ```
> # ngctl mkpeer public: eiface link2 ether
> # dhclient ngeth1
> DHCPDISCOVER on ngeth1 to 255.255.255.255 port 67 interval 7
> DHCPOFFER from 192.168.1.1
> DHCPREQUEST on ngeth1 to 255.255.255.255 port 67
> DHCPACK from 192.168.1.1bound to 192.168.1.37 -- renewal in 300 seconds.
> # ifconfig ngeth1
> ngeth1: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500
> options=28<VLAN_MTU,JUMBO_MTU>
> ether 58:9c:fc:10:c6:73
> inet 192.168.1.60 netmask 0xffffff00 broadcast 192.168.1.255
> inet 192.168.1.37 netmask 0xffffff00 broadcast 192.168.1.255
> inet6 fe80::5a9c:fcff:fe10:c673%ngeth1 prefixlen 64 scopeid 0xb
> media: Ethernet autoselect (1000baseT <full-duplex>)
> status: active nd6 options=21<PERFORMNUD,AUTO_LINKLOCAL>
> ```
correction, I can ping this IP, only link added to the bridge using vm is not pingagble:
```
# ngctl show public:
Name: public Type: bridge ID: 0000000d Num hooks: 3
Local hook Peer name Peer type Peer ID Peer hook
---------- --------- --------- ------- ---------
link3 <unnamed> socket 0000001c vmlink
link2 ngeth1 eiface 00000016 ether link0 vlan0 vlan 0000000a nomatch
>
```
the vm-bhyve log:
```
Apr 29 09:49:08: [bhyve options: -c 1 -m 2G -Hwl bootrom,/usr/local/share/uefi-firmware/BHYVE_UEFI_CSM.fd -U ac3dafab-bedb-11ec-b24d-1402ec690a80 -u]
Apr 29 09:49:08: [bhyve devices: -s 0,hostbridge -s 31,lpc -s 4:0,virtio-blk,/vms/utm/disk0.img -s 5:0,virtio-net,netgraph,path=bgpnet:,peerhook=link3,mac=58:9c:fc:02:3a:be -s 5:1,virtio-net,netgraph,path=public:,peerhook=link3,mac=58:9c:fc:00:6e:5a]Apr 29 09:49:08: [bhyve console: -l com1,stdio]Apr 29 09:49:08: [bhyve devices: -s 0,hostbridge -s 31,lpc -s 4:0,virtio-blk,/vms/utm/disk0.img -s 5:0,virtio-net,netgraph,path=bgpnet:,peerhook=link3,mac=58:9c:fc:02:3a:be -s 5:1,virtio-net,netgraph,path=public:,peerhook=link3,mac=58:9c:fc:00:6e:5a]Apr 29 09:49:08: [bhyve devices: -s 0,hostbridge -s 31,lpc -s 4:0,virtio-blk,/vms/utm/disk0.img -s 5:0,virtio-net,netgraph,path=bgpnet:,peerhook=link3,mac=58:9c:fc:02:3a:be -s 5:1,virtio-net,netgraph,path=public:,peerhook=link3,mac=58:9c:fc:00:6e:5a]
```
[-- Attachment #2 --]
<div style="font-family: arial; font-size: 14px;"><br></div><div class="protonmail_quote"><br>
<blockquote class="protonmail_quote" type="cite">
<div style="font-family: arial; font-size: 14px;">To quickly test, I created an interface added to the bridge that get its IP from DHCP: The IP is correctly given by the DHCP server, but I can't ping from the same server (the router with the DHCP server) to this device. </div><div style="font-family: arial; font-size: 14px;"><br></div><div style="font-family: arial; font-size: 14px;"><br></div><div style="font-family: arial; font-size: 14px;">```</div><div style="font-family: arial; font-size: 14px;"><span># ngctl mkpeer public: eiface link2 ether</span><div># dhclient ngeth1</div><div><span>DHCPDISCOVER on ngeth1 to 255.255.255.255 port 67 interval 7</span></div><div><span>DHCPOFFER from 192.168.1.1</span></div><div><span>DHCPREQUEST on ngeth1 to 255.255.255.255 port 67</span></div><div><span>DHCPACK from 192.168.1.1</span></div><span>bound to 192.168.1.37 -- renewal in 300 seconds.</span><br></div><div style="font-family: arial; font-size: 14px;"><span># ifconfig ngeth1</span><div><span>ngeth1: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500</span></div><div><span> options=28<VLAN_MTU,JUMBO_MTU></span></div><div><span> ether 58:9c:fc:10:c6:73</span></div><div><span> inet 192.168.1.60 netmask 0xffffff00 broadcast 192.168.1.255</span></div><div><span> inet 192.168.1.37 netmask 0xffffff00 broadcast 192.168.1.255</span></div><div><span> inet6 fe80::5a9c:fcff:fe10:c673%ngeth1 prefixlen 64 scopeid 0xb</span></div><div><span> media: Ethernet autoselect (1000baseT <full-duplex>)</span></div><div><span> status: active</span></div><span> nd6 options=21<PERFORMNUD,AUTO_LINKLOCAL></span></div><div style="font-family: arial; font-size: 14px;">```</div></blockquote><div style="font-family: arial; font-size: 14px;"><br></div><div style="font-family: arial; font-size: 14px;">correction, I can ping this IP, only link added to the bridge using vm is not pingagble:</div><div style="font-family: arial; font-size: 14px;"><br></div><div style="font-family: arial; font-size: 14px;">```</div><div style="font-family: arial; font-size: 14px;"><span># ngctl show public:</span><div><span> Name: public Type: bridge ID: 0000000d Num hooks: 3</span></div><div><span> Local hook Peer name Peer type Peer ID Peer hook</span></div><div><span> ---------- --------- --------- ------- ---------</span></div><div><span> link3 <unnamed> socket 0000001c vmlink</span></div><div><span> link2 ngeth1 eiface 00000016 ether</span></div><span> link0 vlan0 vlan 0000000a nomatch</span><br></div><blockquote class="protonmail_quote" type="cite">
</blockquote>```</div><div class="protonmail_quote"><br></div><div>the vm-bhyve log:</div><div><br></div><div>```</div><div><span></span><span></span><span>Apr 29 09:49:08: [bhyve options: -c 1 -m 2G -Hwl bootrom,/usr/local/share/uefi-firmware/BHYVE_UEFI_CSM.fd -U ac3dafab-bedb-11ec-b24d-1402ec690a80 -u]</span><div><span>Apr 29 09:49:08: [bhyve devices: -s 0,hostbridge -s 31,lpc -s 4:0,virtio-blk,/vms/utm/disk0.img -s 5:0,virtio-net,netgraph,path=bgpnet:,peerhook=link3,mac=58:9c:fc:02:3a:be -s 5:1,virtio-net,netgraph,path=public:,peerhook=link3,mac=58:9c:fc:00:6e:5a]</span></div><span>Apr 29 09:49:08: [bhyve console: -l com1,stdio]</span><span>Apr 29 09:49:08: [bhyve devices: -s 0,hostbridge -s 31,lpc -s 4:0,virtio-blk,/vms/utm/disk0.img -s 5:0,virtio-net,netgraph,path=bgpnet:,peerhook=link3,mac=58:9c:fc:02:3a:be -s 5:1,virtio-net,netgraph,path=public:,peerhook=link3,mac=58:9c:fc:00:6e:5a]</span><span>Apr 29 09:49:08: [bhyve devices: -s 0,hostbridge -s 31,lpc -s 4:0,virtio-blk,/vms/utm/disk0.img -s 5:0,virtio-net,netgraph,path=bgpnet:,peerhook=link3,mac=58:9c:fc:02:3a:be -s 5:1,virtio-net,netgraph,path=public:,peerhook=link3,mac=58:9c:fc:00:6e:5a]</span><br></div><div>```</div><div><br></div>
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?j44mtirKHBUgP4TydIcaleS1-QIIvoQIwsfD2Zt3hQM6Lx9VG0MhvRT3UmKKqxs7mGsPDizYkGkxx4slcEDFfPTvtl-QA9wAdXcz34FpmtQ=>
