Check Accessibility Control
This scenario shows how to configure a cellular interface, enabling the accessibility control mechanism that triggers reconnections when network connectivity is lost.
Test Reconnection By Accessibility Control
Description
In DUT0, the cell0 cellular interface is configured with a cellular profile for which accessibility control is enabled. Once connectivity with Google’s DNS public server has been verified, a situation where 100% of the packets received by the network are lost is emulated to verify that the accessibility control mechanism triggers a reconnection.
Scenario
Step 1: Set the following configuration in DUT0 :
set cellular logging level info set cellular profile CELPROFILE accessibility-control ping address 8.8.8.8 set cellular profile CELPROFILE accessibility-control ping interval 10 set cellular profile CELPROFILE apn movistar.es set interfaces cellular cell0 address dhcp set interfaces cellular cell0 encrypted-pin U2FsdGVkX1/qQdAs7eUB/5lrxAfhm1E8qGMh8fxe+F0= set interfaces cellular cell0 profile CELPROFILE set system login user admin authentication encrypted-password '$6$GSjsCj8gHLv$/VcqU6FLi6CT2Oxn0MJQ2C2tqnRDrYKNF8HIYWJp68nvXvPdFccDsT04.WtigUONbKYrgKg8d6rEs8PjljMkH0'
Note
Once the cellular interface is configured, it can be verified that there is network connectivity by pinging Google’s DNS public server.
Step 2: Ping IP address 8.8.8.8 from DUT0:
admin@DUT0$ ping 8.8.8.8 count 1 size 56 timeout 1Show output
PING 8.8.8.8 (8.8.8.8) 56(84) bytes of data. 64 bytes from 8.8.8.8: icmp_seq=1 ttl=116 time=173 ms --- 8.8.8.8 ping statistics --- 1 packets transmitted, 1 received, 0% packet loss, time 0ms rtt min/avg/max/mdev = 172.793/172.793/172.793/0.000 ms
Note
The accessibility control is a mechanism where pings are sent at an interval, and to the IP address, configured by the user. The mechanism then waits for a response within this interval. If no response is received before it times out, a second ping is sent and a response is expected within 10 seconds. If there is still no response, two more pings are sent at 5-second intervals. Finally, if there is still no response, the device reconnects to the network.
Note
As a result, you can verify that no reconnection has been recorded in the system logs if you wait long enough.
Step 3: Run command system journal clear at DUT0.
Step 4: Run command system journal show | cat at DUT0 and check if output does not contain the following tokens:
[Core/cell0] Info: Signal '12' received to reconnect device [Device/cell0] Info: Stopping network connection [Device/cell0] Info: Establishing network connectionShow output
Dec 02 11:46:54.942694 osdx systemd-journald[1568]: Runtime Journal (/run/log/journal/717a595574314751bbe3189204d59539) is 4.8M, max 38.4M, 33.6M free. Dec 02 11:46:54.947795 osdx systemd-journald[1568]: Received client request to rotate journal, rotating. Dec 02 11:46:54.947993 osdx systemd-journald[1568]: Vacuuming done, freed 0B of archived journals from /run/log/journal/717a595574314751bbe3189204d59539. Dec 02 11:46:55.038143 osdx OSDxCLI[1853]: User 'admin' executed a new command: 'system journal clear'.
Note
However, when traffic control is applied, it is possible to prove the ‘ping’ command is failing because ICMP packets are being dropped.
Step 5: Modify the following configuration lines in DUT0 :
set interfaces cellular cell0 traffic control in PLOSS set traffic control PLOSS type network-emulator packet-loss 100
Step 6: Expect a failure in the following command:
Ping IP address 8.8.8.8 from DUT0:
admin@DUT0$ ping 8.8.8.8 count 1 size 56 timeout 1Show output
PING 8.8.8.8 (8.8.8.8) 56(84) bytes of data. --- 8.8.8.8 ping statistics --- 1 packets transmitted, 0 received, 100% packet loss, time 0ms
Note
You can verify that a reconnection has been recorded in the system logs if you wait long enough.
Step 7: Run command system journal clear at DUT0.
Step 8: Run command system journal show | cat at DUT0 and check if output does not contain the following tokens:
[Core/cell0] Info: Signal '12' received to reconnect device [Device/cell0] Info: Stopping network connection [Device/cell0] Info: Establishing network connectionShow output
Dec 02 11:47:39.650170 osdx systemd-journald[1568]: Runtime Journal (/run/log/journal/717a595574314751bbe3189204d59539) is 4.8M, max 38.4M, 33.6M free. Dec 02 11:47:39.655082 osdx systemd-journald[1568]: Received client request to rotate journal, rotating. Dec 02 11:47:39.655285 osdx systemd-journald[1568]: Vacuuming done, freed 0B of archived journals from /run/log/journal/717a595574314751bbe3189204d59539. Dec 02 11:47:39.746142 osdx OSDxCLI[1853]: User 'admin' executed a new command: 'system journal clear'.
Step 9: Run command system journal show | cat at DUT0 and check if output contains the following tokens:
[Core/cell0] Info: Signal '12' received to reconnect device [Device/cell0] Info: Stopping network connection [Device/cell0] Info: Establishing network connectionShow output
Dec 02 11:47:39.650170 osdx systemd-journald[1568]: Runtime Journal (/run/log/journal/717a595574314751bbe3189204d59539) is 4.8M, max 38.4M, 33.6M free. Dec 02 11:47:39.655082 osdx systemd-journald[1568]: Received client request to rotate journal, rotating. Dec 02 11:47:39.655285 osdx systemd-journald[1568]: Vacuuming done, freed 0B of archived journals from /run/log/journal/717a595574314751bbe3189204d59539. Dec 02 11:47:39.746142 osdx OSDxCLI[1853]: User 'admin' executed a new command: 'system journal clear'. Dec 02 11:47:59.924144 osdx OSDxCLI[1853]: User 'admin' executed a new command: 'system journal show | cat'. Dec 02 11:48:00.120137 osdx OSDxCLI[1853]: User 'admin' executed a new command: 'system journal show | cat'. Dec 02 11:48:01.320163 osdx OSDxCLI[1853]: User 'admin' executed a new command: 'system journal show | cat'. Dec 02 11:48:02.532216 osdx OSDxCLI[1853]: User 'admin' executed a new command: 'system journal show | cat'. Dec 02 11:48:03.748167 osdx OSDxCLI[1853]: User 'admin' executed a new command: 'system journal show | cat'. Dec 02 11:48:05.016148 osdx OSDxCLI[1853]: User 'admin' executed a new command: 'system journal show | cat'. Dec 02 11:48:06.260153 osdx OSDxCLI[1853]: User 'admin' executed a new command: 'system journal show | cat'. Dec 02 11:48:07.500150 osdx OSDxCLI[1853]: User 'admin' executed a new command: 'system journal show | cat'. Dec 02 11:48:08.780148 osdx OSDxCLI[1853]: User 'admin' executed a new command: 'system journal show | cat'. Dec 02 11:48:10.072148 osdx OSDxCLI[1853]: User 'admin' executed a new command: 'system journal show | cat'. Dec 02 11:48:11.352179 osdx OSDxCLI[1853]: User 'admin' executed a new command: 'system journal show | cat'. Dec 02 11:48:12.628136 osdx OSDxCLI[1853]: User 'admin' executed a new command: 'system journal show | cat'. Dec 02 11:48:12.956032 osdx wwan-module[2039]: [Core/cell0] Info: Signal '12' received to reconnect device. Dec 02 11:48:12.956110 osdx wwan-module[2039]: [Device/cell0] Info: Stopping network connection... Dec 02 11:48:12.974078 osdx wwan-module[2581]: Network cancelled... releasing resources Dec 02 11:48:13.079712 osdx wwan-module[2581]: [/dev/cdc-wdm0] Network stopped Dec 02 11:48:13.079712 osdx wwan-module[2581]: [/dev/cdc-wdm0] Client ID not released: Dec 02 11:48:13.079712 osdx wwan-module[2581]: Service: 'wds' Dec 02 11:48:13.079712 osdx wwan-module[2581]: CID: '21' Dec 02 11:48:13.081488 osdx wwan-module[2039]: [Device/cell0] Info: Network connection was stopped! Dec 02 11:48:13.083580 osdx wwan-module[2039]: [Network/cell0] Info: Stopping accessibility control... Dec 02 11:48:13.083732 osdx wwan-module[2039]: [Network/cell0] Info: Accessibility control was stopped! Dec 02 11:48:13.087095 osdx kernel: net cell0: link_state 0x1 -> 0x0 Dec 02 11:48:13.096468 osdx modulelauncher[2588]: stop DHCP client for cell0 Dec 02 11:48:13.097606 osdx dhclient[2280]: receive_packet failed on cell0: Network is down Dec 02 11:48:13.099587 osdx wwan-module[2039]: [Device/cell0] Info: Checking registration state... Dec 02 11:48:13.106759 osdx dhclient[2592]: Killed old client process Dec 02 11:48:13.208033 osdx wwan-module[2039]: [Device/cell0] Info: Device registered and PS attached successfully Dec 02 11:48:13.208057 osdx wwan-module[2039]: [Device/cell0] Info: Establishing network connection... Dec 02 11:48:13.243285 osdx dhclient[2592]: DHCPRELEASE of 37.12.22.177 on cell0 to 37.12.22.178 port 67 Dec 02 11:48:13.243313 osdx dhclient[2592]: send_packet: Network is down Dec 02 11:48:13.243325 osdx dhclient[2592]: dhclient.c:3146: Failed to send 300 byte long packet over cell0 interface. Dec 02 11:48:13.469244 osdx wwan-module[2039]: [Device/cell0] Info: Network connection was successfully started: PDH=[2175544864] Dec 02 11:48:13.594877 osdx kernel: net cell0: link_state 0x0 -> 0x1 Dec 02 11:48:13.596389 osdx wwan-module[2039]: [Network/cell0] Info: Starting accessibility control... Dec 02 11:48:13.596682 osdx wwan-module[2039]: [Network/cell0] Info: Accessibility control was started! Dec 02 11:48:13.830713 osdx modulelauncher[2641]: start DHCP client for cell0