User Tools

Site Tools


ipv6accesses

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

ipv6accesses [2011/06/20 21:56] (current)
2001:6f8:1dda:0:20f:eaff:fe3e:8d10 created
Line 1: Line 1:
 +====== IPv6 Accesslog Snippets ======
  
 +
 +All IPv4 addresses:
 +
 +  cat access.log |awk '/​^[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+/​ {print $1}'
 +
 +All IPv6 addresses:
 +
 +  cat access.log |awk '​!/​^[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+/​ {print $1}'
 +
 +
 +Unique first block prefixes:
 +
 +  cat access.log |awk '​!/​^[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+/​ {print $1}'| awk -F: '​{print $1}'​|sort -n| uniq -c|sort -nr
 +
 +Unique full prefixes (but might be full address):
 +
 +  cat access.log |awk '​!/​^[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+/​ {print $1}'| awk -F:: '​{print $1}'​|sort|uniq -c|sort -nr
ipv6accesses.txt ยท Last modified: 2011/06/20 21:56 by 2001:6f8:1dda:0:20f:eaff:fe3e:8d10