Quote:
echo "Number of unique I.P.'s: "
uniq $2 HITS | wc -l
|
I have this code.
In the file called HITS.hits my results are displayed liked this:
filename.hits: 35.114.42.113 Mon Nov 21 08:26:41 GMT 2005
What i want my code to do is to search all of the unique IP addresses.
so count all the adresses that appear.
but just count repeat IPs that are the same as 1.
so if my file had:
filename.hits: 11.111.11.111
filename.hits: 33.333.33.333
filename.hits: 22.222.22.222
filename.hits: 44.33.222.111
filename.hits: 11.111.11.111
the answer would be 4.