Skip to content

Instantly share code, notes, and snippets.

@x-way
Created May 28, 2013 08:35
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save x-way/5661355 to your computer and use it in GitHub Desktop.
Save x-way/5661355 to your computer and use it in GitHub Desktop.
Get the glue records for a domain
#!/bin/bash
TGT=$1
ROOT=${TGT##*.}
ROOT=${ROOT%.}
ROOT="${ROOT}."
RS=$(dig +short -t ns $ROOT|sed 1q)
dig +noall +additional +norec $TGT @$RS
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment