Comments (5)
However, dns tags do not work this way. The tag is only used for routing, and not participating in DNS server selection.
I know exactly what i am doing.
I have two domestic DNS servers(one as primary and one as backup) with same rules/tags configured within the DNS server list, and I am intending to identitify and direct send domestic DNS traffic.
I have read the code of DNS processing, and I am sure those 2 domestic servers will be used in sequence for domestic sites.
it should be more like a bug with the parsing logic of
v2ray convert
, rather than the DNS itself.
I agree with that, too.
As I have mentioned the "merging" behaviour referred in documentation, I don't think the same-tag-merging shoud be applied to DNS configurations.
Can you check whether you can get expected behavior without any sorts of merging, just run with the config as-is?
I am using a workaround right now, by configuring different tag on different servers.
It works as expected now.
For example:
{
// omitted
"dns": {
"queryStrategy": "UseIPv4",
"fallbackStrategy": "disabled-if-any-match",
"domainMatcher": "mph",
"servers": [
{
"address": "aaa.bbb.ccc.ddd", // DNS from ISP
"port": 53,
"domains": [
"geosite:cn"
],
"tag": "dns-domestic"
},
{
"address": "114.114.114.114", // 114 public DNS as backup
"port": 53,
"domains": [
"geosite:cn"
],
"tag": "dns-domestic-backup", // <- WORKAROUND HERE
},
{
"address": "https://1.1.1.1/dns-query", // Cloudflare DoH as default fallback
"tag": "dns-international",
}
]
},
"routing": {
"domainStrategy": "IPIfNonMatch",
"domainMatcher": "mph",
"rules": [
// omitted
{
"type": "field",
"inboundTag": ["dns-domestic", "dns-domestic-backup"], // <- Don't forget to add tag here.
"outboundTag": "direct" // always direct sent domestic site DNS queries
},
{
"type": "field",
"inboundTag": "dns-international",
"outboundTag": "proxy" // proxy international cf DoH queries
}
// omitted
]
}
// omitted
}
from v2ray-core.
See it. I would seek some time to look into the code and propose a fix for it.
from v2ray-core.
What I actually got after configuration parsed:
What are your reproduction steps for What I actually got after configuration parsed
? How is the second configuration generated/printed?
from v2ray-core.
What are your reproduction steps for
What I actually got after configuration parsed
? How is the second configuration generated/printed?
The actual effective configuration is exported by adding stdout print code before+after config load.
It can also be verified by adding some print code during config build.
From what I have seen, the issue reported here can be easily reproduced with v4 JSON config format.
Other config formats are not tested.
from v2ray-core.
@povsister Can reproduce with v2ray convert
.
However, dns tags do not work this way. The tag is only used for routing, and not participating in DNS server selection. It should be more like a bug with the parsing logic of v2ray convert
, rather than the DNS itself.
Can you check whether you can get expected behavior without any sorts of merging, just run with the config as-is?
from v2ray-core.
Related Issues (20)
- 透明代理无法使用 fakedns HOT 2
- 服务端异常退出 "panic: concurrent write to websocket connection" HOT 1
- log missing during core start/stop HOT 1
- V2ray's problem with fedora HOT 1
- V2ray 如何将vmess url翻译成json? HOT 1
- 节点连接成功了为什么还登不上Tik Tok HOT 2
- Leaking Public IP address
- ws transport writes/reads invalid data HOT 2
- V5 格式配置 ws.header 报错 HOT 2
- Can't access via Linux, but works on windows and ios
- 日志输出大量 rejected common/drain: common/drain: unable to drain connection > EOF > proxy/shadowsocks: failed to read IV > EOF
- 服务端开启Shadowsocks的UDP设置之后必须在防火墙添加与Shadowsocks入站TCP端口一致的UDP端口才能使UDP流入
- V5 格式无法配置 dns expectIPs HOT 1
- 订阅服务器解析 vless 链接不成功
- 建议为sniffing增加route_only选项或判断destOverride的域名是否有效以增强对Tor的兼容性 HOT 1
- kali linux 上使用V2RAY, 必须要在浏览器里指定代理,才能用,但是系统其他应用还是不能被代理,请问怎么样设置才能实现系统级代理
- A bug encountered when loading configuration text via STDIN HOT 1
- failed to read response from cachefly.cachefly.net > io: read/write on closed pipe and no access via v2rayn HOT 1
- Flutter iOS v2ray-core plugin
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from v2ray-core.