juniper_junos_pmtud

Perform path MTU discovery from a Junos device to a destination

New in version 2.0.0.

Synopsis

  • Determine the maximum IP MTU supported along a path from a Junos device to a user-specified destination by performing path MTU discovery (PMTUD) using the ping command. The reported MTU will be between min_test_size and max_size where min_test_size = (max_size - max_range + 1). If the actual path MTU is greater than max_size, then max_size will be reported. If the actual path MTU is less than min_test_size, then a failure will be reported.

Requirements

The following software packages must be installed on hosts that execute this module:

Module-specific Options

The following options may be specified for this module:

parameter type required default choices comments
dest
str yes none
The IPv4 address, or hostname if DNS is configured on the Junos device, used as the destination of the PMTUD.

aliases: dest_ip, dest_host, destination, destination_ip, destination_host
interface
str no none
The source interface from which the the PMTUD is performed. If not specified, the default Junos algorithm for determining the source interface is used.
max_range
int no 512
The maximum range of MTU values, in bytes, which will be searched when performing path MTU discovery. This value must be 0 or a power of 2 (2^n) between 2 and 65536. The minimum IPv4 MTU value attempted when performing path MTU discovery is min_test_size = (max_size - max_range + 1)
max_size
int no 1500
The maximum IPv4 MTU, in bytes, to attempt when performing path MTU discovery.
The value returned for inet_mtu will be no more than this value even if the path actually supports a higher MTU.
This value must be between 68 and 65496.
routing_instance
str no none
Name of the source routing instance from which the ping is originated.
If not specified, the default routing instance is used.
source
str no none
The IPv4 address, or hostname if DNS is configured on the Junos device, used as the source address of the PMTUD. If not specified, the Junos default algorithm for determining the source address is used.

aliases: source_ip, source_host, src, src_ip, src_host

Examples

---
- name: Examples of juniper_junos_mtud
  hosts: junos-all
  connection: local
  gather_facts: no
  roles:
    - Juniper.junos

  tasks:
    - name: Perform PMTUD to 192.68.1.1 with default parameters.
      juniper_junos_pmtud:
        dest: "192.68.1.1"

    - name: Perform PMTUD to 192.68.1.1. Register response.
      juniper_junos_pmtud:
        dest: "192.68.1.1"
      register: response
    - name: Print the discovered MTU.
      debug:
        var: response.inet_mtu

    - name: Perform PMTUD to 192.68.1.1. Search all possible MTU values.
      juniper_junos_pmtud:
        dest: "192.68.1.1"
        max_size: 65496
        max_range: 65536
      register: response
    - name: Print the discovered MTU.
      debug:
        var: response.inet_mtu

    - name: Perform PMTUD to 192.68.1.1. Source from ge-0/0/0.0 interface.
      juniper_junos_pmtud:
        dest: "192.68.1.1"
        interface: "ge-0/0/0.0"
      register: response
    - name: Print the discovered MTU.
      debug:
        var: response.inet_mtu

    - name: Perform PMTUD to 192.68.1.1. Source from 192.168.1.2.
      juniper_junos_pmtud:
        dest: "192.68.1.1"
        source: "192.168.1.2"
      register: response
    - name: Print the discovered MTU.
      debug:
        var: response.inet_mtu

    - name: Perform PMTUD to 192.68.1.1. Source from the red routing-instance.
      juniper_junos_pmtud:
        dest: "192.68.1.1"
        routing_instance: "red"
      register: response
    - name: Print the discovered MTU.
      debug:
        var: response.inet_mtu

Notes

Note

  • The NETCONF system service must be enabled on the target Junos device.

Author

  • Martin Komon (@mkomon)
  • Juniper Networks - Stacy Smith (@stacywsmith)

Status

This module is flagged as stableinterface which means that the maintainers for this module guarantee that no backward incompatible interface changes will be made.