Howto: Mobile data on pmOS + Phosh with APN requiring user/pass
#1
Star 
Have been having trouble getting mobile data on any of the available distributions, and finally with the help of IRC, manpages, and a few guides, I managed to get mobile data on my operator, which requires setting up an APN with user and password.

So for me it wasn't a simple matter of using ofonoctl wan --connect --append-dns, or simply enabling ofonod, or anything of the sorts. I had to dig in deeper.

This has only been tested under pmOS + Phosh so far, because it uses NetworkManager and it's easy to install ModemManager without messing up the whole system (like I did once under Ubuntu Touch). YMMV on other distributions.

Step 1

Install pmOS your favorite way, and make sure to install modemmanager


Code:
apk add modemmanager


Step 2

Disable ofono, enable modemmanager at startup

As root:

Code:
rc-service ofono stop
rc-update del ofono
rc-update del ofono-auto-enable
rc-update add modemmanager
rc-service modemmanger start


Step 3

Wait 10-20 seconds and check the status of your modem with:


Code:
mmcli -L
mmcli -m 0


If all is good, you can also see the 4G and modem icons in the status bar.

Step 4

Create a "bearer"

Code:
mmcli -m 0 --create-bearer='apn=APN.NAME,user=USERNAME,password=PASSWORD,allowed-auth=chap,allow-roaming=no'


auth and roaming may vary on your provider.

Once you've done the above successfully, you should see a new device in network manager (previously it was alled ttyUSB2) : cdc-wdm0

This is the device name to use in the next step

Step 5

Now configure the connection with nmcli, I'm not sure if you need to specify tall the APN info all over again or not, I'll have to try without and update this guide:

nmcli c add type gsm ifname cdc-wdm0 con-name OPERATOR-NAME apn APN.NAME user USERNAME password PASSWORD

Step 6

Verify connectivity with all the usual commands


Code:
nmcli c   # check status of the connection named OPERATOR-NAME as above
nmcli d    #  check status of cdc-wdm0
ip addr   # check for wwan0


and so on.

References:
https://docs.ubuntu.com/core/en/stacks/n...onnections
https://docs.ubuntu.com/core/en/stacks/n...onnections
https://www.freedesktop.org/software/Mod...cli.8.html
  Reply


Messages In This Thread
Howto: Mobile data on pmOS + Phosh with APN requiring user/pass - by pajux - 02-23-2020, 10:14 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Public Mobile (Canada): failure to configure VoLTE digdis 6 268 07-14-2025, 04:17 PM
Last Post: digdis
  beta release of a Linux mobile app strength training app coryholl 0 583 04-07-2025, 07:19 PM
Last Post: coryholl
  US Mobile, via T-Mobile, won't support Pinephone Pro - SOLVED, SIMPLY jovval 13 10,625 12-05-2024, 04:38 PM
Last Post: tllim
  box86 Actually Works Well on Manjaro Phosh/xfce jakfish 9 6,323 06-30-2024, 12:26 AM
Last Post: Peter Gamma
  can I retrieve accidentally deleted voice mail with T mobile ? HLing 4 3,171 12-13-2023, 01:24 AM
Last Post: oldschool
  how to backup user data? Uturn 1 1,503 08-30-2023, 05:23 AM
Last Post: Kevin Kofler
  New Zealand network providers mobile data Linux2thabone 3 4,643 08-05-2023, 06:17 AM
Last Post: SchizoPinePhone225
  Problems updating KDE Plasma Mobile OS IMSAI8080 6 5,831 06-30-2023, 11:39 PM
Last Post: ionmich
  Can't get through "User Configuration" on new PinePhone a-l 24 27,130 06-01-2023, 10:08 AM
Last Post: feketej
  Current Situation With Setup and Carrier Activation With Tracfone Verizon T-Mobile pinephoneuser22 0 1,573 05-26-2023, 08:40 PM
Last Post: pinephoneuser22

Forum Jump:


Users browsing this thread: 1 Guest(s)