harumaki.net

インフラ屋の覚書や、ラーメン食べある記とか。

infra network 運用

trafshow

投稿日:2006年10月3日

Last Updated on 2012年6月21日 by かんりにん

[pukiwiki]

#topicpath

#contents

*trafshow [#u9455f3e]

トラフィック・モニターtrafshowのインストールと動作具合をテスト。
//ググっても情報少ないのできつめかも。

[本家ページ]※ロシア語
http://soft.risp.ru/trafshow/index.shtml

[英語ページ]
http://soft.risp.ru/trafshow/index_en.shtml

[ダウンロードページ]
http://soft.risp.ru/download.shtml

**ダウンロード/インストール [#s0eebeef]
よくわからないので、ヘルプを見つつオプションをつけずにビルドしてみる。
# pwd
/usr/local/src
# wget ftp://ftp.nsk.su/pub/RinetSoftware/trafshow-4.0.tgz
# tar -zxvf trafshow-4.0.tgz
# cd trafshow-5.2.3/ ←アーカイブのバージョン名と展開したバージ ョンが違う…
# ./configure
# make
# make install
./install-sh -c -s -m 555 -o bin -g bin trafshow /usr/local/bin/trafshow
./install-sh -c -m 444 -o bin -g bin trafshow.1 /usr/local/man/man1/trafshow.1
[ -f /etc/trafshow ] || ./install-sh -c -m 444 .trafshow /etc/trafshow
#
make installを見ると、設定ファイル、バイナリ、マニュアルをそれぞれに展開して完了。
割りとインストールでの手間はなかった。

**動作テスト [#a00b2dc3]
/usr/local/binにバイナリがおかれているので、シェルからパスなしで実行OK。
オプションを指定しない場合は最初にIFの選択画面が出る。

# trafshow →Enterキー

-インターフェースの選択
オプションなしで起動した場合の最初の画面。
インターフェースを選択してEnterキーを押すとnetstatと同じ情報が出力される。
Interface Address Description
===========================================================================================================
eth0 0:c:29:96:be:af 192.168.0.4 Ethernet
lo 127.0.0.1 Loopback

===========================================================================================================

-出力結果
インターフェースを選択してEnterキーを押すとnetstatと同じ情報が出力され、1秒ごとに更新される。
Source Destination Protocol Size CPS
===========================================================================================================
a123.example.com,ssh b456.example.com,1211 tcp 14K 445
nkabe.example.com,netbios-dg 192.168.0.255,netbios-dg udp 2422 178
dev613.example.com,netbios-dg 192.168.0.255,netbios-dg udp 1471 199
dell2.sms.example.com,netbios-dg 192.168.0.255,netbios-dg udp 1309 228
b456.example.com,1211 a123.example.com,ssh tcp 756 20
mail.example.com,domain a123.example.com,32792 udp 496 44
00:b0:d0:2d:**:** broadcast arp 480 59
192.168.0.137,netbios-dg 192.168.0.255,netbios-dg udp 432 229
mktg.example.com,netbios-dg 192.168.0.255,netbios-dg udp 430 165
00:0f:1f:3b:**:** 01:80:c2:00:00:00 stp 420 27
foo.a.host.example.com,netbios-ns 192.168.0.255,netbios-ns udp 312 105
0*:**:6*:3f:**:** broadcast arp 300 58
**:01:*3:**:**:** broadcast arp 240 234
**:01:8*:*7:**:** broadcast arp 240 58
foo.a.host.example.com,netbios-ns 192.168.0.255,netbios-ns udp 234 146
192.168.***.5,netbios-dg 192.168.0.255,netbios-dg udp 220
a123.example.com,32792 mail.example.com,domain udp 289 9
192.168.2.***,netbios-dg 192.168.0.255,netbios-dg udp 215
00:14:22:73:**:** broadcast arp 212 15
mail.example.com,domain a123.example.com,32791 udp 182
mail.example.com,domain a123.example.com,32790 udp 182
mail.example.com,domain a123.example.com,32786 udp 179
mail.example.com,domain a123.example.com,32785 udp 179
mail.example.com,domain a123.example.com,32787 udp 179
mail.example.com,domain a123.example.com,32789 udp 176
mail.example.com,domain a123.example.com,32788 udp 136
b456.example.com,2273 nkabe.example.com,netbios-ss tcp 133
===========================================================================================================
eth0 92 Flows Total: 31K 4155

**参考[コマンドラインオプション] [#we8f3347]
コマンドラインでのオプションは以下のような感じ(要訳)

# trafshow –help
Usage:
trafshow [-vpnb] [-a len] [-c conf] [-i ifname] [-s str] [-u port] [-R refresh] [-P purge] [-F file | expr]
Where:
-v Print version number, compile-time definitions, and exit
-p Don’t put the interface(s) into promiscuous mode
-n Don’t convert numeric values to names
-b To place a backflow near to the main stream
-a len To aggregate IP addresses using the prefix length
-c conf Color config file instead of default /etc/trafshow
-i ifname Network interface name; all by default
-s str To search & follow for string in the list show
-u port UDP port number to listen for Cisco Netflow; default 9995
-R refresh Set the refresh-period of data show to seconds; default 2 sec
-P purge Set the expired data purge-period to seconds; default 10 sec
-F file Use file as input for the filter expression
expr Filter expression; see tcpdump(1) for syntax
[/pukiwiki]

-infra, network, 運用
-,

執筆者:


comment

メールアドレスが公開されることはありません。 が付いている欄は必須項目です

CAPTCHA


関連記事

no image

[juniper] SRX(JunOS) ルーティング不具合修正(非対称ルートへの対応)

  SSGシリーズからSRX220にリプレイスを行った際に、VPNを経由したリモートオフィスとのLAN通信がうまくいかない事象が起きたので、トラブルシュート。 ・社内LANにおいてゲートウェイが複数あ …

no image

[Juniper]SRX ssh公開鍵認証でログイン

LinuxサーバーへdailyでSRXのコンフィグをバックアップするべく、tftpサーバーを設定しようと思ったら どうやらtftpらしきものがないので、sshでリモートコマンドを使ってコンフィグをとっ …

no image

[NTP]StepモードとSlewモード

DBサーバの時間同期の修正にあたって、どのくらいゆっくり修正できるのか調べたら、もともと”Slewモード”という”ゆっくり修正オプション(?)”があった …

YAMAHA RTX1200 VPNアカウント作成手順(PPTP)

前提条件 すでにVPNサービスが稼働している状態でのアカウント追加の手順。 注意事項としては -トンネルバインド数およびIPアドレスプールを一緒に追加する トンネルバインド数、IPアドレスプールの範囲 …

no image

[パッケージ管理]porgのインストール

[pukiwiki] テスト環境にpacoを入れておこうと、久々に本家サイトへアクセスしたら “This project is no longer active.”とのこと。あ …

Amazon プライム対象