본문 바로가기

728x90

ping check

ping, telnet으로 통신(포트) 상태 확인 ping, telnet으로 통신(포트) 상태 확인 ping test(ICMP) $ ping -c 3 8.8.8.8 PING 8.8.8.8 (8.8.8.8) 56(84) bytes of data. 64 bytes from 8.8.8.8: icmp_seq=1 ttl=105 time=26.5 ms 64 bytes from 8.8.8.8: icmp_seq=2 ttl=105 time=26.5 ms 64 bytes from 8.8.8.8: icmp_seq=3 ttl=105 time=26.5 ms --- 8.8.8.8 ping statistics --- 3 packets transmitted, 3 received, 0% packet loss, time 2003ms rtt min/avg/max/mdev = 26.519.. 더보기
ping check 스크립트 ping check 스크립트 vim pingcheck.sh #!/bin/bash while true; do if ping -c 1 192.168.2.1 >/dev/null; then echo "$(date '+%Y-%m-%d %H:%M:%S') : Success" >> tempfile else echo "$(date '+%Y-%m-%d %H:%M:%S') : Fail" >> tempfile fi sleep 1 done 이제 위의 코드는 1초마다 192.168.2.1에 대한 ping을 수행하고 결과를 tempfile에 기록하는 스크립트로 사용할 수 있습니다. chmod +x pingcheck.sh bash pingcheck.sh & $ tail -f tempfile 2015-03-27 13:41:35 : .. 더보기
원도우에서 tcping을 사용하는 방법 원도우에서 tcping을 사용하는 방법 TCP 포트의 가용성을 확인하기 위한 유용한 도구입니다. tcping.exe - ping over a tcp connection tcping 설치 tcping 다운로드 URL https://www.elifulkerson.com/projects/downloads/tcping-0.34/tcping.exe 다운로드 위치 : D:\app\bind9\bin 환경 변수 : Path 설정 tcping 명령어 사용 tcping -h sangchul.kr C:\Users\Administrator>tcping -h sangchul.kr ** Requesting from sangchul.kr: (for various reasons, kbit/s is an approximation) P.. 더보기

728x90