I have a master node and different slave nodes. I want to perform traceroute from each slave to every other slave and master and send this route to master periodically with timestamp.
Bruteforce approach seems to be performing a traceroute from each slave to different slaves and then send to master.
I have tried calling traceroute
using subprocess
from my python script. But it takes a lot of time in generating the output and then sending the traceroute to master would again take a lot of time.
My main purpose is to store the routes in master and whenever any slaves fails i can get the latest route from these logs which i have stored in the master.
I have looked for other library tools as well such as scapy
python library and mtr
.
Any pointers on how to do this in best possible way ?
Thanks