A newer version of this documentation is available. Click here to view the most up-to-date release of the Greenplum 4.x documentation.


Reports on the health and state of a Greenplum Database system through SNMP.

The gpsnmpd agent is deprecated and will be removed in a future release.


gpsnmpd -s -C connect_string  [-b] [-g] [-m MIB:...] 
        [-M directory:...] 

gpsnmpd -c file -C connect_string [-x address:port] [-b] [-g] 
        [-m MIB:...] [-M directory:...]

gpsnmpd -? 

gpsnmpd --version


Greenplum's gpsnmpd agent is an SNMP (Simple Network Management Protocol) daemon that reports on the health and state of a Greenplum Database system by using a set of MIBs (Management Information Bases). MIBs are a collection of objects that describe an SNMP-manageable entity; in this case, a Greenplum Database system. In a typical environment, gpsnmpd is polled by a network monitor and returns information on a Greenplum Database system. It currently supports the generic RDBMS MIB and typically operates on the master host.

gpsnmpd works in conjunction with the SNMP support that (normally) already exists on the Greenplum Database system. gpsnmpd does not replace the system snmpd agent that monitors items such as hardware, processor, memory, and network functions. However, you can run the Greenplum SNMP agent as a stand-alone agent if required.

As a standalone SNMP agent, gpsnmpd listens (on a network socket) for SNMP queries, and requires the same extensive configuration as the system SNMP agent.

Greenplum recommends that you run gpsnmpd as a sub-agent to the system agent. When it starts, the gpsnmpd sub-agent registers itself with the system-level SNMP agent, and communicates to the system agent the parts of the MIB of which it is aware. The system agent communicates with the SNMP client/network monitoring application and forwards requests for particular sections of the MIB to the gpsnmpd sub-agent. Note that the gpsnmpd sub-agent communicates with the system agent through UNIX sockets; it does not listen on network sockets when used as a sub-agent.


-s (sub-agent)
Run gpsnmpd as an AgentX sub-agent to the system snmpd process. You do not need to use the -x option when using this option.
-b (background)
Run gpsnmpd as a background process.
-c (configuration file)
Specify the SNMP configuration file to use when starting gpsnmpd as a stand-alone agent. Note that you can specify any configuration file to run gpsnmpd as a stand-alone agent; you do not have to use the /etc/snmp/snmpd.conf file. The configuration file you use must include a value for rocommunity.
-C connection_string (libpq)
The libpq connection string to connect to Greenplum Database. Note that you can run gpsnmpd from a remote system. Depending on your network configuration, the gpsnmpd agent can establish a connection and monitor a remote Greenplum Database database instance. The configuration string can contain the database name, the port number, the username, the password, and other information if required.
Greenplum recommends using the postgres database in the connection string (dbname=postgres).
You do not need to specify the -C option if you create a database role (user id) called root, and add the following line in the pg_hba.conf file:
local postgres root ident
This allows the UNIX user root to connect to the postgres database over the local connection. The root user does not require special permissions. The user and password parameters are only required when starting gpsnmpd as a user other than root.
Note: The connection string can be a conninfo data type. Use conninfo data for this parameter to specify a LDAP connection lookup.
-g (use syslog)
Logs gpsnmpd error messages to syslog.
-m MIB:...
Loads one or more MIBs when starting gpsnmpd. Use a colon (:) to separate the MIBs. Enter ALL to load all MIBs. If you do not enter -m in the gpsnmpd command, a default set of MIBs are loaded by default.
-M directory:...
Loads all MIBs from one or more directories when starting gpsnmpd. Use a colon (:) to separate the each directory. Enter the full path to each directory you specify for this option. If you do not enter -M in the gpsnmpd command, a default set of MIBs are loaded by default.
-x address:port (of a network interface)
Specify an IP address for a network interface card on the host system, and specify a port other than the default SNMP port of 161. This enables you to run gpsnmpd without root permissions (you must have root permissions to use ports 1024 and lower).
You do not need to specify this option if you are running gpsnmpd as an AgentX sub-agent (-s).
-? (help)
Displays the online help.
Displays the version of this utility.


Start gpsnmpd as an agentx subagent:

# gpsnmpd -s -b -m ALL -C "dbname=postgres user=gpadmin password=secret"

Start gpsnmpd as a stand-alone agent:

# gpsnmpd -b -c /etc/snmp/snmpd.conf -x -M /usr/mibs/mymibs 
-C "dbname=postgres user=gpadmin password=secret"