Slacker News Slacker News logo featuring a lazy sloth with a folded newspaper hat
  • top
  • new
  • show
  • ask
  • jobs
Library

Comment by contingencies

4 hours ago

You'd better use the default route and not some random IP, particularly DNS IPs which people often meddle with.

  # IPv4 default route only
  uname
  Darwin$ route -n get 0.0.0.0 | grep interface | cut -d ':' -f2
  Linux$ route -nv  |grep ^0.0.0.0 | awk '{print $NF}'

0 comments

contingencies

Reply

No comments yet

Contribute on Hacker News ↗

Slacker News

Product

  • API Reference
  • Hacker News RSS
  • Source on GitHub

Community

  • Support Ukraine
  • Equal Justice Initiative
  • GiveWell Charities