Link to home
Avatar of Ikky786
Ikky786

asked on

Is there a command in Linux which displays the public ip address just like i.e.http://whatismyipaddress.com/

Command to display public ip address in Linux please?
ASKER CERTIFIED SOLUTION
Avatar of woolmilkporc
woolmilkporc
Flag of Germany image

Blurred text
THIS SOLUTION IS ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
If you have a browser on Linux, you can just go to http://whatismyipaddress.com/ on the internet.  Otherwise, you may only see an internal LAN IP address and not your public IP address.
Avatar of Ikky786
Ikky786

ASKER

ok that's good what do the flags mean?
Another site to get your external IP is grc.com.  Scroll down to ShieldsUp and this test will show you the IP and DNS name.
-q suppress wget's status output

-O -  don't create files, write to standard output ( - ) instead
You need to install lynx... sudo yum install lynx (or apt-get, or whatever your distribution is)... then run it like...

lynx --dump http://ipecho.net/plain