Checking Machine and Service Availability : ping « Network « Ruby





Checking Machine and Service Availability

require 'ping'

puts "Pong!" if Ping.pingecho('localhost', 5)

 

Related examples in the same category

1.use the ping library to check servers that are online
2.Using net-ping
3.Use net-ping to connect to a specific port using TCP or UDP