MQTTプラグイン

概要

設定パラメーターを使用すると、MQTTプラグインの動作をカスタマイズできます。

これらは、エージェント 2 の設定ファイルではなく、専用の設定ファイル(例: mqtt.conf)に指定することを推奨します。その後、Include ディレクティブを使用して、このファイルを Zabbix エージェント 2 の設定に含めます。

パラメーターが必須であると明示されていない限り、すべてのパラメーターは任意です。

次の点に注意してください。

  • デフォルト値は、同梱されている設定ファイルの値ではなく、プロセスのデフォルトを反映しています。
  • 値は環境変数をサポートします。
  • Zabbix は、BOM なしの UTF-8 エンコーディングの設定ファイルのみをサポートします。
  • "#" で始まるコメントは、行頭でのみサポートされます。

Parameter details

Plugins.MQTT.Default.Password

Specify the default password for connecting to MQTT.
Used if no value is specified in an item key or named session.

Plugins.MQTT.Default.TLSCAFile

Specify full pathname of the file containing top-level CA(s) certificates for peer certificate verification for encrypted communications between Zabbix agent 2 and MQTT broker.
Used if no value is specified in a named session.

Plugins.MQTT.Default.TLSCertFile

Specify full pathname of the file containing the agent certificate or certificate chain for encrypted communications between Zabbix agent 2 and MQTT broker.
Used if no value is specified in a named session.

Plugins.MQTT.Default.TLSKeyFile

Specify full pathname of the file containing the MQTT private key for encrypted communications between Zabbix agent 2 and MQTT broker.
Used if no value is specified in a named session.

Plugins.MQTT.Default.Topic

Specify the default topic for MQTT subscription.
Used if no value is specified in an item key or named session.
The topic may contain wildcards ("+","#").

Examples:

path/to/file
path/to/#
path/+/topic
Plugins.MQTT.Default.Url

Specify the default MQTT broker connection string.
Used if no value is specified in an item key or named session.
Should not include query parameters.
Must match the URL format.
Supported schemes: tcp (default), ws, tls
A scheme can be omitted.
A port can be omitted (default=1883)

Default: tcp://localhost:1883

Examples:

tcp://host:1883
localhost
ws://host:8080
Plugins.MQTT.Default.User

Specify the default username for connecting to MQTT.
Used if no value is specified in an item key or named session.

Plugins.MQTT.Sessions.<SessionName>.Password

Specify the named session password for connecting to MQTT.
<SessionName> - define name of a session for using in item keys.

Plugins.MQTT.Sessions.<SessionName>.TLSCAFile

Specify full pathname of the file containing top-level CA(s) certificates for peer certificate verification for named session, used for encrypted communications between Zabbix agent 2 and MQTT broker.
<SessionName> - define name of a session for using in item keys.

Plugins.MQTT.Sessions.<SessionName>.TLSCertFile

Specify full pathname of the file containing the agent certificate or certificate chain for named session, used for encrypted communications between Zabbix agent 2 and MQTT broker.
<SessionName> - define name of a session for using in item keys.

Plugins.MQTT.Sessions.<SessionName>.TLSKeyFile

Specify full pathname of the file containing the MQTT private key for named session, used for encrypted communications between Zabbix agent 2 and MQTT broker.
<SessionName> - define name of a session for using in item keys.

Plugins.MQTT.Sessions.<SessionName>.Topic

Specify the named session topic for MQTT subscription.
<SessionName> - define name of a session for using in item keys.
The topic may contain wildcards ("+","#").

Examples:

path/to/file
path/to/#
path/+/topic
Plugins.MQTT.Sessions.<SessionName>.Url

Specify the named session MQTT broker connection string.
<SessionName> - define name of a session for using in item keys.
Should not include query parameters.
Must match the URL format.
Supported schemes: tcp (default), ws, tls
A scheme can be omitted.
A port can be omitted (default=1883)

Default: tcp://localhost:1883

Examples:

tcp://host:1883
localhost
ws://host:8080
Plugins.MQTT.Sessions.<SessionName>.User

Specify the named session username for connecting to MQTT.
<SessionName> - define name of a session for using in item keys.

パラメーター

Parameter Mandatory Range Default Description
Plugins.MQTT.Default.Password no MQTT 接続用のデフォルトパスワード。アイテムキーまたは名前付きセッションで値が指定されていない場合に使用されます。
Plugins.MQTT.Default.TLSCAFile no Zabbix エージェント 2 と MQTT ブローカー間の暗号化通信で、ピア証明書の検証に使用する最上位 CA 証明書を含むファイルの完全なパス名。名前付きセッションで値が指定されていない場合に使用されます。
Plugins.MQTT.Default.TLSCertFile no Zabbix エージェント 2 と MQTT ブローカー間の暗号化通信で、エージェント証明書または証明書チェーンを含むファイルの完全なパス名。名前付きセッションで値が指定されていない場合に使用されます。
Plugins.MQTT.Default.TLSKeyFile no Zabbix エージェント 2 と MQTT ブローカー間の暗号化通信で使用する MQTT 秘密鍵を含むファイルの完全なパス名。名前付きセッションで値が指定されていない場合に使用されます。
Plugins.MQTT.Default.Topic no MQTT サブスクリプション用のデフォルトトピック。アイテムキーまたは名前付きセッションで値が指定されていない場合に使用されます。

トピックにはワイルドカード ("+","#") を含めることができます。
例: path/to/file
path/to/#
path/+/topic
Plugins.MQTT.Default.Url no tcp://localhost:1883 MQTT ブローカー接続文字列のデフォルト値。アイテムキーまたは名前付きセッションで値が指定されていない場合に使用されます。

クエリパラメーターを含めないでください。
URL 形式に一致している必要があります。
サポートされるスキーム: tcp (デフォルト), ws, tls; スキームは省略できます。
ポートは省略できます (デフォルト=1883)。
例: tcp://host:1883
localhost
ws://host:8080
Plugins.MQTT.Default.User no MQTT 接続用のデフォルトユーザー名。アイテムキーまたは名前付きセッションで値が指定されていない場合に使用されます。
Plugins.MQTT.Sessions.<SessionName>.Password no 名前付きセッションのパスワード。
<SessionName> - アイテムキーで使用するセッション名を定義します。
Plugins.MQTT.Sessions.<SessionName>.TLSCAFile no Zabbix エージェント 2 と MQTT ブローカー間の暗号化通信で、ピア証明書の検証に使用する最上位 CA 証明書を含むファイルの完全なパス名。
<SessionName> - アイテムキーで使用するセッション名を定義します。
Plugins.MQTT.Sessions.<SessionName>.TLSCertFile no Zabbix エージェント 2 と MQTT ブローカー間の暗号化通信で使用する、エージェント証明書または証明書チェーンを含むファイルの完全なパス名。
<SessionName> - アイテムキーで使用するセッション名を定義します。
Plugins.MQTT.Sessions.<SessionName>.TLSKeyFile no Zabbix エージェント 2 と MQTT ブローカー間の暗号化通信で使用する MQTT 秘密鍵を含むファイルの完全なパス名。
<SessionName> - アイテムキーで使用するセッション名を定義します。
Plugins.MQTT.Sessions.<SessionName>.Topic no 名前付きセッションの MQTT サブスクリプション用トピック。
<SessionName> - アイテムキーで使用するセッション名を定義します。

トピックにはワイルドカード ("+","#") を含めることができます。
例: path/to/file
path/to/#
path/+/topic
Plugins.MQTT.Sessions.<SessionName>.Url no 名前付きセッションの接続文字列。
<SessionName> - アイテムキーで使用するセッション名を定義します。

クエリパラメーターを含めないでください。
URL 形式に一致している必要があります。
サポートされるスキーム: tcp (デフォルト), ws, tls; スキームは省略できます。
ポートは省略できます (デフォルト=1883)。
例: tcp://host:1883
localhost
ws://host:8080
Plugins.MQTT.Sessions.<SessionName>.User no 名前付きセッションのユーザー名。
<SessionName> - アイテムキーで使用するセッション名を定義します。

リクエストの実行タイムアウト(リクエストが完了するまで待機してから停止するまでの時間)を設定する必要がある場合は、アイテムの設定 フォームを使用してください。

関連情報: