1. 程式人生 > >centos下安裝tcping腳本

centos下安裝tcping腳本

mark usr 編輯 ping http ins size com shadow

#編輯腳本

vim tcping.sh

#! /bin/bash

cd /usr/local/src
wget https://raw.githubusercontent.com/Fsiyuetian/tcping/master/tcping.c
yum install -y gcc
gcc -o tcping tcping.c
cp tcping /usr/bin
tcping baidu.com 80

#運行腳本
sh tcping.sh

#執行後效果如下表示安裝成功
技術分享圖片

centos下安裝tcping腳本