[root@logserver sbclog]# cat checksbc1.sh #!/bin/bashnport=`echo ""|telnet 10.134.41.1 23 2>/dev/null|grep "\^]"|wc -l`if [ "$nport" -eq "0" ];thenmail -s 'xxxxxx' xxxxxxx@163.com < /home/sbclog/sx30001/check.txt fi
用telnet检查服务端口是否打开
本文共 276 字,大约阅读时间需要 1 分钟。
[root@logserver sbclog]# cat checksbc1.sh #!/bin/bashnport=`echo ""|telnet 10.134.41.1 23 2>/dev/null|grep "\^]"|wc -l`if [ "$nport" -eq "0" ];thenmail -s 'xxxxxx' xxxxxxx@163.com < /home/sbclog/sx30001/check.txt fi
用telnet检查服务端口是否打开
转载于:https://blog.51cto.com/9796716/1715047