Post is quite too long to read the last solution so this is the latest one:
And for the people who don't want to use Ruby - the bash only version of the script:
1. Create list of ips to check
nano ~/ips
Content:
127.0.0.1
186.0.0.1
10.1.1.1
2. Create list of node ping tests for the given...