Skip to content

[Bug] APN config matters #2559

@SherlockChiang

Description

@SherlockChiang

Verify steps

  • I have read the documentation and understand the meaning of all the configuration items I have written, rather than just piling up seemingly useful options or default values.
  • I have carefully reviewed the documentation and have not resolved the issue.
  • I have searched the Issue Tracker for the issue I want to raise and did not find it.
  • I am a non-Chinese user.
  • I have tested with the latest Alpha branch version, and the issue still persists.
  • I have provided the server and client configuration files and processes that can reproduce the issue locally, rather than a sanitized complex client configuration file.
  • I provided the simplest configuration that can be used to reproduce the errors in my report, rather than relying on remote servers or piling on a lot of unnecessary configurations for reproduction.
  • I have provided complete logs, rather than just the parts I think are useful out of confidence in my own intelligence.
  • I have directly reproduced the error using the Mihomo command-line program, rather than using other tools or scripts.

Operating System

Android

System Version

a16

Mihomo Version

1.19.19

Configuration File

mixed-port: 7890 
allow-lan: true 
bind-address: '*' 
mode: rule 
log-level: info 
ipv6: true
unified-delay: true
tcp-concurrent: true
external-controller: 0.0.0.0:9090
secret: ""    

external-ui: /data/adb/modules/Maodie-Launcher/maodie/config/webui
external-ui-url: /ui

tun:
  enable: true
  stack: system 
  device: utun 
  auto-route: true 
  auto-detect-interface: true 
  exclude-package:
    - com.tencent.mobileqq
    - com.tencent.mm
  dns-hijack:
    - any:53
  mtu: 9000 

dns:
  enable: true
  listen: 0.0.0.0:1053
  ipv6: true
  enhanced-mode: fake-ip
  fake-ip-range: 198.18.0.1/16
  fake-ip-filter:
    - '*.lan'
    - '*.local'
    - '*.localhost'
    - '+.stun.*'
    - '+.stun.*.*'

  default-nameserver:
    - 223.6.6.6
    - 119.29.29.29
  direct-nameserver:
    - 223.6.6.6
    - 119.29.29.29
  direct-nameserver-follow-policy: true
  proxy-server-nameserver:
    - 223.5.5.5
    - 119.29.29.29
  nameserver:
    - https://dns.alidns.com/dns-query
    - https://doh.pub/dns-query

sniffer:
  enable: true
  force-dns-mapping: true
  parse-pure-ip: true
  override-destination: true
  sniff:
    HTTP:
      ports: [80, 8080-8880]
      override-destination: true
    TLS:
      ports: [443, 8443]
    QUIC:
      ports: [443, 8443]

p: &p
  {type: http, interval: 21600, health-check: {enable: true, url: https://www.gstatic.com/generate_204, interval: 900}}

proxies: 
  - name: "直连"
    type: direct
    udp: true

# url 里填写自己的订阅,名称不能重复
proxy-providers:
  provider1:
    <<: *p
    url: "请填写您自己的代理地址"
    path: ./proxy_providers/subscribe1.yaml
    interval: 21600
  
  provider2:
    <<: *p
    url: "请填写您自己的代理地址"
    path: ./proxy_providers/subscribe2.yaml
    interval: 86400
  
  provider3:
    <<: *p
    url: "请填写您自己的代理地址"
    path: ./proxy_providers/subscribe3.yaml
    interval: 86400

proxy-groups:
  - name: 默认
    type: select
    proxies: [自动选择, 香港, 日本, 美国, 全部节点, 直连]
    icon: "https://raw.githubusercontent.com/Koolson/Qure/master/IconSet/mini/Airport.png"

  - name: Google
    type: select
    proxies: [默认, 香港, 日本, 美国, 全部节点]
    icon: "https://raw.githubusercontent.com/Koolson/Qure/master/IconSet/mini/Google_Search.png"
  
  - name: Google_fcm
    type: select
    proxies: [直连, 默认, 香港, 日本, 美国, 全部节点]
    icon: "https://raw.githubusercontent.com/Koolson/Qure/master/IconSet/mini/Global.png"

  - name: Telegram
    type: select
    proxies: [默认, 香港, 日本, 美国, 全部节点]
    icon: "https://raw.githubusercontent.com/Koolson/Qure/master/IconSet/mini/Telegram.png"

  - name: Github
    type: select
    proxies: [默认, 香港, 日本, 美国, 全部节点]
    icon: "https://raw.githubusercontent.com/Koolson/Qure/master/IconSet/mini/Server.png"

  - name: Microsoft
    type: select
    proxies: [默认, 香港, 日本, 美国, 全部节点, 直连]
    icon: "https://raw.githubusercontent.com/Koolson/Qure/master/IconSet/mini/Microsoft.png"

  - name: 其他
    type: select
    proxies: [默认, 香港, 日本, 美国, 全部节点, 直连]
    icon: "https://raw.githubusercontent.com/Koolson/Qure/master/IconSet/mini/Final.png"

  # 地区分组
  - name: 香港
    type: url-test
    include-all: true
    filter: "(?i)港|hk|hongkong|hong kong"
    tolerance: 50
    icon: "https://raw.githubusercontent.com/Koolson/Qure/master/IconSet/mini/HK.png"

  - name: 日本
    type: url-test
    include-all: true
    filter: "(?i)(?=.*(?:日本|jp|japan))^(?!.*(?:HY|RLY)).*"
    tolerance: 50
    icon: "https://raw.githubusercontent.com/Koolson/Qure/master/IconSet/mini/JP.png"

  - name: 美国
    type: url-test
    include-all: true
    filter: "(?i)(?=.*(?:美国|us))^(?!.*(?:HY|RLY)).*"
    tolerance: 50
    icon: "https://raw.githubusercontent.com/Koolson/Qure/master/IconSet/mini/US.png"

  - name: 全部节点
    type: select
    include-all: true
    filter: "^(?!.*(剩余|到期|官网|重置)).*" # 过滤掉非节点信息
    icon: "https://raw.githubusercontent.com/Koolson/Qure/master/IconSet/mini/Server.png"

  - name: 自动选择
    type: url-test
    include-all: true
    url: "https://cp.cloudflare.com"
    interval: 300
    tolerance: 50
    filter: "^(?!.*(剩余|到期|官网|重置)).*" # 过滤掉非节点信息
    icon: "https://raw.githubusercontent.com/Koolson/Qure/master/IconSet/mini/Auto.png"


# 分流规则
rules:
  # - DST-PORT,53,DNS_Hijack
  - RULE-SET,ad,REJECT

  - RULE-SET,private_ip,直连,no-resolve
  - RULE-SET,private_domain,直连
  - RULE-SET,tencent_domain,直连
  - RULE-SET,cn_domain,直连
  - RULE-SET,cn_ip,直连,no-resolve
  - RULE-SET,google_fcm,Google_fcm
  - RULE-SET,github_domain,Github
  - RULE-SET,microsoft_domain,Microsoft
  - RULE-SET,google_domain,Google
  - RULE-SET,telegram_domain,Telegram
  - RULE-SET,geolocation-!cn,默认
  - RULE-SET,google_ip,Google
  - RULE-SET,telegram_ip,Telegram
  
  - MATCH,其他

# 规则集定义锚点
rule-anchor:
  ip: &ip {type: http, interval: 86400, behavior: ipcidr, format: mrs}
  domain: &domain {type: http, interval: 86400, behavior: domain, format: mrs}

rule-providers:
  private_domain:
    <<: *domain
    url: "https://raw.githubusercontent.com/MetaCubeX/meta-rules-dat/meta/geo/geosite/private.mrs"
  tencent_domain:
    <<: *domain
    url: "https://raw.githubusercontent.com/MetaCubeX/meta-rules-dat/meta/geo/geosite/tencent.mrs"
  cn_domain:
    <<: *domain
    url: "https://raw.githubusercontent.com/MetaCubeX/meta-rules-dat/meta/geo/geosite/cn.mrs"
  github_domain:
    <<: *domain
    url: "https://raw.githubusercontent.com/MetaCubeX/meta-rules-dat/meta/geo/geosite/github.mrs"
  microsoft_domain:
    <<: *domain
    url: "https://raw.githubusercontent.com/MetaCubeX/meta-rules-dat/meta/geo/geosite/microsoft.mrs"
  google_domain:
    <<: *domain
    url: "https://raw.githubusercontent.com/MetaCubeX/meta-rules-dat/meta/geo/geosite/google.mrs"
  telegram_domain:
    <<: *domain
    url: "https://raw.githubusercontent.com/MetaCubeX/meta-rules-dat/meta/geo/geosite/telegram.mrs"
  geolocation-!cn:
    <<: *domain
    url: "https://raw.githubusercontent.com/MetaCubeX/meta-rules-dat/meta/geo/geosite/geolocation-!cn.mrs"
  google_fcm:
    <<: *domain
    url: "https://raw.githubusercontent.com/MetaCubeX/meta-rules-dat/meta/geo/geosite/googlefcm.mrs"
  ad:
    <<: *domain
    url: "https://raw.githubusercontent.com/TG-Twilight/AWAvenue-Ads-Rule/main/Filters/AWAvenue-Ads-Rule-Clash.mrs"
  private_ip:
    <<: *ip
    url: "https://raw.githubusercontent.com/MetaCubeX/meta-rules-dat/meta/geo/geoip/private.mrs"
  cn_ip:
    <<: *ip
    url: "https://raw.githubusercontent.com/MetaCubeX/meta-rules-dat/meta/geo/geoip/cn.mrs"
  google_ip:
    <<: *ip
    url: "https://raw.githubusercontent.com/MetaCubeX/meta-rules-dat/meta/geo/geoip/google.mrs"
  telegram_ip:
    <<: *ip
    url: "https://raw.githubusercontent.com/MetaCubeX/meta-rules-dat/meta/geo/geoip/telegram.mrs"

Description

北京联通,APN设置成pixelos16系统获取的3gnet 3gwap均产生dns玄学问题,切换成cmtds连接正常,仅作问题记录

Reproduction Steps

apollo pixelos16 murtaza unofficial build,联通卡,apn默认配置,通过apatch启用maodielauncher……叠buff太多我难以确定问题在何处发生但是在我这里可以稳定复现,所以仅做记录

Logs

time="2026-02-09T19:42:18.674803330+08:00" level=warning msg="[TCP] dial Github (match RuleSet/github_domain) 198.18.0.1:43112 --> api.github.com:80 error: shark.douyucdn.cn.o8168e628.ksyungslb.com.douyinvod.click:41275 connect error: dial tcp 198.18.5.238:41275: i/o timeout"
time="2026-02-09T19:42:19.971059058+08:00" level=warning msg="[TCP] dial Github (match RuleSet/github_domain) 198.18.0.1:44176 --> api.github.com:80 error: shark.douyucdn.cn.o8168e628.ksyungslb.com.douyinvod.click:41275 connect error: dial tcp 198.18.5.238:41275: i/o timeout"
time="2026-02-09T19:42:21.062033381+08:00" level=warning msg="because 香港 failed multiple times, active health check"
time="2026-02-09T19:42:23.361316974+08:00" level=warning msg="[TCP] dial Google (match RuleSet/google_domain) 198.18.0.1:49784 --> play.googleapis.com:443 error: shark.douyucdn.cn.o8168e628.ksyungslb.com.douyinvod.click:41346 connect error: dial tcp 198.18.5.238:41346: i/o timeout"
time="2026-02-09T19:42:26.064467285+08:00" level=warning msg="because 香港 failed multiple times, active health check"

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions