This repository contains a script to whitelist specific interfaces to be used by eProsima's FastRTPS DDS.
A blog article providing relevant background information can be found here.
ros2 daemon stop
./fastrtps-whitelist-interfaces.sh wlan0 eth0 ...
export FASTRTPS_DEFAULT_PROFILES_FILE=$(pwd)/fastrtps-whitelist-interfaces.xml
export RMW_IMPLEMENTATION=rmw_fastrtps_cpp