PEM Agent Configuration Parameters v7

A number of user-configurable parameters and registry entries control the behavior of the PEM Agent. With the exception of the PEM_MAXCONN (or pem_maxconn) parameter, we strongly recommend against modifying any of the configuration parameters or registry entries listed below without first consulting EnterpriseDB support experts.

  • On 32 bit Windows systems, PEM registry entries are located in HKEY_LOCAL_MACHINE\Software\EnterpriseDB\PEM\agent
  • On 64 bit Windows systems, PEM registry entries are located in HKEY_LOCAL_MACHINE\Software\Wow6432Node\EnterpriseDB\PEM\agent
  • On Linux systems, PEM configuration options are stored in the agent.cfg file, located (by default) in /usr/edb/pem/agent/etc
Parameter NameDescriptionValue (if applicable)
PEM_HOST (on Windows) or pem_host (on Linux)The IP address or hostname of the PEM server.By default, set to 127.0.0.1.
PEM_PORT (on Windows) or pem_port (on Linux)The database server port to which the agent connects to communicate with the PEM server.By default, the PEM server monitors port 5432.
AgentID (on Windows) or agent_id (on Linux)A unique identifier assigned to the PEM agent.The first agent is assigned an identifier of '1', the second agent is assigned an identifier of '2', and so on.
AgentUser (on Windows) or agent_user (on Linux)User to connect the PEM database serverIf present, and not set to empty string, it will be used to connect the PEM database server.
AgentCrtPath (on Windows) or agent_ssl_crt (on Linux)The complete path to the PEM agent's certificate file.By default, on Windows, C:\Users\user_name\AppData\Roaming\pem/agent.crt. By default on Linux, /root/.pem/agent.crt.
AgentKeyPath (on Windows) or agent_ssl_key (on Linux)The complete path to the PEM agent's key file.By default, on Windows, C:\Users\user_name\AppData\Roaming\pem/agent.key. By default on Linux, /root/.pem/agent.key.
AgentFlagDir (on Windows) or agent_flag_dir (on Linux)Used for HA support. Specifies the directory path checked for requests to take over monitoring another server. Requests are made in the form of a file in the specified flag directory.Not set by default. This option allows you to override the hard-coded default.
LogLevel (on Windows) or log_level (on Linux)Log level specifies the type of event that will be written to the PEM log files.Log level may be set to: error, debug1, debug2, or warning By default, log level is set to warning
log_location (on Linux only)Specifies the location of the PEM worker log file.On Linux, /var/log/pem/worker.log. On Windows, Logs & errors will be reported in the Application event log.
agent_log_location (on Linux only)Specifies the location of the PEM agent log file.On Linux, /var/log/pem/agent.log. On Windows, Logs & errors will be reported in the Application event log.
ShortWait (on Windows) or short_wait (on Linux)The minimum length of time (in seconds) that the PEM agent will wait before checking which probes are next in the queue (waiting to run).By default, 10 seconds.
LongWait (on Windows) or long_wait (on Linux)The maximum length of time (in seconds) that the PEM agent will wait before attempting to connect to the PEM server if an initial connection attempt fails.By default, 30 seconds.
AlertThreads (on Windows) or alert_threads (on Linux)The number of alert threads to be spawned by the agent.Set to 1 for the agent that resides on the host of the PEM server; should be set to 0 for all other agents.
EnableSMTP (on Windows) or enable_smtp (on Linux)When set to true for multiple PEM Agents (7.13 or lesser) and PEM backend database (9.4 or lesser) then it may send more duplicate emails. Whereas for PEM Agents (7.14 or higher) and PEM backend database (9.5 or higher) then it may send lesser duplicate emails.By default, set to true for the agent that resides on the host of the PEM server; false for all other agents.
EnableSNMP (on Windows) or enable_snmp (on Linux)When set to true for multiple PEM Agents (7.13 or lesser) and PEM backend database (9.4 or lesser) then it may send more duplicate traps. Whereas for PEM Agents (7.14 or higher) and PEM backend database (9.5 or higher) then it may send lesser duplicate traps.By default, set to true for the agent that resides on the host of the PEM server; false for all other agents.
enable_nagios (on Linux only)When set to true, Nagios alerting is enabled.By default, set to true for the agent that resides on the host of the PEM server; false for all other agents.
EnableWebhook (on Windows) or enable_webhook (on Linux)When set to true, Webhook alerting is enabled.By default, set to true for the agent that resides on the host of the PEM server; false for all other agents.
MaxWebhookRetries (on Windows) or max_webhook_retries (on Linux)Set maximum number of times pemAgent should retry to call webhooks on failure.Default 3.
ConnectTimeout (on Windows) or connect_timeout (on Linux)The maximum length of time (in seconds, written as a decimal integer string) that the agent will wait for a connection.Not set by default. If set to 0, the agent will wait indefinitely.
AllowServerRestart (on Windows) or allow_server_restart (on Linux)If set to TRUE, the agent can restart the database server that it monitors. Some PEM features may be enabled/disabled, depending on the value of this parameter.By default, set to TRUE.
MaxConnections (on Windows) or max_connections (on Linux)The maximum number of probe connections used by the connection throttler.By default, set to 0 (an unlimited number of connections).
ConnectionLifetime (on Windows) or connection_lifetime (on Linux)Use ConnectionLifetime (or connection_lifetime) to specify the minimum number of seconds an open but idle connection is retained. This parameter is ignored if the value specified in MaxConnections is reached and a new connection (to a different database) is required to satisfy a waiting request.By default, set to 0 (a connection is dropped when the connection is idle after the agent's processing loop completes a cycle in which the connection has not been used).
HeartbeatConnection (on Windows) or heartbeat_connection (on Linux)When set to TRUE, a dedicated connection used for sending the heartbeats.By default, set to FALSE.
AllowBatchProbes (on Windows) or allow_batch_probes (on Linux)If set to TRUE, the user will be able to create batch probes using custom probes feature.By default, set to FALSE.
BatchScriptDir (on Windows) or batch_script_dir (on Linux)Provide the path where script file (for alerting) will be stored.On Windows, C:Usersuser_nameAppDataLocalTemp. On Linux, set to /tmp.
AllowBatchJobSteps (on Windows) or batch_script_userProvide the username who will run the script.On Windows, set to TRUE and restart PEM Agent. Entries located in HKEY_LOCAL_MACHINE\Software\Wow6432Node\EnterpriseDB\PEM\agent. On Linux, Restart the agent after modifying the file. If you do not specify a user, or the specified user does not exist, then the script will not be executed.
ConnectionCustomSetup (on Windows) or connection_custom_setup (on Linux)Use this parameter to provide SQL code that will be invoked each time a new connection with the monitored server is established.By default, no value is provided.
ca_file (Linux only)Provide the path where the CA certificate resides.By default, /opt/PEM/agent/share/certs/ca-bundle.crt
WebhookSSLKey (on Windows) or webhook_ssl_key (on Linux)The complete path to the webhook's SSL client key file.
WebhookSSLCrt (on Windows) or webhook_ssl_crt (on Linux)The complete path to the webhook's SSL client certificate file.
WebhookSSLCaCrt (on Windows) or webhook_ssl_ca_crt (on Linux)The complete path to the webhook's SSL ca certificate file.
WebhookSSLCrl (on Windows) or webhook_ssl_crl (on Linux)The complete path of the CRL file to validate webhook server certificate.
AllowInsecureWebhooks (on Windows) or allow_insecure_webhooks (on Linux)When set to true, allow webhooks to call with insecure flag.false

Note

If you add or remove any of the parameter in the agent.cfg file then agent must be restarted to apply the changes.