dig + short The command (as described in "Dig Show Only Answer") is great for batching names into IP addresses. It does a simple job and does it well.
Unfortunately, if there is even a CNAME
+ short is not short enough For example:
$ dig + short docs.sbonds.org ghs.google.com. 220.127.116.11
+ No But it does not seem like it's changing behavior
+ short, I also tried to specify
-t a However, just to make sure that it was not intended for an A-record or CNAME, this (unsurprisingly) does not change anything.
$ dig + noall + short docs.sbonds.org ghs.google.com. 18.104.22.168
I am using RedHat 7
# dig -v DiG 9.9.4-RedHat-9.9.4-73.el7_6
I can filter out the CNAMEs with confidence
grepbut it seems like dig has a way to give "Just the IP, ma'am".
What is it