问题
今天运维同事反馈了一个数据拨号超时的问题,抓了modem日志,需要分析下原因。
分析
首先看到attach过程是成功的:
[0xB0ED] OTA LOG 04:05:09.086400 LTE NAS EMM Plain OTA Outgoing Message Attach request Msg 1
[0xB0EC] OTA LOG 04:05:09.275653 LTE NAS EMM Plain OTA Incoming Message Authentication request Msg 1
[0xB0ED] OTA LOG 04:05:10.762133 LTE NAS EMM Plain OTA Outgoing Message Authentication response Msg 1
[0xB0EC] OTA LOG 04:05:10.966724 LTE NAS EMM Plain OTA Incoming Message Security mode command Msg 1
[0xB0ED] OTA LOG 04:05:10.967915 LTE NAS EMM Plain OTA Outgoing Message Security mode complete Msg 1
[0xB0E2] OTA LOG 04:05:10.992941 LTE NAS ESM Plain OTA Incoming Message ESM information request Msg 1
[0xB0E3] OTA LOG 04:05:10.993140 LTE NAS ESM Plain OTA Outgoing Message ESM information response Msg 1
[0xB0EC] OTA LOG 04:05:11.907686 LTE NAS EMM Plain OTA Incoming Message Attach accept Msg 1
[0xB0E2] OTA LOG 04:05:11.907703 LTE NAS ESM Plain OTA Incoming Message Activate default EPS bearer context request Msg 1
[0xB0ED] OTA LOG 04:05:11.912749 LTE NAS EMM Plain OTA Outgoing Message Attach complete Msg 1
但看Attach accept里是:PDN type IPv6 only allowed
[0xB0EC] OTA LOG 04:05:11.907686 LTE NAS EMM Plain OTA Incoming Message Attach accept Msg 1esm_cause_incl = 1 (0x1)esm_causeesm_cause = 51 (0x33) (PDN type IPv6 only allowed)
再看看QMI数据拨号情况,拨号都是失败的:
04:05:12.369574 [0x1544] QMI_MCS_QCSI_PKT
packetVersion = 2
V2 {MsgType = ResponseCounter = 4ServiceId = WDSMajorRev = 1MinorRev = 217ConHandle = 0x00001E9FMsgId = 0x00000020QmiLength = 26Service_WDS {ServiceWDSV1 {wds_start_network_interface {wds_start_network_interface_respTlvs[0] {Type = 0x02Length = 4resp {result = QMI_RESULT_FAILUREerror = QMI_ERR_CALL_FAILED}}wds_start_network_interface_respTlvs[1] {Type = 0x01Length = 4pkt_data_handle {pkt_data_handle = 0}}wds_start_network_interface_respTlvs[2] {Type = 0x10Length = 2call_end_reason {call_end_reason = WDS_CER_CLIENT_END}}wds_start_network_interface_respTlvs[3] {Type = 0x11Length = 4verbose_call_end_reason {call_end_reason_type = WDS_VCER_TYPE_CALL_MANAGER_DEFINEDcall_end_reason = 2000}}}}}
}
数据拨号失败的原因是:WDS_CER_CLIENT_END。
查看高通QMI文档:
80-16655-5_ab_qmi_wds_1.195_for_mpss.hi.4.0,_qmi_wireless_data_service_spec.pdf
对该原因的描述:Client ended the data call。
客户结束了这个数据拨号?再查看AP的日志,并没有看出AP有明显的结束这个数据拨号的相关命令。
再细看QMI的数据拨号请求情况:
04:05:12.343329 [0x1544] QMI_MCS_QCSI_PKT
packetVersion = 2
V2 {MsgType = RequestCounter = 4ServiceId = WDSMajorRev = 1MinorRev = 217ConHandle = 0x00001E9FMsgId = 0x00000020QmiLength = 51Service_WDS {ServiceWDSV1 {wds_start_network_interface {wds_start_network_interface_reqTlvs[0] {Type = 0x16Length = 1authentication_preference {authentication_preference = QMI_WDS_MASK_AUTH_PREF_PAP}}wds_start_network_interface_reqTlvs[1] {Type = 0x17Length = 8username {username = eesecure}}wds_start_network_interface_reqTlvs[2] {Type = 0x18Length = 6password {password = secure}}wds_start_network_interface_reqTlvs[3] {Type = 0x19Length = 1ip_family_preference {ip_family_preference = WDS_IP_FAMILY_PREF_IPV4}}wds_start_network_interface_reqTlvs[4] {Type = 0x35Length = 1call_type {call_type = WDS_CALL_TYPE_EMBEDDED_CALL}}wds_start_network_interface_reqTlvs[5] {Type = 0x39Length = 1disallow_in_roaming {disallow_in_roaming = true}}wds_start_network_interface_reqTlvs[6] {Type = 0x3DLength = 1bring_up_by_apn_type {bring_up_by_apn_type = true}}wds_start_network_interface_reqTlvs[7] {Type = 0x3ELength = 8apn_type_mask {apn_type_mask = WDS_APN_TYPE_MASK_DEFAULT | WDS_APN_TYPE_MASK_SUPL | WDS_APN_TYPE_MASK_HIPRI | WDS_APN_TYPE_MASK_IA}}}}}
}
原来QMI请求的是IPV4的,而modem是IPV6 only的,这应该是CLIENT_END的原因。
结论
从分析可以看出这里CLIENT_END的原因是AP请求的PDN type和modem支持的不一致。