Configures a switch to forward system messages to a specified syslog server using its host name.
Global configuration mode
Use this command to configure a switch to forward all error log entries to a specified server using the server's host name. You can configure only one syslog server using hostname, this includes all VRFs.
The crypto import syslogca command is required for a secure syslog to be fully functional.
After specifying the host-name and vrf-name, the secure sub-command can be used to specify the secure default port (6514) or specify a secure non-default syslog server port. These sub-commands are only available after specifying the ip_address and vrf-name parameters.
Use the no logging syslog-server-host command with the optional use-vrf keyword to remove the specified hostname and VRF.
By default, all management services are enabled on the management VRF ("mgmt-vrf") and the default VRF ("default-vrf").
To configure a server (using its hostname) to which system messages are sent on a user-specified VRF:
device# configure terminal device(config)# logging syslog-server-host test.server.com use-vrf myvrf device(config-syslog-server-192.168.163.233/myvrf)#
To configure a secure server with a non-default port number:
device(config)# logging syslog-server-host test.server.com use-vrf mgmt-vrf device(config-syslog-server-192.168.163.233/mgmt-vrf)# secure port 6502 device(config-syslog-server-192.168.163.233/mgmt-vrf)#
To remove a configured syslog server:
device# configure terminal device(config)# no logging syslog-server-host test.server.com use-vrf myvrf