查看公网IP

linux上查看公网IP

yum install bind-utils  -y
dig +short myip.opendns.com @resolver1.opendns.com

windows上查看公网IP

$tmp =Invoke-WebRequest -URI http://myip.dnsomatic.com/
$tmp.Content 
posted @ 2021-11-17 15:56  JinweiChang  阅读(54)  评论(0编辑  收藏  举报