Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.os.linux.networking > #4497 > unrolled thread
| Started by | Chris Elvidge <chris@mshome.net> |
|---|---|
| First post | 2019-11-26 13:41 +0000 |
| Last post | 2019-11-28 01:28 +0000 |
| Articles | 7 — 5 participants |
Back to article view | Back to comp.os.linux.networking
Get IP address Chris Elvidge <chris@mshome.net> - 2019-11-26 13:41 +0000
Re: Get IP address Bit Twister <BitTwister@mouse-potato.com> - 2019-11-26 07:52 -0600
Re: Get IP address Chris Elvidge <chris@mshome.net> - 2019-11-26 14:03 +0000
Re: Get IP address Roger Blake <rogblake@iname.invalid> - 2019-11-26 17:58 +0000
Re: Get IP address Bit Twister <BitTwister@mouse-potato.com> - 2019-11-26 14:26 -0600
Re: Get IP address "David W. Hodgins" <dwhodgins@nomail.afraid.org> - 2019-11-26 16:40 -0500
Re: Get IP address Dan Purgert <dan@djph.net> - 2019-11-28 01:28 +0000
| From | Chris Elvidge <chris@mshome.net> |
|---|---|
| Date | 2019-11-26 13:41 +0000 |
| Subject | Get IP address |
| Message-ID | <qrja2g$gof$1@dont-email.me> |
I'm getting different results for my IP address from successive consecutive calls to whatismyipaddress.com and ifconfig.me/ip, depending whether I use wget/curl or links. eg: $ IP=$(wget -O- ifconfig.me/ip 2>/dev/null); echo $IP 217.171.129.78 $ IP=$(wget -O- --user-agent=links whatismyipaddress.com 2>/dev/null | grep -m1 IPv4: | cut -d'>' -f5 | cut -d'<' -f1); echo $IP 94.197.120.175 $ links -dump ifconfig.me/ip | tr -d ' ' 92.40.255.5 $ links -dump whatismyipaddress.com 2>/dev/null | \ > grep -m1 -A1 "IPv4:" | \ > tail -n1 | \ > tr -d ' ' 94.197.120.175 Does it really change that fast? Anyone any ideas why? Thanks. Internet via hotspot, 3 SIM in Windows phone. -- Chris Elvidge, England
[toc] | [next] | [standalone]
| From | Bit Twister <BitTwister@mouse-potato.com> |
|---|---|
| Date | 2019-11-26 07:52 -0600 |
| Message-ID | <slrnqtqbh2.1aq.BitTwister@wb.home.test> |
| In reply to | #4497 |
On Tue, 26 Nov 2019 13:41:35 +0000, Chris Elvidge wrote: > I'm getting different results for my IP address from successive > consecutive calls to whatismyipaddress.com and ifconfig.me/ip, depending > whether I use wget/curl or links. eg: > Does it really change that fast? Anyone any ideas why? Thanks. Maybe you need to get a second opinion from other sites. curl http://icanhazip.com curl http://ident.me curl whatismyip.akamai.com wget -qO - http://icanhazip.com wget -qO - http://ident.me/ wget -qO - http://smxi.org/opt/ip.php
[toc] | [prev] | [next] | [standalone]
| From | Chris Elvidge <chris@mshome.net> |
|---|---|
| Date | 2019-11-26 14:03 +0000 |
| Message-ID | <qrjbcf$p8n$1@dont-email.me> |
| In reply to | #4498 |
On 26/11/2019 13:52, Bit Twister wrote: > On Tue, 26 Nov 2019 13:41:35 +0000, Chris Elvidge wrote: >> I'm getting different results for my IP address from successive >> consecutive calls to whatismyipaddress.com and ifconfig.me/ip, depending >> whether I use wget/curl or links. eg: > >> Does it really change that fast? Anyone any ideas why? Thanks. > > Maybe you need to get a second opinion from other sites. > > curl http://icanhazip.com > curl http://ident.me > curl whatismyip.akamai.com > wget -qO - http://icanhazip.com > wget -qO - http://ident.me/ > wget -qO - http://smxi.org/opt/ip.php > Thanks for that. It seems it's ifconfig.me/ip that's the outlier here. -- Chris Elvidge, England
[toc] | [prev] | [next] | [standalone]
| From | Roger Blake <rogblake@iname.invalid> |
|---|---|
| Date | 2019-11-26 17:58 +0000 |
| Message-ID | <20191126125622@news.eternal-september.org> |
| In reply to | #4498 |
On 2019-11-26, Bit Twister <BitTwister@mouse-potato.com> wrote: > Maybe you need to get a second opinion from other sites. I like http://checkip.dyndns.com, works with any browser (including lynx etc.) and just returns the IP address without a lot of cruft. -- ----------------------------------------------------------------------------- Roger Blake (Posts from Google Groups killfiled due to excess spam.) NSA sedition and treason -- http://www.DeathToNSAthugs.com Don't talk to cops! -- http://www.DontTalkToCops.com Badges don't grant extra rights -- http://www.CopBlock.org -----------------------------------------------------------------------------
[toc] | [prev] | [next] | [standalone]
| From | Bit Twister <BitTwister@mouse-potato.com> |
|---|---|
| Date | 2019-11-26 14:26 -0600 |
| Message-ID | <slrnqtr2ir.pjt.BitTwister@wb.home.test> |
| In reply to | #4500 |
On Tue, 26 Nov 2019 17:58:07 -0000 (UTC), Roger Blake wrote: > On 2019-11-26, Bit Twister <BitTwister@mouse-potato.com> wrote: >> Maybe you need to get a second opinion from other sites. > > I like http://checkip.dyndns.com, works with any browser (including > lynx etc.) and just returns the IP address without a lot of cruft. In a browser, somewhat true. But for getting the ip into a variable via a script, there is way too much cruft. For example: $ curl http://checkip.dyndns.com <html><head><title>Current IP Check</title></head><body>Current IP Address: 48.143.134.52</body></html>
[toc] | [prev] | [next] | [standalone]
| From | "David W. Hodgins" <dwhodgins@nomail.afraid.org> |
|---|---|
| Date | 2019-11-26 16:40 -0500 |
| Message-ID | <op.0bvs55e0a3w0dxdave@hodgins.homeip.net> |
| In reply to | #4501 |
On Tue, 26 Nov 2019 15:26:00 -0500, Bit Twister <BitTwister@mouse-potato.com> wrote: > $ curl http://checkip.dyndns.com > <html><head><title>Current IP Check</title></head><body>Current IP Address: 48.143.134.52</body></html> The following work, returning just the ip address ... wget -qO - icanhazip.com wget -qO - http://myip.dnsomatic.com/ wget -qO - http://ident.me/ Regards, Dave Hodgins -- Change dwhodgins@nomail.afraid.org to davidwhodgins@teksavvy.com for email replies.
[toc] | [prev] | [next] | [standalone]
| From | Dan Purgert <dan@djph.net> |
|---|---|
| Date | 2019-11-28 01:28 +0000 |
| Message-ID | <slrnqtu8l8.doa.dan@djph.net> |
| In reply to | #4497 |
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA256 Chris Elvidge wrote: > Internet via hotspot, 3 SIM in Windows phone. There's the reason right there. Your ISP is rotating you through different ruotes out of their network (i.e. they're employing CGNAT). -----BEGIN PGP SIGNATURE----- iQEzBAEBCAAdFiEEBcqaUD8uEzVNxUrujhHd8xJ5ooEFAl3fIqcACgkQjhHd8xJ5 ooE2mgf/d3BhRfT2CxfT5LapYEMEj10ghmzhu4dDsIL4ua/5gB5iyRnp9b/ItXez l8oQeHtdbwRIrjDLYH8uYPoeAU2B/V9zdhTJm7pI3AYNRHvTYAElENtvMbV20png xyLplRklWYFQerz0kyrlBYGtV0ow0rjnepTA7GtSeb4TBMNd3sggCqQ5CXqjLJuj 33BVcVvq+pDP0wnEj7gKbwwmVBmf3djv/auPdAs4QBwNfQeFCQsklJKNywtX44tU y+0tjesOB1CcgdTeMj/z8g4pHPks0m/uPgko3dL8rRz+Jsrvb+qO/YkxDvR8iwPX 7pvs1dhQGzq1d6VlDKxxqRp7UK0+Fg== =x+uA -----END PGP SIGNATURE----- -- |_|O|_| |_|_|O| Github: https://github.com/dpurgert |O|O|O| PGP: 05CA 9A50 3F2E 1335 4DC5 4AEE 8E11 DDF3 1279 A281
[toc] | [prev] | [standalone]
Back to top | Article view | comp.os.linux.networking
csiph-web