my network is not a good network and sometimes phones got un-registered and I want to pull an active peer list of today and use it as the benchmark to compare a daily active peer list which will let me know if any peers are removed due to any issues so that our operations team proactively react to that and fix the issues.
waiting for some good suggestions from the experts.
Iām far from an expert, but if it were me wanting to complete such a task, Iād write a perl script to do this and put it in cron to run whenever you want it to. (If you design it correctly, you could run it every few minutes so youād get more immediate notifications of peers that go offline.) Assuming these are SIP peers, this command should pull a list of all peers:
asterisk -rx āsip show peersā
Then itās a matter of collecting the output in your perl script, comparing it to what phones should be online, and notify yourself if any are not online.