Configuring and Optimizing Shadowsocks Rust

During the recent holiday, I reorganized the home network with the goal of streaming 4K content without buffering. Since I was rebuilding the server anyway, I decided to migrate from the old setup to the new shadowsocks-rust implementation. System Update 1 sudo apt update && sudo apt upgrade Installing and Configuring SS Option 1: Build from Source via Cargo 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 # Install Rust toolchain curl https://sh.rustup.rs -sSf | sh # Configure Cargo environment (add to .profile / .bash_profile) # CARGO_HOME sets the installation path # target-cpu=native lets rustc optimize for the current CPU CARGO_HOME=/root/cargo RUSTFLAGS="-C target-cpu=native" source .profile # Install build dependencies sudo apt install build-essential # Install shadowsocks-rust cargo install shadowsocks-rust Option 2: Download Prebuilt Binary 1 2 3 4 wget https://github.com/shadowsocks/shadowsocks-rust/releases/download/v1.14.3/shadowsocks-v1.14.3.x86_64-unknown-linux-gnu.tar.xz tar -xf shadowsocks-v1.14.3.x86_64-unknown-linux-gnu.tar.xz cp ssserver /usr/local/bin chmod a+x /usr/local/bin/ssserver Configuration 1 2 mkdir /etc/shadowsocks vi /etc/shadowsocks/config.json 1 2 3 4 5 6 { "server": "::", "server_port": 8888, "method": "aes-256-gcm", "password": "pw" } Test the server: ...

May 6, 2022 · 3 min · haoxiqiang

Shadowsocks Setup and Optimization

Network instability at the office was affecting work, so I set up a Shadowsocks server on my VPS for source code pulls. The steps below work on most Linux distributions and have been tested on Ubuntu 16.04 and 18.04. 2024 Update: The Python version of shadowsocks used in this guide is no longer maintained. The actively maintained implementation is shadowsocks-rust, which offers better performance and support for modern encryption protocols. For a fresh setup, refer to the shadowsocks-rust documentation. The original Python-based steps are preserved below for reference. ...

December 31, 2019 · 3 min · haoxiqiang