mirror of
https://github.com/XTLS/Xray-docs-next.git
synced 2026-10-06 05:48:17 +03:00
Fix prettier format with version 3.6.2
This commit is contained in:
@@ -40,12 +40,10 @@ Xray provides two verification methods:
|
||||
### Install Script
|
||||
|
||||
- Linux Script
|
||||
|
||||
- [XTLS/Xray-install](https://github.com/XTLS/Xray-install) (**Official**)
|
||||
- [tempest](https://github.com/team-cloudchaser/tempest) (supports [`systemd`](https://systemd.io) and [OpenRC](https://github.com/OpenRC/openrc); Linux-only)
|
||||
|
||||
* One Click
|
||||
|
||||
- [Xray-REALITY](https://github.com/zxcvos/Xray-script), [xray-reality](https://github.com/sajjaddg/xray-reality), [reality-ezpz](https://github.com/aleskxyz/reality-ezpz)
|
||||
- [Xray_bash_onekey](https://github.com/hello-yunshu/Xray_bash_onekey), [XTool](https://github.com/LordPenguin666/XTool)
|
||||
- [v2ray-agent](https://github.com/mack-a/v2ray-agent), [Xray_onekey](https://github.com/wulabing/Xray_onekey), [ProxySU](https://github.com/proxysu/ProxySU)
|
||||
|
||||
@@ -95,7 +95,6 @@ If you are not using the username `vpsadmin`, please be sure to understand the m
|
||||
```
|
||||
|
||||
5. Modify `nginx.conf` and restart the `Nginx` service, directing the http access on port 80 to the newly created `html` page.
|
||||
|
||||
1. Modify `nginx.conf`.
|
||||
|
||||
```shell
|
||||
|
||||
@@ -90,7 +90,6 @@ chmod +r ~/xray_cert/xray.key
|
||||

|
||||
|
||||
5. `acme.sh` will check the certificate every 60 days and automatically renew the expiring certificate. But as far as I know, it does not automatically install the new certificate to `xray-core`, so we need to add a system automatic periodic task to complete this step.
|
||||
|
||||
1. Basic Linux commands for beginners:
|
||||
|
||||
| Number | Command name | Command description |
|
||||
@@ -124,7 +123,6 @@ chmod +r ~/xray_cert/xray.key
|
||||
In addition, when recording animated images, the script did not include a command to restart `Xray` because `Xray` plans to support the [Certificate Hot Update] function, which means that `Xray` will automatically identify certificate updates and reload certificates without manual restart. After the function is added, I will modify `config.json` appropriately
|
||||
to enable this setting and delete the restart command in the script.
|
||||
:::
|
||||
|
||||
4. Add [executable] permissions to this file
|
||||
|
||||
```
|
||||
@@ -160,7 +158,6 @@ First, you can refer to the [official VLESS configuration example](https://githu
|
||||
```
|
||||
|
||||
2. Create log files and folders for backup
|
||||
|
||||
1. Basic Linux commands for beginners:
|
||||
| Number | Command name | Command description |
|
||||
|:--:|:--:|:--:|
|
||||
@@ -181,7 +178,6 @@ First, you can refer to the [official VLESS configuration example](https://githu
|
||||
::: warning
|
||||
This location is not the standard log file location of `Xray`. It is placed here to avoid permission issues that cause trouble for new users. Once you are familiar with it, it is recommended to return to the default location: `/var/log/xray/access.log` and `/var/log/xray/error.log`.
|
||||
:::
|
||||
|
||||
4. Because Xray is used by the nobody user by default, we need to allow other users to have "write" permissions (`*.log` means all files with the suffix `log`, and the efficiency advantage of the `CLI` interface gradually appears at this time)
|
||||
```shell
|
||||
chmod a+w ~/xray_log/*.log
|
||||
@@ -403,7 +399,6 @@ If your line really has a very high packet loss rate, the only reliable solution
|
||||
:::
|
||||
|
||||
6. I have said so much because there are too many misconceptions and scam scripts around `BBR` to fool novices. I hope you now have a relatively clear understanding of `BBR`. Next, let's install the latest Debian kernel and enable `BBR`! (It's really simple)
|
||||
|
||||
1. Add the official `backports` source to Debian 10 to get the updated software library
|
||||
|
||||
```shell
|
||||
@@ -415,7 +410,6 @@ If your line really has a very high packet loss rate, the only reliable solution
|
||||
distributions, it is recommended that you create a `/etc/apt/sources.list.d/` folder and create your own configuration file in this folder, such as `/etc/apt/sources.list.d/vpsadmin.list`
|
||||
, to ensure compatibility and avoid the default file being overwritten in unforeseen circumstances and causing configuration loss.
|
||||
:::
|
||||
|
||||
2. Then add the following item at the end, save and exit.
|
||||
|
||||
```
|
||||
@@ -433,12 +427,10 @@ If your line really has a very high packet loss rate, the only reliable solution
|
||||
If your VPS supports it, you can try the [cloud server dedicated kernel] `linux-image-cloud-amd64`. The advantages are simplicity and low resource usage. The disadvantage is that some students have reported that forced installation on an unsupported system will cause the system to fail to boot (the kernel cannot be recognized).
|
||||
|
||||
To avoid the tragedy of being unable to identify, please make sure:
|
||||
|
||||
- Take a system snapshot before trying, or
|
||||
- You have `vnc` to save the day (and you know how to use it)
|
||||
|
||||
:::
|
||||
|
||||
4. Modify the `kernel` parameter configuration file `sysctl.conf` and specify to enable `BBR`
|
||||
|
||||
```shell
|
||||
@@ -450,7 +442,6 @@ If your line really has a very high packet loss rate, the only reliable solution
|
||||
folder and create your own configuration file in this folder, such as `/etc/sysctl.d/vpsadmin.conf`, to ensure compatibility, because some distributions no longer read parameters from `/etc/sysctl.conf` after `systemd`
|
||||
207 version. Using a custom configuration file can also prevent the default file from being overwritten in unexpected circumstances, resulting in configuration loss.
|
||||
:::
|
||||
|
||||
5. Add the following content
|
||||
|
||||
```
|
||||
@@ -473,7 +464,6 @@ If your line really has a very high packet loss rate, the only reliable solution
|
||||
:::
|
||||
|
||||

|
||||
|
||||
8. Confirm that `BBR` is enabled
|
||||
|
||||
If you want to confirm whether `BBR` is enabled correctly, you can use the following command:
|
||||
|
||||
@@ -11,7 +11,6 @@
|
||||
1. APP 要主动或借助转发工具,将数据【流入(`inbounds`)】`Xray` 客户端
|
||||
|
||||
2. 流量进入客户端后,会被【客户端路由(`routing`)】按规则处理后,向不同方向【流出`(outbounds)`】`Xray` 客户端。比如:
|
||||
|
||||
1. 国内流量直连(`direct`)
|
||||
2. 国外流量转发 VPS(`proxy`)
|
||||
3. 广告流量屏蔽(`block`)
|
||||
@@ -52,23 +51,19 @@
|
||||
:::
|
||||
|
||||
- **v2rayN - 适用于 Windows 平台**
|
||||
|
||||
- 请从它的[GitHub 仓库 Release 页面](https://github.com/2dust/v2rayN/releases)获取最新版
|
||||
- 请根据该客户端的说明进行设置
|
||||
|
||||
- **v2rayNG - 适用于 Android 平台**
|
||||
|
||||
- 请从它的[GitHub 仓库 Release 页面](https://github.com/2dust/v2rayNG/releases)获取最新版
|
||||
- 请根据该客户端的说明进行设置
|
||||
|
||||
- **Shadowrocket - 适用于 iOS, 基于苹果 M 芯片的 macOS**
|
||||
|
||||
- 你需要注册一个【非中国区】的 iCloud 账户
|
||||
- 你需要通过 App Store 搜索并购买
|
||||
- 请根据该客户端的说明进行设置
|
||||
|
||||
- **Qv2ray - 跨平台图形界面,适用于 Linux, Windows, macOS**
|
||||
|
||||
- 请从它的[GitHub 仓库 Release 页面](https://github.com/Qv2ray/Qv2ray/releases)获取最新版(还可以从它的[GitHub 自动构建仓库](https://github.com/Qv2ray/Qv2ray/actions)寻找更新的版本)
|
||||
- 请从它的[项目主页](https://qv2ray.net/)学习文档
|
||||
- 请根据该客户端的说明进行设置
|
||||
@@ -98,7 +93,6 @@
|
||||
2. 在合适的文件夹建立空白配置文件:`config.json` (自己常用平台下新建文件大家肯定都会,这就真不用啰嗦了)
|
||||
3. 至于什么是“合适的文件夹”?这就取决于具体的平台了~
|
||||
4. 填写客户端配置
|
||||
|
||||
- 我就以 `8.1` 原理说明里展示的基本三类分流(国内流量直连、国际流量转发 VPS、广告流量屏蔽),结合 `8.2` 的连接要素,写成一个配置文件
|
||||
- 请将 `uuid` 替换成与你服务器一致的 `uuid`
|
||||
- 请将 `address` 替换成你的真实域名
|
||||
|
||||
@@ -198,7 +198,6 @@
|
||||
`vless` 协议流量直接流入 `Xray` 中做后续处理
|
||||
|
||||
3. **非 `VLESS` 协议流量有 4 个不同的回落目标:**
|
||||
|
||||
1. `path` 为 `websocket` 的流量,回落给端口 `1234` 后续处理
|
||||
2. `path` 为 `vmesstcp` 的流量,回落给端口 `2345` 后续处理
|
||||
3. `path` 为 `vmessws` 的流量,回落给端口 `3456` 后续处理
|
||||
@@ -260,7 +259,6 @@
|
||||
```
|
||||
|
||||
看,神奇的事情发生了, `trojan` 协议这里又出现了一个新的 `fallbacks`。前面已经说过,`xray` 中的 `trojan` 协议也具有完整的回落能力,所以,此时 `trojan` 协议可以再次做判断和回落(这也就是传说中的套娃回落了):
|
||||
|
||||
- 所有 `trojan` 协议的流量,流入 `Xray` 中做后续处理
|
||||
- 所有非 `trojan` 协议的流量,转发至 `80` 端口,【主动探测】的防御,完成!
|
||||
|
||||
|
||||
Reference in New Issue
Block a user