IPv6 LXC 使用指南

IPv6 LXC 使用指南

使用IPv6連接伺服器

  1. 用IPv6直接連接
  2. 沒有IPv6的可參考這篇文章,找一台同時有IPv4和IPv6的操作:https://blog.catcatarb.com/socat-ipv4-ipv6-port/

連接Github

  1. 修改 DNS 啟用 NAT64 服務
cp /etc/resolv.conf /etc/resolv.conf.nat64.bak
nano /etc/resolv.conf
  1. 原先的nameserver先不用刪除,加「#」。然後添加以下,用完後把以下nameserver加「#」就好
nameserver 2a00:1098:2b::1
nameserver 2a01:4f9:c010:3f02::1
nameserver 2a01:4f8:c2c:123f::1
nameserver 2a00:1098:2c::1

為它加一個IPv4 socks5出口

  1. 安裝 cloudflare-warp客戶端proxychains4
參考:https://pkg.cloudflareclient.com
apt update && apt install -y curl gnupg lsb-release proxychains4

# Add cloudflare gpg key
curl -fsSL https://pkg.cloudflareclient.com/pubkey.gpg | sudo gpg --yes --dearmor --output /usr/share/keyrings/cloudflare-warp-archive-keyring.gpg

# Add this repo to your apt repositories
echo "deb [arch=amd64 signed-by=/usr/share/keyrings/cloudflare-warp-archive-keyring.gpg] https://pkg.cloudflareclient.com/ $(lsb_release -cs) main" | sudo tee /etc/apt/sources.list.d/cloudflare-client.list

# Install
sudo apt-get update && sudo apt-get install cloudflare-warp
  1. 註冊設備和修改設置
warp-cli register # 看提示輸入Y
warp-cli set-mode proxy
warp-cli set-proxy-port 2555 # 可以自行改本機監聽端口
warp-cli connect
warp-cli enable-always-on
  1. 修改 proxychains4 設置
nano /etc/proxychains4.conf
#socks4         127.0.0.1 9050 #socks4這一行加個「#」或直接刪除 
socks5 127.0.0.1 2555 #上面那個端口
  1. 測試
proxychains4 curl ip.sb
#輸出 104.xx 的 cloudflare ip

哪吒IPv4主控監控IPv6

  1. 編輯:nano /etc/systemd/system/nezha-agent.service
  2. 在 [Service] 的最下面添加
Environment="https_proxy=socks5://127.0.0.1:2555"
Environment="http_proxy=socks5://127.0.0.1:2555"
  1. 執行命令:sudo systemctl daemon-reload
  2. 重啟哪吒程序:./nezha.sh2.Standalone -> Restart Agent

hysteria2出站指南

acl:
  inline: 
   - proxy(geosite:paypal)
   - proxy(geosite:netflix)
 outbounds:
  - name: final 
    type: direct
  - name: proxy
    type: socks5
    socks5:
      addr: 127.0.0.1:2555
      username:
      password:

鳴謝Telegram用家:Baby!(@flix0808)、Riiina


媒體平臺 Media Platform

追隨我的網站 https://catcatarb.com
追隨我的Medium https://medium.com/@arbcutecat
追隨我的Facebook https://facebook.com/arb.cutecat