#!/bin/sh
PORT0=Port0
DATE1=`usban | grep $PORT0 | awk '{print $3}' | awk -F. '{print $1}' | awk '$DATE1<=0{print $1}'`
#echo $DATE1
#
if [ "$DATE1" = 0 ]
then
echo OFF-状態
#
else
echo ON-状態
#/home/kkuma/HDH3/ON-OFF/$PORT0-ON-OFF
/usr/local/bin/tira2_trans2 /usr/local/bin/tira2code/SW-BOX/ext-sw-14ch
sleep 5;echo ""
fi
#
PORT1=Port1
DATE1=`usban | grep $PORT1 | awk '{print $3}' | awk -F. '{print $1}' | awk '$DATE1<=0{print $1}'`
#echo $DATE1
#
if [ "$DATE1" = 0 ]
then
echo OFF-状態
#
else
echo ON-状態
#/home/kkuma/HDH3/ON-OFF/$PORT1-ON-OFF
/usr/local/bin/tira2_trans2 /usr/local/bin/tira2code/SW-BOX/ext-sw-13ch
sleep 5;echo ""
fi
#
PORT2=Port2
DATE1=`usban | grep $PORT2 | awk '{print $3}' | awk -F. '{print $1}' | awk '$DATE1<=0{print $1}'`
#echo $DATE1
#
if [ "$DATE1" = 0 ]
then
echo OFF-状態
#
else
echo ON-状態
#/home/kkuma/HDH3/ON-OFF/$PORT2-ON-OFF
/usr/local/bin/tira2_trans2 /usr/local/bin/tira2code/SW-BOX/ext-sw-12ch
sleep 5;echo ""
fi
#
PORT3=Port3
DATE1=`usban | grep $PORT3 | awk '{print $3}' | awk -F. '{print $1}' | awk '$DATE1<=0{print $1}'`
#echo $DATE1
#
if [ "$DATE1" = 0 ]
then
echo OFF-状態
#
else
echo ON-状態
#/home/kkuma/HDH3/ON-OFF/$PORT3-ON-OFF
/usr/local/bin/tira2_trans2 /usr/local/bin/tira2code/SW-BOX/ext-sw-11ch
sleep 5;echo ""
#
echo ""
usban
Comments