Configure Remote Logging to Use TCP

Learn how to configure the remote server for logging via TCP.

Before you begin

The NPB application supports remote logging on Linux, Mac, or Windows operating systems, and the following commands are Linux-specific. Refer to the documentation for the Rsyslog utility for your operating system, as needed.

About this task

You create a TCP-specific configuration file to enable UDP transport of syslog.

Procedure

  1. At the command prompt, create and open the following file in your preferred text editor.
    $ /etc/rsyslog.d/tcp.conf 
  2. Copy and paste the following text into the tcp.conf file, replacing the port number if needed with one you choose.
    # load TCP listener 
    module(load="imtcp") 
    # start listener at port 514 
    input(type="imtcp" port="514")
  3. Save and close tcp.conf.
  4. Run the following command to restart the rsyslog service.
    $ sudo systemctl restart rsyslog
  5. Run the following command to verify the rsyslog service status.
    $ sudo systemctl status rsyslog