Murphy Mac - Screencasts and Tutorials » Page 'View Airport Express Connections via Command Line'

View Airport Express Connections via Command Line


airport expressThese days I need two Airports to cover the house.   There’s an Airport Extreme and an Airport Express that’s wired via Ethernet to extend the network.   The Express was acting a little flaky and I wanted to know if anyone was connecting to it.  (check out Glenn Fleishman’s e-book for in-depth info on optimizing your Apple wireless network.)

One option is using the Airport Utility to see connections to your Apple wireless access points.  But that’s a lot of clicks, and you can’t easily check it from your iPhone or iPad.   Here’s an alternative:  Use an SNMP command to see what’s going on with your Airport Express.

Murphy found a suitable command on, shown below:

snmpget -v 2c -c PASSWORD -M /usr/share/snmp/mibs:$HOME/share/mibs \
-m+AIRPORT-BASESTATION-3-MIB MyAirportExpress.local AIRPORT-BASESTATION-3-MIB::wirelessNumber.0

You can delete that backslash at the end of the top line and enter it all as one line in Terminal.  You also want to enter your router’s password in place of password, and your router’s name in place of MyAirportExpress.   Don’t get confused and enter your wifi password or the name of your wireless network.  It’s the name of the router you’re looking for and the administrative password.

When you enter that in Terminal you should get a response that looks something like this:


The last number represents the number of clients connected to that Airport.  In this case there aren’t any.
I tried using the same command to query my Airport Extreme and had no luck.  I saw reports of people having trouble with SNMP once the last Airport firmware update hit.   Let me know if you have a solution.
The Terminal command was a more direct way for me to get the information I was looking for.  Using an app like TouchTerm SSH I can get the answer from my phone or iPad as well.
Take a look at the brief screencast.  First it quickly demonstrates how many clicks Airport Utility requires to get the information.  Then it shows the Terminal command being executed.
The command is really long.  You could create an alias and save it in your .profile file so it would always be available in your Terminal.  That way you could enter something like “aeusers” in the Terminal instead of the long command.  See Murphy’s post on alias creation for more information.
The page where Murphy found the command for querying the Airport had other commands as well. SNMP (Simple Network Monitoring Protocol) is a cross-platform protocol that’s been around forever – you can do plenty with it. The Airport can also report its information via Syslog, but that’ll have to wait for another day.
Screencast | Permalink

2 comments to “View Airport Express Connections via Command Line”


  2. The below command works on both a Airport Extreme 802.11n (2nd Generation) and a Airport Extreme 802.11g, running v7.6.1 and v5.7 respectively.

    The additional argument needed is the SNMP Community String. On the 802.11g, it’s the password for the Airport, for the 2nd Gen, you define it in a field below were you enable SNMP.

    The argument is:

    This is the command:
    snmpget -M /usr/share/snmp/mibs:$HOME/share/mibs -m+AIRPORT-BASESTATION-3-MIB -cpublic BaseStation.local wirelessNumber.0

Leave a comment