Some unwanted packets are created automatically after running p4 in the mininet

Hello,

when i p4run to start the mininet with p4 switch and tcpreplay to evaluate my p4 function, there are a;ways some unwanted packets from unknown source like below picture in s1-eth2-out and s1-eth1-out.

There is simple topology with one switch and 2 hosts. And if i tcpdump to monitor the interface s1-eth1 and s1-eth2, there are no unwanted packets in the pcap.file.
I have no idea why there are they. The IPv6 is already disable.
Have you any idea about this? Thank you!

I see commands like these in some of the p4lang/tutorials files, but I have not verified whether they are actually run when you run the tutorials, or not. In a mininet environment, there is a separate Linux network namespace created for each emulated switch, and I have not verified whether these commands need to be run in each namespace, and if so, whether they actually are.

$ grep -r disable_ipv6
Binary file .git/index matches
utils/p4_mininet.py:        self.cmd("sysctl -w net.ipv6.conf.all.disable_ipv6=1")
utils/p4_mininet.py:        self.cmd("sysctl -w net.ipv6.conf.default.disable_ipv6=1")
utils/p4_mininet.py:        self.cmd("sysctl -w net.ipv6.conf.lo.disable_ipv6=1")
utils/mininet/p4_mininet.py:        self.cmd("sysctl -w net.ipv6.conf.all.disable_ipv6=1")
utils/mininet/p4_mininet.py:        self.cmd("sysctl -w net.ipv6.conf.default.disable_ipv6=1")
utils/mininet/p4_mininet.py:        self.cmd("sysctl -w net.ipv6.conf.lo.disable_ipv6=1")
exercises/multicast/disable_ipv6.sh:sudo sysctl -w net.ipv6.conf.all.disable_ipv6=1
exercises/multicast/disable_ipv6.sh:sudo sysctl -w net.ipv6.conf.default.disable_ipv6=1

Hi Andy,

thank you for response. Yes, these commands do need to be run in each namespace.
Yes, when i check these commands, all of them are correctly in the py.files under untils folder. Also, i issued the command: sudo vim /etc/sysctl.conf to add the correspongding command line as the last two line of your post. However, there are still three inet6 when i checked. I dont know where are they from and what could i do for these three network namespace.


Thank you~