This repository has been archived on 2025-09-14. You can view files and clone it, but cannot push or open issues or pull requests.
Files
solutions-tsg-scripts/roles/sapp/files/tera_fake_promisc_setup.sh
fumingwei c80ec96e6e 1、commit the file privilege that is changed
2、add function that is to reboot and  stop device manager in mxn
2021-03-08 10:54:59 +08:00

5 lines
283 B
Bash

set -ex
dp_adapter_ether_addr=$(ifconfig ens1f2 | grep ether | awk '{print $2}')
bpf_rule="ether dst $dp_adapter_ether_addr or ether dst 02:42:c0:a8:fd:03 or ether dst 02:42:c0:a8:fd:83 or ether dst 02:42:c0:a8:fd:82"
sed -i "/BSD_packet_filter=/s/=.*/=\"$bpf_rule\"/" etc/sapp.toml