Applicable environment for this script:
Supported system: CentOS
Memory requirement: ≥128M
Date: July 22, 2017
About this script:
One-click installation of the latest
libev version of Shadowsocks. This version features low memory usage (around 600k), low CPU
consumption, and can even be installed on OpenWRT-based routers.
Friendly reminder: If you have any questions, please refer to this article, Shadowsocks Troubleshooting, before asking.
Default configuration:
Server port: set by yourself (if not set, the default is 8989)
Password: set by yourself (if not set, the default is teddysun.com)
Encryption method: set by yourself (if not set, the default is aes-256-gcm)
Shadowsocks for Windows client download:
https://github.com/shadowsocks/shadowsocks-windows/releases
Usage:
Log in as the root user and run the following command:
wget --no-check-certificate -O shadowsocks-libev.sh https://raw.githubusercontent.com/teddysun/shadowsocks_install/master/shadowsocks-libev.sh chmod +x shadowsocks-libev.sh ./shadowsocks-libev.sh 2>&1 | tee shadowsocks-libev.log
After the installation is complete, the script will display the following:
Congratulations, Shadowsocks-libev server install completed! Your Server IP :your_server_ip Your Server Port :your_server_port Your Password :your_password Your Encryption Method:your_encryption_method Welcome to visit:https://teddysun.com/357.html Enjoy it!
Uninstallation:
Log in as the root user and run the following command:
./shadowsocks-libev.sh uninstall
Other notes:
Reference link for client configuration: https://teddysun.com/339.html
After installation is complete, Shadowsocks-libev will already be running in the background. Run:
/etc/init.d/shadowsocks status
You can check whether the process has started.
After this script is installed, Shadowsocks-libev will be added to start automatically on boot.
Commands:
Start: /etc/init.d/shadowsocks start
Stop: /etc/init.d/shadowsocks stop
Restart: /etc/init.d/shadowsocks restart
Check status: /etc/init.d/shadowsocks status
Install more versions of Shadowsocks:
ShadowsocksR
one-click installation script (CentOS, Debian, Ubuntu)
Shadowsocks Python
one-click installation script (CentOS, Debian, Ubuntu)
Shadowsocks-libev
one-click installation script for Debian
Shadowsocks-go
one-click installation script (CentOS, Debian, Ubuntu)
Changelog
July 22, 2017:
1. Fixed: the default encryption method was changed from aes-256-cfb to aes-256-gcm (the official original client supports this encryption method);
2. Added: during installation, you can choose one of 16 encryption methods, as shown below:
aes-256-gcm aes-192-gcm aes-128-gcm aes-256-ctr aes-192-ctr aes-128-ctr aes-256-cfb aes-192-cfb aes-128-cfb camellia-128-cfb camellia-192-cfb camellia-256-cfb chacha20-ietf-poly1305 chacha20-ietf chacha20 rc4-md5
February 24, 2017:
1. Restored: the function to automatically obtain the latest
release version of Shadowsocks-libev via the Github API (v3.0.3).
February 13, 2017:
1. Updated: upgraded the version to 3.0.2.
February 12, 2017:
1. Updated: upgraded the version to 3.0.1 (please download the latest script for installation).
November 05, 2016:
1. Added: check whether it is already installed; if it is, retrieve the version number and compare it with the latest version, then allow an upgrade with overwrite installation;
2. Fixed: the issue of obtaining the latest version number when not installed.
September 23, 2016:
1. Fixed: the issue where automatically obtaining the version number occasionally failed;
2. Added: automatically detect whether the VPS has an IPv6
address, and if so, add an IPv6 listening address to the configuration file.
September 17, 2016:
1. Refactored the code to automatically fetch and install the latest version from Github, eliminating the need to manually change the version number;
2. Automatically checks whether it is already installed on the local machine, and exits normally if it is already installed (if you want to install a new version, you must uninstall first);
3. Changed to downloading the tar.gz package for installation, without depending on the unzip command.
September 12, 2016:
1. Update: upgraded to version 2.5.2.
September 11, 2016:
1. Update: upgraded to version 2.5.1.
August 29, 2016:
1. Update: upgraded to version 2.5.0;
2. Fix: due to updated filenames during installation, the filenames used during uninstallation were changed to match.
July 14, 2016:
1. Update: upgraded to version 2.4.7.
July 05, 2016:
1. Fix: added the new dependencies xmlto and asciidoc;
2. Fix: due to updated filenames during installation, the filenames used during uninstallation were changed to match.
May 12, 2016:
1. Added: firewall rule settings for CentOS 7.
August 01, 2015:
1. Added: custom server port feature (if not specified, the default is 8989).
April 30, 2015:
1. Fix: the configuration file /etc/shadowsocks-libev/config.json
now enables both IPv4 and IPv6 support:
{
"server":["[::0]","0.0.0.0"],
"server_port":your_server_port,
"local_address":"127.0.0.1",
"local_port":1080,
"password":"your_password",
"timeout":600,
"method":"aes-256-cfb"
}
2. The Shadowsocks libev
version cannot support multiple ports by modifying the configuration file (it can only run multiple processes). If you need multiple ports, please install the
Python or Go version;
Special note:
1. If an old version of shadowsocks
is already installed and needs to be upgraded, download the latest version of this script and run it directly for automatic upgrade
./shadowsocks-libev.sh
Reference link:
https://github.com/shadowsocks/shadowsocks-libev
