Re: can't add a /24 blackhole route with a /32 loopback
- In reply to: Alexander Chernikov : "Re: can't add a /24 blackhole route with a /32 loopback"
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Wed, 14 Jun 2023 09:46:53 UTC
Here is the ifconfig for loopbacks: ``` ifconfig lo1 lo1: flags=8049<UP,LOOPBACK,RUNNING,MULTICAST> metric 0 mtu 16384 options=680003<RXCSUM,TXCSUM,LINKSTATE,RXCSUM_IPV6,TXCSUM_IPV6> inet6 fe80::1%lo1 prefixlen 64 scopeid 0x9 inet6 XXXX:XXXX:1:1::1 prefixlen 128 inet 1.1.1.1 netmask 0xffffffff groups: lo nd6 options=21<PERFORMNUD,AUTO_LINKLOCAL> root@core0:~ # ifconfig lo0 lo0: flags=8049<UP,LOOPBACK,RUNNING,MULTICAST> metric 0 mtu 16384 options=680003<RXCSUM,TXCSUM,LINKSTATE,RXCSUM_IPV6,TXCSUM_IPV6> inet6 ::1 prefixlen 128 inet6 fe80::1%lo0 prefixlen 64 scopeid 0x3 groups: lo nd6 options=21<PERFORMNUD,AUTO_LINKLOCAL> ``` Hope this helps, Benoît ------- Original Message ------- On Wednesday, June 14th, 2023 at 11:42, Alexander Chernikov <melifaro@FreeBSD.org> wrote: > > On 14 Jun 2023, at 10:06, Benoit Chesneau benoitc@enki-multimedia.eu wrote: > > > > I forgot oto add the error message , sorry. > > > > When I try to set the theblackhole flag I get the following error: > > > > `route: writing to routing socket: Operation not supported change net 1.1.1.0 fib 0: Operation not supported` > > Interesting. Could you also share full ifconfig output or at least ifconfig for each of the loopbacks? > If the output contains something you’re not comfortable sharing in the ML, you could consider sending it directly to my email. > > > ------- Original Message ------- > > On Wednesday, June 14th, 2023 at 10:38, Benoit Chesneau benoitc@enki-multimedia.eu wrote: > > > > > Hi, > > > > > > Thanks for your answer. I'm using Freebsd 13.2 latest version: > > > > > > $ uname -srm > > > FreeBSD 13.2-RELEASE amd64 > > > > > > I edited the filtred result of the table since it has a full view: > > > > > > netstat -4rnW |grep -e "1.1.1" > > > 1.1.1.0/24 127.0.0.1 USB 14 16384 lo0 > > > 1.1.1.1 link#9 UHS 26 16384 lo1 > > > 1.1.1.2 10.3.1.1 UGH1 15 9000 vlan2212 > > > 1.1.1.2 10.3.1.1 UGHS 16 1500 vlan2212 > > > 1.1.1.2 10.3.1.1 UGHS 25 9000 vlan2212 > > > > > > Also I forgot to mention that the ethernet driver is MLX4EN(4): > > > > > > mlx4_core0@pci0:8:0:0: class=0x028000 rev=0x00 hdr=0x00 vendor=0x15b3 device=0x1007 subvendor=0x103c subdevice=0x22f3 > > > vendor = 'Mellanox Technologies' > > > device = 'MT27520 Family [ConnectX-3 Pro]' > > > class = network > > > Corrected = Advisory Non-Fatal Error > > > > > > Hope it helps, > > > > > > Benoît > > > ------- Original Message ------- > > > On Wednesday, June 14th, 2023 at 10:29, Alexander Chernikov melifaro@FreeBSD.org wrote: > > > > > > > > On 14 Jun 2023, at 07:05, Benoit Chesneau benoitc@enki-multimedia.eu wrote: > > > > > > > > > > Hi, > > > > > > > > > > When I setup a loopback to a /32 , I can add a /24 as a blackhole route anymore. I can only create a /24 attached to this looopback. Ie. > > > > > > > > Could you add a bit more context? > > > > What is the FreeBSD version (uname -srm)? > > > > What does 'route add 1.1.1.0/24 -blackhole’ show? > > > > Could you also share netstat -4rnW and ifconfig output (maybe privately)? > > > > > > > > > when `lo1` is set to `1.1.1.1/32` I cant create a blackhole route to `1.1.1.0/24` using the command : `route add 1.1.1.0/24 -blackhole` . Is there any reason for it? The idea is to be able to advertise the prefix `1.1.1.0/24` via BGP (bird) and use 1.1.1.1/32` as a loopback distributed to other nodes using OSPF. I can probably make the loopback a /24 used by bird but what would be the other way to do it? > > > > > > > > > > Benoît