BTC: 3B74XpJ12oucMsEgxVbZqwYd6XPgGs8GXt / ETH: 0xae7d573142e3b918cc9d2b0bf35a5f9cb35619e3

Monday 6 February 2023

How To Find My Public IP Address From Linux CLI

Explain IP addresses

IP is short for Internet Protocol. It is used to identify computers or mobile devices on the Internet. Each device connected to the Internet has an IP address. IP address can be used to personalize information.
Use dig command for determining my public IP address Linux:

Open the Terminal application on Linux, macOS or Unix.

Type the following dig (domain information groper) command on a Linux, OS X, or Unix-like operating systems to see your own public IP address assigned by the ISP:

$ dig +short

You can also type:

$ dig TXT +short

Get external IP address in a shell using Cloudflare:

$ dig +short txt ch whoami.cloudflare @

Show your public IPv6 on Linux:

$ dig -6 TXT +short

You should see your IP address on screen. This is the fastest way to find out your IP address without using 3rd party site.

Fig.01: Use dig command to find your IP address

No comments:

Post a Comment