Gowhich

Durban's Blog

罗列一下提高效率的Nodejs模块,分享之。

Cheerio

Fast, flexible, and lean implementation of core jQuery designed specifically for the server.

Cheerio,说它是服务器端的jQuery一点也不为过,在github上也是大受欢迎,star数达4500有余,至目前为止,已经有923次commit。它兼容jQuery绝大部分的库,以至于你只需要一句$ = require(‘cheerio’).load(YOUR_HTML_CONTENT);,便可以像在前端用jQuery一样的舒畅,愉快。

By the way,和Cheerio类似的框架还有:jsdom,一个受欢迎程度略低于Cheerio,但是它有2,147多的commit,可见维护者之诚意。

Waterline

An adapter-based ORM for Node.js with support for mysql, mongo, postgres, redis, and more

Waterline是从Sails框架衍生出来的Nodejs平台下的ORM,除了支持常见的mysql、mongodb,还支持PostgreSQL、Redis、Memory、Disk等等

Bookshelf

A Node.js ORM for PostgreSQL, MySQL and SQLite3 in the style of Backbone.js

与Waterline类似,但作为同类产品且被Ghost选择标配之一的Bookshelf必然有它的特别之处,仍待君细细品来。

Node-Soap

A SOAP client and server for node.js.

对于REST,大家必然熟悉,就算不熟悉,也是久仰其大名,或者是略有耳闻。REST简单而直观,把HTTP协议利用到了极限,在这种思想指导下,它甚至用HTTP请求的头信息来指明资源的表示形式,用HTTP的错误机制来返回访问资源的错误。但在R.T. Fielding博士在他的论文里提出REST之前,又是谁来承担Web Service这份差使呢?

SOAP (Simple Object Access Protocol) 顾名思义,是一个严格定义的信息交换协议,用于在Web Service中把远程调用和返回封装成机器可读的格式化数据。它基于 XML 格式,在绝大多数情况下,使用HTTP协议传输WSDL请求。

而node-soap模块,则允许在node环境中,接入其他程序语言 (诸如 ASP.net、Java 等) 开发的WebService。也能够在node中开发基于SOAP的WebService供其他程序调用。

当然,在大多数情况下,过去SOAP能做的事,REST也是能做到的,且REST更加优雅,简单。以我的水平,我也是想不清楚SOAP依然存在的必然性,但是有那么一句话:「存在,就是合理的」。既然,它存在,也有人用到,那么在合作开发中和SOAP相遇也是有可能性的,相信那是我们的缘分。

如果你有兴趣,听一下我和SOAP邂逅的故事:SOAP,Web service的枢纽

Passport

Simple, unobtrusive authentication for Node.js.

如果你的站点想快速建立passport-user结构的用户系统,且能够简单的接入流行的第三方登录,用passport就没错了。它不但提供了本站登录的解决方案,还有一大堆第三方登录的策略,见:Strategies

如果你用Sails的话,这里还有一个承接Sails和passport的模块:sails-generate-auth

Bluebird

Bluebird is a full featured promise library with unmatched performance.

Javascript 的世界有一种痛叫「callback hell」,中文翻译过来叫「回调地狱」,如果能承受得了她带来的痛楚,且继续爱着她,这是「真爱」。Promise的概念,能够让你与javascript好好爱的深沉。

实现Promise的库有很多,我知道的有:

Q

when

bluebird

jQuery的deferred

javascript自带的Promise(一些高级浏览器内置的Promise对象)

其中,我用的比较顺手的当属bluebird,它也是时下最优秀博客系统Ghost的标配之一。

如果你想深入了解Promise的概念,可以点这里:Promises: The Sync Problem

如果你想珍惜时间,珍惜生命,这里有中文版:深入理解Promise五部曲

Lodash

A JavaScript utility library delivering consistency, modularity, performance, & extras.

我想称它为Javascript的瑞士军刀,或者是一个蓝色工具箱。lodash提供了一系列相当不错的跟函数式编程相关的方法。函数式编程就像搭积木一样,像.identity、.partial、_.compose、splat、unsplat等都是职责单一的函数。别看它们简单,把它们当作积木看待,它们释放的是无尽的活力。 越是简单的东西,蕴藏的越是更为无限的可能性。

Node.bcrypt.js

bcrypt for NodeJs

bcrypt,是一个跨平台的文件加密工具。由它加密的文件可在所有支持的操作系统和处理器上进行转移。它的口令必须是8至56个字符,并将在内部被转化为448位的密钥。然而,所提供的所有字符都具有十分重要的意义。密码越强大,您的数据就越安全。而node.bcrypt.js则是披上Nodejs斗篷的bcrypt,它的62.2%是C++代码,而Javascript代码只有30.3%。

Moment

Parse, validate, manipulate, and display dates in javascript.

Moment是一个轻量级用于处理日期的工具,除了对日期进行格式化以外,你还能够对日期进行操作,验证,解析。其在github的star数有1.9W+,比众所周知的Express(github star是1.7w+)还多一点。这么优秀的框架实在是相见恨晚。

Skipper

Streaming multi-uploads for Sails/Express - supports disk, S3, gridfs, and custom file adapters

Skipper是一款Sails衍生的处理多文件上传的组件,支持上传文件到本地或者远端服务器,如果默认adapter没有你需要的服务,你还能够自定义一套adapter满足你的需求。就像我为了把文件上传到又拍云而定制了的adapter: skipper-upyun

Node-fs-extra

Node.js: extra methods for the fs object.

Node-fs-extra提供了一些额外的fs没有的函数,如果Nodejs自带的fs模块,还不能满足你在进行文件操作的使用,或者用着不顺心。不妨来node-fs-extra找一下有没有你想要的解决方案。

Mocha

mocha - simple, flexible, fun javascript test framework for node.js & the browser. (BDD, TDD, QUnit styles via interfaces)

Nodejs单元测试哪家强?

mocha,mocha,似魔鬼的步伐~~yo!

Should

BDD style assertions for node.js – test framework agnostic

BDD风格的断言模块,旨在让编程像说白话(至少在测试断言上)。

Supertest

Super-agent driven library for testing node.js HTTP servers using a fluent API

如果测试的时候,需要HTTP请求呢?找Supertest吧,和Should同一个作者,TJ大神,你值得信赖。

PM2

Production process manager for Node.JS applications. Perfectly designed for microservice architecture.

Nodejs单线程的特性,意味着,如果你的某一行代码阻塞了,你的整个程序都会崩溃。人非圣贤,孰能无过,没有人能保证自己的写的代码永无BUG(难道要在文件头加上无BUG神兽?)。在生产环境下,如果程序挂了怎么办?让它自动重启呗。

PM2就是一款解决这种问题的工具,当然,作为一个进程管理器,它的作用不仅仅如此。

Markdown-js

A Markdown parser for javascript

Markdown时下越来越受欢迎了,实质上markdown最终是转换成HTML格式才能显示于网页的。而markdown-js则是把markdown格式的文本转化成HTML格式的工具。但是,如果从HTML格式的文本转化成Markdown格式的文本呢?markdown-js好像不支持,那就用to-markdown吧。

a fast, privately secured tunnel to transfer web pages and dns queries

Have you ever wanted to visit sites during the day from a location that denied access to those sites? Perhaps the company has denied access due to bandwidth considerations or you might have decided that the site you want to go to might not always be work safe depending on the story or pictures? What you need is the ability to create a secure and encrypted ssh connection to tunnel your browser traffic through.

Using a ssh tunnel to retrieve the data from websites is significantly faster than trying to use X forwarding to open a remote copy of Firefox on the remote machine. If a remote browser is used the connection will be saturated by the graphical front end of the remote browser window. Use the tunnel for the web site’s data and leave the rendering of the browser to the local machine. This is the most efficient solution.

If you have access to a remote machine by way of ssh you can set up Firefox, or any other SOCKS v5 enabled application, to tunnel its connection through ssh. This way, if you were at work and wanted to browse your favorite sites like MySpace, Facebook or Maxim that are blocked at the company firewall you could.

Getting Started

First you must have ssh access to the remote machine you want to proxy to. Let it be a home machine or a free shell you signed up for on-line. You must also make sure you can ssh from where your browser is to where you want to tunnel to. No need to set this up if port 22 is not open to you from your location to your destination.

ATTENTION: We are proud to announce our Firefox add-on called, “Calomel SSL Validation”. It will grade the security of your SSL connection. The link has screen shots too!

IMPORTANT NOTE: The Firefox tunnel using SOCKS5 (option 1) is the easiest and quickest proxy to setup. If you just want to get the proxy working then follow the SOCKS5 options.

Configure Firefox for the proxy

You need to configure Firefox to use the proxy. Find the section to add a proxy to the browser. On *nix systems of Firefox you will find the settings in File, Preferences, Advanced, Network, Settings. The setting by default is “Direct Connection to the Internet”. We need to setup the “Manual proxy configuration”.

You have two(2) options to pick from. You can proxy directly to the remote machine and then connect directly to web sites. This is the SOCKS5 method and is the easiest to setup. Or, you could use a Squid web proxy (if available) on the remote machine to accept the traffic from the ssh tunnel. Squid would then request the traffic from web sites. Pick one of the options below.

NOTE: For our example, ssh is going to listen on localhost (127.0.0.1) and port 8080 of the local machine.

Option 1: ssh and direct connect (SOCKS5) : If you are going to use the ssh tunnel with the option “-D 8080” then you need to setup the browser to use a SOCKS5 proxy. Setup the proxy config page with the following entries and leave the rest of the entries blank.

Manual proxy configuration:

1
2
SOCKS Proxy  127.0.0.1  Port 8080
check the box for "SOCKS v5"

Option 2: ssh tunnel to squid proxy (HTTP/SSL Proxy) : If you are going to use the ssh tunnel with the option “-L 8080:localhost:2020” to connect to the remote machine’s Squid proxy then configure the browser to use a HTTP/SSL proxy. Setup the proxy config page with the following entries and leave the rest of the entries blank.

Manual proxy configuration:

1
2
HTTP Proxy:  127.0.0.1  Port 8080
SSL Proxy : 127.0.0.1 Port 8080

Optional Step: DNS proxying through SOCKS5 is highly recommended

This step is optional, but since we are going to be proxying the data over the ssh tunnel then we should also proxy the DNS requests as well. The purpose of this exercise is to get to a site we might not otherwise be able to retrieve or just to anonymize our browsing from your location. If we tunneled our data through ssh and then asked the local DNS server for the ips it would defeat the purpose. So, add a boolean option into the URL “about:config” page in Firefox. Name the entry “network.proxy.socks_remote_dns” and set it to true.

This method will only take affect if you use the SOCKS5 proxy method. If you are proxying using the squid method (HTTP/SSL Proxy) you could always check if you can query another, independent DNS server like OpenDNS.

##Preference Name Status Type Value

network.proxy.socks_remote_dns user set boolean true

Making the ssh tunnel

Lastly, we need to start the ssh tunnel. You have two choices depending if you want the packets to be forwarded to squid on the remote machine or not.

Option 1: ssh and direct connect (SOCKS5) : The following line will start the ssh client and connect to username@remote_machine.com. Port 8080 on localhost (127.0.0.1) will listen for requests and send them to the remote machine. The remote machine will then send the packets out as if they originated from itself. The ssh options are in the man page of ssh, but to summarize them in order: Compression, SSH2 only, Quite, Force pseudo-tty allocation, Redirect stdin from /dev/null, and Place the ssh client into “master” mode for connection sharing.

1
ssh -C2qTnN -D 8080 username@remote_machine.com

Option 2: ssh to squid proxy (HTTP/SSL Proxy) : The following line will also start the ssh client and connect to username@remote_machine.com. Port 8080 on localhost (127.0.0.1) on the current machine will listen for requests and ssh tunnel them to the remote machine. On the remote machine ssh will forward the packets to localhost port 2020. If squid is listening on localhost port 2020 on the remote machine then all requests sent though the ssh tunnel will then be forwarded to squid. You can use squid to block ads and speed up web access. If you need assistance with squid, check out the Calomel.org Squid “how to” page.

1
ssh -C2qTnN -L 8080:localhost:2020 username@remote_machine.com

Testing the ssh tunnel

Once you execute the ssh line the encrypted and compressed ssh tunnel will be active in the xterm. We used the “quiet” options in ssh so there will not be any logging or output to the terminal.

Make sure Firefox is working by checking the proxy is active and then try to go to a web page. You can also try a site like WhatIsMyIp.com to verify the ip you have with the proxy is different than without.

If everything is working then you can be assured that all of your browsing traffic is being encrypted through the tunnel and no one at your current location will be able to see your traffic over the network.

Once you are done with the proxy just exit the ssh xterm or kill this instance of ssh with Ctrl-c. Remember to set Firefox back to “Direct Connection” if you want to directly browse from your location otherwise you will not be going anywhere.

Interested in setting up Squid or Samba? Check out our guides covering the Squid Proxy and Samba file share servers. We offer clear explanations and fully working example configurations.

Questions?

How can I setup two or more ssh tunnels through two or more machines ?

At some point you may need to tunnel through multiple ssh tunnels through multiple machines. This is quite easy to do as long as you have ssh access to every machine you want to tunnel through. In this example we will be tunneling from a desktop machine through a machine called host1 and then to a machine called host2 which will then access the internet. Something like so:

Firefox desktop -> host1 -> host2 -> internet

First, make sure you went through the beginning on this page and know how to get firefox to proxy through a SOCKS5 proxy on localhost port 8080. Then run the following ssh command on the desktop running Firefox. This will setup an encrypted ssh tunnel to host1 from the “Firefox desktop”.

1
desktop$ ssh -C2qTnN username@host1 -L 8080:localhost:8080

Now, you need to ssh to host1 directly. Once you are on host1 run the following. This will collect any data from the first tunnel originating from the “Firefox desktop” to host1 and tunnel that data to host2.

1
host1$ ssh -C2qTnN -D 8080 username@host2

So, how does this setup work? Firefox on the desktop will initiate a SOCKS5 connection to localhost port 8080 on the desktop machine. Since a ssh tunnel is listening on localhost:8080 it will ssh tunnel the traffic to host1 which will forward this traffic to host1’s localhost:8080. On host1 the second ssh command will tunnel all traffic it receives on localhost:8080 from the desktop machine to host2. On host2 the traffic will then be able to go out to the internet at large. If you have DNS SOCKS5 resolution on as well then all web traffic and dns queries will goto host2 through both tunnels. From the view of the internet all queries originating from the “Firefox desktop” will look like they come from host2. Nice and anonymous.

What if I need to tunnel through more then two machines? Then just keep repeating “ssh -C2qTnN username@host1 -L 8080:localhost:8080” command for each incremental host. Once you decide you very last host you want the data to access the internet with then use the “ssh -C2qTnN -D 8080 username@host2” command.

To make sure you tunnel is working correctly using a site like ipchicken.com to see what ip address you are coming from. In the case of our example above ipchicken should report the ip address of host2.

Do you have any recommended modifications for Firefox in “about:config” ?

First, make sure to check out our Firefox Add-on “Calomel SSL Validation”.

More open proxy connections: When you use a proxy, Firefox limits the amount of concurrent open connections to 8. This is too small for most users as many people open multiple tabs to many sites. When more then 8 connections are made the browser seems to be “stuck” because Firefox will wait till an open connection is closed before making a new one. To avoid this problem it is highly suggested to increase the persistent connections value from 8 to 25.

1
network.http.max-persistent-connections-per-proxy 25

Turn off pop-up tips: If you are annoyed by pop up text when your mouse hovers over a web element you can turn that function off.

1
browser.chrome.toolbar_tips  false

No animations: Stop all animated gifs and pictures like ads and annoying dancing cartoons characters.

1
image.animation_mode  none

No blinking text: Blinking text is annoying. Webmasters should not use it. In case they do, we will disallow the function in the browser.

1
browser.blink_allowed  false

Parallel connections: An easy way to speed up Firefox is to increase the amount of parallel connections the browser makes to the server. Open up Firefox and type in “about:config” in the URL. Then search for the string “conn” You should see the following entries listed. Modify them as follows:

1
2
3
4
network.http.max-connections                        25
network.http.max-connections-per-server 25
network.http.max-persistent-connections-per-proxy 25
network.http.max-persistent-connections-per-server 25

It is not recommended to use more then 25 parallel connections due to abuse of the remote server and concurrency bottlenecks on the local system. Understand that if you have a slow system then more parallel connections can actually slow the browser down considerably. Also, if you try to open too many connections to a server then that server many consider you hostile and block or blacklist you.

Pipelining Enabled: The fastest and most efficient way to implement a browser is to use pipelining. This is where a single persistent connection is used, but instead of waiting for each response before sending the next request, several requests are sent out at a time. This reduces the amount of time the client and server are waiting for requests or responses to cross the network. Pipelined requests with a single connection are faster than multiple HTTP/1.0 requests in parallel, and considerably reduce the number of packets transmitted across the network. Apache supports both HTTP/1.0 keep-alive and HTTP/1.1 persistent connections. Pipelining is implement entirely at the browser end if supported by the remote web server, using persistent connections.

To enable pipelining in Firefox browser goto the url about:config . Then search for “pipe” and set the following:

1
2
3
4
network.http.pipelining              true
network.http.pipelining.maxrequests 8
network.http.pipelining.ssl true
network.http.proxy.pipelining true

TLSv1 with AES256, AES128 and 3DES 168 Only: When connecting to SSL based servers (https) you only want to use the strongest ciphers available. Most web server admins can setup their servers to prefer weak ciphers over strong ciphers for any reason; sometimes they want a less CPU intensive encryption or perhaps they just configured the server wrong. Even Google’s encrypted pages prefer RC4 instead of AES and this is not our idea of good security. We want to make sure that our version of Firefox only uses AES 256 bit, AES 128 bit or 3DES 168 bit ciphers.

Open up a window and type “about:config”. Then in the “Filter” bar at the top search for the following. Double clicking on each line will change the value.

tls and set the lines to true.

ssl2 and set every line entry to false.

ssl3 and set every line to false _except_ lines containing the strings "aes_256" and "aes_128".

security.ssl3.rsa_des_ede3_sha and set it to true. This is the weakest cipher and may be needed for some older SSL sites.

Now your browser will only accept the TLSv1 protocol in AES256 bit cipher encryption no matter what previous weaker ciphers a web server prefers. This configuration also makes your browser FIPS 120-2 compliant (year 2030 specs).

Is there any way I can switch proxies faster?There are add-ons, also called extensions, for Firefox called FoxyProxy or SwitchProxyTool you can use. They offer the ability to setup multiple proxy settings and choose the one you want, or turn them off, using a drop down menu.

I noticed you use compression in the ssh tunnel proxy. Why?The majority of the data you are retrieving using the browser is text or HTML data. This type of data compresses very well at up to 80%. Using compression in the tunnel will speed up the delivery of the data considerably.

https://calomel.org/firefox_ssh_proxy.html

配置文件的格式变了

是这样子的啦:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
systemLog:
destination: file
path: "/var/log/mongodb/mongodb.log"
logAppend: true
storage:
journal:
enabled: trueprocessManagement:
fork: true
net:
bindIp: 127.0.0.1
port: 27017
setParameter:
enableLocalhostAuthBypass: false

...

如果想要添加其他参数,请到这里查看吧:http://docs.mongodb.org/manual/reference/configuration-options/

只需要执行如下的代码就好了

1
2
$ gem sources --remove https://rubygems.org/
$ gem sources -a http://ruby.taobao.org/

淘宝大哥的,哈哈

pipy国内镜像目前有:

http://pypi.douban.com/simple/ 豆瓣

http://mirrors.aliyun.com/pypi/simple/ 阿里云

https://pypi.tuna.tsinghua.edu.cn/simple 清华大学开源软件镜像站

对于pip这种在线安装的方式来说,很方便,但网络不稳定的话很要命。使用国内镜像相对好一些,
如果想手动指定源,可以在pip后面跟-i 来指定源,比如用豆瓣的源来安装web.py框架:

1
pip install web.py -i http://pypi.douban.com/simple

注意后面要有/simple目录!!!

如果提示:

The repository located at pypi.douban.com is not a trusted or secure host and is being ignored. If this repository is available via HTTPS it is recommended to use HTTPS instead, otherwise you may silence this warning and allow it anyways with ‘–trusted-host pypi.douban.com’.

请试试这个的办法

1
pip install virtualenv  --trusted-host pypi.douban.com -i http://pypi.douban.com/simple

要配制成默认的话,需要创建或修改配置文件
编辑~/.pip/pip.conf:

1
nano ~/.pip/pip.conf

添加

1
2
[global]
index-url = http://pypi.douban.com/simple

python开发解决依赖库的办法

你可以用pip导出你的dependency:

1
$ pip freeze > requirements.txt

然后在通过以下命令安装dependency:

1
$ pip install -r requirements.txt

如此依赖如果你在服务器部署的话,就可以直接安装需要的依赖库,就不用等着报错才去一个一个安装了。

nvm的安装请转到这里:

https://github.com/creationix/nvm

下面先说nvm的加速

nvm 默认是从 http://nodejs.org/dist/ 下载的, 国外服务器, 必然很慢,

好在 nvm 以及支持从镜像服务器下载包, 于是我们可以方便地从七牛的 node dist 镜像下载:

1
$ NVM_NODEJS_ORG_MIRROR=http://dist.u.qiniudn.com nvm install 0.12.7

于是你就会看到一段非常快速进度条:

1
2
######################################################################## 100.0%
Now using node v0.12.7

如果你不想每次都输入环境变量 NVM_NODEJS_ORG_MIRROR, 那么我建议你加入到 .bashrc 文件中:

1
2
3
# nvm
export NVM_NODEJS_ORG_MIRROR=http://dist.u.qiniudn.com
source ~/git/nvm/nvm.sh

然后你可以继续非常方便地安装各个版本的 node 了, 你可以查看一下你当前已经安装的版本:

1
nvm ls

查看远端的

1
nvm ls-remote

下面再说下npm加速

同理 nvm , npm 默认是从国外的源获取和下载包信息, 不慢才奇怪.

可以通过简单的 —registry 参数, 使用国内的镜像 http://r.cnpmjs.org :

1
$ npm --registry=http://r.cnpmjs.org install koa

但是毕竟镜像跟官方的 npm 源还是会有一个同步时间差异, 目前 cnpm 的默认同步时间间隔是 15 分钟.

如果你是模块发布者, 或者你想马上同步一个模块, 那么推荐你安装 cnpm cli:

1
$ npm --registry=http://r.cnpmjs.org install cnpm -g

通过 cnpm 命令行, 你可以快速同步任意模块:

1
$ cnpm sync koa connect mocha

呃, 我就是不想安装 cnpm cli 怎么办? 哈哈, 早就想到你会这么懒了, 于是我们还有一个 web 页面:

例如我想马上同步 koa, 直接打开浏览器: http://cnpmjs.org/sync/koa

或者你是命令行控, 通过 open 命令打开:

1
$ open http://cnpmjs.org/sync/koa

github 慢, 或者说是它的资源 host 被堵而已, 大家可以通过简单的 hosts 映射解决:

1
185.31.16.184 github.global.ssl.fastly.net

原因是这样的吧: http://weibo.com/1415338244/ACTYkq8xK

最近在使用Nodejs的一个库Iconv-lite,有时候会报出这样一个提示

Iconv-lite warning: decode()-ing strings is deprecated. Refer to https://github.com/ashtuchkin/iconv-lite/wiki/Use-Buffers-when-decoding

已经给出了对应的Refer。

具体详情见:https://github.com/ashtuchkin/iconv-lite/wiki/Use-Buffers-when-decoding
其实看完之后,很简单就是
如果有一个Buffer数据的话,你进行了toString()后,就已经进行了一层默认的decode操作,一般默认的是utf-8,
所以如果你在进行iconv.decode()的时候,就会出现一个提示,这个在最新版本会出现这个问题,其他的版本我就不知道了,
如果你在使用的过程中,decode之后,没有效果的话,可以试试,在decode之前先不要任何操作,直接将Buffer数据进行
decode,进过测试,直接decode(Bufffer)数据会效果比较好,谁用谁知道。

=>]Open DNS

208.67.222.222

208.67.220.220

=>]V2EX DNS

199.91.73.222

178.79.131.110

=>]OneDNS

112.124.47.27

=>]Comodo Secure DNS

8.26.56.26

8.20.247.20

=>]Google Public DNS

The Google Public DNS IPv4 addresses

8.8.8.8

8.8.4.4

The Google Public DNS IPv6 addresses

2001:4860:4860::8888

2001:4860:4860::8844

=>]114 DNS

无劫持

114.114.114.114

114.114.115.115

拦截有害网站

114.114.114.119

114.114.115.119

拦截色情网站

114.114.114.110

114.114.115.110

=>]Norton ConnectSafe

A - Security (malware, phishing sites and scam sites)

Preferred DNS: 199.85.126.10

Alternate DNS: 199.85.127.10

B - Security + Pornography

Preferred DNS: 199.85.126.20

Alternate DNS: 199.85.127.20

C - Security + Pornography + Non-Family Friendly

Preferred DNS: 199.85.126.30

Alternate DNS: 199.85.127.30

=>]DNS派 公共DNS

电信:

101.226.4.6

218.30.118.6

联通:

123.125.81.6

140.207.198.6

移动:

101.226.4.6

218.30.118.6

铁通:

101.226.4.6

218.30.118.6

=>]阿里DNS

223.5.5.5

223.6.6.6


DNS 网站

http://dns.v2ex.com/

http://www.114dns.com/

http://www.alidns.com/

http://www.opendns.com/

http://www.internic.net/

http://www.nortondns.com/

http://www.mwsl.org.cn/onedns

http://www.dnspai.com/public.html

http://www.comodo.com/secure-dns/

http://code.google.com/intl/zh-CN/speed/public-dns

http://www.dnsbed.com/

http://www.zndns.com/

http://www.8jdns.com/

http://www.360dns.com/

http://public-dns.tk/

0%