< Home

ttl

Function

The ttl command sets the time to live (TTL) value for the test packets of an NQA test instance.

The undo ttl command restores the default setting.

Format

ttl number

undo ttl

Parameters

Parameter Description Value
number Specifies the TTL value. The value is an integer ranging from 1 to 255. The default value is 30.

Views

NQA view

Default Level

2: Configuration level

Usage Guidelines

Usage Scenario

To prevent test packets from being transmitted endlessly, ensure that the test instance is complete within a specified number of hops.

After test packets are created, the ttl command can be used to set TTL to a specified value. The TTL value is deducted by 1 each time a test packet passes through a router. After the TTL value reduces to 0 on a router, the router discards the test packet and sends an error message to the transmit end. This prevents endless transmission of test packets.

Prerequisites

Before running the datafill command, run the test-type command to specify the type of a test instance, which may be one of the following:
  • ICMP
  • FTP
  • HTTP
  • TCP
  • UDP
  • UDP-jitter

Configuration Impact

If the TTL value has been configured, running the ttl command will override the previous configuration.

Precautions

The TTL value of test packets for a running test instance cannot be changed.

Example

# Set the TTL value for the test packets of a test instance named admin http to 10.

<sysname> system-view
[sysname] nqa test-instance admin http
[sysname-nqa-admin-http] test-type http
[sysname-nqa-admin-http] ttl 10
Copyright © Huawei Technologies Co., Ltd.
Copyright © Huawei Technologies Co., Ltd.
< Previous topic Next topic >