
realm转发教程,纯V4—V6,纯V6—V6转发
realm转发教程,纯V4—V6,纯V6—V6转发
1. 下载解压realm
wget -O realm.tar.gz https://pan.bobqu.cyou/Code/realm-x86_64-unknown-linux-gnu.tar.gz
tar -xvf realm.tar.gz
chmod +x realm
2.realm配置
1.V4—V6转发
cat > /root/config.toml <<EOF
[[endpoints]]
listen = "0.0.0.0:8000"
remote = "1.1.1.1:443"
[[endpoints]]
listen = "本机V4:本机端口"
remote = "[落地鸡V6]:落地鸡端口"
[network]
no_tcp = false
use_udp = true
EOF
2.纯V6—V6转发
cat > /root/config.toml <<EOF
[[endpoints]]
listen = "0.0.0.0:8000"
remote = "1.1.1.1:443"
[[endpoints]]
listen = "[本机V6]:本机端口"
remote = "[落地鸡V6]:落地鸡端口"
[network]
no_tcp = false
use_udp = true
EOF
3.编辑启动服务
cat > /etc/systemd/system/realm.service <<EOF
[Unit]
Description=realm
After=network-online.target
Wants=network-online.target systemd-networkd-wait-online.service
[Service]
Type=simple
User=root
Restart=on-failure
RestartSec=5s
DynamicUser=true
WorkingDirectory=/root
ExecStart=/root/realm -c /root/config.toml
[Install]
WantedBy=multi-user.target
EOF
4.启动realm
systemctl daemon-reload
systemctl enable realm
systemctl restart realm
systemctl status realm