Community discussions

MikroTik App
 
An5teifo
Frequent Visitor
Frequent Visitor
Topic Author
Posts: 89
Joined: Mon Dec 13, 2021 10:51 am
Location: Austria

CRS312 gets to 100 % CPU

Wed Dec 20, 2023 1:33 pm

Hello everyone,
I am using a CRS312-4C+8XG as my main switch.

It is connected to two Proxmox servers via LACP.
On my Proxmox servers I run an OPNsense appliance for firewalling and intervlan routing.

I recently stumbled accross a strange behaviour regarding switching traffic: If I run iperf3 within the same VLAN I get near wire speed (~ 9.5 Gbit).
If I do VLAN routing via OPNsense I get around 5 Gbit but after some time the switch CPU gets to 100 % mostly at bridging and networking.
On CRS312 everything is HW offloaded.

The current config would be:
# 2023-12-20 12:27:50 by RouterOS 7.13
# software id = BD85-SIEN
#
# model = CRS312-4C+8XG
# serial number = abc123
/interface bridge
add admin-mac=74:4D:28:B7:7C:A4 auto-mac=no fast-forward=no ingress-filtering=no name=bridge port-cost-mode=short priority=0x2000 vlan-filtering=yes
/interface ethernet
set [ find default-name=ether1 ] l2mtu=1592 name=Desktop rx-flow-control=auto tx-flow-control=auto
set [ find default-name=ether7 ] l2mtu=1592 name="Mikrotik R1" rx-flow-control=auto tx-flow-control=auto
set [ find default-name=combo3 ] l2mtu=1592 name=ccr2004
set [ find default-name=combo1 ] l2mtu=1592 rx-flow-control=auto tx-flow-control=auto
set [ find default-name=combo2 ] l2mtu=1592 rx-flow-control=auto tx-flow-control=auto
set [ find default-name=combo4 ] l2mtu=1592 name=css326
set [ find default-name=ether2 ] l2mtu=1592 rx-flow-control=auto tx-flow-control=auto
set [ find default-name=ether3 ] l2mtu=1592 rx-flow-control=auto tx-flow-control=auto
set [ find default-name=ether4 ] l2mtu=1592 rx-flow-control=auto tx-flow-control=auto
set [ find default-name=ether5 ] l2mtu=1592 rx-flow-control=auto tx-flow-control=auto
set [ find default-name=ether6 ] l2mtu=1592 rx-flow-control=auto tx-flow-control=auto
set [ find default-name=ether8 ] l2mtu=1592 rx-flow-control=auto tx-flow-control=auto
set [ find default-name=ether9 ] l2mtu=1592 rx-flow-control=auto tx-flow-control=auto
/interface vlan
add interface=bridge name=vlan10 vlan-id=10
/interface bonding
add mode=802.3ad name=Proxmox1 slaves=ether5,ether6 transmit-hash-policy=layer-2-and-3
add mode=802.3ad name=Proxmox2 slaves=combo1,combo2 transmit-hash-policy=layer-2-and-3
/interface ethernet switch
set 0 l3-hw-offloading=yes
/interface ethernet switch port
set 1 l3-hw-offloading=no
set 2 l3-hw-offloading=no
set 3 l3-hw-offloading=no
set 4 l3-hw-offloading=no
set 5 l3-hw-offloading=no
set 6 l3-hw-offloading=no
set 7 l3-hw-offloading=no
set 8 l3-hw-offloading=no
set 9 l3-hw-offloading=no
set 10 l3-hw-offloading=no
set 11 l3-hw-offloading=no
set 12 l3-hw-offloading=no
/interface list
add name=WAN
add name=LAN
/interface lte apn
set [ find default=yes ] ip-type=ipv4 use-network-apn=no
/interface wireless security-profiles
set [ find default=yes ] supplicant-identity=MikroTik
/ip hotspot profile
add hotspot-address=192.168.10.248 html-directory=flash/hotspot name=hsprof1
/port
set 0 name=serial0
/routing ospf instance
add disabled=no name=default-v2
/routing ospf area
add disabled=yes instance=default-v2 name=backbone-v2
/caps-man manager
set enabled=yes upgrade-policy=suggest-same-version
/interface bridge port
add bridge=bridge interface=Mathias-Desktop internal-path-cost=10 path-cost=10 pvid=10
add bridge=bridge interface=ccr2004 internal-path-cost=10 path-cost=10
add bridge=bridge interface=css326 internal-path-cost=10 path-cost=10
add bridge=bridge frame-types=admit-only-vlan-tagged interface=Proxmox1 internal-path-cost=10 path-cost=10
add bridge=bridge frame-types=admit-only-vlan-tagged interface=Proxmox2 internal-path-cost=10 path-cost=10
add bridge=bridge interface=vlan10 pvid=10
add bridge=bridge interface="Mikrotik R1" internal-path-cost=10 path-cost=10
/interface ethernet switch l3hw-settings
set ipv6-hw=yes
/ip neighbor discovery-settings
set discover-interface-list=none
/ip settings
set max-neighbor-entries=8192
/ipv6 settings
set max-neighbor-entries=8192
/interface bridge vlan
add bridge=bridge tagged=bridge,vlan10,Proxmox1,Proxmox2,ccr2004,css326 vlan-ids=10
add bridge=bridge tagged="bridge,Proxmox1,Proxmox2,ccr2004,css326,Mikrotik R1" vlan-ids=11
add bridge=bridge tagged="bridge,Proxmox1,Proxmox2,ccr2004,css326,Mikrotik R1" vlan-ids=20
add bridge=bridge tagged="bridge,Proxmox1,Proxmox2,ccr2004,css326,Mikrotik R1" vlan-ids=30
add bridge=bridge tagged="bridge,Proxmox1,Proxmox2,ccr2004,css326,Mikrotik R1" vlan-ids=31
add bridge=bridge tagged="bridge,Proxmox1,Proxmox2,ccr2004,css326,Mikrotik R1" vlan-ids=90
add bridge=bridge tagged="bridge,Proxmox1,Proxmox2,ccr2004,css326,Mikrotik R1" vlan-ids=500
add bridge=bridge tagged="bridge,Proxmox1,Proxmox2,ccr2004,css326,Mikrotik R1" vlan-ids=450
/interface list member
add interface=ether9 list=LAN
add interface=Mathias-Desktop list=LAN
add interface=ether2 list=LAN
add interface=ether3 list=LAN
add interface=ether4 list=LAN
add interface=ether5 list=LAN
add interface=ether6 list=LAN
add interface="Mikrotik R1" list=LAN
add interface=ether8 list=LAN
add interface=combo1 list=LAN
add interface=combo2 list=LAN
add interface=ccr2004 list=LAN
add interface=css326 list=LAN
/interface ovpn-server server
set auth=sha1,md5
/ip address
add address=192.168.10.248/24 interface=vlan10 network=192.168.10.0
/ip cloud
set update-time=no
/ip dhcp-client
add comment=defconf disabled=yes interface=bridge
/ip dns
set servers=192.168.10.103,192.168.10.104,192.168.101.170
/ip hotspot user
add name=user1
/ip route
add disabled=no dst-address=0.0.0.0/0 gateway=192.168.10.254
/ip service
set telnet disabled=yes
set ftp disabled=yes
set www disabled=yes
set www-ssl tls-version=only-1.2
set api address=192.168.20.50/32
set api-ssl disabled=yes
/ip ssh
set host-key-size=4096 strong-crypto=yes
/ipv6 nd
set [ find default=yes ] advertise-dns=no interface=vlan10
add advertise-dns=no
/system clock
set time-zone-name=Europe/Vienna
/system identity
set name=Switch-CRS312
/system note
set show-at-login=no
/system ntp client
set enabled=yes
/system ntp client servers
add address=pool.ntp.org
/system routerboard settings
set auto-upgrade=yes boot-os=router-os
/system scheduler
add interval=1d name="schedule update" on-event="/system package update\r\
    \ncheck-for-updates once\r\
    \n:delay 3s;\r\
    \n:if ( [get status] = \"New version is available\") do={ install }" policy=ftp,reboot,read,write,policy,test,password,sniff,sensitive,romon start-date=2022-04-18 start-time=03:00:00
/tool bandwidth-server
set authenticate=no

For comparsion I did also run some tests on my CCR2004 router which is in general in front of my OPNsense firewall.
With that routing config CRS312 is not getting to 100 % but CCR2004 does (which is kinda expected).


Anyone got ideas why my switch is having troubles with handling L3 traffic which is not being routed by itself?
 
User avatar
raimondsp
MikroTik Support
MikroTik Support
Posts: 287
Joined: Mon Apr 27, 2020 10:14 am

Re: CRS312 gets to 100 % CPU

Fri Dec 22, 2023 12:06 pm

Hi, why have you disabled l3-hw-offloading on all switch ports?
/interface ethernet switch port
set 1 l3-hw-offloading=no
set 2 l3-hw-offloading=no
set 3 l3-hw-offloading=no
set 4 l3-hw-offloading=no
set 5 l3-hw-offloading=no
set 6 l3-hw-offloading=no
set 7 l3-hw-offloading=no
set 8 l3-hw-offloading=no
set 9 l3-hw-offloading=no
set 10 l3-hw-offloading=no
set 11 l3-hw-offloading=no
set 12 l3-hw-offloading=no
 
An5teifo
Frequent Visitor
Frequent Visitor
Topic Author
Posts: 89
Joined: Mon Dec 13, 2021 10:51 am
Location: Austria

Re: CRS312 gets to 100 % CPU

Fri Dec 22, 2023 12:10 pm

I disabled it as I only want to do L2 traffic but I already reenabled it - although result is the same nevertheless if L3 hw offloading is on or off.
 
User avatar
raimondsp
MikroTik Support
MikroTik Support
Posts: 287
Joined: Mon Apr 27, 2020 10:14 am

Re: CRS312 gets to 100 % CPU

Fri Dec 22, 2023 12:57 pm

Here is the problem:
/interface bridge vlan
add bridge=bridge tagged=bridge,vlan10,Proxmox1,Proxmox2,ccr2004,css326 vlan-ids=10

/interface vlan
add interface=bridge name=vlan10 vlan-id=10
vlan10 is set on bridge (correct), but the bridge has vlan10 as a VLAN member (incorrect), resulting in a dependency loop. IIRC, we added a sanity check for such misconfiguration, but it might not be released it.

Solution: remove vlan10 from /in/br/vlan members:
/interface bridge vlan
add bridge=bridge tagged=bridge,Proxmox1,Proxmox2,ccr2004,css326 vlan-ids=10

/interface vlan
add interface=bridge name=vlan10 vlan-id=10

P.S. If you are using CRS312 as an L2 switch only, then disable l3-hw-offloading on the switch level to save hardware resources.
/interface/ethernet/switch/set [find] l3-hw-offloading=no
 
An5teifo
Frequent Visitor
Frequent Visitor
Topic Author
Posts: 89
Joined: Mon Dec 13, 2021 10:51 am
Location: Austria

Re: CRS312 gets to 100 % CPU

Fri Dec 22, 2023 1:14 pm

Thanks for the info - I have done that but the CPU goes up to 100 % CPU immediately:
[mathias@Switch-CRS312] > /tool/profile
Columns: NAME, USAGE
NAME          USAGE
ethernet      5%
console       1%
ssh           0.5%
networking    49.5%
winbox        0%
management    1.5%
routing       0%
profiling     0%
bridging      36.5%
unclassified  6%
total         100%
Some additional stuff from the ticket I raised:

The workflow from my perspective:

1) Mathias-Desktop which is a physical machine
2) CRS312
3) LACP to Proxmox1 server (physical) which hosts OPNsense
4) OPNsense routes the traffic from VLAN10 to VLAN20
5) I am not sure if a standard linux bridge would forward the traffic back to CRS312 or not. Assuming it would then VLAN20 traffic would go back to CRS312 and would go back to Proxmox1 for the VM in VLAN20.
6) Routed traffic hits the VM running `iperf3 -s`
7) Traffic returns to Mathias-Desktop


When running iperf3 the first couple of seconds the switch is having a normal CPU load but then spikes to 100 % and iperf3 traffic gets slower:
First iperf3 block:
[ ID] Interval           Transfer     Bandwidth
[  4]   0.00-1.00   sec   116 MBytes   975 Mbits/sec
[  6]   0.00-1.00   sec  66.8 MBytes   560 Mbits/sec
[  8]   0.00-1.00   sec  44.1 MBytes   370 Mbits/sec
[ 10]   0.00-1.00   sec  69.9 MBytes   586 Mbits/sec
[ 12]   0.00-1.00   sec  50.5 MBytes   424 Mbits/sec
[ 14]   0.00-1.00   sec  64.1 MBytes   538 Mbits/sec
[ 16]   0.00-1.00   sec  65.4 MBytes   548 Mbits/sec
[ 18]   0.00-1.00   sec  57.5 MBytes   482 Mbits/sec
[ 20]   0.00-1.00   sec  64.1 MBytes   538 Mbits/sec
[ 22]   0.00-1.00   sec  98.2 MBytes   824 Mbits/sec
[SUM]   0.00-1.00   sec   697 MBytes  5.84 Gbits/sec
- - - - - - - - - - - - - - - - - - - - - - - - -

Last iperf3 block before stopping the process:
- - - - - - - - - - - - - - - - - - - - - - - - -
[  4]  25.00-25.87  sec  89.8 MBytes   870 Mbits/sec
[  6]  25.00-25.87  sec  41.5 MBytes   402 Mbits/sec
[  8]  25.00-25.87  sec  34.0 MBytes   330 Mbits/sec
[ 10]  25.00-25.87  sec  25.1 MBytes   243 Mbits/sec
[ 12]  25.00-25.87  sec  30.0 MBytes   291 Mbits/sec
[ 14]  25.00-25.87  sec  25.8 MBytes   250 Mbits/sec
[ 16]  25.00-25.87  sec  42.0 MBytes   407 Mbits/sec
[ 18]  25.00-25.87  sec  25.0 MBytes   242 Mbits/sec
[ 20]  25.00-25.87  sec  20.9 MBytes   202 Mbits/sec
[ 22]  25.00-25.87  sec  49.5 MBytes   480 Mbits/sec
[SUM]  25.00-25.87  sec   384 MBytes  3.72 Gbits/sec
- - - - - - - - - - - - - - - - - - - - - - - - -
 
User avatar
raimondsp
MikroTik Support
MikroTik Support
Posts: 287
Joined: Mon Apr 27, 2020 10:14 am

Re: CRS312 gets to 100 % CPU

Fri Dec 22, 2023 1:32 pm

Sorry, I forgot to mention that you need to remove vlan10 from /interface/bridge/port too.

If that will not help, see if all bridge ports have H flag in /interface/bridge/port/print
 
An5teifo
Frequent Visitor
Frequent Visitor
Topic Author
Posts: 89
Joined: Mon Dec 13, 2021 10:51 am
Location: Austria

Re: CRS312 gets to 100 % CPU

Fri Dec 22, 2023 1:34 pm

I have already removed VLAN10 from the port configuration.
I had initally added it due to the message the VLAN10 is not a port member of the bridge which was resolved by your last information.

In general all interfaces are hardware offloaded:
[mathias@Switch-CRS312] > interface/bridge/port/print
Flags: I - INACTIVE; H - HW-OFFLOAD
Columns: INTERFACE, BRIDGE, HW, PVID, PRIORITY, PATH-COST, INTERNAL-PATH-COST, HORIZON
#    INTERFACE        BRIDGE  HW   PVID  PRIORITY  PATH-COST  INTERNAL-PATH-COST  HORIZON
0  H Mathias-Desktop  bridge  yes    10  0x80             10                  10  none
1  H ccr2004          bridge  yes     1  0x80             10                  10  none
2  H css326           bridge  yes     1  0x80             10                  10  none
3  H Proxmox1         bridge  yes     1  0x80             10                  10  none
4  H Proxmox2         bridge  yes     1  0x80             10                  10  none
5 IH Mikrotik R1      bridge  yes     1  0x80             10                  10  none
 
User avatar
raimondsp
MikroTik Support
MikroTik Support
Posts: 287
Joined: Mon Apr 27, 2020 10:14 am

Re: CRS312 gets to 100 % CPU

Fri Dec 22, 2023 2:39 pm

5) I am not sure if a standard linux bridge would forward the traffic back to CRS312 or not. Assuming it would then VLAN20 traffic would go back to CRS312 and would go back to Proxmox1 for the VM in VLAN20.
If that hadn't been the case, then for CRS312 both test cases (within a single vlan and inter-vlan) wouldn't matter, as it would see VLAN10 traffic only. So I guess the VLAN20 traffic gets forwarded via CRS312.

I'm afraid that "7) Traffic returns to Mathias-Desktop" is not that simple. If the reply is sent via VLAN20, then it first must be sent to OPNsense (via CRS312 again?) for routing back to VLAN10, only then it returns to Mathias-Desktop via CRS312.

I suppose the packet flow should be the following:
                    UNTAGGED                  VLAN10
Mathias-Desktop ----------------> CRS312 ----------------> Proxmox1  // route to VLAN20
                                              VLAN20
                                  CRS312 <---------------- Proxmox1
                                              VLAN20
                                  CRS312 ----------------> Proxmox1  // reaches VM running "iperf -s" here
                                              VLAN20
                                  CRS312 <---------------- Proxmox1  // iperf reply
                                              VLAN20
                                  CRS312 ----------------> Proxmox1  // route to VLAN10
                    UNTAGGED                  VLAN10
Mathias-Desktop <---------------- CRS312 <---------------- Proxmox1

Since CRS312 does not do any routing in this case but only L2 forwarding (bridging), the reason for packets entering the CPU could be a problem in MAC learning. You can run Packet Sniffer on CRS312 to see which packets are entering the CPU, then check if their destination MAC addresses are inside /interface/bridge/host/print (matching VLAN ID). If the destination MAC address is not in the hardware FDB table, the packets get redirected to the CPU and then flooded to all bridge ports (within the VLAN).

For example, if the iperf reply does not traverse CRS312 within VLAN20 but immediately gets routed to VLAN10, CRS312 never learns VM's VLAN20 MAC address as the former does not see any packets coming from the latter (within VLAN20).
 
User avatar
raimondsp
MikroTik Support
MikroTik Support
Posts: 287
Joined: Mon Apr 27, 2020 10:14 am

Re: CRS312 gets to 100 % CPU

Fri Dec 22, 2023 2:51 pm

I forgot to mention: if the traffic goes back and forth between CRS312 and Proxmox1, then it halves the bandwidth. It does not explain 100% CPU usage, though.
 
An5teifo
Frequent Visitor
Frequent Visitor
Topic Author
Posts: 89
Joined: Mon Dec 13, 2021 10:51 am
Location: Austria

Re: CRS312 gets to 100 % CPU

Fri Dec 22, 2023 2:52 pm

Thanks for the marvelous packetflow drawing - this is exactly how I imagine it.
I was able to check CRS312 hosts database on the bridge interface and both Mathias-Desktop as well as the VMs MAC address are known by the bridge.
Unfortunately sniffing packages do not work as the bridge is hw-offloaded and therefore package sniffing is not woring:

Packets that are processed with hardware offloading enabled bridge will not be visible (flooded packets like unknown unicast, broadcast, and multicast traffic might be visible).
https://help.mikrotik.com/docs/display/ ... et+Sniffer
 
An5teifo
Frequent Visitor
Frequent Visitor
Topic Author
Posts: 89
Joined: Mon Dec 13, 2021 10:51 am
Location: Austria

Re: CRS312 gets to 100 % CPU

Fri Dec 22, 2023 4:02 pm

With regards to 1/2 bandwith: Initially I do get 6.5 Gbit sometimes.
 
User avatar
raimondsp
MikroTik Support
MikroTik Support
Posts: 287
Joined: Mon Apr 27, 2020 10:14 am

Re: CRS312 gets to 100 % CPU

Fri Dec 22, 2023 4:41 pm

Hardware-forwarded packets are not visible by Packet Sniffer - that's correct. However, if you get 100% CPU load, then I suppose the CPU processes some packets, which are visible by Sniffer.
Another option is to disable L2 HW offloading ("/interface/bridge/port set [find] hw=no") and send one packet through the network (e.g., ping) - to identify how many times it goes through CRS312, src/dst MAC addresses and VLAN ID.
 
An5teifo
Frequent Visitor
Frequent Visitor
Topic Author
Posts: 89
Joined: Mon Dec 13, 2021 10:51 am
Location: Austria

Re: CRS312 gets to 100 % CPU

Sat Dec 23, 2023 10:37 am

The switch just discovers some broadcast packages when running at 100 %:
[mathias@Switch-CRS312] /tool/sniffer> packet/print
Columns: TIME, INTERFACE, SRC-ADDRESS, DST-ADDRESS, IP-PROTOCOL, SIZE, CPU
#  TIME    INTERFACE        SRC-ADDRESS         DST-ADDRESS           IP-PROTOCOL  SIZE  CPU
0  14.692  Mathias-Desktop  192.168.10.12:1837  239.255.255.250:1900  udp           162    0
1  14.692  bridge           192.168.10.12:1837  239.255.255.250:1900  udp           166    0
2  14.692  vlan10           192.168.10.12:1837  239.255.255.250:1900  udp           162    0
3  14.692  Mathias-Desktop  192.168.10.12:1837  239.255.255.250:1900  udp           162    0
4  14.692  bridge           192.168.10.12:1837  239.255.255.250:1900  udp           166    0
5  14.692  vlan10           192.168.10.12:1837  239.255.255.250:1900  udp           162    0
6  30.839  Mathias-Desktop                                                           60    0
7  30.839  bridge                                                                    64    0
8  30.839  vlan10                                                                    60    0

Regarding packet flow:
I disabled hw offloading on L2 as you have mentioned and would see following flow:
Columns: TIME, INTERFACE, SRC-ADDRESS, DST-ADDRESS, IP-PROTOCOL, SIZE, CPU
 #  TIME   INTERFACE        SRC-ADDRESS    DST-ADDRESS    IP-PROTOCOL  SIZE  CPU
 0  1.74   Mathias-Desktop  192.168.10.12  192.168.20.97  icmp           74    0
 1  1.74   Proxmox1         192.168.10.12  192.168.20.97  icmp           78    0
 2  1.74   ether6           192.168.10.12  192.168.20.97  icmp           78    0
 3  1.741  ether5           192.168.20.97  192.168.10.12  icmp           78    0
 4  1.741  Proxmox1         192.168.20.97  192.168.10.12  icmp           78    0
 5  1.741  Mathias-Desktop  192.168.20.97  192.168.10.12  icmp           74    0
 6  2.753  ether5           192.168.20.97  192.168.10.12  icmp           78    0
 7  2.753  Proxmox1         192.168.20.97  192.168.10.12  icmp           78    0
 8  2.753  Mathias-Desktop  192.168.20.97  192.168.10.12  icmp           74    0
 9  3.76   Mathias-Desktop  192.168.10.12  192.168.20.97  icmp           74    0
10  3.76   Proxmox1         192.168.10.12  192.168.20.97  icmp           78    0
11  3.76   ether6           192.168.10.12  192.168.20.97  icmp           78    0
12  3.761  ether5           192.168.20.97  192.168.10.12  icmp           78    0
13  3.761  Proxmox1         192.168.20.97  192.168.10.12  icmp           78    0
14  3.761  Mathias-Desktop  192.168.20.97  192.168.10.12  icmp           74    0
15  4.763  Mathias-Desktop  192.168.10.12  192.168.20.97  icmp           74    0
16  4.763  Proxmox1         192.168.10.12  192.168.20.97  icmp           78    0
17  4.763  ether6           192.168.10.12  192.168.20.97  icmp           78    0
18  4.764  ether5           192.168.20.97  192.168.10.12  icmp           78    0
19  4.764  Proxmox1         192.168.20.97  192.168.10.12  icmp           78    0
20  4.764  Mathias-Desktop  192.168.20.97  192.168.10.12  icmp           74    0
So what I understand my package hits the switch and on the switch the LACP bond which then decided if ether5 or 6 should be used.
Settings I have used:
[mathias@Switch-CRS312] /tool/sniffer> print
                     only-headers: no
                     memory-limit: 100KiB
                    memory-scroll: yes
                        file-name:
                       file-limit: 1000KiB
                streaming-enabled: no
                 streaming-server: 0.0.0.0:37008
                    filter-stream: no
                 filter-interface: all
               filter-mac-address:
           filter-src-mac-address:
           filter-dst-mac-address:
              filter-mac-protocol:
                filter-ip-address:
            filter-src-ip-address: 192.168.10.12/32,192.168.20.97/32
            filter-dst-ip-address:
              filter-ipv6-address:
          filter-src-ipv6-address:
          filter-dst-ipv6-address:
               filter-ip-protocol: icmp
                      filter-port:
                  filter-src-port:
                  filter-dst-port:
                      filter-vlan:
                       filter-cpu:
                      filter-size:
                 filter-direction: any
  filter-operator-between-entries: or
                          running: no
 
An5teifo
Frequent Visitor
Frequent Visitor
Topic Author
Posts: 89
Joined: Mon Dec 13, 2021 10:51 am
Location: Austria

Re: CRS312 gets to 100 % CPU

Sat Jan 06, 2024 12:26 pm

Another interessting fact: Even if I tell iperf3 to only use 1 thread the switch CPU goes up to 100 %
PS E:\Users\mmuehlbacher\Downloads\iperf-3.1.3-win64> .\iperf3.exe -P 1 -c db1.hks.lan -t 60
Connecting to host db1.hks.lan, port 5201
[  4] local 192.168.10.12 port 63031 connected to 192.168.20.97 port 5201
[ ID] Interval           Transfer     Bandwidth
[  4]   0.00-1.00   sec   137 MBytes  1.15 Gbits/sec
[  4]   1.00-2.00   sec   134 MBytes  1.12 Gbits/sec
[  4]   2.00-3.00   sec   158 MBytes  1.32 Gbits/sec
[  4]   3.00-4.00   sec   137 MBytes  1.15 Gbits/sec
[  4]   4.00-5.00   sec   132 MBytes  1.10 Gbits/sec
[  4]   5.00-6.00   sec   136 MBytes  1.15 Gbits/sec
[  4]   6.00-7.00   sec   141 MBytes  1.18 Gbits/sec
[  4]   7.00-8.00   sec   148 MBytes  1.24 Gbits/sec
[  4]   8.00-9.00   sec   138 MBytes  1.15 Gbits/sec
[  4]   9.00-10.00  sec   147 MBytes  1.23 Gbits/sec
[  4]  10.00-10.67  sec  88.4 MBytes  1.11 Gbits/sec
[mathias@Switch-CRS312] > /tool/profile
Columns: NAME, USAGE
NAME          USAGE
ethernet      3.5%
console       1.5%
ssh           0%
networking    55.5%
management    2%
profiling     2.5%
bridging      31.5%
unclassified  3.5%
total         100%
 
An5teifo
Frequent Visitor
Frequent Visitor
Topic Author
Posts: 89
Joined: Mon Dec 13, 2021 10:51 am
Location: Austria

Re: CRS312 gets to 100 % CPU

Sun Jan 07, 2024 12:18 am

I think I finally found the trouble maker:
As I use two OPNsense in HA configuration they syncronise each and every connection state so if a OPNsense goes down the other can take over immediately without any downtime.

The setting is called "Synchronize Peer IP" and its default value is directed multicast (224.0.0.240).
In my opinion if I run iperf3 it generates a lot of multicasts which I can see at packet sniffer.

Insted of using multicast I set the proper IP address of the corresponding OPNsense VM. Now I can run iperf3 without having 100 % CPU.

I am not sure if directed multicast is a L2 or L3 topic.

Who is online

Users browsing this forum: Bing [Bot], Google [Bot], kleshki, RobertsN and 75 guests