Simple bash script for checking network availability

First published at 11:51 UTC on August 24th, 2022.
subscribers

#!/bin/bash

if [ $# -eq 1 ]; then
ping -q -c 1 $1 2>&1

if [ $? -eq 0 ]; then
echo "Connected"
else
echo "Not Connected"
fi
else
echo "requires hostname"
if

#script has been write…

MORE
CategoryScience & Technology
SensitivityNormal - Content that is suitable for ages 16 and over
DISCUSS THIS VIDEO