Modem not reconnecting after 4G disconnect
Most of the time, whenever the 4G connection drops our systems manage to reestablish the connection. In some of our systems we recently had the problem that after a disconnect from the 4G network the modem did not reestablish the connection, even though the 4G connection was back up again. A manual reboot of the machine was required to get it to reconnect. Since our machines are on remote locations, this is very inconvenient. That is why I would like to understand what happened and how we can avoid this in the future.
You can find some logs below. These show the continuous connection loop that the system went through until we did a reboot. I suspect the key to what the problem is lies "failed to connect modem: Cannot create new bearer: all existing bearers are connected" but a search for these errors has not gotten me any further and I am unsure as how to proceed in debugging or solving this.
It would be great if someone could help me gain an understanding as to what is going on here, and could give some advice on what to do to make sure the system can get out of this state without a reboot. Thanks for your help!
System info:
- Ubuntu 18.04.3 LTS
- Modem: Huawei ME909s-120
- Modem manager version: 1.12.2
- Network manager version: 1.10.6
Maybe it is good to mention that this error does not occur on our systems running ModemManager 1.8.2.
2020-04-20T07:51:34.965590+00:00 NetworkManager[808]: <info> [1587369094.9650] manager: NetworkManager state is now CONNECTED_LOCAL
2020-04-20T07:51:34.966537+00:00 NetworkManager[808]: <warn> [1587369094.9661] device (ttyUSB0): Activation: failed for connection 'lte0'
2020-04-20T07:51:34.968115+00:00 NetworkManager[808]: <info> [1587369094.9678] device (ttyUSB0): state change: failed -> disconnected (reason 'none', sys-iface-state: 'managed')
2020-04-20T07:51:34.970223+00:00 NetworkManager[808]: <info> [1587369094.9698] policy: auto-activating connection 'lte0'
2020-04-20T07:51:34.973195+00:00 NetworkManager[808]: <info> [1587369094.9729] device (ttyUSB0): Activation: starting connection 'lte0' (3a37dbea-8a70-44ed-87ae-3330cadd316c)
2020-04-20T07:51:34.973838+00:00 NetworkManager[808]: <info> [1587369094.9736] device (ttyUSB0): state change: disconnected -> prepare (reason 'none', sys-iface-state: 'managed')
2020-04-20T07:51:34.974495+00:00 NetworkManager[808]: <info> [1587369094.9741] manager: NetworkManager state is now CONNECTING
2020-04-20T07:51:34.979746+00:00 ModemManager[831]: <info> Modem /org/freedesktop/ModemManager1/Modem/0: state changed (connected -> disconnecting)
2020-04-20T07:51:34.980154+00:00 ModemManager[831]: <warn> Couldn't find associated cdc-wdm port for 'net/wwp0s20u3c2'
2020-04-20T07:51:34.981988+00:00 NetworkManager[808]: <info> [1587369094.9816] modem["ttyUSB0"]: modem state changed, 'connected' --> 'disconnecting' (reason: user-requested)
2020-04-20T07:51:34.985048+00:00 ModemManager[831]: <info> Simple connect started...
2020-04-20T07:51:34.985248+00:00 ModemManager[831]: <info> Simple connect state (4/8): Wait to get fully enabled
2020-04-20T07:51:34.999103+00:00 ModemManager[831]: <info> Modem /org/freedesktop/ModemManager1/Modem/0: state changed (disconnecting -> connected)
2020-04-20T07:51:34.999326+00:00 ModemManager[831]: <info> Simple connect state (5/8): Register
2020-04-20T07:51:34.999787+00:00 ModemManager[831]: <info> Simple connect state (6/8): Bearer
2020-04-20T07:51:35.000799+00:00 NetworkManager[808]: <info> [1587369095.0005] modem["ttyUSB0"]: modem state changed, 'disconnecting' --> 'connected' (reason: user-requested)
2020-04-20T07:51:35.018235+00:00 NetworkManager[808]: <warn> [1587369095.0178] modem-broadband[ttyUSB0]: failed to connect modem: Cannot create new bearer: all existing bearers are connected
2020-04-20T07:51:35.018764+00:00 NetworkManager[808]: <info> [1587369095.0179] device (ttyUSB0): state change: prepare -> failed (reason 'unknown', sys-iface-state: 'managed')
2020-04-20T07:51:35.019176+00:00 NetworkManager[808]: <info> [1587369095.0186] manager: NetworkManager state is now CONNECTED_LOCAL
2020-04-20T07:51:35.020684+00:00 NetworkManager[808]: <warn> [1587369095.0203] device (ttyUSB0): Activation: failed for connection 'lte0'
2020-04-20T07:51:35.023262+00:00 NetworkManager[808]: <info> [1587369095.0222] device (ttyUSB0): state change: failed -> disconnected (reason 'none', sys-iface-state: 'managed')