title: Using Awk to add hostname to line
body: <p>I have this text file TopIP.txt:
  (fiction IPs and hostname)</p>
  
  <pre><code>Top destination for Source IP 1.2.3.4
      34322 2.3.4.5
      455   2.3.4.6
  </code></pre>
  
  <p>I want to add the hostname to each IP at the end of the line. My desire output is this:</p>
  
  <pre><code>Top destination for Source IP 1.2.3.4 hostname3.com
      34322 2.3.4.5 hostname1.com
      455   2.3.4.6 hostname2.com
  </code></pre>
  
  <p>I made it happen last week and didnt save and now i cant replicate it.</p>
  
  <p>my code started something similar to this:</p>
  
  <pre><code>cat TopIP.txt | awk '{print $0, system("host " $NF)}'
  </code></pre>