< Home

info-center loghost source

Function

The info-center loghost source command configures the source interface used by the Switch to send information to a log host.

The undo info-center loghost source command restores the default source interface used by the Switch to send information to a log host.

By default, the source interface for a device to send logs to a log host is the actual interface that sends the logs.

Format

info-center loghost source interface-type interface-number

undo info-center loghost source

Parameters

Parameter Description Value
interface-type interface-number Specifies the type and number of an interface. -

Views

System view

Default Level

3: Management level

Usage Guidelines

Usage Scenario

If multiple devices send log messages to the same log host, you can identify the devices by setting different source interfaces so as to index the received log messages.

The source interface specified in the info-center loghost source command for a device to send logs to a log host is not necessarily the actual interface that sends the logs, but the IP address of the specified source interface is carried in logs.

Prerequisites

There is a reachable route between the source interface and the log host.

Example

# Specify Loopback0 IP address as the source interface address to send information to a log host.

<HUAWEI> system-view
[HUAWEI] interface loopback 0
[HUAWEI-LoopBack0] ip address 10.1.1.1 255.255.255.0
[HUAWEI-LoopBack0] quit
[HUAWEI] info-center loghost source loopback 0
Copyright © Huawei Technologies Co., Ltd.
Copyright © Huawei Technologies Co., Ltd.
< Previous topic Next topic >