community.windows.win_net_adapter_feature (2.2.0) — module

Enable or disable certain network adapters.

| "added in version" 1.2.0 of community.windows"

Authors: ライトウェルの人 (@jirolin)

Install collection

Install with ansible-galaxy collection install community.windows:==2.2.0


Add to requirements.yml

  collections:
    - name: community.windows
      version: 2.2.0

Description

Enable or disable some network components of a certain network adapter or all the network adapters.

Usage examples

  • Success
    Steampunk Spotter scan finished with no errors, warnings or hints.
- name: enable multiple interfaces of multiple interfaces
  community.windows.win_net_adapter_feature:
    interface:
    - 'Ethernet0'
    - 'Ethernet1'
    state: enabled
    component_id:
    - ms_tcpip6
    - ms_server
  • Success
    Steampunk Spotter scan finished with no errors, warnings or hints.
- name: Enable ms_tcpip6 of all the Interface
  community.windows.win_net_adapter_feature:
    interface: '*'
    state: enabled
    component_id:
    - ms_tcpip6

Inputs

    
state:
    choices:
    - enabled
    - disabled
    default: enabled
    description:
    - Specify the state of ms_tcpip6 of interfaces.
    required: false
    type: str

interface:
    description:
    - Name of Network Adapter Interface. For example, C(Ethernet0) or C(*).
    elements: str
    required: true
    type: list

component_id:
    description:
    - Specify the below component_id of network adapters.
    - component_id (DisplayName)
    - C(ms_implat) (Microsoft Network Adapter Multiplexor Protocol)
    - C(ms_lltdio) (Link-Layer Topology Discovery Mapper I/O Driver)
    - C(ms_tcpip6) (Internet Protocol Version 6 (TCP/IPv6))
    - C(ms_tcpip) (Internet Protocol Version 4 (TCP/IPv4))
    - C(ms_lldp) (Microsoft LLDP Protocol Driver)
    - C(ms_rspndr) (Link-Layer Topology Discovery Responder)
    - C(ms_msclient) (Client for Microsoft Networks)
    - C(ms_pacer) (QoS Packet Scheduler)
    - If you'd like to set custom adapters like 'Juniper Network Service', get the I(component_id)
      by running the C(Get-NetAdapterBinding) cmdlet.
    elements: str
    required: true
    type: list