Is there an oid for the number of registered clients on an AP? I have looked all over for one and I can’t find one. If not is there a possibility that one could be added in the future?
Thanks
Is there an oid for the number of registered clients on an AP? I have looked all over for one and I can’t find one. If not is there a possibility that one could be added in the future?
Thanks
Why dont you use perl and make a script which telnets to the router and gets that number. You just put this script as input to the mrtg config file. If you dont do programming tell me which command is used to get that number and i will put a simple script in the forum.
In 2.8.x, the command is
/interface wireless registration-table print count-only
I would guess the command is similar in 2.9, but not certain. FWIW, you can get this number by parsing the available SNMP stuff directly (without needing to log in.
I am working on a script to do this but I was just wondering why it doesn’t have an oid already. I am sure almost everyone that runs the Mikrotik as an AP would like to graph this kind of information. I just think that and oid would make it a lot simpler to graph than having to write a script to connect to each ap and get the data. Well I will see what I can come up with for a script.
Also we have multiple radios in some of our mikrotiks so we can’t just print the regestration table and use that as that list all radios. I need the number associated to each radio.
In unix:
snmpwalk -v1 -c public 10.100.18.2 1.3.6.1.4.1.14988.1.1.1.2.1.3|wc -l
That does it. In windows? Who knows.
by the way: 10.100.18.2 is the IP of the router, and the oid I listed above is the signal strength for the radios. You may prefer a different oid to poll, though.
So this command /interface wireless registration-table print count-only will give you this output;
#0 wlan1-st5 000C42050353 00:0C:42:05:03:53 yes -28dBm... 54Mbps
#1 wlan2-st2.4 000C420506F3 00:0C:42:05:06:F3 yes -35dBm... 48Mbps
Ive never used 802.11 so if you can tell me what does this mean !! Im stuck with the script. If you can give me info I think it is very easy to get it for each wifi card.
$username = "demo";
$passwd = "";
die "USAGE: IP address & Interface \n" if @ARGV < 2;
($hostip,$interface) = @ARGV;
use Net::Telnet ();
$t = new Net::Telnet (Timeout => 10,);
$t->open("$hostip");
$t->login($username, $passwd);
$t->waitfor("/> /") or die ;
@lines = $t->cmd("interface wireless registration-table print");
foreach $wifi (@lines) {
???
No. The command “/interface wireless registration-table print” gives that output. The column meanings are in the documentation (and are, for the most part) self explanatory. the “count-only” part of that command will return a number, which is the total number of connected radios listed in the reg table.
@lines = $t->cmd("interface wireless registration-table print");
>
This should read:
```text
@lines = $t->cmd("/interface wireless registration-table print");