Having some dual stack issues here on a Sierra EM7565, but with a workaround. Regardless of whether I set --set-ip-family ipv6/4
in the same command as --start-network
, the v6 connection always fails. v4 comes up successfully. Interestingly, the pdp type is always set to ipv4
, regardless.
I'm unclear, looking at the uqmi source, as to exactly how/where the pdp type is set.
As an experiment, I tried creating a profile on the modem itself with the pdp type manually set to ipv4v6
AT+CGDCONT=1,"IPV4V6","telstra.internet"
I can then connect a v4 and a v6 session with:
uqmi -d /dev/cdc-wdm0 --get-client-id wds
uqmi -d /dev/cdc-wdm0 --set-client-id wds,<cid1> --set-ip-family ipv6
uqmi -d /dev/cdc-wdm0 --get-client-id wds
uqmi -d /dev/cdc-wdm0 --set-client-id wds,<cid2> --set-ip-family ipv4
uqmi -d /dev/cdc-wdm0 --set-client-id wds,<cid1> --start-network --profile 1
uqmi -d /dev/cdc-wdm0 --set-client-id wds,<cid2> --start-network --profile 1
uqmi -d /dev/cdc-wdm0 --set-client-id wds,18 --get-current-settings
{
"pdp-type": "ipv4-or-ipv6",
"ip-family": "ipv6",
"mtu": 1500,
"ipv4": {
},
"ipv6": {
"ip": "2001:8004:1500:274c:5866:1801:4907:8bc1",
"ip-prefix-length": 64,
"gateway": "2001:8004:1500:274c:95b2:8140:73e7:d7b",
"gw-prefix-length": 64,
"dns1": "2001:8004::a1a0:7:e1c0:0:10",
"dns2": "2001:8004::a080:7:e1c0:0:10"
},
"domain-names": {
}
}
uqmi -d /dev/cdc-wdm0 --set-client-id wds,19 --get-current-settings
{
"pdp-type": "ipv4-or-ipv6",
"ip-family": "ipv4",
"mtu": 1500,
"ipv4": {
"ip": "10.98.25.136",
"dns1": "10.4.130.164",
"dns2": "10.5.136.242",
"gateway": "10.98.25.137",
"subnet": "255.255.255.240"
},
"ipv6": {
},
"domain-names": {
}
}
I can then get OpenWRT to bring up both v4 and v6 sessions by specifying the ipv4v6 profile rather than the APN:
# uci show network.WWANQMI
network.WWANQMI=interface
network.WWANQMI.proto='qmi'
network.WWANQMI.device='/dev/cdc-wdm0'
network.WWANQMI.ipv6='1'
network.WWANQMI.profile='1'
network.WWANQMI.pdptype='ipv4v6'
This does rely on that profile manually having manually defined in the modem.
The only issue outstanding then is why it's apparently not possible (or I'm missing something) to force a specific pdp type as well as an APN when starting a session in uqmi.