Tag: ip地址
-
使用sort把IP地址排序
[root@localhost shell]# cat ip.txt 192.168.2.3 10.4.1.3 172.3.4.5 10.64.31.3 7.3.4.6 123.23.58.29 192.16.17.13 11.23.93.153 10.14.1.3 [root@localhost shell]# sort -t “.” -k1n,1 -k2n,2 -k3n,3 -k4n,4 ip.txt 7.3.4.6 10.4.1.3 10.14.1.3 10.64.31.3 11.23.93.153 123.23.58.29 172.3.4.5 192.16.17.13 192.168.2.3 ——————— 作者:ivnetware 来源:CSDN 原文:https://blog.csdn.net/ivnetware/article/details/54564101 版权声明:本文为博主原创文章,转载请附上博文链接!
-
docker-获取容器ip地址的10个方法
10 EXAMPLES OF HOW TO GET DOCKER CONTAINER IP ADDRESS Much of the motivation to show so many different ways is to help folks see the flexibility that I still run into nearly daily which is hard not to excite a hacker. They can also be viewed in this Gist. 1 2 3 4 5 6…
-
如何获取电信运营商ip地址分配的详细信息
whois 工具获取 APNIC是管理亚太地区IP地址分配的机构,它有着丰富准确的IP地址分配库,同时这些信息也是对外公开的!下面就让我们看看如何在Linux下获得一些电信运营商的IP地址分配情况:shell> wget http://ftp.apnic.net/apnic/dbase/tools/ripe-dbase-client-v3.tar.gzshell> tar xzvf ripe-dbase-client-v3.tar.gzshell> cd whois-3.1shell> ./configureshell> make完成上述编译安装工作后,我们开始获取IP地址段;中国网通:shell> ./whois3 -h whois.apnic.net -l -i mb MAINT-CNCGROUP > /var/cnc中国电信:shell> ./whois3 -h whois.apnic.net -l -i mb MAINT-CHINANET > /var/chinanet中国铁通:shell> ./whois3 -h whois.apnic.net -l -i mb MAINT-CN-CRTC > /var/crtc打开获取后的文件可以看到里面的信息非常详细,甚至可以看到各个分公司的负责人、电话、电子邮件等等信息。如果想得到一份整齐干净的IP地址段文件,只要用grep和awk简单过滤就可以了:)一个转自CU的自动获取脚本 :复制代码 代码如下:#!/bin/sh#auto get the IP Table#get the newest delegated-apnic-latestrm delegated-apnic-latestif type wgetthen wget http://ftp.apnic.net/apnic/stats/apnic/delegated-apnic-latestelse fetch http://ftp.apnic.net/apnic/stats/apnic/delegated-apnic-latestfigrep…