⚠️ Experimental Notice (Important)
This article documents my personal configuration refactoring process in a Clash Verge Rev + WireGuard + Wstunnel + MetaCubeX dataset environment.
This content is an experimental technical exploration:
- It is not guaranteed to work in all network environments
- It is not recommended to copy directly for production or critical business use
- It is primarily used to verify the feasibility of the “minimalist rule model”
Network environments, DNS behavior, and VPS line quality vary by region, all of which will affect the final outcome.
1. Background: From “Works” to “Unstable”
The initial goal was simple:
Set up a stable, cross-platform proxy solution (Windows + Ubuntu + Android)
The tech stack included:
- Clash Verge Rev
- WireGuard (ZgoCloud)
- Wstunnel
- Custom DNS fallback
- GEOSITE + GEOIP rule system
❌ Initial Symptoms
During long-term use, several typical issues gradually emerged:
- Domestic websites occasionally became inaccessible, recovering after a delay of tens of seconds
- Google Play app updates behaved abnormally
- Thunderbird failed to send emails
- Inconsistent behavior across different devices (Ubuntu / Android)
2. Problem Analysis: Typical Side Effects of a Complex System
I ultimately identified three main sources of the problems:
1. Overly Complex DNS Architecture
It included:
- fallback DNS
- fallback-filter
- proxy DNS
- Mixed DoH / DoT
This led to the result:
The same domain resolved to different results at different times
2. Overly Granular Rule System
For example:
- Separate rules for Google / YouTube
- Forced CDN traffic splitting
- SMTP port rules
- Dual checking for .cn domains + GEOIP
The problem was:
Priority conflicts existed among the rules, making behavior unpredictable
3. Mixed Use of TUN / System Proxy
Existing simultaneously were:
- System DNS
- Clash DNS
- WireGuard DNS
This formed multiple network paths:
The network request path was uncontrollable
3. Refactoring Approach: Returning to the MetaCubeX Model
The core reference for this refactoring:
MetaCubeX geosite.dat + geoip.dat
Core philosophy:
Replace "manual rule maintenance" with "geographical categorization"
4. Status Update (Important)
It should be specifically noted:
👉 All the above issues have been resolved in subsequent configuration adjustments
The current system runs stably:
- Domestic access is normal
- Google Play is normal
- Email sending is normal
- Network behavior is consistent
The first half of this article serves as a “record of issue evolution” and does not represent the current state.
5. Final Solution: Minimalist Stable Model (Experimental Version)
✔ Architecture
Clash Verge Rev (TUN)
↓
WireGuard
↓
Wstunnel
↓
VPS
✔ Core Principles
- ❌ No maintaining DNS rules
- ❌ No using fallback DNS
- ❌ No granular traffic splitting for Google / YouTube
- ❌ No mixing with system proxy
✔ Final Configuration (Extension Override)
# ==============================================
# ZgoCloud + Wstunnel + WireGuard
# MetaCubeX 极简稳定版 v1 (clean)
#
# 特点:
# - 不使用 DNS 覆写(交给 Verge)
# - 不使用 SMTP / Google / YouTube 特殊规则
# - 基于 GEOSITE + GEOIP
# - 结构最小化,便于排错
# ==============================================
profile:
store-selected: true
# ==============================================
# WireGuard(代理入口)
# ==============================================
proxies:
- name: ZgoCloud-WG
type: wireguard
server: 127.0.0.1
port: 51820
ip: xxx
public-key: xxx
private-key: xxx
pre-shared-key: xxx
udp: true
mtu: 1280
# ==============================================
# 代理组
# ==============================================
proxy-groups:
- name: Proxy
type: select
proxies:
- ZgoCloud-WG
- DIRECT
# ==============================================
# 分流规则(核心简化版)
# ==============================================
rules:
# ------------------------------
# Wstunnel 服务器直连(避免回环)
# ------------------------------
- IP-CIDR,154.21.196.249/32,DIRECT,no-resolve
# ------------------------------
# 本地 / 私有网络
# ------------------------------
- GEOSITE,private,DIRECT
- GEOIP,private,DIRECT,no-resolve
# ------------------------------
# 中国大陆直连
# ------------------------------
- GEOSITE,cn,DIRECT
- GEOIP,CN,DIRECT,no-resolve
# ------------------------------
# 非中国大陆全部走代理
# ------------------------------
- GEOSITE,geolocation-!cn,Proxy
# ------------------------------
# 默认兜底
# ------------------------------
- MATCH,Proxy
6. Activation Method (Key)
In Clash Verge Rev:
- ✔ Enable TUN mode (GUI)
- ❌ No longer use system proxy
- ✔ Use MetaCubeX databases (built-in by default)
7. Changes in Effects
After the refactoring, the system behavior became:
China traffic → DIRECT
Overseas traffic → Proxy
✔ Improvements
- Domestic websites no longer stall randomly
- DNS behavior is stable and consistent
- Behavior is unified across multiple devices
- Troubleshooting complexity has dropped significantly
✔ Maintainability Improvements
Issues are now reduced to three categories:
- WireGuard
- TUN
- VPS network quality
8. Future Optimization Directions
The current solution is a “baseline stable version”, which can be gradually expanded later:
- Granular rules for Google / GitHub
- AI service optimization
- Ad filtering
- CDN acceleration strategies
Recommended principle:
Run stably for 1~2 weeks first, then gradually add rules
9. Summary
The core change of this refactoring is:
From “rule-driven network” → “model-driven network”
The ultimate goal is not “more granular rules”, but rather:
More stable, predictable, and maintainable network behavior
