libf 2 лет назад
Родитель
Сommit
ed50f3d257
4 измененных файлов с 192 добавлено и 6 удалено
  1. BIN
      bin/mping.zip
  2. 94 1
      ping/hosts.last.txt
  3. 94 1
      ping/hosts.txt
  4. 4 4
      ping/ping.go

+ 94 - 1
ping/hosts.last.txt

@@ -44,4 +44,97 @@ weiyun.com,weibo.com,189.cn,jianguoyun.com
 
 187.158.31.146,218.109.149.137
 60.217.223.70
-178.122.238.81
+178.122.238.81
+126.177.146.120
+100.15.184.2
+83.212.104.130,37.68.11.245
+23.88.252.50
+119.210.175.63
+207.246.84.68,104.160.26.117,84.184.162.89
+41.196.12.95
+86.4.18.154
+99.230.224.5
+210.21.79.93
+177.72.45.232
+27.7.22.182
+108.7.189.53
+79.54.196.78
+216.228.42.52,154.13.79.253
+92.210.14.31
+81.45.83.165
+119.166.78.180
+116.73.140.240
+94.15.196.2
+182.211.133.129
+90.205.22.68
+153.251.213.115
+5.254.99.194,77.178.101.81
+188.80.170.118
+104.172.79.248
+144.64.157.139
+210.187.215.82,91.153.246.53
+111.85.234.186
+45.33.60.238
+211.251.166.213
+174.117.108.130
+220.148.201.222
+61.101.86.153
+61.73.115.45
+84.198.159.110,72.74.130.150
+153.251.87.67
+31.46.184.244
+193.38.250.185
+64.191.71.177
+46.36.109.171
+119.152.228.101
+189.168.121.241
+58.211.197.183,73.45.226.50,47.40.165.90
+52.204.189.59
+211.125.180.133
+60.143.56.220
+189.73.143.40,107.178.155.138
+80.26.171.183
+162.154.163.5
+5.151.112.215
+222.221.40.236
+8.134.66.192
+72.52.145.115
+165.227.43.126,119.200.78.25
+80.114.95.90,118.77.91.189
+73.228.37.109
+1.234.253.254
+121.190.204.135
+39.88.14.224,86.83.18.212
+165.166.49.249
+182.127.201.176
+124.132.73.83
+171.217.16.140
+134.96.184.1
+151.227.192.64
+24.128.229.106,88.10.158.190
+104.69.107.201,219.123.152.150
+126.216.98.142,85.150.191.132
+42.56.206.20
+89.247.110.60
+124.230.239.238
+14.65.33.131,2.127.107.210
+91.177.247.78,113.226.182.253
+70.176.158.90,68.61.132.18,23.49.175.182
+104.223.102.1
+113.242.97.76
+92.240.106.13
+119.54.247.98
+181.67.29.68,36.79.50.224,2.132.109.97
+223.240.41.192
+68.12.249.224
+185.201.153.248
+98.253.42.124
+47.184.41.166
+180.136.219.158
+37.9.186.91,86.4.187.32
+109.129.39.253
+101.91.222.63
+51.79.40.168
+175.214.166.176
+145.14.116.56
+115.139.137.217

+ 94 - 1
ping/hosts.txt

@@ -45,4 +45,97 @@ weiyun.com,weibo.com,189.cn,jianguoyun.com
 187.158.31.146,218.109.149.137
 60.217.223.70
 178.122.238.81
-126.177.146.120
+126.177.146.120
+100.15.184.2
+83.212.104.130,37.68.11.245
+23.88.252.50
+119.210.175.63
+207.246.84.68,104.160.26.117,84.184.162.89
+41.196.12.95
+86.4.18.154
+99.230.224.5
+210.21.79.93
+177.72.45.232
+27.7.22.182
+108.7.189.53
+79.54.196.78
+216.228.42.52,154.13.79.253
+92.210.14.31
+81.45.83.165
+119.166.78.180
+116.73.140.240
+94.15.196.2
+182.211.133.129
+90.205.22.68
+153.251.213.115
+5.254.99.194,77.178.101.81
+188.80.170.118
+104.172.79.248
+144.64.157.139
+210.187.215.82,91.153.246.53
+111.85.234.186
+45.33.60.238
+211.251.166.213
+174.117.108.130
+220.148.201.222
+61.101.86.153
+61.73.115.45
+84.198.159.110,72.74.130.150
+153.251.87.67
+31.46.184.244
+193.38.250.185
+64.191.71.177
+46.36.109.171
+119.152.228.101
+189.168.121.241
+58.211.197.183,73.45.226.50,47.40.165.90
+52.204.189.59
+211.125.180.133
+60.143.56.220
+189.73.143.40,107.178.155.138
+80.26.171.183
+162.154.163.5
+5.151.112.215
+222.221.40.236
+8.134.66.192
+72.52.145.115
+165.227.43.126,119.200.78.25
+80.114.95.90,118.77.91.189
+73.228.37.109
+1.234.253.254
+121.190.204.135
+39.88.14.224,86.83.18.212
+165.166.49.249
+182.127.201.176
+124.132.73.83
+171.217.16.140
+134.96.184.1
+151.227.192.64
+24.128.229.106,88.10.158.190
+104.69.107.201,219.123.152.150
+126.216.98.142,85.150.191.132
+42.56.206.20
+89.247.110.60
+124.230.239.238
+14.65.33.131,2.127.107.210
+91.177.247.78,113.226.182.253
+70.176.158.90,68.61.132.18,23.49.175.182
+104.223.102.1
+113.242.97.76
+92.240.106.13
+119.54.247.98
+181.67.29.68,36.79.50.224,2.132.109.97
+223.240.41.192
+68.12.249.224
+185.201.153.248
+98.253.42.124
+47.184.41.166
+180.136.219.158
+37.9.186.91,86.4.187.32
+109.129.39.253
+101.91.222.63
+51.79.40.168
+175.214.166.176
+145.14.116.56
+115.139.137.217
+189.153.21.195

+ 4 - 4
ping/ping.go

@@ -80,8 +80,8 @@ func main() {
 		StatInterval: 600,
 	}
 	inputcfg.Poolsize = mcfg.GetInt("poolsize", inputcfg.Poolsize)
-	if mcfg.GetString("detect", "") == "1" {
-		go detect()
+	if detect_interval := mcfg.GetDuration("detect", 0); detect_interval != 0 {
+		go detect(detect_interval)
 	}
 	fips := func() []string {
 		xips := mcfg.GetStrings("ip|ping.ip", "")
@@ -417,8 +417,8 @@ func (input *Input) send(t *task, workerNum int) error {
 
 var detectips = []string{}
 
-func detect() {
-	t := time.NewTicker(100 * time.Millisecond)
+func detect(detect_interval time.Duration) {
+	t := time.NewTicker(detect_interval)
 	for {
 		<-t.C
 		randip := fmt.Sprintf("%d.%d.%d.%d", 1+rand.Intn(254), 1+rand.Intn(254), 1+rand.Intn(254), 1+rand.Intn(254))