Hi, I'm struggling to connect to a private Vodafone APN using MM and NM.
Modem Telit LE910-EU1 (MBIM) ModemManager 1.18.6 libmbim 1.18.4 libqmi 1.30.2 NetworkManager 1.22.10 My problem is, that the bearer gets connected, but not assigned an IP address. To make it work, I was told to use PDP context ID 3 instead of 1 for this private APN. When searching the internet, I've found this older thread about selecting a CID. https://lists.freedesktop.org/archives/modemmanager-devel/2021-February/008420.html With MR 179 merged, this feature should be available now. Unfortunately, the documentation about 3gpp-profile-management is a little bit poor and mmcli --help-3gpp-profile-manager leaves me with some questions. Is the 3gpp-profile-manager 'profile-id' corresponding with the PDP context ID (CID) which can be set by AT+CGDCONT? >From the merge request discussion, I've noticed, that one cannot specify a >specific profile-id when creating a new profile. Do I have to create empty profiles until getting to the profile ID to use? For instance: root@dev:~# mmcli -m 0 --3gpp-profile-manager-set="" --------------------------- 3GPP profile manager | set: profile-id: 1 | apn-type: default root@dev:~# mmcli -m 0 --3gpp-profile-manager-set="" --------------------------- 3GPP profile manager | set: profile-id: 2 | apn-type: default root@dev:~# mmcli -m 0 --3gpp-profile-manager-set="apn=apn.vodafone.de,ip-type=ipv4,allowed-auth=pap,user=abc,password=def" error: couldn't set profile: 'GDBus.Error:org.freedesktop.libmbim.Error.Core.InvalidMessage: Couldn't validate update of profile '3': cannot read string data (6 bytes) (274 < 278)' I wonder, what are the correct options to be passed to 3gpp-profile-manager-set? My first assumption is to use the same options as for create-bearer. After deleting all profiles, I can use the same settings for profile 1 and 2 with success, but for profile 3 it fails. root@dev:~# mmcli -m 0 --3gpp-profile-manager-delete=3 successfully deleted the profile root@dev:~# mmcli -m 0 --3gpp-profile-manager-delete=2 successfully deleted the profile root@dev:~# mmcli -m 0 --3gpp-profile-manager-delete=1 successfully deleted the profile root@dev:~# mmcli -m 0 --3gpp-profile-manager-set="apn=apn.vodafone.de,ip-type=ipv4,allowed-auth=pap,user=abc,password=def" --------------------------- 3GPP profile manager | set: profile-id: 1 | apn: apn.vodafone.de | allowed-auth: pap | user: abc | password: d | apn-type: default Why are the last two characters of the given password "def" not shown? I've tried with password='def' (in single quotes), but that doesn't help. root@dev:~# mmcli -m 0 --3gpp-profile-manager-set="apn=apn.vodafone.de,ip-type=ipv4,allowed-auth=pap,user=abc,password=def" --------------------------- 3GPP profile manager | set: profile-id: 2 | apn: apn.vodafone.de | allowed-auth: pap | user: abc | password: d | apn-type: default root@dev:~# mmcli -m 0 --3gpp-profile-manager-set="apn=apn.vodafone.de,ip-type=ipv4,allowed-auth=pap,user=abc,password=def" error: couldn't set profile: 'GDBus.Error:org.freedesktop.libmbim.Error.Core.InvalidMessage: Couldn't validate update of profile '3': cannot read string data (6 bytes) (358 < 362)' Is this a bug? I've found, that setting profile ID 3 only succeeds, if only "apn=apn.vodafone.de" is given. root@dev:~# mmcli -m 0 --3gpp-profile-manager-delete=3 successfully deleted the profile root@dev:~# mmcli -m 0 --3gpp-profile-manager-set="apn=apn.vodafone.de" --------------------------- 3GPP profile manager | set: profile-id: 3 | apn: apn.vodafone.de | apn-type: default If I try to give a username, it fails. root@dev:~# mmcli -m 0 --3gpp-profile-manager-delete=3 successfully deleted the profile root@dev:~# mmcli -m 0 --3gpp-profile-manager-set="apn=apn.vodafone.de,user=abc" error: couldn't set profile: 'GDBus.Error:org.freedesktop.libmbim.Error.Core.InvalidMessage: Couldn't validate update of profile '3': cannot read string data (6 bytes) (352 < 354)' If I could manage to set profile-id 3 properly with the requested APN settings, do I have to create the bearer pointing to the profile-id in this way? mmcli -m 0 --create-bearer="profile-id=3" root@dev:~# mmcli -m 0 -------------------------------- General | path: /org/freedesktop/ModemManager1/Modem/0 | device id: *** -------------------------------- Hardware | manufacturer: Telit | model: FIH7160 | firmware revision: 20.00.413 | h/w revision: XMM7160_V1.2_HWID790_MBIM_NAND | supported: gsm-umts, lte | current: gsm-umts, lte | equipment id: *** -------------------------------- System | device: /sys/devices/platform/soc/2100000.bus/2184200.usb/ci_hdrc.1/usb1/1-1/1-1.2 | drivers: cdc_acm, cdc_mbim | plugin: telit | primary port: cdc-wdm0 | ports: cdc-wdm0 (mbim), ttyACM0 (at), ttyACM1 (ignored), | ttyACM2 (ignored), ttyACM3 (at), ttyACM4 (ignored), ttyACM5 (ignored), | wwan0 (net) -------------------------------- Status | unlock retries: sim-pin2 (3) | state: registered | power state: on | access tech: gprs, edge | signal quality: 64% (recent) -------------------------------- Modes | supported: allowed: 2g; preferred: none | allowed: 4g; preferred: none | allowed: 2g, 4g; preferred: none | current: allowed: 2g; preferred: none -------------------------------- Bands | supported: egsm, dcs, eutran-1, eutran-3, eutran-7, eutran-8, eutran-20 | current: egsm, dcs, eutran-1 -------------------------------- IP | supported: ipv4, ipv6, ipv4v6 -------------------------------- 3GPP | imei: *** | enabled locks: sim, fixed-dialing | operator id: 26202 | operator name: Vodafone.de | registration: home -------------------------------- 3GPP EPS | ue mode of operation: csps-1 -------------------------------- SIM | primary sim path: /org/freedesktop/ModemManager1/SIM/0 root@dev:~# mmcli -m 0 -b 0 ---------------------------------- General | path: /org/freedesktop/ModemManager1/Bearer/0 | type: default ---------------------------------- Status | connected: yes | suspended: no | multiplexed: no | interface: wwan0 | ip timeout: 20 ---------------------------------- Properties | apn: ***.vodafone.de | roaming: allowed | ip type: ipv4 | allowed-auth: pap | user: *** | password: *** ---------------------------------- IPv4 configuration | method: dhcp | prefix: 0 ---------------------------------- Statistics | attempts: 1 Because the wrong CID=1 is used, the bearer gets no valid IP configuration and defaults to "dhcp", but this doesn't work. Your help is very much appreciated. Thank you. Carsten Stelling