Skip to content

Instantly share code, notes, and snippets.

@CharlieGreenman
Created July 25, 2019 08:47
Show Gist options
  • Save CharlieGreenman/ea3d3f8ee498ca3bcaf76c37bd2f88c4 to your computer and use it in GitHub Desktop.
Save CharlieGreenman/ea3d3f8ee498ca3bcaf76c37bd2f88c4 to your computer and use it in GitHub Desktop.
How to get ip address for your current ubuntu server
ip addr show eth0 | grep inet | awk '{ print $2; }' | sed 's/\/.*$//'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment