From 117bb3602bb4a85f35157f55e640556985db1629 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=A3=8E=E6=89=87=E6=BB=91=E7=BF=94=E7=BF=BC?= Date: Wed, 25 Dec 2024 02:38:55 +0800 Subject: [PATCH] Update log.md --- docs/en/config/log.md | 43 ++++++------------------------------------- 1 file changed, 6 insertions(+), 37 deletions(-) diff --git a/docs/en/config/log.md b/docs/en/config/log.md index f604393..0095a36 100644 --- a/docs/en/config/log.md +++ b/docs/en/config/log.md @@ -50,45 +50,14 @@ The log level for error logs, indicating the information that needs to be record Log DNS queries made by built-in [DNS clients](./dns.md) to the access log. Example log record: `DOH//doh.server got answer: domain.com -> [ip1, ip2] 2.333ms`. -::: tip TIP 1 -Xray doesn't perform all DNS queries via its built-in clients. Therefore, enabling this option doesn't mean that all DNS queries performed by Xray will be logged. +::: tip +1. Xray doesn't perform all DNS queries via its built-in clients. Therefore, enabling this option doesn't mean that all DNS queries performed by Xray will be logged. + +2. DNS queries made by built-in [DNS clients](./dns.md) are also logged to the error log (with "Info" level) even if this option is disabled. +3. +4. FakeDNS client queries are never logged to the access log. ::: -::: tip TIP 2 -DNS queries made by built-in [DNS clients](./dns.md) are also logged to the error log (with "Info" level) even if this option is disabled. -::: - -::: tip TIP 3 -FakeDNS client queries are never logged to the access log. -::: - -Below is a client config example that allows you to see DNS logs. No server needed. - -```json -{ - "log": { - "dnsLog": true - }, - "dns": { - "servers": ["https://1.1.1.1/dns-query"] - }, - "inbounds": [ - { - "listen": "0.0.0.0", - "port": 1984, - "protocol": "socks" - } - ], - "outbounds": [ - { - "protocol": "freedom", - "settings": { - "domainStrategy": "UseIPv4" - } - } - ] -} -``` > `maskAddress`: "quarter" | "half" | "full"