This article is current to the last version of airControl, but will not be updated further since airControl has been retired.
This article will show users steps they must take to debug and troubleshoot device connectivity with airControl.
Table of Contents
- Debugging Commands
- Viewing Logs
- Starting MCAD Reporting Agent Manuall
- How to Test Telnet Connection
- Related Articles
The Management Console Agent (MCA) establishes secure connections from devices to airControl using SSH public keys. Below are commands that can be run from the end devices (airOS devices) to debug connectivity issues between a device and the airControl Server.
This command lists all available and known provisioners. If running this command does not return any results, the airOS device is not currently being monitored by airControl.
unknown @ http://10.0.100.69:9081/AC2/report -
mca-ctrl -t status
This command will show current connections and reporting status/statistics for the device.
XW.v5.6.5# mca-ctrl -t status
| 21:18:58 | 30 | 22 | 0 | Heartbeat | Ready | http://10.0.100.69:9081/AC2/report
One row per active console connection, where columns are:
- The time of the last heartbeat transmit attempt
- Interval value for periodic transmission (in seconds)
- Number of successful transmits
- Number of subsequent transmittal failures (is reset to 0 after successful transmit)
- URL of the console
mca-ctrl -t connect -s <url of airControl>
This command will manually establish reporting heartbeat with airControl using default time interval of 60 seconds.
XW.v5.6.5# mca-ctrl -t connect -s http://10.0.100.69:9081/AC2/report
Going to create 'Heartbeat' reporter version = 0, url = http://10.0.100.69:9081/AC2/report, interval = 0s, crypted = false, compressed = false
Heartbeat reporter created successfully
mca-ctrl -t stop -s <url of airControl>
This command will remove reporting heartbeat with airControl.
XW.v5.6.5# mca-ctrl -t stop -s http://10.0.100.69:9081/AC2/report
Going to stop reporter url = http://10.0.100.69:9081/AC2/report
Reporter stopped successfully
This command deletes provisioner information based on console url, public key file, or ID (if specified).
XW.v5.6.5# mca-provision-rm http://10.0.100.69:9081/AC2/report
Found 1 entries matching 'http://10.0.100.69:9081/AC2/report':
Removing: unknown @ http://10.0.100.69:9081/AC2/report ...
Found Backup1 on ...
Found Active on ...
Storing Active ... [%100]
Active->Backup ... [%100]
MCA logs are written to /var/log/messages. Connect to device using SSH and view logs by entering the following command:
XW.v5.6.5# cat /var/log/messages
Example below shows log entries of device initiating connection to airControl:
May 15 21:08:24 mca-ctrl: Going to create 'FirstPing' reporter url = http://10.0.100.69:9081/AC2/report
May 15 21:08:24 mcad: New reporter created, type = FirstPing, url = http://10.0.100.69:9081/AC2/report, interval = 10s
May 15 21:08:24 mca-ctrl: FirstPing reporter created successfully
May 15 21:08:24 mcad: Reporter type = FirstPing, url = http://10.0.100.69:9081/AC2/report got http response, http_code = 200
May 15 21:08:24 mcad: FirstPing reporter success!
May 15 21:08:24 mcad: Destroying reporter, type = FirstPing, url = http://10.0.100.69:9081/AC2/report
May 15 21:08:24 dropbear: Child connection from 10.0.100.69:51486
May 15 21:08:27 dropbear: Pubkey auth succeeded for 'mcuser' with key md5 cb:22:ba:80:a6:17:92:50:c4:7c:c4:49:8c:b7:7e:b5 from 10.0.100.69:51486
May 15 21:08:28 FileSystem: End check.
May 15 21:08:28 mca-ctrl: Going to create 'Heartbeat' reporter version = 0, url = http://10.0.100.69:9081/AC2/report, interval = 30s, crypted = true, compressed = false
May 15 21:08:28 mcad: New reporter created, type = Heartbeat, url = http://10.0.100.69:9081/AC2/report, interval = 30s
May 15 21:08:28 mca-ctrl: Heartbeat reporter created successfully
May 15 21:08:28 dropbear: Exit (mcuser): Exited normally
Starting MCAD Reporting Agent Manually
Open initab file and comment out line that contains mcad:
# vi /etc/inittab
... <-- this is a file excerpt
null::respawn:/bin/ubntspecd -w -t -a -i wifi1 -j airview1 -m 4 -f 20 -s 200
ttyS0::askfirst:/sbin/getty -L ttyS0 115200 vt100
Restart init process:
# kill -1 1
Stop running mcad process:
# kill <pidof mcad>
Run mcad with debug options:
# mcad -vvv -l 3
Connect to server (run this in a separate SSH session):
# mca-ctrl -t connect -s http://<AC2 Server IP>:9081/AC2/report -i 15 -f 1
How to Test Telnet Connection
Follow these steps to test connectivity:
1. Open SSH connection to device.
2. Run telnet 192.168.1.1 9081
Where 192.168.1.1 is AC2 server IP address.
3. When connected using telnet you will get no indication of something happening. Execute these commands one after another and finish the last one by pressing enter twice. Don't forget to substitute the IP with your own.
GET /AC2/report HTTP/1.1