Shadowsocksx-ng: 如何更新 kcptun client (嘗試更新後無法訪問)

Created on 29 Dec 2018  ·  6Comments  ·  Source: shadowsocks/ShadowsocksX-NG

你好,我剛搭建起來:

  • Server (CentOS 7 with 4.18 kernel):

    • shadowsocks-libev (v3.2.3)

    • kcptun-server 20181226 版本

  • Client (MacOS 10.13):

    • ShadowsocksX-NG 1.8.2

    • kcptun (ShadowsocksX-NG 自攜帶版本 v20170718,soft link 到 ~/Library/Application\ Support/ShadowsocksX-NG/kcptun_v20170718/kcptun_client)

服務端 shadowsocks 配置:

{
  "server":["[::0]","0.0.0.0"],
  "server_port": ${SS_PORT},
  "password": "${SS_PASSWORD}",
  "method": "${SS_METHOD}",
  "mode": "tcp_and_udp",
  "timeout": 600,
  "fast_open": false
}

服務端 kcptun 配置:

{
  "listen": ":${KCPTUN_PORT}",
  "target": "127.0.0.1:${SS_PORT}",
  "key": "${KCPTUN_PASSWORD}",
  "crypt": "aes-192",
  "mode": "fast3"
}

我在 Mac 上的 ShadowsocksX-NG 設置兩種配置 (不贅述,依照服務端設置進行配置):

  • 純 shadowsocks:使用 shadowsocks-libev-server 監聽端口
  • shadowsocks + kcptun:使用 kcptun-server 監聽端口,外加 plugin 的配置

上面兩者都能科學上網,但...

問題一:使用 kcptun 下載反而變慢

http://fast.com 使用 kcptun 時下載反而比較慢、latency 也比較長 (使用另外一個測速的服務也是如此 http://www.speedtest.net):

翻牆方式 | download (Mbps) | latency: unloaded (ms) | latency: loaded (ms) | upload (Mbps)
----|:----:|:----:|:----:|:----:
純 SS | 9.5 | 94 | 154 | 8.7
SS+kcptun | 4.5 | 109 | 3000 | 12

問題:是兩者 speed test 比較方式不恰當,或是配置的問題,還是說大家使用 kcptun 真的反而下載比較慢呢?

問題二:嘗試更新 kcptun client,卻導致無法訪問

我嘗試下載跟服務端同一個版本的 kcptun Mac client (client_darwin_amd64, 20181226 版本),並將 plugins 下的 kcptun 重新 soft link 到該新版的路徑上,反而導致 Shadowsocks 無法再透過 kcptun 科學上網 (ShadowsocksX-NG 的配置都一樣,重開機也還是無法訪問):

ln -s ${path_to_latest_kcptun}/kcptun-20181226/client_darwin_amd64 ~/Library/Application\ Support/ShadowsocksX-NG/plugins/kcptun

問題:Mac 客戶端要如何更新 kcptun?

順帶一問,如何更新 shadowsocks-libev client (ss-local?)

Most helpful comment

@tkisme 厉害了,成功搞定

All 6 comments

更新kcptun client需要将shadowsocks/kcptun里面关于SIP300的提交合并到xatic/kcptun,然后使用go build client/*.go重新构建程序

我根据你的方法确实可以使用最新的kcptun客户端,感谢你提供的方法。 @alphayan

@tkisme 厉害了,成功搞定

@tkisme 牛逼!!

@tkisme 请问下,这个新编辑的文件放在哪个位置呀

更新kcptun client需要将shadowsocks/kcptun里面关于SIP300的提交合并到xatic/kcptun,然后使用go build client/*.go重新构建程序

请问直接使用shadowsocks/kcptun 来编译可以嘛?
为啥一定要合并到xatic/kcptun里面来编译呢?

Was this page helpful?
0 / 5 - 0 ratings

Related issues

jayzch picture jayzch  ·  5Comments

gnaixx picture gnaixx  ·  4Comments

qingping209 picture qingping209  ·  4Comments

ilovebamboo picture ilovebamboo  ·  4Comments

bitweng picture bitweng  ·  4Comments