Skip to content

Instantly share code, notes, and snippets.

@kbbgl
Last active May 10, 2020 18:12
Show Gist options
  • Select an option

  • Save kbbgl/871a314e2a218380433bad3b160e31a7 to your computer and use it in GitHub Desktop.

Select an option

Save kbbgl/871a314e2a218380433bad3b160e31a7 to your computer and use it in GitHub Desktop.
[inline for look in bash] #bash
#!/bin/bash
# If iplist.txt contains a list of IPs in each line:
# 192.168.1.1
# 192.168.1.2
# ...
# & runs each ping in different thread
for ip in $(cat iplist.txt): do ping $ip & done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment