Hysteria2 部署笔记

1. 安装与初始化 Hysteria2 提供了一键安装脚本,支持大部分 Linux 发行版 1 2 # 执行官方安装脚本 bash <(curl -fsSL [https://get.hy2.sh/](https://get.hy2.sh/)) 安装完成后,主程序位于 /usr/local/bin/hysteria,配置文件默认位于 /etc/hysteria/config.yaml 2. 服务端配置 (YAML) 以下配置启用了 ACME 自动证书申请、HTTP 后端认证以及 反向代理伪装 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 # /etc/hysteria/config.yaml listen: :443 acme: domains: - your.domain.net # 替换为你的解析好的域名 email: your@email.com # 接收证书通知的邮箱 auth: # 使用 HTTP 认证模式,适合对接自己的用户管理系统 http: url: [http://your.backend.com/auth](http://your.backend.com/auth) insecure: false masquerade: type: proxy proxy: url: [https://news.ycombinator.com/](https://news.ycombinator.com/) # 流量探测时伪装的目标 rewriteHost: true 3. 核心黑科技:端口跳跃 (Port Hopping) 由于部分运营商会对单一 UDP 端口进行限速或断流,通过 iptables 实现多端口转发(端口跳跃)可以显著提升稳定性 ...

December 30, 2025 · 谦兰君

VLESS + Reality + Vision 部署笔记

1. 准备工作 1.1 选择目标域名 Reality 需要一个目标域名作为伪装。理想的选择是:国外知名、支持 TLSv1.3、且在国内访问延迟较低的网站 辅助工具:DNSlytics (用于查询同 IP 下的优质域名) 1.2 系统网络优化 在部署前,建议开启 BBRv3 或进行 TCP 优化以提升吞吐量 安装 BBRv3: 1 bash <(curl -l -s [https://raw.githubusercontent.com/byJoey/Actions-bbr-v3/refs/heads/main/install.sh](https://raw.githubusercontent.com/byJoey/Actions-bbr-v3/refs/heads/main/install.sh)) 综合 TCP 优化脚本: 1 wget -O tcpx.sh "[https://github.com/ylx2016/Linux-NetSpeed/raw/master/tcpx.sh](https://github.com/ylx2016/Linux-NetSpeed/raw/master/tcpx.sh)" && chmod +x tcpx.sh && ./tcpx.sh 2. 安装与环境配置 2.1 安装 Xray 核心 使用官方脚本一键安装: 1 bash -c "$(curl -L [https://github.com/XTLS/Xray-install/raw/main/install-release.sh](https://github.com/XTLS/Xray-install/raw/main/install-release.sh))" @ install 2.2 生成必要参数 在配置前,需要生成 UUID 以及 Reality 专用的密钥对 生成 UUID: 1 2 xray uuid # 输出示例:2233ebed-68b0-4606-a241-1be5f8ad4668 生成 x25519 密钥对: 1 2 3 xray x25519 # PrivateKey: aIRW_Eh8-n8JEmkHFRxQeHnBipHrxt6OrIbAeUVr12s # PublicKey: YLr6CDT0jCxaxZaDypHnOZzB4D83MWLwR06nSWykzBI 3. 服务端配置 编辑配置文件:/usr/local/etc/xray/config.json ...

December 30, 2025 · 谦兰君