Giter Site home page Giter Site logo

cloudflare-fping's Introduction

cfping.sh

ping [fping] all cloudflare ips to find the best ip

Usage

Invoking cfping.sh -h prints usage information:

$ cfping.sh -h
$ usage: 
$      cfping.sh -c [-p 2000] [-s 5] [-g 1] [-m 500]
$         -c     ping [fping] all cloudflare ips to find the best ip
$         -p <x> sets the time in milliseconds that fping waits between successive
$                packets to an individual target (default is 2000, minimum is 10)
$         -s <x> set the number of request packets to send to each target (default is 5)
$         -g <x> the minimum amount of time (in milliseconds) between sending a
$                ping packet to any target (default is 1, minimum is 1)
$         -l     show cloudflare ip location
$         -m <x> you may want to use this according to system resources limit 
                 larger number faster result (default is 500)

---

$     cfping.sh -d [-L https://domain.com/xxx] [-N 100] [-P 10] [-I ip]
$         -d     speed test (default testing best 100 IPs unless -I used)
$         -L <x> set the file link to test (default: https://speed.cloudflare.com/__down?bytes=100001000)
$                the domain of this link must have cname record on cloudflare
$         -N <x> set the number of IPs to test (default is 100)
$         -P <x> set the parallel number of speed test (default is 10)
$         -I <x> specify an ip to test

---

$     cfping.sh [options] <start> <end>
$         -n <x> set the number of addresses to print (<end> must not be set)
$         -f <x> set the format of addresses (hex, dec, or dot)
$         -i <x> set the increment to 'x'
$         -h     display this help message and exit
$         -v     display the version number and exit

ping cloudflare 所有的 IP 找到最优 IP 并测速

使用方法

cfping.sh -c

  • 1分钟就可以得到结果
  • 所有的 ip 都在 ip_sorted
  • 如果要显示 ip 位置, 加参数 -l

cfping.sh -d

  • 默认测速 100 个 ip
  • 如果要自定义测速文件, 加参数 -L 文件链接的域名必须在 cloudflare 有 cname 记录
  • 如果测速单个指定 IP, 加参数 -I

部分网络无法分配到香港 ip, 建议更换其他网络

mac / linux 测试通过


Credits

fping

prips.sh

Inquirer.sh

© 2020 MTimer. MIT license.

cloudflare-fping's People

Contributors

woniuzfb avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.