How to config dns based on android11 RK3399/RK3568 ppp/wwan network card???

本帖最后由 Buck 于 2022-2-18 19:09 编辑

Dear:

How to config dns at android11?? It failed that ping www.baidu.com.

Log as below:

#ip rule add from all lookup main
#ndc resolver setdefaultif wwan0
500 0 Command not recongnized
#ndc resolver setifdns wwan0 “114.114.114.114” “8.8.8.8”
500 0 Command not recongnized
#ping 8.8.8.8
PING 8.8.8.8 (8.8.8.8) 56(84) bytes of data.
64 bytes from 8.8.8.8: icmp_seq=1 ttl=249 time=146 ms
64 bytes from 8.8.8.8: icmp_seq=2 ttl=249 time=64.7 ms
64 bytes from 8.8.8.8: icmp_seq=3 ttl=249 time=37.5 ms
#ping www.baidu.com
ping: unknown host www.baidu.com

have not try these in android, try to ref android source
https://source.android.com/devices/architecture/modular-system/dns-resolver

Thank you for your professional answer.
I also find the source code about dns which located at packages/modules/DnsResolver for android11 SDK.
But I don’t know how to use by new way, and kindly, could you help to support this new issue based on rk3399/rk3399pro/rk3568 board?

zhansb 发表于 2022-2-19 15:00
have not try these in android, try to ref android source
https://source.android.com/devices/archite

Thank you for your professional answer.
I also find the source code about dns which located at packages/modules/DnsResolver for android11 SDK.
But I don’t know how to use by new way, and kindly, could you help to support this new issue based on rk3399/rk3399pro/rk3568 board?