Backtracking to find a less error-prone script-creation process:

Step (1): Apply Magic Banana's one-line processor to the single-column Hostname_List containing all the Webalizer
records for a time period:

tr -sc 0-9\\n ' ' < hostname_list | awk '{ k = 0; for (i = 0; k < 4 && ++i Two-Col-Output-Sorted.txt

Where it will be clear that many bare IPv4 addresses are duplicated, along with many resolved hostnames, but there will be unintended bystanders that have legitimate IPv4 addresses but are absent from the original hostname_list that are not duplicated, along with bare IPv4 addresses that weren't resolved with nMap and also aren't duplicated.

Step (4) Select the properly resolved outputs from the sorted output file:

I tried selecting just the duplicated rows of the sorted output file, but that discarded legitimately resolved hostnames along with the inadvertent bystanders, so the sorted hostname_list file has to be compared to the sorted output file in order to retain all the properly resolved input hostnames. This can be done with LibreOffice Calc, but that would be
considered "off-script" in the present discussion.

Hostnames that haven't been resolved with the main script have to be included and resolved by using other search methods,
such as Google and Hurricane Electric.

Steps (1 -3) can be concatenated:

time tr -sc 0-9\\n ' ' < CPV-GB-OneCol0-6192019.txt | awk '{ k = 0; for (i = 0; k < 4 && ++i CPV-NSL-Supplemental-Output-Sorted.txt

Lots of post-processing to be done.

Reply via email to