Mac Terminal Cheat Sheet



ipconfig

  1. An A-Z Index of the Apple OS X command line (TERMINAL) The tcsh command shell of Darwin (the open source core of OSX) alias Create an alias alloc List used and free memory awk Find and Replace text within file(s) basename Convert a full pathname to just a folder path bash Bourne-Again SHell (Linux).
  2. Our cheat sheet explains the essential tasks on the command line. Download it for free. For many, the command line belongs to long gone days: when computers were controlled by typing mystical commands into a black window; when the mouse possessed no power. But for many use cases, the command line is still absolutely indispensable!
  3. Mac Terminal Cheat Sheet. GitHub Gist: instantly share code, notes, and snippets.

Cheat Sheet 7: MakeUseOf.com. This cheat sheet is for the MAC terminal. It has the command and a description to what the command does. It does not have any examples in it, but it is pretty straight forward on the commands and actions performed. Pros: Rated ā€˜E’ for everyone. Cons: None that I can see. Cheat Sheet 8: SysTweak Blog.

  1. get ip address

  2. get subnet mask

  3. get dns server

  4. get info about how en0 got its dhcp on

ifconfig

  1. get network info

  2. set ip address and netmask

  3. renew dhcp leases

networksetup

  1. get a list of location on the computer

  2. get active location

  3. config manual static ip address

  4. config dns server

  5. get dns server

firewall

  1. stop the application layer firewall

  2. start the application layer firewall

  3. allow an app to communicate outside through the application layer firewall

route

  1. routing table

  2. add a route

  3. delete a route

Terminal

netstat

  1. view info on all sockets

  2. network info for ipv6

  3. per protocol network statistics

  4. statistics for a specific network protocol

  5. statistics for network interfaces

  6. view network info as it happens

ping

Macos Command Line Cheat Sheet

  1. put a delay in pings

  2. ping hostname 5 times and then stop

  3. flood ping the host

  4. set packet size during ping

  5. customize source ip during ping

trace

  1. trace the path packets go through

  2. without looking up names

  3. in debug mode

Git Terminal Commands Mac Cheat Sheet

nc

  1. establish a network connection

  2. establish a network connection over port 2195

  3. establish a network connection only allowing ipv4

  4. setup a network listener on port 2196 for testing

tcpdump

  1. capture some packets

  2. capture all packets

  3. capture packets for port

  4. capture all packets for a given port going to destination 192.168.1.160

  5. capture packets as above but dump to a pcap file

  6. read tcpdump (cap) files and make them human readable

other

Mac Terminal Cheat Sheet

  1. flush the dns cache

  2. clear arp cache

  3. what binaries have what ports and in what states are those ports

  4. make an alias for looking at what has a listener open, called ports

  5. edit hosts file

Mac Os Terminal Cheat Sheet

references