差分
このページの2つのバージョン間の差分を表示します。
両方とも前のリビジョン 前のリビジョン 次のリビジョン | 前のリビジョン最新のリビジョン両方とも次のリビジョン | ||
ja:documentation:05_big_environments:04_netflow [2022/10/28 22:15] – [Netflow プローブのインストール] junichi | ja:documentation:05_big_environments:04_netflow [2023/05/12 06:25] – [設定] junichi | ||
---|---|---|---|
行 1: | 行 1: | ||
- | ====== Netflow によるネットワークトラフィック監視 ====== | + | ====== Netflow |
{{indexmenu_n> | {{indexmenu_n> | ||
行 146: | 行 146: | ||
</ | </ | ||
- | たとえば、このコマンドを実行すると、すべての | + | For instance, executing this command, all '' |
- | | + | たとえば、このコマンドを実行すると、すべての '' |
+ | |||
+ | < | ||
+ | / | ||
+ | |||
+ | </ | ||
+ | |||
+ | Once the traffic has been generated, you may see its statistics in the NetFlow collector by entering this command: | ||
トラフィックが生成されたら、次のコマンドでトラフィックの状態を見る事ができます。 | トラフィックが生成されたら、次のコマンドでトラフィックの状態を見る事ができます。 | ||
+ | < | ||
+ | nfdump -R / | ||
- | nfdump -R / | + | </code> |
次のような情報が表示されます。 | 次のような情報が表示されます。 | ||
行 192: | 行 201: | ||
ここまでの動作確認ができたら、次はそれを利用できるようにするための Pandora FMS の設定です。 | ここまでの動作確認ができたら、次はそれを利用できるようにするための Pandora FMS の設定です。 | ||
+ | |||
+ | == pmacct のインストール == | ||
+ | |||
+ | <WRAP center round info 60%> | ||
+ | |||
+ | Experimental. | ||
+ | |||
+ | </ | ||
+ | |||
+ | <WRAP center round info 60%> | ||
+ | |||
+ | 実験的 | ||
+ | |||
+ | </ | ||
+ | |||
+ | Among many features of the [[http:// | ||
+ | |||
+ | [[http:// | ||
+ | |||
+ | The source code is hosted at: | ||
+ | |||
+ | ソースコードは以下にあります。 | ||
+ | |||
+ | <WRAP center round download 60%> | ||
+ | |||
+ | [[https:// | ||
+ | |||
+ | </ | ||
+ | |||
+ | **Rocky Linux 8** | ||
+ | |||
+ | Install dependencies with administrator rights: | ||
+ | |||
+ | 依存ファイルの管理者権限でのインストール。 | ||
+ | |||
+ | < | ||
+ | |||
+ | dnf config-manager --set-enabled powertools | ||
+ | dnf groupinstall ' | ||
+ | dnf install libpcap libpcap-devel | ||
+ | |||
+ | </ | ||
+ | |||
+ | Download **pmacct** source code (you may use **curl** instead of **wget**) and build it: | ||
+ | |||
+ | **pmacct** のソースをダウンロード(**wget** の代わりに **curl** も使えます)してビルドします。 | ||
+ | |||
+ | < | ||
+ | cd /tmp | ||
+ | wget -O pmacct-1.7.7.tar.gz " | ||
+ | tar xvzf pmacct-1.7.7.tar.gz | ||
+ | cd pmacct-1.7.7 | ||
+ | ./ | ||
+ | ./configure | ||
+ | make && make install | ||
+ | |||
+ | </ | ||
+ | |||
+ | Start **pmacct** as a NetFlow probe in //daemon// mode: | ||
+ | |||
+ | // | ||
+ | |||
+ | * Create **pmacct** | ||
+ | |||
+ | * **pmacct** 設定の作成: | ||
+ | |||
+ | For instance, all '' | ||
+ | |||
+ | 例では、すべての '' | ||
+ | |||
+ | < | ||
+ | cat> pmacctd_probe.conf <<EOF | ||
+ | daemonize: true | ||
+ | pcap_interface: | ||
+ | aggregate: src_host, dst_host, src_port, dst_port, proto, tos | ||
+ | plugins: nfprobe | ||
+ | nfprobe_receiver: | ||
+ | nfprobe_version: | ||
+ | EOF | ||
+ | |||
+ | </ | ||
+ | |||
+ | * Start **pmacctd**: | ||
+ | |||
+ | * **pmacctd** の起動: | ||
+ | |||
+ | < | ||
+ | # pmacctd -f pmacctd_probe.conf | ||
+ | |||
+ | </ | ||
+ | |||
==== Pandora FMS における Netflow の動作 ==== | ==== Pandora FMS における Netflow の動作 ==== | ||
- | Pandora FMS は、補助システムとしての Netflow と連動します。つまり、データベースに NetFlow データを保存しません。 Pandora FMS は、その情報をオンデマンドでレポートとして表示します。 | ||
- | Pandora FMS は、//フィルタ// を使って Netflow データを処理します。フィルタは、通信パターンにマッチするルールのセットです。ルールは、' | + | Pandora FMS works along with Netflow as an auxiliary system, that means** it does not store NetFlow data in its database**. Pandora FMS shows that information as reports on demand. |
+ | |||
+ | Pandora FMS は、補助システムとしての Netflow と連動します。つまり、**データベースに NetFlow データを保存しません**。 Pandora FMS は、その情報をオンデマンドでレポートとして表示します。 | ||
+ | |||
+ | Pandora FMS works with NetFlow data by using filters, which are sets of rules that match certain traffic patterns. A rule can be as simple as 'all the traffic from 192.168.70.0/24 network' | ||
+ | |||
+ | Pandora FMS は、フィルタを使って Netflow データを処理します。フィルタは、通信パターンにマッチするルールのセットです。ルールは、' | ||
フィルタを作成したら、フィルタにマッチした情報をどのように表示するか(グラフや表)および時間範囲をレポートで定義する必要があります。Netflow レポートは、他の Pandora FMS レポートと同様にオンデマンドでのアクセスです。 | フィルタを作成したら、フィルタにマッチした情報をどのように表示するか(グラフや表)および時間範囲をレポートで定義する必要があります。Netflow レポートは、他の Pandora FMS レポートと同様にオンデマンドでのアクセスです。 | ||
行 210: | 行 315: | ||
<WRAP center round important 60%> Netflow データが保存されるハードディスクアクセス速度は、通常、パフォーマンスに関わる重要な要素です。</ | <WRAP center round important 60%> Netflow データが保存されるハードディスクアクセス速度は、通常、パフォーマンスに関わる重要な要素です。</ | ||
- | まず最初に、Netflow を操作(Operation)およびシステム管理(Administration)メニューからアクセスできるようにする必要があります。設定画面(管理メニュー)に、Netflow | + | First of all, enable NetFlow in order for it to become accessible from the **Operation** and **Administration |
- | {{ : | + | まず最初に、Netflow を **操作(Operation)** および **システム管理(Administration)** メニューからアクセスできるようにする必要があります。設定画面(**管理**メニュー)に、Netflow を有効化・無効化するオプションがあります。 |
+ | |||
+ | **For version 769 and earlier: | ||
+ | |||
+ | **バージョン 769 およびそれ以前: | ||
+ | |||
+ | {{ : | ||
+ | |||
+ | **For version 770 and later:** | ||
+ | |||
+ | **バージョン 770 およびそれ以降: | ||
+ | |||
+ | {{ : | ||
+ | |||
+ | Once activated, a new NetFlow configuration option will appear in the setup section. | ||
有効化すると、新たに Netflow 設定オプションが表示されます。 | 有効化すると、新たに Netflow 設定オプションが表示されます。 | ||
- | {{ | + | **For version 769 and earlier:** |
- | ここでは、nfcapd デーモンが Pandora FMS サーバと同時に起動するように正しく設定する必要があります。 | + | **バージョン 769 およびそれ以前: |
+ | |||
+ | {{ : | ||
+ | |||
+ | **For version 770 and later:** | ||
+ | |||
+ | **バージョン 770 およびそれ以降: | ||
+ | |||
+ | {{ : | ||
+ | |||
+ | This section must be correctly configured so that the **nfcapd **daemon may be started together with the Pandora FMS server: | ||
+ | |||
+ | ここでは、**nfcapd** デーモンが Pandora FMS サーバと同時に起動するように正しく設定する必要があります。 | ||
* **Data storage path: | * **Data storage path: | ||
- | * **Daemon interval:** | + | |
- | * **Daemon binary path: | + | |
- | * **Nfdump binary path: | + | * **Daemon binary path: |
- | * **Nfexpire binary path: | + | * **Nfdump binary path: |
+ | * **Nfexpire binary path: | ||
* **Maximum chart resolution: | * **Maximum chart resolution: | ||
- | * **Disable custom live view filters: | + | * **Disable custom live view filters: |
- | * **Netflow | + | * **NetFlow |
- | * **Enable IP address name resolution: | + | * **Enable IP address name resolution: |
+ | * **Daemon interval: | ||
* **データ保存パス(Data storage path):** Netflow データが保存されるディレクトリです。 | * **データ保存パス(Data storage path):** Netflow データが保存されるディレクトリです。 | ||
- | | + | |
- | * **デーモンバイナリパス(Daemon binary path): | + | * //バージョン 770 およびそれ以降// |
- | * **Nfdump バイナリパス(Nfdump binary path): | + | * **デーモンバイナリパス(Daemon binary path): |
- | * **Nfexpire バイナリパス(Nfexpire binary path): | + | * **Nfdump バイナリパス(Nfdump binary path): |
+ | * **Nfexpire バイナリパス(Nfexpire binary path): | ||
* **最大グラフ解像度(Maximum chart resolution): | * **最大グラフ解像度(Maximum chart resolution): | ||
* **ライブビューカスタムフィルタの無効化(Disable custom live view filters):** 有効にすると、管理者によってあらかじめ作成された Netflow フィルタのみが Netflow ライブビューで利用できます。 | * **ライブビューカスタムフィルタの無効化(Disable custom live view filters):** 有効にすると、管理者によってあらかじめ作成された Netflow フィルタのみが Netflow ライブビューで利用できます。 | ||
* **Netflow 最大保存期間(Netflow max lifespan): | * **Netflow 最大保存期間(Netflow max lifespan): | ||
* **IP アドレス名前解決の有効化(Enable IP address name resolution): | * **IP アドレス名前解決の有効化(Enable IP address name resolution): | ||
+ | * **デーモン間隔(Daemon interval): | ||
- | netflow 設定を有効にした場合、// | + | <WRAP center round tip 90%> |
- | <WRAP center round tip 60%> このサーバは、Pandora FMS サーバではないため、サーバ表示には現れません。 </ | + | //Version 770 or later:// |
+ | |||
+ | In case you need to change the default value of the **Daemon interval** | ||
+ | |||
+ | * Through a command line session or through the [[: | ||
+ | * [[: | ||
+ | * Open a terminal window and delete the data generated with the above interval with '' | ||
+ | * Start the PFMS server. | ||
+ | |||
+ | </ | ||
+ | |||
+ | <WRAP center round tip 90%> | ||
+ | |||
+ | // | ||
+ | |||
+ | **デーモン間隔(Daemon interval)** のデフォルト値を変更する必要がある場合は、次の手順を実行する必要があります。 | ||
+ | |||
+ | * コマンドラインまたは [[: | ||
+ | * [[: | ||
+ | * ターミナル画面を開き、上記の間隔で生成されたデータを '' | ||
+ | * Pandora FMS サーバを起動します。 | ||
+ | |||
+ | </ | ||
+ | |||
+ | Once NetFlow is configured in the console, restart Pandora FMS Server so that it starts the **nfcapd **server. This server must be properly installed before trying to run it. Check server logs in case of doubt. | ||
+ | |||
+ | netflow 設定を有効にした場合、**nfcapd** サーバを起動するために Pandora FMS サーバを再起動する必要があります。このサーバは、システムからアクセスできるパスにインストールされている必要があります。動作に関して疑問点があればサーバログを確認してください。 | ||
+ | |||
+ | <WRAP center round tip 75%> | ||
+ | |||
+ | **Version 769 and earlier: | ||
+ | |||
+ | </ | ||
+ | |||
+ | <WRAP center round tip 75%> | ||
+ | |||
+ | **バージョン 769 およびそれ以前: | ||
+ | |||
+ | </ | ||
<WRAP center round info 95%>If you decide to store the NetFlow data **on a device other than the PFMS server** | <WRAP center round info 95%>If you decide to store the NetFlow data **on a device other than the PFMS server** | ||
< | < | ||
- | 0 * * * * root yes 2>/ | + | 0 * * * * root yes 2>/ |
</ | </ | ||
行 257: | 行 429: | ||
< | < | ||
- | 0 * * * * root yes 2>/ | + | 0 * * * * root yes 2>/ |
</ | </ | ||
行 263: | 行 435: | ||
ここで、'' | ここで、'' | ||
==== フィルタ ==== | ==== フィルタ ==== | ||
- | リソース(Resources) > NetFlow フィルタ(NetFlow Filters) をクリックすることにより、作成および編集ができます。ここでは作成済のフィルタ一覧が表示され、変更したり削除したりできます。 | ||
+ | You may access the creation and edition of filters by clicking on **Ressources** -> **NetFlow Filters**. | ||
- | {{ wiki: | + | **リソース(Resources)** > **NetFlow フィルタ(NetFlow Filters)** をクリックすることにより、作成および編集ができます。 |
+ | {{ : | ||
+ | This section contains a list of already created filters which can be modified or deleted. | ||
+ | ここには、変更または削除できる作成済みのフィルタの一覧が表示されます。 | ||
+ | |||
+ | {{ wiki: | ||
" | " | ||
行 503: | 行 680: | ||
nfdump: Version: 1.6.13 | nfdump: Version: 1.6.13 | ||
+ | |||
+ | ===== sFlow でのネットワーク監視 ===== | ||
+ | |||
+ | <WRAP center round info 60%> | ||
+ | |||
+ | NG 770 version or later. | ||
+ | |||
+ | </ | ||
+ | |||
+ | <WRAP center round info 60%> | ||
+ | |||
+ | バージョン NG 770 以降 | ||
+ | |||
+ | </ | ||
+ | |||
+ | From Pandora FMS version 770 onwards, support for [[http:// | ||
+ | |||
+ | Pandora FMS バージョン 770 以降では、[[http:// | ||
+ | |||
+ | The operation of sFlow in PFMS is [[: | ||
+ | |||
+ | Pandora FMS での sFlow の動作は [[: | ||
+ | |||
+ | ==== sFlow 設定 ==== | ||
+ | |||
+ | <WRAP center round info 60%> | ||
+ | |||
+ | NG 770 version or later. | ||
+ | |||
+ | </ | ||
+ | |||
+ | <WRAP center round info 60%> | ||
+ | |||
+ | バージョン NG 770 以降 | ||
+ | |||
+ | </ | ||
+ | |||
+ | You must enable sFlow to be accessible from the Operation and Management menus. Under **Setup** | ||
+ | |||
+ | 操作メニューと管理メニューからアクセスできるように、sFlow を有効化する必要があります。 **セットアップ(Setup)** → **セットアップ(Setup)** → **基本設定(General)** (**管理(Management)** メニュー) の下に、sFlow をグローバルに有効または無効にするオプションがあります。 | ||
+ | |||
+ | {{ : | ||
+ | |||
+ | Once you have activated sFlow, configure **General network path** | ||
+ | |||
+ | sFlow を有効化したら、**一般的なネットワークパス** (NetFlow と共有されるネットワークの一般的なパス) を設定します。デフォルトは次の通りです。 | ||
+ | |||
+ | < | ||
+ | |||
+ | / | ||
+ | |||
+ | </ | ||
+ | |||
+ | {{ : | ||
+ | |||
+ | A new tab will be enabled specifically for sFlow: | ||
+ | |||
+ | sFlow 専用の新しいタブが有効になります。 | ||
+ | |||
+ | {{ : | ||
+ | |||
+ | * **Data storage path**: Directory where the sFlow data files are to be stored (see [[: | ||
+ | * **Daemon binary path**: | ||
+ | * **Nfdump binary path**: | ||
+ | * **Nfexpire binary path**: | ||
+ | * **Maximum chart resolution**: | ||
+ | * **Disable custom live view filters**: Disables the definition of custom filters from the sFlow view (filters that are already created can still be used). | ||
+ | * **sFlow max lifetime**: Indicates the maximum time in days of sFlow data to be stored. | ||
+ | * **Enable IP address name resolution**: | ||
+ | |||
+ | * **データ保存パス(Data storage path)**: sFlow データファイルが保存されるディレクトリ。([[: | ||
+ | * **デーモンバイナリパス(Daemon binary path)**: **nfcapd** のバイナリのパス。 | ||
+ | * **nfdump バイナリパス(Nfdump binary path)**: **nfdump** のバイナリのパス。 | ||
+ | * **nfexpire バイナリパス(Nfexpire binary path)**: **nfexpire** のバイナリのパス。 | ||
+ | * **最大グラフ解像度(Maximum chart resolution)**: | ||
+ | * **カスタムライブビューフィルタ無効化(Disable custom live view filters)**: sFlow 表示のカスタムフィルターの定義を無効にします (既に作成されているフィルターは引き続き使用できます)。 | ||
+ | * **sFlow 最大保存期間(sFlow max lifetime)**: | ||
+ | * **IP アドレス名前解決の有効化(Enable IP address name resolution)**: | ||
[[ja: | [[ja: |