<?xml version="1.0" encoding="utf-8"?>
<?xml-stylesheet href="https://www.bigdick.live/feed_style.xsl" type="text/xsl"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
    <tabi:metadata xmlns:tabi="https://github.com/welpo/tabi">
        <tabi:base_url>https:&#x2F;&#x2F;www.bigdick.live</tabi:base_url>
        <tabi:separator>
            •
        </tabi:separator>
        <tabi:about_feeds>This is a web feed, also known as an Atom feed. Subscribe by copying the URL from the address bar into your newsreader. Visit About Feeds to learn more and get started. It&#x27;s free.</tabi:about_feeds>
        <tabi:visit_the_site>Visit website</tabi:visit_the_site>
        <tabi:recent_posts>Recent posts</tabi:recent_posts>
        <tabi:last_updated_on>Updated on $DATE</tabi:last_updated_on>
        <tabi:default_theme></tabi:default_theme>
        <tabi:post_listing_date>date</tabi:post_listing_date>
        <tabi:current_section>Network</tabi:current_section>
    </tabi:metadata><link rel="extra-stylesheet" href="https://www.bigdick.live/skins/black-orange.css?h=c64b7f81e34a143cd725" /><title>Yu Sun - Network</title>
        <subtitle>Yu Sun&#x27;s personal site for bioinformatics, data science, software engineering, public resume, projects, and posts.</subtitle>
    <link href="https://www.bigdick.live/en/tags/network/atom.xml" rel="self" type="application/atom+xml"/>
    <link href="https://www.bigdick.live/en/tags/network/" rel="alternate" type="text/html"/>
    <generator uri="https://www.getzola.org/">Zola</generator><updated>2017-02-15T00:00:00+00:00</updated><id>https://www.bigdick.live/en/tags/network/atom.xml</id><entry xml:lang="en">
        <title>Break through GFW blockade with shadowsocks (built on Digital Ocean or AWS)</title>
        <published>2017-02-15T00:00:00+00:00</published>
        <updated>2017-02-15T00:00:00+00:00</updated>
        <author>
            <name>Yu Sun</name>
        </author>
        <link rel="alternate" href="https://www.bigdick.live/en/blog/break-through-gfw/" type="text/html"/>
        <id>https://www.bigdick.live/en/blog/break-through-gfw/</id>
        
            <content type="html">&lt;h2 id=&quot;on-digital-ocean&quot;&gt;On &lt;em&gt;Digital Ocean&lt;&#x2F;em&gt;&lt;&#x2F;h2&gt;
&lt;ol&gt;
&lt;li&gt;If you’re a student, try apply for a &lt;a class=&quot;external&quot; rel=&quot;noopener external&quot; target=&quot;_blank&quot; href=&quot;https:&#x2F;&#x2F;education.github.com&#x2F;pack&#x2F;&quot;&gt;student pack&lt;&#x2F;a&gt; on &lt;em&gt;GitHub&lt;&#x2F;em&gt;.&lt;&#x2F;li&gt;
&lt;li&gt;Use code of &lt;em&gt;Digital Ocean&lt;&#x2F;em&gt; in student pack to register a &lt;strong&gt;new account&lt;&#x2F;strong&gt; and buy a droplet at &lt;em&gt;San Fransico&lt;&#x2F;em&gt; (both node 1 &amp;amp; 2 is OK, maybe 2 is better).&lt;&#x2F;li&gt;
&lt;li&gt;Install &lt;em&gt;Fedora 25 (64 bit)&lt;&#x2F;em&gt; on your VPS then do as below:&lt;&#x2F;li&gt;
&lt;&#x2F;ol&gt;
&lt;p&gt;Install shadowsocks:&lt;&#x2F;p&gt;
&lt;pre class=&quot;giallo z-code&quot;&gt;&lt;code data-lang=&quot;shellscript&quot;&gt;&lt;span class=&quot;giallo-l&quot;&gt;&lt;span class=&quot;z-entity z-name z-function&quot;&gt;sudo&lt;&#x2F;span&gt;&lt;span class=&quot;z-string&quot;&gt; dnf install m2crypto python-setuptools&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;
&lt;span class=&quot;giallo-l&quot;&gt;&lt;span class=&quot;z-entity z-name z-function&quot;&gt;easy_install&lt;&#x2F;span&gt;&lt;span class=&quot;z-string&quot;&gt; pip&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;
&lt;span class=&quot;giallo-l&quot;&gt;&lt;span class=&quot;z-entity z-name z-function&quot;&gt;pip&lt;&#x2F;span&gt;&lt;span class=&quot;z-string&quot;&gt; install shadowsocks&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;&lt;&#x2F;code&gt;&lt;&#x2F;pre&gt;
&lt;p&gt;Shadowsocks use a json file as configuration. For all users, this file can be placed in &lt;code&gt;&#x2F;etc&lt;&#x2F;code&gt;.
Use &lt;code&gt;vi  &#x2F;etc&#x2F;shadowsocks.json&lt;&#x2F;code&gt; to edit the file and fill in contents below:&lt;&#x2F;p&gt;
&lt;pre class=&quot;giallo z-code&quot;&gt;&lt;code data-lang=&quot;json&quot;&gt;&lt;span class=&quot;giallo-l&quot;&gt;&lt;span class=&quot;z-punctuation&quot;&gt;{&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;
&lt;span class=&quot;giallo-l&quot;&gt;&lt;span class=&quot;z-punctuation&quot;&gt;    &amp;quot;&lt;&#x2F;span&gt;&lt;span class=&quot;z-support z-type z-property-name z-json&quot;&gt;server&lt;&#x2F;span&gt;&lt;span class=&quot;z-punctuation&quot;&gt;&amp;quot;:&lt;&#x2F;span&gt;&lt;span class=&quot;z-punctuation z-definition z-string z-string&quot;&gt;&amp;quot;0.0.0.0&amp;quot;&lt;&#x2F;span&gt;&lt;span class=&quot;z-punctuation&quot;&gt;,&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;
&lt;span class=&quot;giallo-l&quot;&gt;&lt;span class=&quot;z-punctuation&quot;&gt;    &amp;quot;&lt;&#x2F;span&gt;&lt;span class=&quot;z-support z-type z-property-name z-json&quot;&gt;server_port&lt;&#x2F;span&gt;&lt;span class=&quot;z-punctuation&quot;&gt;&amp;quot;:&lt;&#x2F;span&gt;&lt;span class=&quot;z-punctuation z-definition z-string z-string&quot;&gt;&amp;quot;port&amp;quot;&lt;&#x2F;span&gt;&lt;span class=&quot;z-punctuation&quot;&gt;,&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;
&lt;span class=&quot;giallo-l&quot;&gt;&lt;span class=&quot;z-punctuation&quot;&gt;    &amp;quot;&lt;&#x2F;span&gt;&lt;span class=&quot;z-support z-type z-property-name z-json&quot;&gt;local_address&lt;&#x2F;span&gt;&lt;span class=&quot;z-punctuation&quot;&gt;&amp;quot;:&lt;&#x2F;span&gt;&lt;span class=&quot;z-punctuation z-definition z-string z-string&quot;&gt; &amp;quot;127.0.0.1&amp;quot;&lt;&#x2F;span&gt;&lt;span class=&quot;z-punctuation&quot;&gt;,&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;
&lt;span class=&quot;giallo-l&quot;&gt;&lt;span class=&quot;z-punctuation&quot;&gt;    &amp;quot;&lt;&#x2F;span&gt;&lt;span class=&quot;z-support z-type z-property-name z-json&quot;&gt;local_port&lt;&#x2F;span&gt;&lt;span class=&quot;z-punctuation&quot;&gt;&amp;quot;:&lt;&#x2F;span&gt;&lt;span class=&quot;z-constant z-numeric&quot;&gt;1080&lt;&#x2F;span&gt;&lt;span class=&quot;z-punctuation&quot;&gt;,&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;
&lt;span class=&quot;giallo-l&quot;&gt;&lt;span class=&quot;z-punctuation&quot;&gt;    &amp;quot;&lt;&#x2F;span&gt;&lt;span class=&quot;z-support z-type z-property-name z-json&quot;&gt;password&lt;&#x2F;span&gt;&lt;span class=&quot;z-punctuation&quot;&gt;&amp;quot;:&lt;&#x2F;span&gt;&lt;span class=&quot;z-punctuation z-definition z-string z-string&quot;&gt;&amp;quot;passwd&amp;quot;&lt;&#x2F;span&gt;&lt;span class=&quot;z-punctuation&quot;&gt;,&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;
&lt;span class=&quot;giallo-l&quot;&gt;&lt;span class=&quot;z-punctuation&quot;&gt;    &amp;quot;&lt;&#x2F;span&gt;&lt;span class=&quot;z-support z-type z-property-name z-json&quot;&gt;timeout&lt;&#x2F;span&gt;&lt;span class=&quot;z-punctuation&quot;&gt;&amp;quot;:&lt;&#x2F;span&gt;&lt;span class=&quot;z-constant z-numeric&quot;&gt;300&lt;&#x2F;span&gt;&lt;span class=&quot;z-punctuation&quot;&gt;,&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;
&lt;span class=&quot;giallo-l&quot;&gt;&lt;span class=&quot;z-punctuation&quot;&gt;    &amp;quot;&lt;&#x2F;span&gt;&lt;span class=&quot;z-support z-type z-property-name z-json&quot;&gt;method&lt;&#x2F;span&gt;&lt;span class=&quot;z-punctuation&quot;&gt;&amp;quot;:&lt;&#x2F;span&gt;&lt;span class=&quot;z-punctuation z-definition z-string z-string&quot;&gt;&amp;quot;rc4-md5&amp;quot;&lt;&#x2F;span&gt;&lt;span class=&quot;z-punctuation&quot;&gt;,&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;
&lt;span class=&quot;giallo-l&quot;&gt;&lt;span class=&quot;z-punctuation&quot;&gt;    &amp;quot;&lt;&#x2F;span&gt;&lt;span class=&quot;z-support z-type z-property-name z-json&quot;&gt;fast_open&lt;&#x2F;span&gt;&lt;span class=&quot;z-punctuation&quot;&gt;&amp;quot;:&lt;&#x2F;span&gt;&lt;span class=&quot;z-constant z-language z-json&quot;&gt; false&lt;&#x2F;span&gt;&lt;span class=&quot;z-punctuation&quot;&gt;,&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;
&lt;span class=&quot;giallo-l&quot;&gt;&lt;span class=&quot;z-punctuation&quot;&gt;    &amp;quot;&lt;&#x2F;span&gt;&lt;span class=&quot;z-support z-type z-property-name z-json&quot;&gt;workers&lt;&#x2F;span&gt;&lt;span class=&quot;z-punctuation&quot;&gt;&amp;quot;:&lt;&#x2F;span&gt;&lt;span class=&quot;z-constant z-numeric&quot;&gt; 1&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;
&lt;span class=&quot;giallo-l&quot;&gt;&lt;span class=&quot;z-punctuation&quot;&gt;}&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;&lt;&#x2F;code&gt;&lt;&#x2F;pre&gt;
&lt;p&gt;To keep shadowsocks running in background after you cut off SSH connection, you may use &lt;code&gt;supervisor&lt;&#x2F;code&gt;.&lt;&#x2F;p&gt;
&lt;pre class=&quot;giallo z-code&quot;&gt;&lt;code data-lang=&quot;shellscript&quot;&gt;&lt;span class=&quot;giallo-l&quot;&gt;&lt;span class=&quot;z-entity z-name z-function&quot;&gt;sudo&lt;&#x2F;span&gt;&lt;span class=&quot;z-string&quot;&gt; dnf install supervisor&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;
&lt;span class=&quot;giallo-l&quot;&gt;&lt;span class=&quot;z-entity z-name z-function&quot;&gt;echo_supervisord_conf&lt;&#x2F;span&gt;&lt;span class=&quot;z-keyword z-operator&quot;&gt; &amp;gt;&lt;&#x2F;span&gt;&lt;span class=&quot;z-string&quot;&gt; &#x2F;etc&#x2F;supervisord.conf&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;&lt;&#x2F;code&gt;&lt;&#x2F;pre&gt;
&lt;p&gt;Execute &lt;code&gt;vi &#x2F;etc&#x2F;supervisord.conf&lt;&#x2F;code&gt; to configure it:&lt;&#x2F;p&gt;
&lt;pre class=&quot;giallo z-code&quot;&gt;&lt;code data-lang=&quot;plain&quot;&gt;&lt;span class=&quot;giallo-l&quot;&gt;&lt;span&gt;[program:shadowsocks]&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;
&lt;span class=&quot;giallo-l&quot;&gt;&lt;span&gt;command=ssserver -c &#x2F;etc&#x2F;shadowsocks.json&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;
&lt;span class=&quot;giallo-l&quot;&gt;&lt;span&gt;autostart=true&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;
&lt;span class=&quot;giallo-l&quot;&gt;&lt;span&gt;autorestart=true&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;
&lt;span class=&quot;giallo-l&quot;&gt;&lt;span&gt;user=nobody&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;&lt;&#x2F;code&gt;&lt;&#x2F;pre&gt;
&lt;p&gt;Finally, &lt;code&gt;supervisord&lt;&#x2F;code&gt; or &lt;code&gt;supervisord -c &#x2F;etc&#x2F;supervisord.conf&lt;&#x2F;code&gt; to start shadowsocks server and visit &lt;a class=&quot;external&quot; rel=&quot;noopener external&quot; target=&quot;_blank&quot; href=&quot;https:&#x2F;&#x2F;github.com&#x2F;shadowsocks&quot;&gt;the project’s homepage&lt;&#x2F;a&gt; on GitHub for a client.
For Windows user, try https:&#x2F;&#x2F;github.com&#x2F;shadowsocks&#x2F;shadowsocks-windows&#x2F;releases.
For Linux user, &lt;a class=&quot;external&quot; rel=&quot;noopener external&quot; target=&quot;_blank&quot; href=&quot;https:&#x2F;&#x2F;github.com&#x2F;shadowsocks&#x2F;shadowsocks-qt5&#x2F;releases&quot;&gt;shadowsocks-qt5&lt;&#x2F;a&gt; is a good choice.
There’re also &lt;a class=&quot;external&quot; rel=&quot;noopener external&quot; target=&quot;_blank&quot; href=&quot;https:&#x2F;&#x2F;github.com&#x2F;shadowsocks&#x2F;shadowsocks-android&#x2F;releases&quot;&gt;shadowsocks for Android&lt;&#x2F;a&gt; and &lt;a class=&quot;external&quot; rel=&quot;noopener external&quot; target=&quot;_blank&quot; href=&quot;https:&#x2F;&#x2F;github.com&#x2F;shadowsocks&#x2F;shadowsocks-iOS&#x2F;releases&quot;&gt;shadowsocks for iOS&lt;&#x2F;a&gt;.&lt;&#x2F;p&gt;
&lt;h3 id=&quot;appendix&quot;&gt;Appendix&lt;&#x2F;h3&gt;
&lt;p&gt;&lt;code&gt;supervisorctl status&lt;&#x2F;code&gt; for checking all processes’ status controlled by &lt;em&gt;supervisor&lt;&#x2F;em&gt;.&lt;&#x2F;p&gt;
&lt;p&gt;&lt;code&gt;supervisorctl stop ssserver&lt;&#x2F;code&gt; for kill a process.&lt;&#x2F;p&gt;
&lt;p&gt;&lt;code&gt;supervisorctl start ssserver&lt;&#x2F;code&gt; for start a process.&lt;&#x2F;p&gt;
&lt;p&gt;&lt;code&gt;supervisorctl shutdown&lt;&#x2F;code&gt; for killing all processes controlled by &lt;em&gt;supervisor&lt;&#x2F;em&gt;.&lt;&#x2F;p&gt;
&lt;h3 id=&quot;known-issue&quot;&gt;Known issue&lt;&#x2F;h3&gt;
&lt;p&gt;Sometimes shadowsocks works fine in &lt;em&gt;Windows&lt;&#x2F;em&gt;,
but your browser can not visit pages in &lt;em&gt;Arch Linux&lt;&#x2F;em&gt;,
it is because that too frequently updating &lt;code&gt;libQtShadowsocks&lt;&#x2F;code&gt; brings conflict.&lt;&#x2F;p&gt;
&lt;p&gt;To &lt;a class=&quot;external&quot; rel=&quot;noopener external&quot; target=&quot;_blank&quot; href=&quot;https:&#x2F;&#x2F;github.com&#x2F;shadowsocks&#x2F;shadowsocks-qt5&#x2F;issues&#x2F;550&quot;&gt;solve this problem&lt;&#x2F;a&gt;,
you can downgrade &lt;code&gt;libQtShadowsocks&lt;&#x2F;code&gt; or change the encryption method from &lt;code&gt;AES-256-CFB&lt;&#x2F;code&gt; to &lt;code&gt;AES-256-CTR&lt;&#x2F;code&gt;.&lt;&#x2F;p&gt;
&lt;h2 id=&quot;on-aws&quot;&gt;On &lt;em&gt;AWS&lt;&#x2F;em&gt;&lt;&#x2F;h2&gt;
&lt;ol&gt;
&lt;li&gt;
&lt;p&gt;Creat an &lt;em&gt;EC2&lt;&#x2F;em&gt; (choose &lt;em&gt;Ubuntu&lt;&#x2F;em&gt; here) instance, and be sure to keep in mind that the key pair should be generated during the process, then download your private key (.pem) file.&lt;&#x2F;p&gt;
&lt;&#x2F;li&gt;
&lt;li&gt;
&lt;p&gt;Change your private key’s priviledge to 400: &lt;code&gt;chmod 400 &#x2F;path&#x2F;my-key-pair.pem&lt;&#x2F;code&gt;.&lt;&#x2F;p&gt;
&lt;&#x2F;li&gt;
&lt;li&gt;
&lt;p&gt;Log-in your instance with such command: &lt;code&gt;ssh -i &#x2F;path&#x2F;my-key-pair.pem ubuntu@ec2-13-124-234-100.ap-northeast-2.compute.amazonaws.com&lt;&#x2F;code&gt;.&lt;&#x2F;p&gt;
&lt;&#x2F;li&gt;
&lt;li&gt;
&lt;p&gt;Upgrade OS:&lt;&#x2F;p&gt;
&lt;pre class=&quot;giallo z-code&quot;&gt;&lt;code data-lang=&quot;shellscript&quot;&gt;&lt;span class=&quot;giallo-l&quot;&gt;&lt;span class=&quot;z-entity z-name z-function&quot;&gt;sudo&lt;&#x2F;span&gt;&lt;span class=&quot;z-string&quot;&gt; apt-get update&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;
&lt;span class=&quot;giallo-l&quot;&gt;&lt;span class=&quot;z-entity z-name z-function&quot;&gt;sudo&lt;&#x2F;span&gt;&lt;span class=&quot;z-string&quot;&gt; apt-get dist-upgrade&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;&lt;&#x2F;code&gt;&lt;&#x2F;pre&gt;&lt;&#x2F;li&gt;
&lt;li&gt;
&lt;p&gt;Install Shadowsocks:&lt;&#x2F;p&gt;
&lt;pre class=&quot;giallo z-code&quot;&gt;&lt;code data-lang=&quot;shellscript&quot;&gt;&lt;span class=&quot;giallo-l&quot;&gt;&lt;span class=&quot;z-entity z-name z-function&quot;&gt;sudo&lt;&#x2F;span&gt;&lt;span class=&quot;z-string&quot;&gt; apt-get install python-pip&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;
&lt;span class=&quot;giallo-l&quot;&gt;&lt;span class=&quot;z-entity z-name z-function&quot;&gt;sudo&lt;&#x2F;span&gt;&lt;span class=&quot;z-string&quot;&gt; pip install shadowsocks&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;&lt;&#x2F;code&gt;&lt;&#x2F;pre&gt;&lt;&#x2F;li&gt;
&lt;&#x2F;ol&gt;
&lt;blockquote class=&quot;markdown-alert-note&quot;&gt;
&lt;p&gt;You may see this error during installation of Shadowsocks:&lt;&#x2F;p&gt;
&lt;pre class=&quot;giallo z-code&quot;&gt;&lt;code data-lang=&quot;plain&quot;&gt;&lt;span class=&quot;giallo-l&quot;&gt;&lt;span&gt;Traceback (most recent call last):&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;
&lt;span class=&quot;giallo-l&quot;&gt;&lt;span&gt;File &amp;quot;&#x2F;usr&#x2F;bin&#x2F;pip&amp;quot;, line 11, in &amp;lt;module&amp;gt;&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;
&lt;span class=&quot;giallo-l&quot;&gt;&lt;span&gt;    sys.exit(main())&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;
&lt;span class=&quot;giallo-l&quot;&gt;&lt;span&gt;File &amp;quot;&#x2F;usr&#x2F;lib&#x2F;python2.7&#x2F;dist-packages&#x2F;pip&#x2F;__init__.py&amp;quot;, line 215, in main&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;
&lt;span class=&quot;giallo-l&quot;&gt;&lt;span&gt;    locale.setlocale(locale.LC_ALL, &amp;#39;&amp;#39;)&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;
&lt;span class=&quot;giallo-l&quot;&gt;&lt;span&gt;File &amp;quot;&#x2F;usr&#x2F;lib&#x2F;python2.7&#x2F;locale.py&amp;quot;, line 581, in setlocale&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;
&lt;span class=&quot;giallo-l&quot;&gt;&lt;span&gt;    return _setlocale(category, locale)&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;
&lt;span class=&quot;giallo-l&quot;&gt;&lt;span&gt;locale.Error: unsupported locale setting&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;&lt;&#x2F;code&gt;&lt;&#x2F;pre&gt;
&lt;p&gt;It is caused by wrong language settings. Fix it by &lt;code&gt;export LC_ALL=C&lt;&#x2F;code&gt; (only works in &lt;strong&gt;current&lt;&#x2F;strong&gt; tty), then try again.&lt;&#x2F;p&gt;
&lt;&#x2F;blockquote&gt;
&lt;ol start=&quot;6&quot;&gt;
&lt;li&gt;Start Shadowsocks server by: &lt;code&gt;sudo ssserver -p 2333 -k password -m rc4-md5 -d start&lt;&#x2F;code&gt; (use &lt;code&gt;2333&lt;&#x2F;code&gt; as port and &lt;code&gt;password&lt;&#x2F;code&gt; as password, change &lt;code&gt;start&lt;&#x2F;code&gt; to &lt;code&gt;stop&lt;&#x2F;code&gt; if you wanna stop the process).&lt;&#x2F;li&gt;
&lt;&#x2F;ol&gt;
&lt;blockquote class=&quot;markdown-alert-note&quot;&gt;
&lt;p&gt;You should use &lt;code&gt;AES-256-CTR&lt;&#x2F;code&gt; as encryption method at ArchLinux to avoid problems brought by over-updated &lt;code&gt;libqtshadowsocks&lt;&#x2F;code&gt;.&lt;&#x2F;p&gt;
&lt;&#x2F;blockquote&gt;
&lt;h3 id=&quot;optimization&quot;&gt;Optimization&lt;&#x2F;h3&gt;
&lt;h4 id=&quot;break-though-limit-of-file-open-number&quot;&gt;Break though limit of file open number&lt;&#x2F;h4&gt;
&lt;ol&gt;
&lt;li&gt;
&lt;p&gt;Edit &lt;code&gt;limits.conf&lt;&#x2F;code&gt;: &lt;code&gt;sudo vi &#x2F;etc&#x2F;security&#x2F;limits.conf&lt;&#x2F;code&gt;.&lt;&#x2F;p&gt;
&lt;&#x2F;li&gt;
&lt;li&gt;
&lt;p&gt;Add those two lines:&lt;&#x2F;p&gt;
&lt;pre class=&quot;giallo z-code&quot;&gt;&lt;code data-lang=&quot;plain&quot;&gt;&lt;span class=&quot;giallo-l&quot;&gt;&lt;span&gt;* soft nofile 51200&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;
&lt;span class=&quot;giallo-l&quot;&gt;&lt;span&gt;* hard nofile 51200&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;&lt;&#x2F;code&gt;&lt;&#x2F;pre&gt;&lt;&#x2F;li&gt;
&lt;li&gt;
&lt;p&gt;Restart the OS.&lt;&#x2F;p&gt;
&lt;&#x2F;li&gt;
&lt;&#x2F;ol&gt;
&lt;h4 id=&quot;improve-system-performance&quot;&gt;Improve system performance&lt;&#x2F;h4&gt;
&lt;ol&gt;
&lt;li&gt;
&lt;p&gt;Edit &lt;code&gt;sysctl.conf&lt;&#x2F;code&gt;: &lt;code&gt;sudo vi &#x2F;etc&#x2F;sysctl.conf&lt;&#x2F;code&gt;.&lt;&#x2F;p&gt;
&lt;&#x2F;li&gt;
&lt;li&gt;
&lt;p&gt;Add these lines:&lt;&#x2F;p&gt;
&lt;pre class=&quot;giallo z-code&quot;&gt;&lt;code data-lang=&quot;plain&quot;&gt;&lt;span class=&quot;giallo-l&quot;&gt;&lt;span&gt;fs.file-max = 51200&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;
&lt;span class=&quot;giallo-l&quot;&gt;&lt;span&gt;net.core.rmem_max = 67108864&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;
&lt;span class=&quot;giallo-l&quot;&gt;&lt;span&gt;net.core.wmem_max = 67108864&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;
&lt;span class=&quot;giallo-l&quot;&gt;&lt;span&gt;net.core.netdev_max_backlog = 250000&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;
&lt;span class=&quot;giallo-l&quot;&gt;&lt;span&gt;net.core.somaxconn = 4096&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;
&lt;span class=&quot;giallo-l&quot;&gt;&lt;span&gt;net.ipv4.tcp_syncookies = 1&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;
&lt;span class=&quot;giallo-l&quot;&gt;&lt;span&gt;net.ipv4.tcp_tw_reuse = 1&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;
&lt;span class=&quot;giallo-l&quot;&gt;&lt;span&gt;net.ipv4.tcp_tw_recycle = 0&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;
&lt;span class=&quot;giallo-l&quot;&gt;&lt;span&gt;net.ipv4.tcp_fin_timeout = 30&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;
&lt;span class=&quot;giallo-l&quot;&gt;&lt;span&gt;net.ipv4.tcp_keepalive_time = 1200&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;
&lt;span class=&quot;giallo-l&quot;&gt;&lt;span&gt;net.ipv4.ip_local_port_range = 10000 65000&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;
&lt;span class=&quot;giallo-l&quot;&gt;&lt;span&gt;net.ipv4.tcp_max_syn_backlog = 8192&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;
&lt;span class=&quot;giallo-l&quot;&gt;&lt;span&gt;net.ipv4.tcp_max_tw_buckets = 5000&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;
&lt;span class=&quot;giallo-l&quot;&gt;&lt;span&gt;net.ipv4.tcp_fastopen = 3&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;
&lt;span class=&quot;giallo-l&quot;&gt;&lt;span&gt;net.ipv4.tcp_rmem = 4096 87380 67108864&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;
&lt;span class=&quot;giallo-l&quot;&gt;&lt;span&gt;net.ipv4.tcp_wmem = 4096 65536 67108864&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;
&lt;span class=&quot;giallo-l&quot;&gt;&lt;span&gt;net.ipv4.tcp_mtu_probing = 1&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;
&lt;span class=&quot;giallo-l&quot;&gt;&lt;span&gt;net.ipv4.tcp_congestion_control = hybla&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;&lt;&#x2F;code&gt;&lt;&#x2F;pre&gt;&lt;&#x2F;li&gt;
&lt;li&gt;
&lt;p&gt;Run &lt;code&gt;sudo sysctl -p&lt;&#x2F;code&gt; to reload settings.&lt;&#x2F;p&gt;
&lt;&#x2F;li&gt;
&lt;&#x2F;ol&gt;
&lt;h4 id=&quot;serverspeeder&quot;&gt;ServerSpeeder&lt;&#x2F;h4&gt;
&lt;p&gt;ServerSpeeder cannot be used on Ubuntu 16.04 now.&lt;&#x2F;p&gt;
&lt;h4 id=&quot;net-speeder&quot;&gt;net-speeder&lt;&#x2F;h4&gt;
&lt;p&gt;net-speeder will double the network traffic. Not recommended.&lt;&#x2F;p&gt;
</content>
        <summary type="html">Guide to break through Chinese government&#x27;s GFW</summary>
        </entry>
</feed>
