You can use the vCenter Server Management API or HTTP requests to configure the forwarding of vCenter Server syslog messages and test the connection between the vCenter Server instance and remote servers.

The table below lists operations that you can perform to manage the forwarding of syslog messages to remote logging servers.

Table 1. User Operations
Operation Description
Get forwarding configuration You retrieve information about the log forwarding configuration. For more information refer to the diagrams below.
Test forwarding configuration You can validate the current log forwarding configuration. Optionally, you can send a test diagnostic log message from the vCenter Server instance to all configured logging servers to allow manual end-to-end validation. For more information refer to the diagrams below.
Set forwarding configuration You can change the log forwarding configuration. For more information refer to the diagrams below.

The forwarding configuration includes the IP or FQDN of the remote server, the remote port for receiving syslog information, and the communication protocol. The remote server must be a server with running rsyslog, for example, another vCenter Server instance. The API supports the TCP, UDP, TLS, and RELP protocols. For information about the supported TLS versions, see KB article 2147469. By creating a Forwarding.Config object, you specify the connection with a remote server. For information about the Forwarding class and its methods, see the API Reference documentation and diagrams below.

You can use several remote servers by creating a list with Forwarding.Config objects and passing it to the set method. The maximum number of remote servers is three. You can validate the forwarding configuration by using the test method. The returned Forwarding.ConnectionStatus object shows the status of the connection between the vCenter Server instance and a remote server. The State enumeration shows whether the vCenter Server instance can reach the remote server. State can be UP, DOWN, or UNKNOWN. If the state is DOWN or UNKNOWN, the vCenter Server instance cannot access the remote server and you must check the remote server and its settings such as network ports, firewall, supported protocols, and syslog configuration.

Note: If you use UDP, the connection status is always UNKNOWN.
Figure 1. Forwarding Class Diagram for Python
A diagram with boxes in which each box represents a different class. The boxes are connected with arrows which show the correlation.
Figure 2. Example Configuration Workflow
A flow chart with example configuration workflow steps, which shows each individual step between the Start and End points.

For a code example of configuring the syslog forwarding, see Python Example of Configuring Syslog Forwarding.