#!/bin/bash if ssh "root@$1" -o ConnectTimeout=6 -o BatchMode=yes -o StrictHostKeyChecking=no -- bash <&2 echo "$1" >> unavailable.txt fi