bookstand

Taming the Terminal

The Technical Manual and Podcast to Master the macOS Command Line

Bart Busschots

First annotation on .

4 quotes


TTT Part 23 of n — Networking Intro

  • You can use the terminal command traceroute (tracert on Windows) to see what routers a packet follows from your computer to my server as follows:Apr 28 2022 9:24PM
  • In the first window, we’ll use the tcpdump command to print out each packet that is sent from your computer to my server as follows: sudo tcpdump -nn host 46.22.130.125Apr 28 2022 9:25PM

TTT Part 26 of n — DHCP

  • Finally, ipconfig can be used to show the DHCP ACK packet that was used to configure a network interface (again replacing enX with the actual interface you want to get the packet for): sudo ipconfig getpacket enXApr 28 2022 9:27PM

TTT Part 27 of n — DNS

  • On most Linux and Unix OSes, DNS resolution is controlled using the configuration file /etc/resolv.conf. This file is present in OS X but is used as a way for the OS to expose the settings to scripts and command-line utilities rather than as a way of controlling DNS configuration. The file on OS X is in the identical format to the ones on Linux and Unix. You can have a look at this file with the command:Apr 28 2022 9:28PM