<div dir="ltr"><span class="gmail-im" style="color:rgb(80,0,80);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial">On 16 March 2018 at 22:51, Dan Williams<span> </span><span dir="ltr"><<a href="mailto:dcbw@redhat.com" target="_blank" style="color:rgb(17,85,204)">dcbw@redhat.com</a>></span><span> </span>wrote:<br></span><blockquote class="gmail_quote" style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div class="gmail-m_1859207377408006212m_2405812848907071932gmail-m_-2753696819137889896gmail-m_-1409246023813991094m_-2132539241688928001HOEnZb"><div class="gmail-m_1859207377408006212m_2405812848907071932gmail-m_-2753696819137889896gmail-m_-1409246023813991094m_-2132539241688928001h5"><span class="gmail-im" style="color:rgb(80,0,80)">On Wed, 2018-03-14 at 16:41 +0000, Hugh Warrington wrote:<br></span><span class="gmail-im" style="color:rgb(80,0,80)">> 1. Is registration denied a recoverable error -- and if so should I<br>> expect<br>> modemmanager to retry registration?<br><br></span></div></div><span class="gmail-im" style="color:rgb(80,0,80)">It's recoverable to the extent that you can attempt to manually<br>register with another network, or you could airplane-mode-then-retry<br>registration to the same network and see if it works, or you could<br>change the preferred access technology.  But usually, if the network<br>denies you, that same network will deny you again.<br></span></blockquote><div style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial"><br></div><div style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial"><div style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:small;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial">I've written a script to repeatedly reset the modem and see if registration succeeds. After hundreds of trials I've found that registration seems to succeed or fail at random in this case.</div><div style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:small;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial"><br></div><div style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:small;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial">It doesn't make sense to me, and having spoken to the network it makes no sense to them either. I had a support call in which they performed a 'live trace'. On the attempts where registration was denied they saw nothing whatsoever in their logs (not even a connection attempt) and the support call ended with a big shrug.</div><div style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:small;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial"><br></div><div style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:small;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial">What's more, some SIMs from the same provider display this intermittent failure mode while others work every time. But putting the SIMs in a different device with a Quectel modem, they work every time. So the problem seems to be the combination of modem model and SIM (for completeness I also tested in other identical instances of the same modem/PC, with the same results).</div><div style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:small;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial"><br></div><div style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:small;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial">From what you say it sounds like registration denied shouldn't be a 'routine' failure mode. But is there any option to have modemmanger automatically retry? If not then I will just write a cron job to detect registration denied and reset the modem.</div><br></div><span class="gmail-im" style="color:rgb(80,0,80);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">(as an aside, there are tables in the SIM card that control how<br>automatic registration works; it could be that your operator is perhaps<br>denying registration to the UMTS network but would allow LTE and the<br>SIM doesn't distinguish the two.  Or something like that...  but this<br>would be odd.)<br></blockquote><div><br></div></span><div style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial">That sounds exactly the kind of mistake they might make. Any idea if/how I can access that SIM state?</div><span class="gmail-im" style="color:rgb(80,0,80);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial"><div> <br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><span>> Finally, if I try to manually reconnect after the above error I get<br>> this<br>> every time -- instantly, rather than after a delay, even though the<br>> message<br>> mentions a timeout:<br>><br>><br>> root@host:~# mmcli -m 0 --simple-connect="apn=EEM2M,ip<wbr>-type=ipv4" --<br>> verbose<br>> [09 Mar 2018, 16:55:53] [Debug] Forcing request to be run<br>> asynchronously<br>> [09 Mar 2018, 16:55:53] [Debug] Assuming '0' is the modem index<br>> [09 Mar 2018, 16:55:53] [Debug] ModemManager process found at ':1.3'<br>> [09 Mar 2018, 16:55:53] [Debug] Modem found at '/org/freedesktop/<br>> ModemManager1/Modem/0'<br>><br>> [09 Mar 2018, 16:55:53] [Debug] Asynchronously connecting the<br>> modem...<br>> error: couldn't connect the modem: 'GDBus.Error:org.freedesktop.<br>> ModemManager1.Error.MobileEqui<wbr>pment.NetworkTimeout: Network timeout'<br><br></span>That message would be coming directly from the modem in the AT ERROR<br>response, I think.  And it may well be that the modem firmware thinks<br>there's a timeout or is just returning that error code for the attempt.<br></blockquote><div><br></div></span><div style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial">Here's the mm logs immediately after running the simple-connect command above:</div><div style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial"><br></div><div style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial"><div>Mar 20 10:31:15 x ModemManager[919]: <info>  Simple connect started...</div><div>Mar 20 10:31:15 x ModemManager[919]: <debug>    PIN: unspecified</div><div>Mar 20 10:31:15 x ModemManager[919]: <debug>    Operator ID: unspecified</div><div>Mar 20 10:31:15 x ModemManager[919]: <debug>    Allowed roaming: yes</div><div>Mar 20 10:31:15 x ModemManager[919]: <debug>    APN: EEM2M</div><div>Mar 20 10:31:15 x ModemManager[919]: <debug>    IP family: ipv4</div><div>Mar 20 10:31:15 x ModemManager[919]: <debug>    Allowed authentication: unspecified</div><div>Mar 20 10:31:15 x ModemManager[919]: <debug>    User: unspecified</div><div>Mar 20 10:31:15 x ModemManager[919]: <debug>    Password: unspecified</div><div>Mar 20 10:31:15 x ModemManager[919]: <debug>    Number: unspecified</div><div>Mar 20 10:31:15 x ModemManager[919]: <info>  Simple connect state (4/8): Wait to get fully enabled</div><div>Mar 20 10:31:15 x ModemManager[919]: <info>  Simple connect state (5/8): Register</div><div>Mar 20 10:31:15 x ModemManager[919]: <debug> Launching automatic network registration...</div><div>Mar 20 10:31:15 x ModemManager[919]: <debug> (ttyUSB0) device open count is 2 (open)</div><div>Mar 20 10:31:15 x ModemManager[919]: <debug> (ttyUSB0): --> 'AT+COPS=0<CR>'</div><div>Mar 20 10:31:15 x ModemManager[919]: <debug> (ttyUSB0): <-- '<CR><LF>OK<CR><LF>'</div><div>Mar 20 10:31:15 x ModemManager[919]: <debug> Running registration checks (CS: 'yes', PS: 'yes', EPS: 'no')</div><div>Mar 20 10:31:15 x ModemManager[919]: <debug> (ttyUSB0) device open count is 3 (open)</div><div>Mar 20 10:31:15 x ModemManager[919]: <debug> (ttyUSB0) device open count is 2 (close)</div><div>Mar 20 10:31:15 x ModemManager[919]: <debug> (ttyUSB0): --> 'AT+CREG?<CR>'</div><div>Mar 20 10:31:15 x ModemManager[919]: <debug> (ttyUSB0): <-- '<CR><LF>+CREG: 2,3<CR><LF><CR><LF>OK<CR><LF>'</div><div>Mar 20 10:31:15 x ModemManager[919]: <debug> (ttyUSB0) device open count is 3 (open)</div><div>Mar 20 10:31:15 x ModemManager[919]: <debug> (ttyUSB0) device open count is 2 (close)</div><div>Mar 20 10:31:15 x ModemManager[919]: <debug> (ttyUSB0): --> 'AT+CGREG?<CR>'</div><div>Mar 20 10:31:15 x ModemManager[919]: <debug> (ttyUSB0): <-- '<CR><LF>+CGREG: 2,3<CR><LF><CR><LF>OK<CR><LF>'</div><div>Mar 20 10:31:15 x ModemManager[919]: <debug> (ttyUSB0) device open count is 1 (close)</div><div>Mar 20 10:31:15 x ModemManager[919]: <debug> Registration denied</div><div>Mar 20 10:31:15 x ModemManager[919]: <info>  Modem /org/freedesktop/ModemManager1<wbr>/Modem/13: 3GPP Registration state changed (denied -> idle)</div><div>Mar 20 10:31:15 x ModemManager[919]: <debug> Modem /org/freedesktop/ModemManager1<wbr>/Modem/13: access technology changed (umts -> unknown)</div></div><span class="gmail-im" style="color:rgb(80,0,80);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial"><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div><div class="gmail-m_1859207377408006212m_2405812848907071932gmail-m_-2753696819137889896gmail-m_-1409246023813991094m_-2132539241688928001h5">> However if I do 'mmcli -m 0 --reset', it seems to attempt a new<br>> connection<br>> from scratch (which succeeds intermittently as on a fresh boot).<br><br></div></div>--reset doesn't look like it's implemented for Huawei AT-based modems,<br>actually.  What do the ModemManager logs look like when you try reset?</blockquote><div><br></div></span><div style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial"><div>Mar 19 18:15:50 x ModemManager[919]: <debug> (ttyUSB0) device open count is 2 (open)</div><div>Mar 19 18:15:50 x ModemManager[919]: <debug> (ttyUSB0): --> 'AT^RESET<CR>'</div><div>Mar 19 18:15:50 x ModemManager[919]: <debug> (ttyUSB0): <-- '<CR><LF>OK<CR><LF>'</div><div>Mar 19 18:15:50 x ModemManager[919]: <debug> (ttyUSB0) device open count is 1 (close)</div><div>Mar 19 18:15:50 x ModemManager[919]: <debug> (ttyUSB2): <-- '<CR><LF>+CGREG: 0<CR><LF>'</div><div>Mar 19 18:15:50 x ModemManager[919]: <debug> (ttyUSB2): <-- '<CR><LF>+CREG: 0<CR><LF>'</div><div>Mar 19 18:15:50 x ModemManager[919]: <info>  Modem /org/freedesktop/ModemManager1<wbr>/Modem/11: 3GPP Registration state changed (denied -> idle)</div><div>Mar 19 18:15:50 x ModemManager[919]: <debug> (ttyUSB0): <-- '<CR><LF>+CGREG: 0<CR><LF><CR><LF>+CREG: 0<CR><LF><CR><LF>^SRVST: 0<CR><LF>'</div><div>Mar 19 18:15:50 x ModemManager[919]: <debug> (ttyUSB2): <-- '<CR><LF>^SRVST: 0<CR><LF>'</div><div>Mar 19 18:15:50 x ModemManager[919]: <debug> (ttyUSB0): <-- '<CR><LF>^SRVST: 1<CR><LF>'</div><div>Mar 19 18:15:50 x ModemManager[919]: <debug> (ttyUSB2): <-- '<CR><LF>^SRVST: 1<CR><LF>'</div><div>Mar 19 18:15:50 x ModemManager[919]: <debug> (ttyUSB2): <-- '<CR><LF>^SRVST: 0<CR><LF><CR><LF>^MODE: 0,0<CR><LF>'</div><div>Mar 19 18:15:50 x ModemManager[919]: <debug> Access Technology: 'unknown'</div><div>Mar 19 18:15:50 x ModemManager[919]: <debug> (ttyUSB0): <-- '<CR><LF>^SRVST: 0<CR><LF><CR><LF>^MODE: 0,0<CR><LF>'</div><div>Mar 19 18:15:50 x ModemManager[919]: <debug> Access Technology: 'unknown'</div><div>Mar 19 18:15:53 x ModemManager[919]: <info>  (net/enp0s21f0u8c2): released by modem /sys/devices/pci0000:00/0000:0<wbr>0:15.0/usb1/1-8</div><div>Mar 19 18:15:53 x ModemManager[919]: <debug> (ttyUSB0) unexpected port hangup!</div><div>Mar 19 18:15:53 x ModemManager[919]: <debug> (ttyUSB0) forced to close port</div><div>Mar 19 18:15:53 x ModemManager[919]: <debug> (ttyUSB0) device open count is 0 (close)</div><div>Mar 19 18:15:53 x ModemManager[919]: <debug> (ttyUSB0) closing serial port...</div><div>Mar 19 18:15:53 x ModemManager[919]: <debug> (ttyUSB0) serial port closed</div><div>Mar 19 18:15:53 x ModemManager[919]: <debug> (ttyUSB2) unexpected port hangup!</div><div>Mar 19 18:15:53 x ModemManager[919]: <debug> (ttyUSB2) forced to close port</div><div>Mar 19 18:15:53 x ModemManager[919]: <debug> (ttyUSB2) device open count is 0 (close)</div><div>Mar 19 18:15:53 x ModemManager[919]: <debug> (ttyUSB2) closing serial port...</div><div>Mar 19 18:15:53 x ModemManager[919]: <debug> (ttyUSB2) serial port closed</div><div>Mar 19 18:15:53 x ModemManager[919]: <info>  (tty/ttyUSB0): released by modem /sys/devices/pci0000:00/0000:0<wbr>0:15.0/usb1/1-8</div><div>Mar 19 18:15:53 x ModemManager[919]: <info>  (tty/ttyUSB1): released by modem /sys/devices/pci0000:00/0000:0<wbr>0:15.0/usb1/1-8</div><div>Mar 19 18:15:53 x ModemManager[919]: <info>  (tty/ttyUSB2): released by modem /sys/devices/pci0000:00/0000:0<wbr>0:15.0/usb1/1-8</div><div>Mar 19 18:15:53 x ModemManager[919]: <info>  (tty/ttyUSB4): released by modem /sys/devices/pci0000:00/0000:0<wbr>0:15.0/usb1/1-8</div><div>Mar 19 18:15:53 x ModemManager[919]: <info>  (tty/ttyUSB3): released by modem /sys/devices/pci0000:00/0000:0<wbr>0:15.0/usb1/1-8</div><div>Mar 19 18:15:53 x ModemManager[919]: <debug> Removing empty device '/sys/devices/pci0000:00/0000:<wbr>00:15.0/usb1/1-8'</div><div>Mar 19 18:15:53 x ModemManager[919]: <debug> Unexported modem '/sys/devices/pci0000:00/0000:<wbr>00:15.0/usb1/1-8' from path '/org/freedesktop/ModemManager<wbr>1/Modem/11'</div><div>Mar 19 18:15:53 x ModemManager[919]: <debug> (ttyUSB3) forced to close port</div><div>Mar 19 18:15:53 x ModemManager[919]: <debug> Modem (Huawei) '/sys/devices/pci0000:00/0000:<wbr>00:15.0/usb1/1-8' completely disposed</div></div><div style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial"><div>Mar 19 18:15:58 x ModemManager[919]: <debug> [plugin manager] task 15: new support task for device: /sys/devices/pci0000:00/0000:0<wbr>0:15.0/usb1/1-8</div><div>Mar 19 18:15:58 x ModemManager[919]: <debug> [plugin manager] task 15: port grabbed: ttyUSB0</div></div><div style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial"><br></div><div style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial">Followed by what looks like modem setup.</div><div style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial"><br></div><div style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial">Many thanks for your help,<br></div><div style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial"><br></div><div style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial">Hugh</div><br></div><div class="gmail_extra"><br><div class="gmail_quote">On 16 March 2018 at 22:51, Dan Williams <span dir="ltr"><<a href="mailto:dcbw@redhat.com" target="_blank">dcbw@redhat.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="HOEnZb"><div class="h5">On Wed, 2018-03-14 at 16:41 +0000, Hugh Warrington wrote:<br>
> Hello!<br>
><br>
> I am using network-manager 1.2.6-0ubuntu0.16.04.2,<br>
> modemmanager 1.6.4-1ubuntu0.16.04.1 with a Huawei ME909s-120,<br>
> firmware 11.617.01.00.00.<br>
><br>
> We're using a SIM card from EE M2M here in the UK.<br>
><br>
> Intermittently when I boot the machine, I get a 3GPP registration<br>
> denied<br>
> message in mm logs. Having run mm in debug mode and read through the<br>
> AT<br>
> commands going back and forth, I believe mm is correctly reporting<br>
> the<br>
> modem state.<br>
><br>
> Here's some mm journald logs from a failed attempt (with many lines<br>
> of<br>
> noise removed):<br>
><br>
><br>
> ModemManager (version 1.4.12) starting in system bus...<br>
> Creating modem with plugin 'Huawei' and '6' ports<br>
> Modem for device at '/sys/devices/pci0000:00/0000:<wbr>00:15.0/usb1/1-8'<br>
> successfully created<br>
> mobile equipment error code: 50<br>
> Modem: state changed (unknown -> disabled)<br>
> Modem /org/freedesktop/<wbr>ModemManager1/Modem/0: state changed (disabled<br>
> -><br>
> enabling)<br>
> mobile equipment error code: 50<br>
> Modem /org/freedesktop/<wbr>ModemManager1/Modem/0: 3GPP Registration state<br>
> changed (unknown -> denied)<br>
> Modem /org/freedesktop/<wbr>ModemManager1/Modem/0: state changed (enabling<br>
> -><br>
> enabled)<br>
><br>
><br>
> I've contacted the network about why the registration is sometimes<br>
> denied.<br>
> But I have a couple of questions:<br>
><br>
> 1. Is registration denied a recoverable error -- and if so should I<br>
> expect<br>
> modemmanager to retry registration?<br>
<br>
</div></div>It's recoverable to the extent that you can attempt to manually<br>
register with another network, or you could airplane-mode-then-retry<br>
registration to the same network and see if it works, or you could<br>
change the preferred access technology.  But usually, if the network<br>
denies you, that same network will deny you again.<br>
<br>
(as an aside, there are tables in the SIM card that control how<br>
automatic registration works; it could be that your operator is perhaps<br>
denying registration to the UMTS network but would allow LTE and the<br>
SIM doesn't distinguish the two.  Or something like that...  but this<br>
would be odd.)<br>
<span class=""><br>
> 2. Does the final line in the logs above indicate a problem? It seems<br>
> strange that the registration failed but then it reports the modem is<br>
> 'enabled'.<br>
<br>
</span>No, since you can force-register with another operator or change the<br>
preferred access technology while the modem is enabled.  Just because<br>
you're denied one operator doesn't mean you're denied all of them.<br>
<span class=""><br>
> Finally, if I try to manually reconnect after the above error I get<br>
> this<br>
> every time -- instantly, rather than after a delay, even though the<br>
> message<br>
> mentions a timeout:<br>
><br>
><br>
> root@host:~# mmcli -m 0 --simple-connect="apn=EEM2M,<wbr>ip-type=ipv4" --<br>
> verbose<br>
> [09 Mar 2018, 16:55:53] [Debug] Forcing request to be run<br>
> asynchronously<br>
> [09 Mar 2018, 16:55:53] [Debug] Assuming '0' is the modem index<br>
> [09 Mar 2018, 16:55:53] [Debug] ModemManager process found at ':1.3'<br>
> [09 Mar 2018, 16:55:53] [Debug] Modem found at '/org/freedesktop/<br>
> ModemManager1/Modem/0'<br>
><br>
> [09 Mar 2018, 16:55:53] [Debug] Asynchronously connecting the<br>
> modem...<br>
> error: couldn't connect the modem: 'GDBus.Error:org.freedesktop.<br>
> ModemManager1.Error.<wbr>MobileEquipment.<wbr>NetworkTimeout: Network timeout'<br>
<br>
</span>That message would be coming directly from the modem in the AT ERROR<br>
response, I think.  And it may well be that the modem firmware thinks<br>
there's a timeout or is just returning that error code for the attempt.<br>
<div><div class="h5"><br>
><br>
> And in the mm journalctl logs:<br>
><br>
><br>
> <info>  [1520872097.948148] [mm-iface-modem-simple.c:641]<br>
> connect_auth_ready(): Simple connect started...<br>
> <debug> [1520872097.948222] [mm-iface-modem-simple.c:651]<br>
> connect_auth_ready():    PIN: unspecified<br>
> <debug> [1520872097.948244] [mm-iface-modem-simple.c:653]<br>
> connect_auth_ready():    Operator ID: unspecified<br>
> <debug> [1520872097.948263] [mm-iface-modem-simple.c:655]<br>
> connect_auth_ready():    Allowed roaming: yes<br>
> <debug> [1520872097.948282] [mm-iface-modem-simple.c:657]<br>
> connect_auth_ready():    APN: EEM2M<br>
> <debug> [1520872097.948302] [mm-iface-modem-simple.c:662]<br>
> connect_auth_ready():    IP family: ipv4<br>
> <debug> [1520872097.948320] [mm-iface-modem-simple.c:673]<br>
> connect_auth_ready():    Allowed authentication: unspecified<br>
> <debug> [1520872097.948339] [mm-iface-modem-simple.c:675]<br>
> connect_auth_ready():    User: unspecified<br>
> <debug> [1520872097.948356] [mm-iface-modem-simple.c:677]<br>
> connect_auth_ready():    Password: unspecified<br>
> <debug> [1520872097.948375] [mm-iface-modem-simple.c:679]<br>
> connect_auth_ready():    Number: unspecified<br>
> <info>  [1520872097.948392] [mm-iface-modem-simple.c:469]<br>
> connection_step(): Simple connect state (4/8): Wait to get fully<br>
> enabled<br>
> <info>  [1520872097.948472] [mm-iface-modem-simple.c:478]<br>
> connection_step(): Simple connect state (5/8): Register<br>
> <debug> [1520872097.948519] [mm-iface-modem-3gpp.c:407]<br>
> mm_iface_modem_3gpp_register_<wbr>in_network(): Launching automatic<br>
> network<br>
> registration...<br>
> <debug> [1520872097.948600] [mm-port-serial.c:1288]<br>
> mm_port_serial_open():<br>
> (ttyUSB0) device open count is 2 (open)<br>
> <debug> [1520872097.948679] [mm-port-serial-at.c:459] debug_log():<br>
> (ttyUSB0): --> 'AT+COPS=0<CR>'<br>
> <debug> [1520872097.966674] [mm-port-serial-at.c:459] debug_log():<br>
> (ttyUSB0): <-- '<CR><LF>OK<CR><LF>'<br>
> <debug> [1520872097.966851] [mm-iface-modem-3gpp.c:761]<br>
> mm_iface_modem_3gpp_run_<wbr>registration_checks(): Running registration<br>
> checks<br>
> (CS: 'yes', PS: 'yes', EPS: 'no')<br>
> <debug> [1520872097.966906] [mm-port-serial.c:1288]<br>
> mm_port_serial_open():<br>
> (ttyUSB0) device open count is 3 (open)<br>
> <debug> [1520872097.966954] [mm-port-serial.c:1345]<br>
> _close_internal():<br>
> (ttyUSB0) device open count is 2 (close)<br>
> <debug> [1520872097.967011] [mm-port-serial-at.c:459] debug_log():<br>
> (ttyUSB0): --> 'AT+CREG?<CR>'<br>
> <debug> [1520872097.978564] [mm-port-serial-at.c:459] debug_log():<br>
> (ttyUSB0): <-- '<CR><LF>+CREG: 2,3<CR><LF><CR><LF>OK<CR><LF>'<br>
> <info>  [1520872097.978719] [mm-iface-modem-3gpp.c:1186]<br>
> update_registration_state(): Modem<br>
> /org/freedesktop/<wbr>ModemManager1/Modem/0:<br>
> 3GPP Registration state changed (idle -> denied)<br>
> <debug> [1520872097.978961] [mm-port-serial.c:1288]<br>
> mm_port_serial_open():<br>
> (ttyUSB0) device open count is 3 (open)<br>
> <debug> [1520872097.979022] [mm-port-serial.c:1345]<br>
> _close_internal():<br>
> (ttyUSB0) device open count is 2 (close)<br>
> <debug> [1520872097.979408] [mm-port-serial-at.c:459] debug_log():<br>
> (ttyUSB0): --> 'AT+CGREG?<CR>'<br>
> <debug> [1520872097.993673] [mm-port-serial-at.c:459] debug_log():<br>
> (ttyUSB0): <-- '<CR><LF>+CGREG: 2,3<CR><LF><CR><LF>OK<CR><LF>'<br>
> <debug> [1520872097.993969] [mm-port-serial.c:1345]<br>
> _close_internal():<br>
> (ttyUSB0) device open count is 1 (close)<br>
> <debug> [1520872097.994049] [mm-iface-modem-3gpp.c:262]<br>
> run_registration_checks_ready(<wbr>): Registration denied<br>
> <info>  [1520872097.994097] [mm-iface-modem-3gpp.c:1186]<br>
> update_registration_state(): Modem<br>
> /org/freedesktop/<wbr>ModemManager1/Modem/0:<br>
> 3GPP Registration state changed (denied -> idle)<br>
><br>
><br>
> However if I do 'mmcli -m 0 --reset', it seems to attempt a new<br>
> connection<br>
> from scratch (which succeeds intermittently as on a fresh boot).<br>
<br>
</div></div>--reset doesn't look like it's implemented for Huawei AT-based modems,<br>
actually.  What do the ModemManager logs look like when you try reset?<br>
<br>
Dan<br>
<span class=""><br>
> Question number 3 is a bit more vague: is the difference between a<br>
> new<br>
> 'simple connect' and modem reset expected?<br>
><br>
> Many thanks in advance for any insight.<br>
> Best wishes,<br>
><br>
> Hugh Warrington<br>
> Engineer<br>
> Hoxton Analytics<br>
</span>> ______________________________<wbr>_________________<br>
> ModemManager-devel mailing list<br>
> <a href="mailto:ModemManager-devel@lists.freedesktop.org">ModemManager-devel@lists.<wbr>freedesktop.org</a><br>
> <a href="https://lists.freedesktop.org/mailman/listinfo/modemmanager-devel" rel="noreferrer" target="_blank">https://lists.freedesktop.org/<wbr>mailman/listinfo/modemmanager-<wbr>devel</a><br>
</blockquote></div><br></div>