Win32_NetworkAdapterConfiguration

Win32 Network Adapter Configuration
root/cimv2dynamiqueclé : Index

Représente les attributs et le comportement d'un adaptateur réseau. Cette classe comprend des propriétés et des méthodes supplémentaires qui assurent la gestion du protocole TCP/IP, indépendamment de l'adaptateur réseau.

Sur cette page

Exemple principal

Lister les instances

# Toutes les instances de Win32_NetworkAdapterConfiguration, avec les propriétés principales
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration |
    Select-Object -Property @(
        'Description'
        'IPEnabled'
        'DHCPEnabled'
        'IPAddress'
        'DefaultIPGateway'
        'DNSServerSearchOrder'
        'MACAddress'
    )

Exemples

Filtrer avec WQL

# Filtre WQL évalué par le fournisseur : cartes réseau où IP est activé
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Filter 'IPEnabled = TRUE' |
    Select-Object -Property @(
        'Description'
        'IPEnabled'
        'DHCPEnabled'
        'IPAddress'
        'DefaultIPGateway'
        'DNSServerSearchOrder'
        'MACAddress'
    )

Le filtre est évalué par le fournisseur WMI : moins de données transitent qu'avec Where-Object.

Décoder les valeurs numériques

# Table de correspondance pour IGMPLevel (valeurs documentées par Microsoft)
$iGMPLevelName = @{
    0 = 'No Multicast'
    1 = 'IP Multicast'
    2 = 'IP & IGMP multicast'
}
# Table de correspondance pour IPXMediaType (valeurs documentées par Microsoft)
$iPXMediaTypeName = @{
    1 = 'Ethernet'
    2 = 'Token ring'
    3 = 'FDDI'
    8 = 'ARCNET'
}

Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration |
    Select-Object -Property @(
        'Description'
        'IPEnabled'
        'DHCPEnabled'
        'IPAddress'
        'DefaultIPGateway'
        'DNSServerSearchOrder'
        'MACAddress'
    )

Interroger un ordinateur distant (session CIM)

à vérifier avant exécution
# Nom de l'ordinateur distant
$computerName = 'SERVER01'
# La session CIM (WSMan par défaut) est réutilisable pour plusieurs requêtes
$cimSession = New-CimSession -ComputerName $computerName
try {
    Get-CimInstance -CimSession $cimSession -ClassName Win32_NetworkAdapterConfiguration |
        Select-Object -Property @(
            'Description'
            'IPEnabled'
            'DHCPEnabled'
            'IPAddress'
            'DefaultIPGateway'
            'DNSServerSearchOrder'
            'MACAddress'
        )
} finally {
    Remove-CimSession -CimSession $cimSession
}

WSMan (WinRM) est utilisé par défaut. Pour un hôte sans WinRM, créez la session avec -SessionOption (New-CimSessionOption -Protocol Dcom). Ajoutez -Credential pour un autre compte.

Afficher la structure de la classe

# Structure de la classe : propriétés, types et indicateurs (Key, ReadOnly…)
$cimClass = Get-CimClass -ClassName Win32_NetworkAdapterConfiguration
$cimClass.CimClassProperties |
    Select-Object -Property Name, CimType, Flags

# Méthodes de la classe
$cimClass.CimClassMethods |
    Select-Object -Property Name, ReturnType

Propriétés

61 sur 61 propriétés
NomTypeAccèsDescription
ArpAlwaysSourceRoutebooleanlecture

Si TRUE, TCP/IP transmet les requêtes ARP (Address Resolution Protocol) avec le routage par la source activé sur les réseaux Token Ring. Par défaut (FALSE), ARP interroge d'abord sans routage par la source, puis réessaie avec le routage par la source activé si aucune réponse n'est reçue. Le routage par la source permet d'acheminer les paquets réseau entre différents types de réseaux.

Code
# Valeur de ArpAlwaysSourceRoute pour chaque instance
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property Index, ArpAlwaysSourceRoute |
    Select-Object -Property Index, ArpAlwaysSourceRoute
ArpUseEtherSNAPbooleanlecture

Si TRUE, les paquets Ethernet suivent le codage SNAP (Sub-Network Access Protocol) de l'IEEE 802.3. Définir ce paramètre sur 1 oblige TCP/IP à transmettre les paquets Ethernet à l'aide du codage 802.3 SNAP. Par défaut (FALSE), la pile transmet les paquets au format Ethernet DIX.

Code
# Valeur de ArpUseEtherSNAP pour chaque instance
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property Index, ArpUseEtherSNAP |
    Select-Object -Property Index, ArpUseEtherSNAP
Captionstringlecture

Brève description textuelle de l'objet actuel.

Code
# Valeur de Caption pour chaque instance
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property Index, Caption |
    Select-Object -Property Index, Caption
DatabasePathstringlecture

Chemin de fichier Windows valide vers les fichiers de base de données Internet standard (HOSTS, LMHOSTS, NETWORKS et PROTOCOLS). Ce chemin est utilisé par l'interface Windows Sockets.

Code
# Valeur de DatabasePath pour chaque instance
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property Index, DatabasePath |
    Select-Object -Property Index, DatabasePath
DeadGWDetectEnabledbooleanlecture

Si TRUE, la détection de passerelle inactive est effectuée. Lorsque cette fonctionnalité est activée, le protocole TCP (Transmission Control Protocol) demande au protocole IP (Internet Protocol) de basculer vers une passerelle de secours s'il retransmet un segment plusieurs fois sans recevoir de réponse.

Code
# Valeur de DeadGWDetectEnabled pour chaque instance
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property Index, DeadGWDetectEnabled |
    Select-Object -Property Index, DeadGWDetectEnabled
DefaultIPGatewaystring[]lecture

Tableau des adresses IP des passerelles par défaut utilisées par le système informatique.

Exemple : "192.168.12.1 192.168.46.1"

Code
# Valeur de DefaultIPGateway pour chaque instance
# DefaultIPGateway est un tableau : -ExpandProperty renvoie ses éléments un par un
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property DefaultIPGateway |
    Select-Object -ExpandProperty DefaultIPGateway
DefaultTOSuint8lecture

Valeur par défaut du type de service (TOS) définie dans l'en-tête des paquets IP sortants. La Request for Comments (RFC) 791 définit les valeurs. Par défaut : 0 (zéro), plage valide : 0 à 255.

Code
# Valeur de DefaultTOS pour chaque instance
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property Index, DefaultTOS |
    Select-Object -Property Index, DefaultTOS
DefaultTTLuint8lecture

Valeur par défaut de la durée de vie (TTL) définie dans l'en-tête des paquets IP sortants. Le TTL indique le nombre de routeurs qu'un paquet IP peut traverser avant d'atteindre sa destination ou d'être rejeté. Chaque routeur traversé décrémente de un le compteur TTL du paquet, et rejette le paquet si le TTL vaut 0 (zéro). Par défaut : 32, plage valide : 1 à 255.

Code
# Valeur de DefaultTTL pour chaque instance
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property Index, DefaultTTL |
    Select-Object -Property Index, DefaultTTL
Descriptionstringlecture

Description textuelle de l'objet actuel.

Code
# Valeur de Description pour chaque instance
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property Index, Description |
    Select-Object -Property Index, Description
DHCPEnabledbooleanlecture

Si TRUE, le serveur DHCP (Dynamic Host Configuration Protocol) attribue automatiquement une adresse IP au système informatique lors de l'établissement d'une connexion réseau.

Code
# Valeur de DHCPEnabled pour chaque instance
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property Index, DHCPEnabled |
    Select-Object -Property Index, DHCPEnabled
DHCPLeaseExpiresdatetimelecture

Date et heure d'expiration d'une adresse IP en location, attribuée à l'ordinateur par le serveur DHCP (Dynamic Host Configuration Protocol).

Exemple : 20521201000230.000000000

Code
# Valeur de DHCPLeaseExpires pour chaque instance
# Les cmdlets CIM renvoient déjà un objet DateTime : aucune conversion n'est nécessaire
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property Index, DHCPLeaseExpires |
    Select-Object -Property Index, DHCPLeaseExpires
DHCPLeaseObtaineddatetimelecture

Date et heure d'obtention de la location de l'adresse IP attribuée à l'ordinateur par le serveur DHCP (Dynamic Host Configuration Protocol).

Exemple : 19521201000230.000000000

Code
# Valeur de DHCPLeaseObtained pour chaque instance
# Les cmdlets CIM renvoient déjà un objet DateTime : aucune conversion n'est nécessaire
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property Index, DHCPLeaseObtained |
    Select-Object -Property Index, DHCPLeaseObtained
DHCPServerstringlecture

Adresse IP du serveur DHCP (Dynamic Host Configuration Protocol).

Exemple : "10.55.34.2"

Code
# Valeur de DHCPServer pour chaque instance
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property Index, DHCPServer |
    Select-Object -Property Index, DHCPServer
DNSDomainstringlecture

Nom de l'organisation suivi d'un point et d'une extension indiquant le type d'organisation, par exemple "microsoft.com". Le nom peut être composé de n'importe quelle combinaison des lettres A à Z, des chiffres 0 à 9 et du trait d'union (-), le caractère point (.) servant de séparateur.

Exemple : "microsoft.com"

Code
# Valeur de DNSDomain pour chaque instance
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property Index, DNSDomain |
    Select-Object -Property Index, DNSDomain
DNSDomainSuffixSearchOrderstring[]lecture

Tableau des suffixes de domaine DNS à ajouter à la fin des noms d'hôte lors de la résolution de noms. Lorsqu'il tente de résoudre un nom de domaine complet (FQDN) à partir d'un nom d'hôte seul, le système ajoute d'abord le nom de domaine local. En cas d'échec, le système utilise la liste des suffixes de domaine pour créer des FQDN supplémentaires, dans l'ordre indiqué, et interroge les serveurs DNS pour chacun d'eux.

Exemple : "samples.microsoft.com example.microsoft.com"

Code
# Valeur de DNSDomainSuffixSearchOrder pour chaque instance
# DNSDomainSuffixSearchOrder est un tableau : -ExpandProperty renvoie ses éléments un par un
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property DNSDomainSuffixSearchOrder |
    Select-Object -ExpandProperty DNSDomainSuffixSearchOrder
DNSEnabledForWINSResolutionbooleanlecture

Si TRUE, le système DNS (Domain Name System) est activé pour la résolution de noms, avant la résolution WINS (Windows Internet Naming Service). Si le nom ne peut pas être résolu à l'aide de DNS, la demande de nom est transmise à WINS pour résolution.

Code
# Valeur de DNSEnabledForWINSResolution pour chaque instance
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property Index, DNSEnabledForWINSResolution |
    Select-Object -Property Index, DNSEnabledForWINSResolution
DNSHostNamestringlecture

Nom d'hôte utilisé pour identifier l'ordinateur local lors de l'authentification par certains utilitaires. D'autres utilitaires basés sur TCP/IP peuvent utiliser cette valeur pour obtenir le nom de l'ordinateur local. Les noms d'hôte sont stockés sur les serveurs DNS, dans une table qui associe les noms aux adresses IP. Le nom peut être composé de n'importe quelle combinaison des lettres A à Z, des chiffres 0 à 9 et du trait d'union (-), le caractère point (.) servant de séparateur. Par défaut, cette valeur correspond au nom d'ordinateur de mise en réseau Microsoft, mais l'administrateur réseau peut attribuer un autre nom d'hôte sans modifier le nom de l'ordinateur.

Exemple : "corpdns"

Code
# Valeur de DNSHostName pour chaque instance
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property Index, DNSHostName |
    Select-Object -Property Index, DNSHostName
DNSServerSearchOrderstring[]lecture

Tableau des adresses IP des serveurs à utiliser pour interroger les serveurs DNS.

Code
# Valeur de DNSServerSearchOrder pour chaque instance
# DNSServerSearchOrder est un tableau : -ExpandProperty renvoie ses éléments un par un
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property DNSServerSearchOrder |
    Select-Object -ExpandProperty DNSServerSearchOrder
DomainDNSRegistrationEnabledbooleanlecture

Si TRUE, les adresses IP de cette connexion sont enregistrées dans DNS sous le nom de domaine de cette connexion, en plus d'être enregistrées sous le nom DNS complet de l'ordinateur. Le nom de domaine de cette connexion est défini à l'aide de la méthode SetDNSDomain() ou attribué par DSCP. Le nom enregistré correspond au nom d'hôte de l'ordinateur auquel est ajouté le nom de domaine.

Code
# Valeur de DomainDNSRegistrationEnabled pour chaque instance
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property Index, DomainDNSRegistrationEnabled |
    Select-Object -Property Index, DomainDNSRegistrationEnabled
ForwardBufferMemoryuint32lecture

Mémoire allouée par IP pour stocker les données des paquets dans la file d'attente des paquets du routeur. Lorsque cet espace tampon est plein, le routeur commence à supprimer aléatoirement des paquets de sa file d'attente. Les tampons de données de la file d'attente des paquets ont une longueur de 256 octets ; la valeur de ce paramètre doit donc être un multiple de 256. Plusieurs tampons sont chaînés pour les paquets plus volumineux. L'en-tête IP d'un paquet est stocké séparément. Ce paramètre est ignoré et aucun tampon n'est alloué si le routeur IP n'est pas activé. La taille du tampon peut aller de la MTU du réseau à une valeur inférieure à 0xFFFFFFFF. Par défaut : 74240 (cinquante paquets de 1480 octets, arrondis à un multiple de 256).

Unité : bytes

Code
# Valeur de ForwardBufferMemory pour chaque instance
# ForwardBufferMemory est exprimé en octets : conversion en Go
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property Index, ForwardBufferMemory |
    Select-Object -Property @(
        'Index'
        @{ Name = 'ForwardBufferMemoryGB'; Expression = { [math]::Round($_.ForwardBufferMemory / 1GB, 2) } }
    )
FullDNSRegistrationEnabledbooleanlecture

Si TRUE, les adresses IP de cette connexion sont enregistrées dans DNS sous le nom DNS complet de l'ordinateur. Le nom DNS complet de l'ordinateur s'affiche dans l'onglet Identification réseau de l'application Système du Panneau de configuration.

Code
# Valeur de FullDNSRegistrationEnabled pour chaque instance
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property Index, FullDNSRegistrationEnabled |
    Select-Object -Property Index, FullDNSRegistrationEnabled
GatewayCostMetricuint16[]lecture

Tableau de valeurs entières de métrique de coût (comprises entre 1 et 9999) utilisées pour calculer les routes les plus rapides, les plus fiables ou les moins gourmandes en ressources. Cet argument correspond une à une à la propriété DefaultIPGateway.

Code
# Valeur de GatewayCostMetric pour chaque instance
# GatewayCostMetric est un tableau : -ExpandProperty renvoie ses éléments un par un
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property GatewayCostMetric |
    Select-Object -ExpandProperty GatewayCostMetric
IGMPLeveluint8lecture

Mesure dans laquelle le système prend en charge la multidiffusion IP et participe au protocole IGMP (Internet Group Management Protocol). Au niveau 0 (zéro), le système n'offre aucune prise en charge de la multidiffusion. Au niveau 1, le système ne peut envoyer que des paquets de multidiffusion IP. Au niveau 2, le système peut envoyer des paquets de multidiffusion IP et participer pleinement à IGMP pour recevoir des paquets de multidiffusion.

Valeurs (3)
ValeurLibelléDescription
0No Multicast
1IP Multicast
2IP & IGMP multicastIP et multidiffusion IGMP (par défaut)
Code
# Valeur de IGMPLevel pour chaque instance
# Table de correspondance pour IGMPLevel (valeurs documentées par Microsoft)
$iGMPLevelName = @{
    0 = 'No Multicast'
    1 = 'IP Multicast'
    2 = 'IP & IGMP multicast'
}
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property Index, IGMPLevel |
    Select-Object -Property @(
        'Index'
        @{ Name = 'IGMPLevel'; Expression = { $iGMPLevelName[[int]$_.IGMPLevel] } }
    )
Index cléuint32lecture

Numéro d'index de la configuration de l'adaptateur réseau Windows. Ce numéro d'index est utilisé lorsque plusieurs configurations sont disponibles.

Code
# Valeur de Index pour chaque instance
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property Index |
    Select-Object -Property Index
InterfaceIndexuint32lecture

Valeur d'index qui identifie de manière unique une interface réseau locale. La valeur de cette propriété est identique à celle de la propriété InterfaceIndex de l'instance de Win32_IP4RouteTable qui représente l'interface réseau dans la table de routage.

Code
# Valeur de InterfaceIndex pour chaque instance
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property Index, InterfaceIndex |
    Select-Object -Property Index, InterfaceIndex
IPAddressstring[]lecture

Tableau de toutes les adresses IP associées à l'adaptateur réseau actuel. Cette propriété peut contenir des adresses IPv6 ou IPv4. Pour plus d'informations, consultez Prise en charge d'IPv6 et d'IPv4 dans WMI.

Exemple d'adresse IPv6 : "2010:836B:4179::836B:4179"

Code
# Valeur de IPAddress pour chaque instance
# IPAddress est un tableau : -ExpandProperty renvoie ses éléments un par un
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property IPAddress |
    Select-Object -ExpandProperty IPAddress
IPConnectionMetricuint32lecture

Coût d'utilisation des routes configurées pour l'adaptateur lié à IP. Il s'agit de la valeur pondérée de ces routes dans la table de routage IP. Lorsqu'il existe plusieurs routes vers une même destination dans la table de routage IP, la route ayant la métrique la plus faible est utilisée. La valeur par défaut est 1.

Code
# Valeur de IPConnectionMetric pour chaque instance
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property Index, IPConnectionMetric |
    Select-Object -Property Index, IPConnectionMetric
IPEnabledbooleanlecture

Si TRUE, TCP/IP est lié et activé sur cet adaptateur réseau.

Code
# Valeur de IPEnabled pour chaque instance
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property Index, IPEnabled |
    Select-Object -Property Index, IPEnabled
IPFilterSecurityEnabledbooleanlecture

Si TRUE, la sécurité des ports IP est activée globalement pour tous les adaptateurs réseau liés à IP, et les valeurs de sécurité associées à chaque adaptateur réseau sont appliquées. Cette propriété est utilisée conjointement avec IPSecPermitTCPPorts, IPSecPermitUDPPorts et IPSecPermitIPProtocols. Si FALSE, la sécurité du filtre IP est désactivée sur tous les adaptateurs réseau et autorise l'ensemble du trafic de ports et de protocoles à circuler sans filtrage.

Code
# Valeur de IPFilterSecurityEnabled pour chaque instance
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property Index, IPFilterSecurityEnabled |
    Select-Object -Property Index, IPFilterSecurityEnabled
IPPortSecurityEnabledbooleanlecture

Si TRUE, la sécurité des ports IP est activée globalement pour tous les adaptateurs réseau liés à IP. Cette propriété est obsolète. Il convient d'utiliser IPFilterSecurityEnabled à sa place.

Code
# Valeur de IPPortSecurityEnabled pour chaque instance
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property Index, IPPortSecurityEnabled |
    Select-Object -Property Index, IPPortSecurityEnabled
IPSecPermitIPProtocolsstring[]lecture

Tableau des protocoles autorisés à s'exécuter sur IP. La liste des protocoles est définie à l'aide de la méthode EnableIPSec. La liste est soit vide, soit composée de valeurs numériques. Une valeur numérique de 0 (zéro) indique que l'autorisation d'accès est accordée à tous les protocoles. Une chaîne vide indique qu'aucun protocole n'est autorisé à s'exécuter lorsque IPFilterSecurityEnabled est TRUE.

Code
# Valeur de IPSecPermitIPProtocols pour chaque instance
# IPSecPermitIPProtocols est un tableau : -ExpandProperty renvoie ses éléments un par un
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property IPSecPermitIPProtocols |
    Select-Object -ExpandProperty IPSecPermitIPProtocols
IPSecPermitTCPPortsstring[]lecture

Tableau des ports auxquels l'autorisation d'accès est accordée pour TCP. La liste des protocoles est définie à l'aide de la méthode EnableIPSec. La liste est soit vide, soit composée de valeurs numériques. Une valeur numérique de 0 (zéro) indique que l'autorisation d'accès est accordée à tous les ports. Une chaîne vide indique qu'aucun port n'est autorisé lorsque IPFilterSecurityEnabled est TRUE.

Code
# Valeur de IPSecPermitTCPPorts pour chaque instance
# IPSecPermitTCPPorts est un tableau : -ExpandProperty renvoie ses éléments un par un
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property IPSecPermitTCPPorts |
    Select-Object -ExpandProperty IPSecPermitTCPPorts
IPSecPermitUDPPortsstring[]lecture

Tableau des ports auxquels l'autorisation d'accès UDP (User Datagram Protocol) est accordée. La liste des protocoles est définie à l'aide de la méthode EnableIPSec. La liste est soit vide, soit composée de valeurs numériques. Une valeur numérique de 0 (zéro) indique que l'autorisation d'accès est accordée à tous les ports. Une chaîne vide indique qu'aucun port n'est autorisé lorsque IPFilterSecurityEnabled est TRUE.

Code
# Valeur de IPSecPermitUDPPorts pour chaque instance
# IPSecPermitUDPPorts est un tableau : -ExpandProperty renvoie ses éléments un par un
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property IPSecPermitUDPPorts |
    Select-Object -ExpandProperty IPSecPermitUDPPorts
IPSubnetstring[]lecture

Tableau de tous les masques de sous-réseau associés à l'adaptateur réseau actuel.

Exemple : "255.255.0.0"

Code
# Valeur de IPSubnet pour chaque instance
# IPSubnet est un tableau : -ExpandProperty renvoie ses éléments un par un
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property IPSubnet |
    Select-Object -ExpandProperty IPSubnet
IPUseZeroBroadcastbooleanlecture

Si TRUE, les diffusions IP à zéros (0.0.0.0) sont utilisées, et le système utilise les diffusions à uns (255.255.255.255). Les systèmes informatiques utilisent généralement les diffusions à uns, mais ceux qui dérivent des implémentations BSD utilisent les diffusions à zéros. Les systèmes qui n'utilisent pas les mêmes diffusions ne peuvent pas interagir sur le même réseau. La valeur par défaut est FALSE.

Code
# Valeur de IPUseZeroBroadcast pour chaque instance
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property Index, IPUseZeroBroadcast |
    Select-Object -Property Index, IPUseZeroBroadcast
IPXAddressstringlecture

La technologie IPX (Internetwork Packet Exchange) n'est plus prise en charge et cette propriété ne contient aucune donnée utile.

Code
# Valeur de IPXAddress pour chaque instance
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property Index, IPXAddress |
    Select-Object -Property Index, IPXAddress
IPXEnabledbooleanlecture

La technologie IPX (Internetwork Packet Exchange) n'est plus prise en charge et cette propriété ne contient aucune donnée utile.

Code
# Valeur de IPXEnabled pour chaque instance
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property Index, IPXEnabled |
    Select-Object -Property Index, IPXEnabled
IPXFrameTypeuint32[]lecture

La technologie IPX (Internetwork Packet Exchange) n'est plus prise en charge et cette propriété ne contient aucune donnée utile.

Valeurs (5)
ValeurLibelléDescription
0Ethernet II
1Ethernet 802.3
2Ethernet 802.2
3Ethernet SNAP
255AUTO
Code
# Valeur de IPXFrameType pour chaque instance
# Table de correspondance pour IPXFrameType (valeurs documentées par Microsoft)
$iPXFrameTypeName = @{
    0 = 'Ethernet II'
    1 = 'Ethernet 802.3'
    2 = 'Ethernet 802.2'
    3 = 'Ethernet SNAP'
    255 = 'AUTO'
}
# IPXFrameType est un tableau : -ExpandProperty renvoie ses éléments un par un
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property IPXFrameType |
    Select-Object -ExpandProperty IPXFrameType |
    ForEach-Object -Process { $iPXFrameTypeName[[int]$_] }
IPXMediaTypeuint32lecture

La technologie IPX (Internetwork Packet Exchange) n'est plus prise en charge et cette propriété ne contient aucune donnée utile.

Valeurs (4)
ValeurLibelléDescription
1Ethernet
2Token ring
3FDDI
8ARCNET
Code
# Valeur de IPXMediaType pour chaque instance
# Table de correspondance pour IPXMediaType (valeurs documentées par Microsoft)
$iPXMediaTypeName = @{
    1 = 'Ethernet'
    2 = 'Token ring'
    3 = 'FDDI'
    8 = 'ARCNET'
}
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property Index, IPXMediaType |
    Select-Object -Property @(
        'Index'
        @{ Name = 'IPXMediaType'; Expression = { $iPXMediaTypeName[[int]$_.IPXMediaType] } }
    )
IPXNetworkNumberstring[]lecture

La technologie IPX (Internetwork Packet Exchange) n'est plus prise en charge et cette propriété ne contient aucune donnée utile.

Code
# Valeur de IPXNetworkNumber pour chaque instance
# IPXNetworkNumber est un tableau : -ExpandProperty renvoie ses éléments un par un
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property IPXNetworkNumber |
    Select-Object -ExpandProperty IPXNetworkNumber
IPXVirtualNetNumberstringlecture

La technologie IPX (Internetwork Packet Exchange) n'est plus prise en charge et cette propriété ne contient aucune donnée utile.

Code
# Valeur de IPXVirtualNetNumber pour chaque instance
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property Index, IPXVirtualNetNumber |
    Select-Object -Property Index, IPXVirtualNetNumber
KeepAliveIntervaluint32lecture

Intervalle séparant les retransmissions de Keep Alive jusqu'à réception d'une réponse. Une fois la réponse reçue, le délai avant la transmission Keep Alive suivante est de nouveau contrôlé par la valeur de KeepAliveTime. La connexion est interrompue après le nombre de retransmissions spécifié par TcpMaxDataRetransmissions restées sans réponse. Par défaut : 1000, plage valide : 1 à 0xFFFFFFFF.

Unité : milliseconds

Code
# Valeur de KeepAliveInterval pour chaque instance
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property Index, KeepAliveInterval |
    Select-Object -Property Index, KeepAliveInterval
KeepAliveTimeuint32lecture

La propriété KeepAliveTime indique la fréquence à laquelle TCP tente de vérifier qu'une connexion inactive est toujours intacte, en envoyant un paquet Keep Alive. Un système distant accessible accusera réception de la transmission Keep Alive. Les paquets Keep Alive ne sont pas envoyés par défaut. Cette fonctionnalité peut être activée sur une connexion par une application. Par défaut : 7 200 000 (deux heures).

Unité : milliseconds

Code
# Valeur de KeepAliveTime pour chaque instance
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property Index, KeepAliveTime |
    Select-Object -Property Index, KeepAliveTime
MACAddressstringlecture

Adresse MAC (Media Access Control) de l'adaptateur réseau. Une adresse MAC est attribuée par le fabricant pour identifier de manière unique l'adaptateur réseau.

Exemple : "00:80:C7:8F:6C:96"

Code
# Valeur de MACAddress pour chaque instance
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property Index, MACAddress |
    Select-Object -Property Index, MACAddress
MTUuint32lecture

Remplace l'unité de transmission maximale (MTU) par défaut d'une interface réseau. La MTU est la taille maximale de paquet (en-tête de transport inclus) que le protocole de transport transmet sur le réseau sous-jacent. Le datagramme IP peut s'étendre sur plusieurs paquets. La plage de valeurs va de la taille minimale de paquet (68) à la MTU prise en charge par le réseau sous-jacent.

Unité : bytes

Code
# Valeur de MTU pour chaque instance
# MTU est exprimé en octets : conversion en Go
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property Index, MTU |
    Select-Object -Property @(
        'Index'
        @{ Name = 'MTUGB'; Expression = { [math]::Round($_.MTU / 1GB, 2) } }
    )
NumForwardPacketsuint32lecture

Nombre d'en-têtes de paquets IP alloués à la file d'attente des paquets du routeur. Lorsque tous les en-têtes sont utilisés, le routeur commence à supprimer aléatoirement des paquets de la file d'attente. Cette valeur doit être au moins égale à la valeur de ForwardBufferMemory divisée par la taille maximale des données IP des réseaux connectés au routeur. Elle ne doit pas dépasser la valeur de ForwardBufferMemory divisée par 256, car au moins 256 octets de mémoire tampon de transfert sont utilisés pour chaque paquet. Le nombre optimal de paquets de transfert pour une taille donnée de ForwardBufferMemory dépend du type de trafic sur le réseau. Il se situe entre ces deux valeurs. Si le routeur n'est pas activé, ce paramètre est ignoré et aucun en-tête n'est alloué. Par défaut : 50, plage valide : 1 à 0xFFFFFFFE.

Code
# Valeur de NumForwardPackets pour chaque instance
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property Index, NumForwardPackets |
    Select-Object -Property Index, NumForwardPackets
PMTUBHDetectEnabledbooleanlecture

Si TRUE, la détection des routeurs trou noir s'effectue pendant que TCP découvre le chemin de l'unité de transmission maximale (MTU). Un routeur trou noir ne renvoie pas de messages ICMP Destination Unreachable lorsqu'il doit fragmenter un datagramme IP dont le bit Don't Fragment est défini. TCP dépend de la réception de ces messages pour effectuer la découverte de MTU de chemin. Lorsque cette fonctionnalité est activée, TCP tente d'envoyer des segments sans le bit Don't Fragment défini si plusieurs retransmissions d'un segment restent sans accusé de réception. Si le segment est alors accusé de réception, la MSS est réduite et le bit Don't Fragment est défini dans les paquets suivants de la connexion. L'activation de la détection des trous noirs augmente le nombre maximal de retransmissions effectuées pour un segment donné. La valeur par défaut de cette propriété est FALSE.

Code
# Valeur de PMTUBHDetectEnabled pour chaque instance
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property Index, PMTUBHDetectEnabled |
    Select-Object -Property Index, PMTUBHDetectEnabled
PMTUDiscoveryEnabledbooleanlecture

Si TRUE, le chemin de l'unité de transmission maximale (MTU) est découvert jusqu'à un hôte distant. En découvrant le chemin MTU et en limitant les segments TCP à cette taille, TCP peut éliminer la fragmentation au niveau des routeurs situés sur le chemin qui relient des réseaux ayant des MTU différentes. La fragmentation nuit au débit TCP et à la congestion du réseau. Si ce paramètre est défini sur FALSE, une MTU de 576 octets est utilisée pour toutes les connexions vers des machines qui ne se trouvent pas sur le sous-réseau local. La valeur par défaut est TRUE.

Code
# Valeur de PMTUDiscoveryEnabled pour chaque instance
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property Index, PMTUDiscoveryEnabled |
    Select-Object -Property Index, PMTUDiscoveryEnabled
ServiceNamestringlecture

Nom du service de l'adaptateur réseau. Ce nom est généralement plus court que le nom complet du produit.

Exemple : "Elnkii"

Code
# Valeur de ServiceName pour chaque instance
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property Index, ServiceName |
    Select-Object -Property Index, ServiceName
SettingIDstringlecture

Identifiant par lequel l'objet actuel est connu.

Code
# Valeur de SettingID pour chaque instance
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property Index, SettingID |
    Select-Object -Property Index, SettingID
TcpipNetbiosOptionsuint32lecture

Bitmap des paramètres possibles liés à NetBIOS sur TCP/IP. Les valeurs sont identifiées dans la liste suivante.

Valeurs (3)
ValeurLibelléDescription
0EnableNetbiosViaDhcp
1EnableNetbios
2DisableNetbios
Code
# Valeur de TcpipNetbiosOptions pour chaque instance
# Table de correspondance pour TcpipNetbiosOptions (valeurs documentées par Microsoft)
$tcpipNetbiosOptionsName = @{
    0 = 'EnableNetbiosViaDhcp'
    1 = 'EnableNetbios'
    2 = 'DisableNetbios'
}
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property Index, TcpipNetbiosOptions |
    Select-Object -Property @(
        'Index'
        @{ Name = 'TcpipNetbiosOptions'; Expression = { $tcpipNetbiosOptionsName[[int]$_.TcpipNetbiosOptions] } }
    )
TcpMaxConnectRetransmissionsuint32lecture

Nombre de fois où TCP tente de retransmettre une demande de connexion avant de mettre fin à la connexion. Le délai initial de retransmission est de 3 secondes. Ce délai double à chaque tentative. Par défaut : 3, plage valide : 0 à 0xFFFFFFFF.

Code
# Valeur de TcpMaxConnectRetransmissions pour chaque instance
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property Index, TcpMaxConnectRetransmissions |
    Select-Object -Property Index, TcpMaxConnectRetransmissions
TcpMaxDataRetransmissionsuint32lecture

Nombre de fois où TCP retransmet un segment de données individuel (segment hors connexion) avant de mettre fin à la connexion. Le délai de retransmission double à chaque retransmission successive sur une connexion. Par défaut : 5, plage valide : 0 à 0xFFFFFFFF.

Code
# Valeur de TcpMaxDataRetransmissions pour chaque instance
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property Index, TcpMaxDataRetransmissions |
    Select-Object -Property Index, TcpMaxDataRetransmissions
TcpNumConnectionsuint32lecture

Nombre maximal de connexions que TCP peut avoir ouvertes simultanément. Par défaut : 0xFFFFFE, plage valide : 0 à 0xFFFFFE.

Code
# Valeur de TcpNumConnections pour chaque instance
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property Index, TcpNumConnections |
    Select-Object -Property Index, TcpNumConnections
TcpUseRFC1122UrgentPointerbooleanlecture

Si TRUE, TCP utilise la spécification RFC 1122 pour les données urgentes. Si FALSE (par défaut), TCP utilise le mode utilisé par les systèmes dérivés de Berkeley Software Design (BSD). Les deux mécanismes interprètent différemment le pointeur urgent et ne sont pas interopérables. La valeur par défaut est FALSE.

Code
# Valeur de TcpUseRFC1122UrgentPointer pour chaque instance
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property Index, TcpUseRFC1122UrgentPointer |
    Select-Object -Property Index, TcpUseRFC1122UrgentPointer
TcpWindowSizeuint16lecture

Taille maximale de la fenêtre de réception TCP proposée par le système. La fenêtre de réception indique le nombre d'octets qu'un expéditeur peut transmettre sans recevoir d'accusé de réception. En général, des fenêtres de réception plus grandes améliorent les performances sur les réseaux à forte latence et à haut débit. Pour une meilleure efficacité, la fenêtre de réception doit être un multiple pair de la taille maximale de segment TCP (MSS). Par défaut : quatre fois la taille maximale des données TCP, ou un multiple pair de la taille des données TCP arrondi au multiple de 8192 supérieur. Les réseaux Ethernet utilisent 8760 par défaut. Plage valide : 0 - 65535.

Remarque : Windows Vista : cette propriété accède à l'entrée de Registre "CurrentControlSet\Services\Tcpip\Parameters|TcpWindowSize", qui n'est pas utilisée dans l'implémentation actuelle du système d'exploitation.

Unité : bytes

Code
# Valeur de TcpWindowSize pour chaque instance
# TcpWindowSize est exprimé en octets : conversion en Go
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property Index, TcpWindowSize |
    Select-Object -Property @(
        'Index'
        @{ Name = 'TcpWindowSizeGB'; Expression = { [math]::Round($_.TcpWindowSize / 1GB, 2) } }
    )
WINSEnableLMHostsLookupbooleanlecture

Si TRUE, des fichiers de recherche locaux sont utilisés. Ces fichiers contiennent une correspondance entre adresses IP et noms d'hôte. S'ils existent sur le système local, ils se trouvent dans %SystemRoot%\system32\drivers\etc.

Code
# Valeur de WINSEnableLMHostsLookup pour chaque instance
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property Index, WINSEnableLMHostsLookup |
    Select-Object -Property Index, WINSEnableLMHostsLookup
WINSHostLookupFilestringlecture

Chemin d'accès à un fichier de recherche WINS sur le système local. Ce fichier contient une correspondance entre adresses IP et noms d'hôte. Si le fichier spécifié dans cette propriété est trouvé, il est copié dans le dossier %SystemRoot%\system32\drivers\etc du système local. Valide uniquement si la propriété WINSEnableLMHostsLookup est TRUE.

Code
# Valeur de WINSHostLookupFile pour chaque instance
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property Index, WINSHostLookupFile |
    Select-Object -Property Index, WINSHostLookupFile
WINSPrimaryServerstringlecture

Adresse IP du serveur WINS principal.

Code
# Valeur de WINSPrimaryServer pour chaque instance
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property Index, WINSPrimaryServer |
    Select-Object -Property Index, WINSPrimaryServer
WINSScopeIDstringlecture

Valeur ajoutée à la fin du nom NetBIOS qui isole un groupe de systèmes informatiques ne communiquant qu'entre eux. Elle est utilisée pour toutes les transactions NetBIOS sur les communications TCP/IP de ce système informatique. Les ordinateurs configurés avec des identificateurs d'étendue identiques peuvent communiquer avec cet ordinateur. Les clients TCP/IP dont les identificateurs d'étendue sont différents ignorent les paquets provenant d'ordinateurs ayant cet identificateur d'étendue. Valide uniquement lorsque la méthode EnableWINS s'exécute correctement.

Code
# Valeur de WINSScopeID pour chaque instance
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property Index, WINSScopeID |
    Select-Object -Property Index, WINSScopeID
WINSSecondaryServerstringlecture

Adresse IP du serveur WINS secondaire.

Code
# Valeur de WINSSecondaryServer pour chaque instance
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Property Index, WINSSecondaryServer |
    Select-Object -Property Index, WINSSecondaryServer

Méthodes

DisableIPSec #

Désactive IPsec sur cet adaptateur réseau compatible TCP/IP.

uint32 DisableIPSec();

Codes de retour

ValeurLibelléDescription
0Successful completion, no reboot required
1Successful completion, reboot required
64Method not supported on this platform
65Unknown failure
66Invalid subnet mask
67An error occurred while processing an Instance that was returned
68Invalid input parameter
69More than 5 gateways specifiedPlus de cinq passerelles spécifiées.
70Invalid IP address
71Invalid gateway IP address
72An error occurred while accessing the Registry for the requested information
73Invalid domain name
74Invalid host name
75No primary/secondary WINS server definedAucun serveur WINS principal ou secondaire défini.
76Invalid file
77Invalid system path
78File copy failed
79Invalid security parameter
80Unable to configure TCP/IP service
81Unable to configure DHCP service
82Unable to renew DHCP lease
83Unable to release DHCP lease
84IP not enabled on adapter
85IPX not enabled on adapter
86Frame/network number bounds errorErreur de limite de trame ou de numéro de réseau.
87Invalid frame type
88Invalid network number
89Duplicate network number
90Parameter out of bounds
91Access denied
92Out of memory
93Already exists
94Path, file or object not foundChemin, fichier ou objet introuvable.
95Unable to notify service
96Unable to notify DNS service
97Interface not configurable
98Not all DHCP leases could be released/renewedTous les baux DHCP n'ont pas pu être libérés ou renouvelés.
100DHCP not enabled on adapterDHCP n'est pas activé sur la carte réseau.
101..4294967295Other

Appeler la méthode DisableIPSec

à vérifier avant exécution
# Attention : cette méthode peut modifier le système. -WhatIf affiche l'opération sans l'exécuter.
# Instance cible
$instance = Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Filter 'IPEnabled = TRUE'
$methodParameters = @{
    InputObject = $instance
    MethodName  = 'DisableIPSec'
    WhatIf      = $true  # Retirez cette ligne pour exécuter réellement la méthode
}
$result = Invoke-CimMethod @methodParameters

# Avec -WhatIf, rien n'est exécuté et aucun résultat n'est renvoyé
if ($result) {
    $returnValueName = @{
        0 = 'Successful completion, no reboot required'
        1 = 'Successful completion, reboot required'
        64 = 'Method not supported on this platform'
        65 = 'Unknown failure'
        66 = 'Invalid subnet mask'
        67 = 'An error occurred while processing an Instance that was returned'
        68 = 'Invalid input parameter'
        69 = 'More than 5 gateways specified'
        70 = 'Invalid IP address'
        71 = 'Invalid gateway IP address'
        72 = 'An error occurred while accessing the Registry for the…'
        73 = 'Invalid domain name'
        74 = 'Invalid host name'
        75 = 'No primary/secondary WINS server defined'
        76 = 'Invalid file'
        77 = 'Invalid system path'
        78 = 'File copy failed'
        79 = 'Invalid security parameter'
        80 = 'Unable to configure TCP/IP service'
        81 = 'Unable to configure DHCP service'
        82 = 'Unable to renew DHCP lease'
        83 = 'Unable to release DHCP lease'
        84 = 'IP not enabled on adapter'
        85 = 'IPX not enabled on adapter'
        86 = 'Frame/network number bounds error'
        87 = 'Invalid frame type'
        88 = 'Invalid network number'
        89 = 'Duplicate network number'
        90 = 'Parameter out of bounds'
        91 = 'Access denied'
        92 = 'Out of memory'
        93 = 'Already exists'
        94 = 'Path, file or object not found'
        95 = 'Unable to notify service'
        96 = 'Unable to notify DNS service'
        97 = 'Interface not configurable'
        98 = 'Not all DHCP leases could be released/renewed'
        100 = 'DHCP not enabled on adapter'
    }
    $returnValueName[[int]$result.ReturnValue]
}

Cette méthode peut modifier le système. Le paramètre -WhatIf affiche l'opération sans l'exécuter : retirez-le seulement après vérification.

EnableDHCP #

Active le protocole DHCP (Dynamic Host Configuration Protocol) pour le service avec cet adaptateur réseau.

uint32 EnableDHCP();

Codes de retour

ValeurLibelléDescription
0Successful completion, no reboot required
1Successful completion, reboot required
64Method not supported on this platform
65Unknown failure
66Invalid subnet mask
67An error occurred while processing an Instance that was returned
68Invalid input parameter
69More than 5 gateways specifiedPlus de cinq passerelles spécifiées.
70Invalid IP address
71Invalid gateway IP address
72An error occurred while accessing the Registry for the requested information
73Invalid domain name
74Invalid host name
75No primary/secondary WINS server definedAucun serveur WINS principal ou secondaire défini.
76Invalid file
77Invalid system path
78File copy failed
79Invalid security parameter
80Unable to configure TCP/IP service
81Unable to configure DHCP service
82Unable to renew DHCP lease
83Unable to release DHCP lease
84IP not enabled on adapter
85IPX not enabled on adapter
86Frame/network number bounds errorErreur de limite de trame ou de numéro de réseau.
87Invalid frame type
88Invalid network number
89Duplicate network number
90Parameter out of bounds
91Access denied
92Out of memory
93Already exists
94Path, file or object not foundChemin, fichier ou objet introuvable.
95Unable to notify service
96Unable to notify DNS service
97Interface not configurable
98Not all DHCP leases could be released/renewedTous les baux DHCP n'ont pas pu être libérés ou renouvelés.
100DHCP not enabled on adapterDHCP n'est pas activé sur la carte réseau.
101..4294967295Other

Appeler la méthode EnableDHCP

à vérifier avant exécution
# Attention : cette méthode peut modifier le système. -WhatIf affiche l'opération sans l'exécuter.
# Instance cible
$instance = Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Filter 'IPEnabled = TRUE'
$methodParameters = @{
    InputObject = $instance
    MethodName  = 'EnableDHCP'
    WhatIf      = $true  # Retirez cette ligne pour exécuter réellement la méthode
}
$result = Invoke-CimMethod @methodParameters

# Avec -WhatIf, rien n'est exécuté et aucun résultat n'est renvoyé
if ($result) {
    $returnValueName = @{
        0 = 'Successful completion, no reboot required'
        1 = 'Successful completion, reboot required'
        64 = 'Method not supported on this platform'
        65 = 'Unknown failure'
        66 = 'Invalid subnet mask'
        67 = 'An error occurred while processing an Instance that was returned'
        68 = 'Invalid input parameter'
        69 = 'More than 5 gateways specified'
        70 = 'Invalid IP address'
        71 = 'Invalid gateway IP address'
        72 = 'An error occurred while accessing the Registry for the…'
        73 = 'Invalid domain name'
        74 = 'Invalid host name'
        75 = 'No primary/secondary WINS server defined'
        76 = 'Invalid file'
        77 = 'Invalid system path'
        78 = 'File copy failed'
        79 = 'Invalid security parameter'
        80 = 'Unable to configure TCP/IP service'
        81 = 'Unable to configure DHCP service'
        82 = 'Unable to renew DHCP lease'
        83 = 'Unable to release DHCP lease'
        84 = 'IP not enabled on adapter'
        85 = 'IPX not enabled on adapter'
        86 = 'Frame/network number bounds error'
        87 = 'Invalid frame type'
        88 = 'Invalid network number'
        89 = 'Duplicate network number'
        90 = 'Parameter out of bounds'
        91 = 'Access denied'
        92 = 'Out of memory'
        93 = 'Already exists'
        94 = 'Path, file or object not found'
        95 = 'Unable to notify service'
        96 = 'Unable to notify DNS service'
        97 = 'Interface not configurable'
        98 = 'Not all DHCP leases could be released/renewed'
        100 = 'DHCP not enabled on adapter'
    }
    $returnValueName[[int]$result.ReturnValue]
}

Cette méthode peut modifier le système. Le paramètre -WhatIf affiche l'opération sans l'exécuter : retirez-le seulement après vérification.

EnableDNS statique#

Active le système DNS (Domain Name System) pour le service sur cet adaptateur réseau lié à TCP/IP.

uint32 EnableDNS(
    [in] string DNSHostName,
    [in] string DNSDomain,
    [in] string[] DNSServerSearchOrder,
    [in] string[] DNSDomainSuffixSearchOrder
);

Paramètres

ParamètreTypeSensDescription
DNSHostNamestringentrée

Nom de l'hôte DNS que cette méthode active.

Exemple : "corpdns"

DNSDomainstringentrée

Représente un nom d'organisation suivi d'un point et d'une extension indiquant le type d'organisation.

Exemple : "microsoft.com"

DNSServerSearchOrderstring[]entrée

Liste des adresses IP de serveurs à interroger pour trouver les serveurs DNS.

DNSDomainSuffixSearchOrderstring[]entrée

Suffixe de domaine DNS ajouté à un nom d'hôte lors de la résolution de noms. Lors de la résolution d'un nom de domaine complet (FQDN) à partir d'un nom d'hôte uniquement, le système ajoute le nom de domaine local. Si la résolution de noms échoue, le système utilise la liste des suffixes de domaine pour créer des FQDN supplémentaires dans l'ordre indiqué, puis interroge les serveurs DNS pour chacun d'eux.

Codes de retour

ValeurLibelléDescription
0Successful completion, no reboot required
1Successful completion, reboot required
64Method not supported on this platform
65Unknown failure
66Invalid subnet mask
67An error occurred while processing an Instance that was returned
68Invalid input parameter
69More than 5 gateways specifiedPlus de cinq passerelles spécifiées.
70Invalid IP address
71Invalid gateway IP address
72An error occurred while accessing the Registry for the requested information
73Invalid domain name
74Invalid host name
75No primary/secondary WINS server definedAucun serveur WINS principal ou secondaire défini.
76Invalid file
77Invalid system path
78File copy failed
79Invalid security parameter
80Unable to configure TCP/IP service
81Unable to configure DHCP service
82Unable to renew DHCP lease
83Unable to release DHCP lease
84IP not enabled on adapter
85IPX not enabled on adapter
86Frame/network number bounds errorErreur de limite de trame ou de numéro de réseau.
87Invalid frame type
88Invalid network number
89Duplicate network number
90Parameter out of bounds
91Access denied
92Out of memory
93Already exists
94Path, file or object not foundChemin, fichier ou objet introuvable.
95Unable to notify service
96Unable to notify DNS service
97Interface not configurable
98Not all DHCP leases could be released/renewedTous les baux DHCP ne peuvent pas être libérés ou renouvelés.
100DHCP not enabled on adapter
101..4294967295Other

Appeler la méthode EnableDNS

à vérifier avant exécution
# Attention : cette méthode peut modifier le système. -WhatIf affiche l'opération sans l'exécuter.
$methodParameters = @{
    ClassName  = 'Win32_NetworkAdapterConfiguration'
    MethodName = 'EnableDNS'
    Arguments  = @{
        DNSHostName                = 'Example'
        DNSDomain                  = 'Example'
        DNSServerSearchOrder       = @('Example')
        DNSDomainSuffixSearchOrder = @('Example')
    }
    WhatIf     = $true  # Retirez cette ligne pour exécuter réellement la méthode
}
$result = Invoke-CimMethod @methodParameters

# Avec -WhatIf, rien n'est exécuté et aucun résultat n'est renvoyé
if ($result) {
    $returnValueName = @{
        0 = 'Successful completion, no reboot required'
        1 = 'Successful completion, reboot required'
        64 = 'Method not supported on this platform'
        65 = 'Unknown failure'
        66 = 'Invalid subnet mask'
        67 = 'An error occurred while processing an Instance that was returned'
        68 = 'Invalid input parameter'
        69 = 'More than 5 gateways specified'
        70 = 'Invalid IP address'
        71 = 'Invalid gateway IP address'
        72 = 'An error occurred while accessing the Registry for the…'
        73 = 'Invalid domain name'
        74 = 'Invalid host name'
        75 = 'No primary/secondary WINS server defined'
        76 = 'Invalid file'
        77 = 'Invalid system path'
        78 = 'File copy failed'
        79 = 'Invalid security parameter'
        80 = 'Unable to configure TCP/IP service'
        81 = 'Unable to configure DHCP service'
        82 = 'Unable to renew DHCP lease'
        83 = 'Unable to release DHCP lease'
        84 = 'IP not enabled on adapter'
        85 = 'IPX not enabled on adapter'
        86 = 'Frame/network number bounds error'
        87 = 'Invalid frame type'
        88 = 'Invalid network number'
        89 = 'Duplicate network number'
        90 = 'Parameter out of bounds'
        91 = 'Access denied'
        92 = 'Out of memory'
        93 = 'Already exists'
        94 = 'Path, file or object not found'
        95 = 'Unable to notify service'
        96 = 'Unable to notify DNS service'
        97 = 'Interface not configurable'
        98 = 'Not all DHCP leases could be released/renewed'
        100 = 'DHCP not enabled on adapter'
    }
    $returnValueName[[int]$result.ReturnValue]
}

Cette méthode peut modifier le système. Le paramètre -WhatIf affiche l'opération sans l'exécuter : retirez-le seulement après vérification.

EnableIPFilterSec statique#

Active IPsec globalement sur l'ensemble des adaptateurs réseau liés à IP.

uint32 EnableIPFilterSec([in] boolean IPFilterSecurityEnabled);

Paramètres

ParamètreTypeSensDescription
IPFilterSecurityEnabledbooleanentrée

Si true, IPsec est activé globalement sur toutes les cartes réseau liées à IP. Si false, tout le trafic de ports et de protocoles est autorisé à circuler sans filtrage.

Codes de retour

ValeurLibelléDescription
0Successful completion, no reboot required
1Successful completion, reboot required
64Method not supported on this platform
65Unknown failure
66Invalid subnet mask
67An error occurred while processing an Instance that was returned
68Invalid input parameter
69More than 5 gateways specifiedPlus de cinq passerelles spécifiées.
70Invalid IP address
71Invalid gateway IP address
72An error occurred while accessing the Registry for the requested information
73Invalid domain name
74Invalid host name
75No primary/secondary WINS server definedAucun serveur WINS principal ou secondaire défini.
76Invalid file
77Invalid system path
78File copy failed
79Invalid security parameter
80Unable to configure TCP/IP service
81Unable to configure DHCP service
82Unable to renew DHCP lease
83Unable to release DHCP lease
84IP not enabled on adapter
85IPX not enabled on adapter
86Frame/network number bounds errorErreur de limite de trame ou de numéro de réseau.
87Invalid frame type
88Invalid network number
89Duplicate network number
90Parameter out of bounds
91Access denied
92Out of memory
93Already exists
94Path, file or object not foundChemin, fichier ou objet introuvable.
95Unable to notify service
96Unable to notify DNS service
97Interface not configurable
98Not all DHCP leases could be released/renewedTous les baux DHCP n'ont pas pu être libérés ou renouvelés.
100DHCP not enabled on adapterDHCP n'est pas activé sur la carte réseau.
101..4294967295Other

Appeler la méthode EnableIPFilterSec

à vérifier avant exécution
# Attention : cette méthode peut modifier le système. -WhatIf affiche l'opération sans l'exécuter.
$methodParameters = @{
    ClassName  = 'Win32_NetworkAdapterConfiguration'
    MethodName = 'EnableIPFilterSec'
    Arguments  = @{ IPFilterSecurityEnabled = $false }
    WhatIf     = $true  # Retirez cette ligne pour exécuter réellement la méthode
}
$result = Invoke-CimMethod @methodParameters

# Avec -WhatIf, rien n'est exécuté et aucun résultat n'est renvoyé
if ($result) {
    $returnValueName = @{
        0 = 'Successful completion, no reboot required'
        1 = 'Successful completion, reboot required'
        64 = 'Method not supported on this platform'
        65 = 'Unknown failure'
        66 = 'Invalid subnet mask'
        67 = 'An error occurred while processing an Instance that was returned'
        68 = 'Invalid input parameter'
        69 = 'More than 5 gateways specified'
        70 = 'Invalid IP address'
        71 = 'Invalid gateway IP address'
        72 = 'An error occurred while accessing the Registry for the…'
        73 = 'Invalid domain name'
        74 = 'Invalid host name'
        75 = 'No primary/secondary WINS server defined'
        76 = 'Invalid file'
        77 = 'Invalid system path'
        78 = 'File copy failed'
        79 = 'Invalid security parameter'
        80 = 'Unable to configure TCP/IP service'
        81 = 'Unable to configure DHCP service'
        82 = 'Unable to renew DHCP lease'
        83 = 'Unable to release DHCP lease'
        84 = 'IP not enabled on adapter'
        85 = 'IPX not enabled on adapter'
        86 = 'Frame/network number bounds error'
        87 = 'Invalid frame type'
        88 = 'Invalid network number'
        89 = 'Duplicate network number'
        90 = 'Parameter out of bounds'
        91 = 'Access denied'
        92 = 'Out of memory'
        93 = 'Already exists'
        94 = 'Path, file or object not found'
        95 = 'Unable to notify service'
        96 = 'Unable to notify DNS service'
        97 = 'Interface not configurable'
        98 = 'Not all DHCP leases could be released/renewed'
        100 = 'DHCP not enabled on adapter'
    }
    $returnValueName[[int]$result.ReturnValue]
}

Cette méthode peut modifier le système. Le paramètre -WhatIf affiche l'opération sans l'exécuter : retirez-le seulement après vérification.

EnableIPSec #

Active IPsec sur cet adaptateur réseau spécifique compatible TCP/IP.

uint32 EnableIPSec(
    [in] string[] IPSecPermitTCPPorts,
    [in] string[] IPSecPermitUDPPorts,
    [in] string[] IPSecPermitIPProtocols
);

Paramètres

ParamètreTypeSensDescription
IPSecPermitTCPPortsstring[]entrée

Liste des ports auxquels l'autorisation d'accès est accordée pour TCP. La valeur numérique 0 (zéro) indique que l'autorisation d'accès est accordée pour tous les ports. Un tableau vide indique qu'aucun port ne se voit accorder l'autorisation d'accès.

IPSecPermitUDPPortsstring[]entrée

Liste des ports auxquels l'autorisation d'accès est accordée pour UDP. La valeur numérique 0 (zéro) indique que l'autorisation d'accès est accordée pour tous les ports. Un tableau vide indique qu'aucun port ne se voit accorder l'autorisation d'accès.

IPSecPermitIPProtocolsstring[]entrée

Liste des protocoles autorisés à s'exécuter sur IP. La valeur numérique 0 (zéro) indique que l'autorisation d'accès est accordée pour tous les protocoles. Un tableau vide indique qu'aucun protocole ne se voit accorder l'autorisation d'accès.

Codes de retour

ValeurLibelléDescription
0Successful completion, no reboot required
1Successful completion, reboot required
64Method not supported on this platform
65Unknown failure
66Invalid subnet mask
67An error occurred while processing an Instance that was returned
68Invalid input parameter
69More than 5 gateways specifiedPlus de cinq passerelles spécifiées.
70Invalid IP address
71Invalid gateway IP address
72An error occurred while accessing the Registry for the requested information
73Invalid domain name
74Invalid host name
75No primary/secondary WINS server definedAucun serveur WINS principal ou secondaire défini.
76Invalid file
77Invalid system path
78File copy failed
79Invalid security parameter
80Unable to configure TCP/IP service
81Unable to configure DHCP service
82Unable to renew DHCP lease
83Unable to release DHCP lease
84IP not enabled on adapter
85IPX not enabled on adapter
86Frame/network number bounds errorErreur de limite de trame ou de numéro de réseau.
87Invalid frame type
88Invalid network number
89Duplicate network number
90Parameter out of bounds
91Access denied
92Out of memory
93Already exists
94Path, file or object not foundChemin, fichier ou objet introuvable.
95Unable to notify service
96Unable to notify DNS service
97Interface not configurable
98Not all DHCP leases could be released/renewedTous les baux DHCP n'ont pas pu être libérés ou renouvelés.
100DHCP not enabled on adapterDHCP n'est pas activé sur la carte réseau.
101..4294967295Other

Appeler la méthode EnableIPSec

à vérifier avant exécution
# Attention : cette méthode peut modifier le système. -WhatIf affiche l'opération sans l'exécuter.
# Instance cible
$instance = Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Filter 'IPEnabled = TRUE'
$methodParameters = @{
    InputObject = $instance
    MethodName  = 'EnableIPSec'
    Arguments   = @{
        IPSecPermitTCPPorts    = @('Example')
        IPSecPermitUDPPorts    = @('Example')
        IPSecPermitIPProtocols = @('Example')
    }
    WhatIf      = $true  # Retirez cette ligne pour exécuter réellement la méthode
}
$result = Invoke-CimMethod @methodParameters

# Avec -WhatIf, rien n'est exécuté et aucun résultat n'est renvoyé
if ($result) {
    $returnValueName = @{
        0 = 'Successful completion, no reboot required'
        1 = 'Successful completion, reboot required'
        64 = 'Method not supported on this platform'
        65 = 'Unknown failure'
        66 = 'Invalid subnet mask'
        67 = 'An error occurred while processing an Instance that was returned'
        68 = 'Invalid input parameter'
        69 = 'More than 5 gateways specified'
        70 = 'Invalid IP address'
        71 = 'Invalid gateway IP address'
        72 = 'An error occurred while accessing the Registry for the…'
        73 = 'Invalid domain name'
        74 = 'Invalid host name'
        75 = 'No primary/secondary WINS server defined'
        76 = 'Invalid file'
        77 = 'Invalid system path'
        78 = 'File copy failed'
        79 = 'Invalid security parameter'
        80 = 'Unable to configure TCP/IP service'
        81 = 'Unable to configure DHCP service'
        82 = 'Unable to renew DHCP lease'
        83 = 'Unable to release DHCP lease'
        84 = 'IP not enabled on adapter'
        85 = 'IPX not enabled on adapter'
        86 = 'Frame/network number bounds error'
        87 = 'Invalid frame type'
        88 = 'Invalid network number'
        89 = 'Duplicate network number'
        90 = 'Parameter out of bounds'
        91 = 'Access denied'
        92 = 'Out of memory'
        93 = 'Already exists'
        94 = 'Path, file or object not found'
        95 = 'Unable to notify service'
        96 = 'Unable to notify DNS service'
        97 = 'Interface not configurable'
        98 = 'Not all DHCP leases could be released/renewed'
        100 = 'DHCP not enabled on adapter'
    }
    $returnValueName[[int]$result.ReturnValue]
}

Cette méthode peut modifier le système. Le paramètre -WhatIf affiche l'opération sans l'exécuter : retirez-le seulement après vérification.

EnableStatic #

Active l'adressage TCP/IP statique pour l'adaptateur réseau cible.

uint32 EnableStatic([in] string[] IPAddress, [in] string[] SubnetMask);

Paramètres

ParamètreTypeSensDescription
IPAddressstring[]entrée

Répertorie toutes les adresses IP statiques de la carte réseau actuelle.

Exemple : 155.34.22.0.

SubnetMaskstring[]entrée

Masques de sous-réseau complémentaires des valeurs du paramètre *IPAddress*.

Exemple : 255.255.0.0.

Codes de retour

ValeurLibelléDescription
0Successful completion, no reboot required
1Successful completion, reboot required
64Method not supported on this platform
65Unknown failure
66Invalid subnet mask
67An error occurred while processing an Instance that was returned
68Invalid input parameter
69More than 5 gateways specifiedPlus de cinq passerelles spécifiées.
70Invalid IP address
71Invalid gateway IP address
72An error occurred while accessing the Registry for the requested information
73Invalid domain name
74Invalid host name
75No primary/secondary WINS server definedAucun serveur WINS principal ou secondaire défini.
76Invalid file
77Invalid system path
78File copy failed
79Invalid security parameter
80Unable to configure TCP/IP service
81Unable to configure DHCP serviceImpossible de configurer le service DHCP. Pour plus d'informations, consultez la section Remarques.
82Unable to renew DHCP lease
83Unable to release DHCP lease
84IP not enabled on adapter
85IPX not enabled on adapter
86Frame/network number bounds errorErreur de limite de trame ou de numéro de réseau.
87Invalid frame type
88Invalid network number
89Duplicate network number
90Parameter out of bounds
91Access denied
92Out of memory
93Already exists
94Path, file or object not foundChemin, fichier ou objet introuvable.
95Unable to notify service
96Unable to notify DNS service
97Interface not configurable
98Not all DHCP leases could be released/renewedTous les baux DHCP n'ont pas pu être libérés ou renouvelés.
100DHCP not enabled on adapter
2147786788Verrou d'écriture non activé. Pour plus d'informations, consultez INetCfgLock::AcquireWriteLock).
101..4294967295Other

Appeler la méthode EnableStatic

à vérifier avant exécution
# Attention : cette méthode peut modifier le système. -WhatIf affiche l'opération sans l'exécuter.
# Instance cible
$instance = Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Filter 'IPEnabled = TRUE'
$methodParameters = @{
    InputObject = $instance
    MethodName  = 'EnableStatic'
    Arguments   = @{
        IPAddress  = @('Example')
        SubnetMask = @('Example')
    }
    WhatIf      = $true  # Retirez cette ligne pour exécuter réellement la méthode
}
$result = Invoke-CimMethod @methodParameters

# Avec -WhatIf, rien n'est exécuté et aucun résultat n'est renvoyé
if ($result) {
    $returnValueName = @{
        0 = 'Successful completion, no reboot required'
        1 = 'Successful completion, reboot required'
        64 = 'Method not supported on this platform'
        65 = 'Unknown failure'
        66 = 'Invalid subnet mask'
        67 = 'An error occurred while processing an Instance that was returned'
        68 = 'Invalid input parameter'
        69 = 'More than 5 gateways specified'
        70 = 'Invalid IP address'
        71 = 'Invalid gateway IP address'
        72 = 'An error occurred while accessing the Registry for the…'
        73 = 'Invalid domain name'
        74 = 'Invalid host name'
        75 = 'No primary/secondary WINS server defined'
        76 = 'Invalid file'
        77 = 'Invalid system path'
        78 = 'File copy failed'
        79 = 'Invalid security parameter'
        80 = 'Unable to configure TCP/IP service'
        81 = 'Unable to configure DHCP service'
        82 = 'Unable to renew DHCP lease'
        83 = 'Unable to release DHCP lease'
        84 = 'IP not enabled on adapter'
        85 = 'IPX not enabled on adapter'
        86 = 'Frame/network number bounds error'
        87 = 'Invalid frame type'
        88 = 'Invalid network number'
        89 = 'Duplicate network number'
        90 = 'Parameter out of bounds'
        91 = 'Access denied'
        92 = 'Out of memory'
        93 = 'Already exists'
        94 = 'Path, file or object not found'
        95 = 'Unable to notify service'
        96 = 'Unable to notify DNS service'
        97 = 'Interface not configurable'
        98 = 'Not all DHCP leases could be released/renewed'
        100 = 'DHCP not enabled on adapter'
        2147786788 = 'Write lock not enabled'
    }
    $returnValueName[[int]$result.ReturnValue]
}

Cette méthode peut modifier le système. Le paramètre -WhatIf affiche l'opération sans l'exécuter : retirez-le seulement après vérification.

EnableWINS statique#

Active les paramètres WINS propres à TCP/IP, mais indépendants de l'adaptateur réseau.

uint32 EnableWINS(
    [in] boolean DNSEnabledForWINSResolution,
    [in] boolean WINSEnableLMHostsLookup,
    [in] string WINSHostLookupFile,
    [in] string WINSScopeID
);

Paramètres

ParamètreTypeSensDescription
DNSEnabledForWINSResolutionbooleanentrée

Si true, le système DNS (Domain Name System) est activé pour la résolution de noms, prioritaire sur la résolution WINS.

WINSEnableLMHostsLookupbooleanentrée

Si true, les fichiers de recherche locaux sont utilisés. Les fichiers de recherche contiennent les mappages des adresses IP aux noms d'hôte.

WINSHostLookupFilestringentrée

Fichiers de recherche qui contiennent les mappages des adresses IP aux noms d'hôte. Si disponibles, les fichiers se trouvent dans %SystemRoot%\system32\drivers\ .

WINSScopeIDstringentrée

Valeur d'identificateur d'étendue ajoutée à la fin du nom NetBIOS de l'ordinateur. Les systèmes qui utilisent le même identificateur d'étendue peuvent communiquer avec cet ordinateur.

Codes de retour

ValeurLibelléDescription
0Successful completion, no reboot required
1Successful completion, reboot required
64Method not supported on this platform
65Unknown failure
66Invalid subnet mask
67An error occurred while processing an Instance that was returned
68Invalid input parameter
69More than 5 gateways specified
70Invalid IP address
71Invalid gateway IP address
72An error occurred while accessing the Registry for the requested information
73Invalid domain name
74Invalid host name
75No primary/secondary WINS server defined
76Invalid file
77Invalid system path
78File copy failed
79Invalid security parameter
80Unable to configure TCP/IP service
81Unable to configure DHCP service
82Unable to renew DHCP lease
83Unable to release DHCP lease
84IP not enabled on adapter
85IPX not enabled on adapter
86Frame/network number bounds error
87Invalid frame type
88Invalid network number
89Duplicate network number
90Parameter out of bounds
91Access denied
92Out of memory
93Already exists
94Path, file or object not found
95Unable to notify service
96Unable to notify DNS service
97Interface not configurable
98Not all DHCP leases could be released/renewed
100DHCP not enabled on adapter
101..4294967295Other

Appeler la méthode EnableWINS

à vérifier avant exécution
# Attention : cette méthode peut modifier le système. -WhatIf affiche l'opération sans l'exécuter.
$methodParameters = @{
    ClassName  = 'Win32_NetworkAdapterConfiguration'
    MethodName = 'EnableWINS'
    Arguments  = @{
        DNSEnabledForWINSResolution = $false
        WINSEnableLMHostsLookup     = $false
        WINSHostLookupFile          = 'Example'
        WINSScopeID                 = 'Example'
    }
    WhatIf     = $true  # Retirez cette ligne pour exécuter réellement la méthode
}
$result = Invoke-CimMethod @methodParameters

# Avec -WhatIf, rien n'est exécuté et aucun résultat n'est renvoyé
if ($result) {
    $returnValueName = @{
        0 = 'Successful completion, no reboot required'
        1 = 'Successful completion, reboot required'
        64 = 'Method not supported on this platform'
        65 = 'Unknown failure'
        66 = 'Invalid subnet mask'
        67 = 'An error occurred while processing an Instance that was returned'
        68 = 'Invalid input parameter'
        69 = 'More than 5 gateways specified'
        70 = 'Invalid IP address'
        71 = 'Invalid gateway IP address'
        72 = 'An error occurred while accessing the Registry for the…'
        73 = 'Invalid domain name'
        74 = 'Invalid host name'
        75 = 'No primary/secondary WINS server defined'
        76 = 'Invalid file'
        77 = 'Invalid system path'
        78 = 'File copy failed'
        79 = 'Invalid security parameter'
        80 = 'Unable to configure TCP/IP service'
        81 = 'Unable to configure DHCP service'
        82 = 'Unable to renew DHCP lease'
        83 = 'Unable to release DHCP lease'
        84 = 'IP not enabled on adapter'
        85 = 'IPX not enabled on adapter'
        86 = 'Frame/network number bounds error'
        87 = 'Invalid frame type'
        88 = 'Invalid network number'
        89 = 'Duplicate network number'
        90 = 'Parameter out of bounds'
        91 = 'Access denied'
        92 = 'Out of memory'
        93 = 'Already exists'
        94 = 'Path, file or object not found'
        95 = 'Unable to notify service'
        96 = 'Unable to notify DNS service'
        97 = 'Interface not configurable'
        98 = 'Not all DHCP leases could be released/renewed'
        100 = 'DHCP not enabled on adapter'
    }
    $returnValueName[[int]$result.ReturnValue]
}

Cette méthode peut modifier le système. Le paramètre -WhatIf affiche l'opération sans l'exécuter : retirez-le seulement après vérification.

ReleaseDHCPLease #

Libère l'adresse IP liée à un adaptateur réseau spécifique compatible DHCP.

uint32 ReleaseDHCPLease();

Codes de retour

ValeurLibelléDescription
0Successful completion, no reboot required
1Successful completion, reboot required
64Method not supported on this platform
65Unknown failure
66Invalid subnet mask
67An error occurred while processing an Instance that was returned
68Invalid input parameter
69More than 5 gateways specifiedPlus de cinq passerelles spécifiées.
70Invalid IP address
71Invalid gateway IP address
72An error occurred while accessing the Registry for the requested information
73Invalid domain name
74Invalid host name
75No primary/secondary WINS server definedAucun serveur WINS principal ou secondaire défini.
76Invalid file
77Invalid system path
78File copy failed
79Invalid security parameter
80Unable to configure TCP/IP service
81Unable to configure DHCP service
82Unable to renew DHCP lease
83Unable to release DHCP lease
84IP not enabled on adapter
85IPX not enabled on adapter
86Frame/network number bounds errorErreur de limite de trame ou de numéro de réseau.
87Invalid frame type
88Invalid network number
89Duplicate network number
90Parameter out of bounds
91Access denied
92Out of memory
93Already exists
94Path, file or object not foundChemin, fichier ou objet introuvable.
95Unable to notify service
96Unable to notify DNS service
97Interface not configurable
98Not all DHCP leases could be released/renewedTous les baux DHCP n'ont pas pu être libérés ou renouvelés.
100DHCP not enabled on adapter
101..4294967295Other

Appeler la méthode ReleaseDHCPLease

à vérifier avant exécution
# Attention : cette méthode peut modifier le système. -WhatIf affiche l'opération sans l'exécuter.
# Instance cible
$instance = Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Filter 'IPEnabled = TRUE'
$methodParameters = @{
    InputObject = $instance
    MethodName  = 'ReleaseDHCPLease'
    WhatIf      = $true  # Retirez cette ligne pour exécuter réellement la méthode
}
$result = Invoke-CimMethod @methodParameters

# Avec -WhatIf, rien n'est exécuté et aucun résultat n'est renvoyé
if ($result) {
    $returnValueName = @{
        0 = 'Successful completion, no reboot required'
        1 = 'Successful completion, reboot required'
        64 = 'Method not supported on this platform'
        65 = 'Unknown failure'
        66 = 'Invalid subnet mask'
        67 = 'An error occurred while processing an Instance that was returned'
        68 = 'Invalid input parameter'
        69 = 'More than 5 gateways specified'
        70 = 'Invalid IP address'
        71 = 'Invalid gateway IP address'
        72 = 'An error occurred while accessing the Registry for the…'
        73 = 'Invalid domain name'
        74 = 'Invalid host name'
        75 = 'No primary/secondary WINS server defined'
        76 = 'Invalid file'
        77 = 'Invalid system path'
        78 = 'File copy failed'
        79 = 'Invalid security parameter'
        80 = 'Unable to configure TCP/IP service'
        81 = 'Unable to configure DHCP service'
        82 = 'Unable to renew DHCP lease'
        83 = 'Unable to release DHCP lease'
        84 = 'IP not enabled on adapter'
        85 = 'IPX not enabled on adapter'
        86 = 'Frame/network number bounds error'
        87 = 'Invalid frame type'
        88 = 'Invalid network number'
        89 = 'Duplicate network number'
        90 = 'Parameter out of bounds'
        91 = 'Access denied'
        92 = 'Out of memory'
        93 = 'Already exists'
        94 = 'Path, file or object not found'
        95 = 'Unable to notify service'
        96 = 'Unable to notify DNS service'
        97 = 'Interface not configurable'
        98 = 'Not all DHCP leases could be released/renewed'
        100 = 'DHCP not enabled on adapter'
    }
    $returnValueName[[int]$result.ReturnValue]
}

Cette méthode peut modifier le système. Le paramètre -WhatIf affiche l'opération sans l'exécuter : retirez-le seulement après vérification.

ReleaseDHCPLeaseAll statique#

Libère les adresses IP liées à tous les adaptateurs réseau compatibles DHCP.

uint32 ReleaseDHCPLeaseAll();

Codes de retour

ValeurLibelléDescription
0Successful completion, no reboot required
1Successful completion, reboot required
64Method not supported on this platform
65Unknown failure
66Invalid subnet mask
67An error occurred while processing an Instance that was returned
68Invalid input parameter
69More than 5 gateways specifiedPlus de cinq passerelles spécifiées.
70Invalid IP address
71Invalid gateway IP address
72An error occurred while accessing the Registry for the requested information
73Invalid domain name
74Invalid host name
75No primary/secondary WINS server definedAucun serveur WINS principal ou secondaire défini.
76Invalid file
77Invalid system path
78File copy failed
79Invalid security parameter
80Unable to configure TCP/IP service
81Unable to configure DHCP service
82Unable to renew DHCP lease
83Unable to release DHCP lease
84IP not enabled on adapter
85IPX not enabled on adapter
86Frame/network number bounds errorErreur de limite de trame ou de numéro de réseau.
87Invalid frame type
88Invalid network number
89Duplicate network number
90Parameter out of bounds
91Access denied
92Out of memory
93Already exists
94Path, file or object not foundChemin, fichier ou objet introuvable.
95Unable to notify service
96Unable to notify DNS service
97Interface not configurable
98Not all DHCP leases could be released/renewedTous les baux DHCP n'ont pas pu être libérés ou renouvelés.
100DHCP not enabled on adapter
101..4294967295Other

Appeler la méthode ReleaseDHCPLeaseAll

à vérifier avant exécution
# Attention : cette méthode peut modifier le système. -WhatIf affiche l'opération sans l'exécuter.
$methodParameters = @{
    ClassName  = 'Win32_NetworkAdapterConfiguration'
    MethodName = 'ReleaseDHCPLeaseAll'
    WhatIf     = $true  # Retirez cette ligne pour exécuter réellement la méthode
}
$result = Invoke-CimMethod @methodParameters

# Avec -WhatIf, rien n'est exécuté et aucun résultat n'est renvoyé
if ($result) {
    $returnValueName = @{
        0 = 'Successful completion, no reboot required'
        1 = 'Successful completion, reboot required'
        64 = 'Method not supported on this platform'
        65 = 'Unknown failure'
        66 = 'Invalid subnet mask'
        67 = 'An error occurred while processing an Instance that was returned'
        68 = 'Invalid input parameter'
        69 = 'More than 5 gateways specified'
        70 = 'Invalid IP address'
        71 = 'Invalid gateway IP address'
        72 = 'An error occurred while accessing the Registry for the…'
        73 = 'Invalid domain name'
        74 = 'Invalid host name'
        75 = 'No primary/secondary WINS server defined'
        76 = 'Invalid file'
        77 = 'Invalid system path'
        78 = 'File copy failed'
        79 = 'Invalid security parameter'
        80 = 'Unable to configure TCP/IP service'
        81 = 'Unable to configure DHCP service'
        82 = 'Unable to renew DHCP lease'
        83 = 'Unable to release DHCP lease'
        84 = 'IP not enabled on adapter'
        85 = 'IPX not enabled on adapter'
        86 = 'Frame/network number bounds error'
        87 = 'Invalid frame type'
        88 = 'Invalid network number'
        89 = 'Duplicate network number'
        90 = 'Parameter out of bounds'
        91 = 'Access denied'
        92 = 'Out of memory'
        93 = 'Already exists'
        94 = 'Path, file or object not found'
        95 = 'Unable to notify service'
        96 = 'Unable to notify DNS service'
        97 = 'Interface not configurable'
        98 = 'Not all DHCP leases could be released/renewed'
        100 = 'DHCP not enabled on adapter'
    }
    $returnValueName[[int]$result.ReturnValue]
}

Cette méthode peut modifier le système. Le paramètre -WhatIf affiche l'opération sans l'exécuter : retirez-le seulement après vérification.

RenewDHCPLease #

Renouvelle l'adresse IP sur certains adaptateurs réseau compatibles DHCP.

uint32 RenewDHCPLease();

Codes de retour

ValeurLibelléDescription
0Successful completion, no reboot required
1Successful completion, reboot required
64Method not supported on this platform
65Unknown failure
66Invalid subnet mask
67An error occurred while processing an Instance that was returned
68Invalid input parameter
69More than 5 gateways specifiedPlus de cinq passerelles spécifiées.
70Invalid IP address
71Invalid gateway IP address
72An error occurred while accessing the Registry for the requested information
73Invalid domain name
74Invalid host name
75No primary/secondary WINS server definedAucun serveur WINS principal ou secondaire défini.
76Invalid file
77Invalid system path
78File copy failed
79Invalid security parameter
80Unable to configure TCP/IP service
81Unable to configure DHCP service
82Unable to renew DHCP lease
83Unable to release DHCP lease
84IP not enabled on adapter
85IPX not enabled on adapter
86Frame/network number bounds errorErreur de limite de trame ou de numéro de réseau.
87Invalid frame type
88Invalid network number
89Duplicate network number
90Parameter out of bounds
91Access denied
92Out of memory
93Already exists
94Path, file or object not foundChemin, fichier ou objet introuvable.
95Unable to notify service
96Unable to notify DNS service
97Interface not configurable
98Not all DHCP leases could be released/renewedTous les baux DHCP n'ont pas pu être libérés ou renouvelés.
100DHCP not enabled on adapter
101..4294967295Other

Appeler la méthode RenewDHCPLease

à vérifier avant exécution
# Attention : cette méthode peut modifier le système. -WhatIf affiche l'opération sans l'exécuter.
# Instance cible
$instance = Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Filter 'IPEnabled = TRUE'
$methodParameters = @{
    InputObject = $instance
    MethodName  = 'RenewDHCPLease'
    WhatIf      = $true  # Retirez cette ligne pour exécuter réellement la méthode
}
$result = Invoke-CimMethod @methodParameters

# Avec -WhatIf, rien n'est exécuté et aucun résultat n'est renvoyé
if ($result) {
    $returnValueName = @{
        0 = 'Successful completion, no reboot required'
        1 = 'Successful completion, reboot required'
        64 = 'Method not supported on this platform'
        65 = 'Unknown failure'
        66 = 'Invalid subnet mask'
        67 = 'An error occurred while processing an Instance that was returned'
        68 = 'Invalid input parameter'
        69 = 'More than 5 gateways specified'
        70 = 'Invalid IP address'
        71 = 'Invalid gateway IP address'
        72 = 'An error occurred while accessing the Registry for the…'
        73 = 'Invalid domain name'
        74 = 'Invalid host name'
        75 = 'No primary/secondary WINS server defined'
        76 = 'Invalid file'
        77 = 'Invalid system path'
        78 = 'File copy failed'
        79 = 'Invalid security parameter'
        80 = 'Unable to configure TCP/IP service'
        81 = 'Unable to configure DHCP service'
        82 = 'Unable to renew DHCP lease'
        83 = 'Unable to release DHCP lease'
        84 = 'IP not enabled on adapter'
        85 = 'IPX not enabled on adapter'
        86 = 'Frame/network number bounds error'
        87 = 'Invalid frame type'
        88 = 'Invalid network number'
        89 = 'Duplicate network number'
        90 = 'Parameter out of bounds'
        91 = 'Access denied'
        92 = 'Out of memory'
        93 = 'Already exists'
        94 = 'Path, file or object not found'
        95 = 'Unable to notify service'
        96 = 'Unable to notify DNS service'
        97 = 'Interface not configurable'
        98 = 'Not all DHCP leases could be released/renewed'
        100 = 'DHCP not enabled on adapter'
    }
    $returnValueName[[int]$result.ReturnValue]
}

Cette méthode peut modifier le système. Le paramètre -WhatIf affiche l'opération sans l'exécuter : retirez-le seulement après vérification.

RenewDHCPLeaseAll statique#

Renouvelle les adresses IP sur tous les adaptateurs réseau compatibles DHCP.

uint32 RenewDHCPLeaseAll();

Codes de retour

ValeurLibelléDescription
0Successful completion, no reboot required
1Successful completion, reboot required
64Method not supported on this platform
65Unknown failure
66Invalid subnet mask
67An error occurred while processing an Instance that was returned
68Invalid input parameter
69More than 5 gateways specifiedPlus de cinq passerelles spécifiées.
70Invalid IP address
71Invalid gateway IP address
72An error occurred while accessing the Registry for the requested information
73Invalid domain name
74Invalid host name
75No primary/secondary WINS server definedAucun serveur WINS principal ou secondaire défini.
76Invalid file
77Invalid system path
78File copy failed
79Invalid security parameter
80Unable to configure TCP/IP service
81Unable to configure DHCP service
82Unable to renew DHCP lease
83Unable to release DHCP lease
84IP not enabled on adapter
85IPX not enabled on adapter
86Frame/network number bounds errorErreur de limite de trame ou de numéro de réseau.
87Invalid frame type
88Invalid network number
89Duplicate network number
90Parameter out of bounds
91Access denied
92Out of memory
93Already exists
94Path, file or object not foundChemin, fichier ou objet introuvable.
95Unable to notify service
96Unable to notify DNS service
97Interface not configurable
98Not all DHCP leases could be released/renewedTous les baux DHCP n'ont pas pu être libérés ou renouvelés.
100DHCP not enabled on adapter
101..4294967295Other

Appeler la méthode RenewDHCPLeaseAll

à vérifier avant exécution
# Attention : cette méthode peut modifier le système. -WhatIf affiche l'opération sans l'exécuter.
$methodParameters = @{
    ClassName  = 'Win32_NetworkAdapterConfiguration'
    MethodName = 'RenewDHCPLeaseAll'
    WhatIf     = $true  # Retirez cette ligne pour exécuter réellement la méthode
}
$result = Invoke-CimMethod @methodParameters

# Avec -WhatIf, rien n'est exécuté et aucun résultat n'est renvoyé
if ($result) {
    $returnValueName = @{
        0 = 'Successful completion, no reboot required'
        1 = 'Successful completion, reboot required'
        64 = 'Method not supported on this platform'
        65 = 'Unknown failure'
        66 = 'Invalid subnet mask'
        67 = 'An error occurred while processing an Instance that was returned'
        68 = 'Invalid input parameter'
        69 = 'More than 5 gateways specified'
        70 = 'Invalid IP address'
        71 = 'Invalid gateway IP address'
        72 = 'An error occurred while accessing the Registry for the…'
        73 = 'Invalid domain name'
        74 = 'Invalid host name'
        75 = 'No primary/secondary WINS server defined'
        76 = 'Invalid file'
        77 = 'Invalid system path'
        78 = 'File copy failed'
        79 = 'Invalid security parameter'
        80 = 'Unable to configure TCP/IP service'
        81 = 'Unable to configure DHCP service'
        82 = 'Unable to renew DHCP lease'
        83 = 'Unable to release DHCP lease'
        84 = 'IP not enabled on adapter'
        85 = 'IPX not enabled on adapter'
        86 = 'Frame/network number bounds error'
        87 = 'Invalid frame type'
        88 = 'Invalid network number'
        89 = 'Duplicate network number'
        90 = 'Parameter out of bounds'
        91 = 'Access denied'
        92 = 'Out of memory'
        93 = 'Already exists'
        94 = 'Path, file or object not found'
        95 = 'Unable to notify service'
        96 = 'Unable to notify DNS service'
        97 = 'Interface not configurable'
        98 = 'Not all DHCP leases could be released/renewed'
        100 = 'DHCP not enabled on adapter'
    }
    $returnValueName[[int]$result.ReturnValue]
}

Cette méthode peut modifier le système. Le paramètre -WhatIf affiche l'opération sans l'exécuter : retirez-le seulement après vérification.

SetArpAlwaysSourceRoute statique#

Définit la transmission des requêtes ARP par TCP/IP.

uint32 SetArpAlwaysSourceRoute([in] boolean ArpAlwaysSourceRoute);

Paramètres

ParamètreTypeSensDescription
ArpAlwaysSourceRoutebooleanentrée

Si true, TCP/IP est contraint de transmettre les requêtes ARP avec le routage source activé sur les réseaux Token Ring. Par défaut, la pile transmet d'abord les requêtes ARP sans routage source, puis effectue une nouvelle tentative avec le routage source activé si aucune réponse n'est reçue.

Codes de retour

ValeurLibelléDescription
0Successful completion, no reboot required
1Successful completion, reboot required
64Method not supported on this platform
65Unknown failure
66Invalid subnet mask
67An error occurred while processing an Instance that was returned
68Invalid input parameter
69More than 5 gateways specifiedPlus de cinq passerelles spécifiées.
70Invalid IP address
71Invalid gateway IP address
72An error occurred while accessing the Registry for the requested information
73Invalid domain name
74Invalid host name
75No primary/secondary WINS server definedAucun serveur WINS principal ou secondaire défini.
76Invalid file
77Invalid system path
78File copy failed
79Invalid security parameter
80Unable to configure TCP/IP service
81Unable to configure DHCP service
82Unable to renew DHCP lease
83Unable to release DHCP lease
84IP not enabled on adapter
85IPX not enabled on adapter
86Frame/network number bounds errorErreur de limite de trame ou de numéro de réseau.
87Invalid frame type
88Invalid network number
89Duplicate network number
90Parameter out of bounds
91Access denied
92Out of memory
93Already exists
94Path, file or object not foundChemin, fichier ou objet introuvable.
95Unable to notify service
96Unable to notify DNS service
97Interface not configurable
98Not all DHCP leases could be released/renewedTous les baux DHCP n'ont pas pu être libérés ou renouvelés.
100DHCP not enabled on adapter
101..4294967295Other

Appeler la méthode SetArpAlwaysSourceRoute

à vérifier avant exécution
# Attention : cette méthode peut modifier le système. -WhatIf affiche l'opération sans l'exécuter.
$methodParameters = @{
    ClassName  = 'Win32_NetworkAdapterConfiguration'
    MethodName = 'SetArpAlwaysSourceRoute'
    Arguments  = @{ ArpAlwaysSourceRoute = $false }
    WhatIf     = $true  # Retirez cette ligne pour exécuter réellement la méthode
}
$result = Invoke-CimMethod @methodParameters

# Avec -WhatIf, rien n'est exécuté et aucun résultat n'est renvoyé
if ($result) {
    $returnValueName = @{
        0 = 'Successful completion, no reboot required'
        1 = 'Successful completion, reboot required'
        64 = 'Method not supported on this platform'
        65 = 'Unknown failure'
        66 = 'Invalid subnet mask'
        67 = 'An error occurred while processing an Instance that was returned'
        68 = 'Invalid input parameter'
        69 = 'More than 5 gateways specified'
        70 = 'Invalid IP address'
        71 = 'Invalid gateway IP address'
        72 = 'An error occurred while accessing the Registry for the…'
        73 = 'Invalid domain name'
        74 = 'Invalid host name'
        75 = 'No primary/secondary WINS server defined'
        76 = 'Invalid file'
        77 = 'Invalid system path'
        78 = 'File copy failed'
        79 = 'Invalid security parameter'
        80 = 'Unable to configure TCP/IP service'
        81 = 'Unable to configure DHCP service'
        82 = 'Unable to renew DHCP lease'
        83 = 'Unable to release DHCP lease'
        84 = 'IP not enabled on adapter'
        85 = 'IPX not enabled on adapter'
        86 = 'Frame/network number bounds error'
        87 = 'Invalid frame type'
        88 = 'Invalid network number'
        89 = 'Duplicate network number'
        90 = 'Parameter out of bounds'
        91 = 'Access denied'
        92 = 'Out of memory'
        93 = 'Already exists'
        94 = 'Path, file or object not found'
        95 = 'Unable to notify service'
        96 = 'Unable to notify DNS service'
        97 = 'Interface not configurable'
        98 = 'Not all DHCP leases could be released/renewed'
        100 = 'DHCP not enabled on adapter'
    }
    $returnValueName[[int]$result.ReturnValue]
}

Cette méthode peut modifier le système. Le paramètre -WhatIf affiche l'opération sans l'exécuter : retirez-le seulement après vérification.

SetArpUseEtherSNAP statique#

Active l'encodage SNAP 802.3 pour les paquets Ethernet.

uint32 SetArpUseEtherSNAP([in] boolean ArpUseEtherSNAP);

Paramètres

ParamètreTypeSensDescription
ArpUseEtherSNAPbooleanentrée

Si true, TCP/IP active la transmission de paquets Ethernet à l'aide de l'encodage 802.3 SNAP.

Codes de retour

ValeurLibelléDescription
0Successful completion, no reboot required
1Successful completion, reboot required
64Method not supported on this platform
65Unknown failure
66Invalid subnet mask
67An error occurred while processing an Instance that was returned
68Invalid input parameter
69More than 5 gateways specifiedPlus de cinq passerelles spécifiées.
70Invalid IP address
71Invalid gateway IP address
72An error occurred while accessing the Registry for the requested information
73Invalid domain name
74Invalid host name
75No primary/secondary WINS server definedAucun serveur WINS principal ou secondaire défini.
76Invalid file
77Invalid system path
78File copy failed
79Invalid security parameter
80Unable to configure TCP/IP service
81Unable to configure DHCP service
82Unable to renew DHCP lease
83Unable to release DHCP lease
84IP not enabled on adapter
85IPX not enabled on adapter
86Frame/network number bounds errorErreur de limite de trame ou de numéro de réseau.
87Invalid frame type
88Invalid network number
89Duplicate network number
90Parameter out of bounds
91Access denied
92Out of memory
93Already exists
94Path, file or object not foundChemin, fichier ou objet introuvable.
95Unable to notify service
96Unable to notify DNS service
97Interface not configurable
98Not all DHCP leases could be released/renewedTous les baux DHCP n'ont pas pu être libérés ou renouvelés.
100DHCP not enabled on adapter
101..4294967295Other

Appeler la méthode SetArpUseEtherSNAP

à vérifier avant exécution
# Attention : cette méthode peut modifier le système. -WhatIf affiche l'opération sans l'exécuter.
$methodParameters = @{
    ClassName  = 'Win32_NetworkAdapterConfiguration'
    MethodName = 'SetArpUseEtherSNAP'
    Arguments  = @{ ArpUseEtherSNAP = $false }
    WhatIf     = $true  # Retirez cette ligne pour exécuter réellement la méthode
}
$result = Invoke-CimMethod @methodParameters

# Avec -WhatIf, rien n'est exécuté et aucun résultat n'est renvoyé
if ($result) {
    $returnValueName = @{
        0 = 'Successful completion, no reboot required'
        1 = 'Successful completion, reboot required'
        64 = 'Method not supported on this platform'
        65 = 'Unknown failure'
        66 = 'Invalid subnet mask'
        67 = 'An error occurred while processing an Instance that was returned'
        68 = 'Invalid input parameter'
        69 = 'More than 5 gateways specified'
        70 = 'Invalid IP address'
        71 = 'Invalid gateway IP address'
        72 = 'An error occurred while accessing the Registry for the…'
        73 = 'Invalid domain name'
        74 = 'Invalid host name'
        75 = 'No primary/secondary WINS server defined'
        76 = 'Invalid file'
        77 = 'Invalid system path'
        78 = 'File copy failed'
        79 = 'Invalid security parameter'
        80 = 'Unable to configure TCP/IP service'
        81 = 'Unable to configure DHCP service'
        82 = 'Unable to renew DHCP lease'
        83 = 'Unable to release DHCP lease'
        84 = 'IP not enabled on adapter'
        85 = 'IPX not enabled on adapter'
        86 = 'Frame/network number bounds error'
        87 = 'Invalid frame type'
        88 = 'Invalid network number'
        89 = 'Duplicate network number'
        90 = 'Parameter out of bounds'
        91 = 'Access denied'
        92 = 'Out of memory'
        93 = 'Already exists'
        94 = 'Path, file or object not found'
        95 = 'Unable to notify service'
        96 = 'Unable to notify DNS service'
        97 = 'Interface not configurable'
        98 = 'Not all DHCP leases could be released/renewed'
        100 = 'DHCP not enabled on adapter'
    }
    $returnValueName[[int]$result.ReturnValue]
}

Cette méthode peut modifier le système. Le paramètre -WhatIf affiche l'opération sans l'exécuter : retirez-le seulement après vérification.

SetDatabasePath statique#

Définit le chemin d'accès aux fichiers de base de données Internet standard (HOSTS, LMHOSTS, NETWORKS et PROTOCOLS).

uint32 SetDatabasePath([in] string DatabasePath);

Paramètres

ParamètreTypeSensDescription
DatabasePathstringentrée

Chemin de fichier valide vers les fichiers de base de données Internet standard (HOSTS, LMHOSTS, NETWORKS et PROTOCOLS) utilisés par l'interface Windows Sockets.

Codes de retour

ValeurLibelléDescription
0Successful completion, no reboot required
1Successful completion, reboot required
64Method not supported on this platform
65Unknown failure
66Invalid subnet mask
67An error occurred while processing an Instance that was returned
68Invalid input parameter
69More than 5 gateways specifiedPlus de cinq passerelles spécifiées.
70Invalid IP address
71Invalid gateway IP address
72An error occurred while accessing the Registry for the requested information
73Invalid domain name
74Invalid host name
75No primary/secondary WINS server definedAucun serveur WINS principal ou secondaire défini.
76Invalid file
77Invalid system path
78File copy failed
79Invalid security parameter
80Unable to configure TCP/IP service
81Unable to configure DHCP service
82Unable to renew DHCP lease
83Unable to release DHCP lease
84IP not enabled on adapter
85IPX not enabled on adapter
86Frame/network number bounds errorErreur de limite de trame ou de numéro de réseau.
87Invalid frame type
88Invalid network number
89Duplicate network number
90Parameter out of bounds
91Access denied
92Out of memory
93Already exists
94Path, file or object not foundChemin, fichier ou objet introuvable.
95Unable to notify service
96Unable to notify DNS service
97Interface not configurable
98Not all DHCP leases could be released/renewedTous les baux DHCP n'ont pas pu être libérés ou renouvelés.
100DHCP not enabled on adapter
101..4294967295Other

Appeler la méthode SetDatabasePath

à vérifier avant exécution
# Attention : cette méthode peut modifier le système. -WhatIf affiche l'opération sans l'exécuter.
$methodParameters = @{
    ClassName  = 'Win32_NetworkAdapterConfiguration'
    MethodName = 'SetDatabasePath'
    Arguments  = @{ DatabasePath = 'Example' }
    WhatIf     = $true  # Retirez cette ligne pour exécuter réellement la méthode
}
$result = Invoke-CimMethod @methodParameters

# Avec -WhatIf, rien n'est exécuté et aucun résultat n'est renvoyé
if ($result) {
    $returnValueName = @{
        0 = 'Successful completion, no reboot required'
        1 = 'Successful completion, reboot required'
        64 = 'Method not supported on this platform'
        65 = 'Unknown failure'
        66 = 'Invalid subnet mask'
        67 = 'An error occurred while processing an Instance that was returned'
        68 = 'Invalid input parameter'
        69 = 'More than 5 gateways specified'
        70 = 'Invalid IP address'
        71 = 'Invalid gateway IP address'
        72 = 'An error occurred while accessing the Registry for the…'
        73 = 'Invalid domain name'
        74 = 'Invalid host name'
        75 = 'No primary/secondary WINS server defined'
        76 = 'Invalid file'
        77 = 'Invalid system path'
        78 = 'File copy failed'
        79 = 'Invalid security parameter'
        80 = 'Unable to configure TCP/IP service'
        81 = 'Unable to configure DHCP service'
        82 = 'Unable to renew DHCP lease'
        83 = 'Unable to release DHCP lease'
        84 = 'IP not enabled on adapter'
        85 = 'IPX not enabled on adapter'
        86 = 'Frame/network number bounds error'
        87 = 'Invalid frame type'
        88 = 'Invalid network number'
        89 = 'Duplicate network number'
        90 = 'Parameter out of bounds'
        91 = 'Access denied'
        92 = 'Out of memory'
        93 = 'Already exists'
        94 = 'Path, file or object not found'
        95 = 'Unable to notify service'
        96 = 'Unable to notify DNS service'
        97 = 'Interface not configurable'
        98 = 'Not all DHCP leases could be released/renewed'
        100 = 'DHCP not enabled on adapter'
    }
    $returnValueName[[int]$result.ReturnValue]
}

Cette méthode peut modifier le système. Le paramètre -WhatIf affiche l'opération sans l'exécuter : retirez-le seulement après vérification.

SetDeadGWDetect statique#

Active la détection de passerelle inactive.

uint32 SetDeadGWDetect([in] boolean DeadGWDetectEnabled);

Paramètres

ParamètreTypeSensDescription
DeadGWDetectEnabledbooleanentrée

Si true, la détection de passerelle défaillante doit être activée.

Codes de retour

ValeurLibelléDescription
0Successful completion, no reboot required
1Successful completion, reboot required
64Method not supported on this platform
65Unknown failure
66Invalid subnet mask
67An error occurred while processing an Instance that was returned
68Invalid input parameter
69More than 5 gateways specifiedPlus de cinq passerelles spécifiées.
70Invalid IP address
71Invalid gateway IP address
72An error occurred while accessing the Registry for the requested information
73Invalid domain name
74Invalid host name
75No primary/secondary WINS server definedAucun serveur WINS principal ou secondaire défini.
76Invalid file
77Invalid system path
78File copy failed
79Invalid security parameter
80Unable to configure TCP/IP service
81Unable to configure DHCP service
82Unable to renew DHCP lease
83Unable to release DHCP lease
84IP not enabled on adapter
85IPX not enabled on adapter
86Frame/network number bounds errorErreur de limite de trame ou de numéro de réseau.
87Invalid frame type
88Invalid network number
89Duplicate network number
90Parameter out of bounds
91Access denied
92Out of memory
93Already exists
94Path, file or object not foundChemin, fichier ou objet introuvable.
95Unable to notify service
96Unable to notify DNS service
97Interface not configurable
98Not all DHCP leases could be released/renewedTous les baux DHCP n'ont pas pu être libérés ou renouvelés.
100DHCP not enabled on adapter
101..4294967295Other

Appeler la méthode SetDeadGWDetect

à vérifier avant exécution
# Attention : cette méthode peut modifier le système. -WhatIf affiche l'opération sans l'exécuter.
$methodParameters = @{
    ClassName  = 'Win32_NetworkAdapterConfiguration'
    MethodName = 'SetDeadGWDetect'
    Arguments  = @{ DeadGWDetectEnabled = $false }
    WhatIf     = $true  # Retirez cette ligne pour exécuter réellement la méthode
}
$result = Invoke-CimMethod @methodParameters

# Avec -WhatIf, rien n'est exécuté et aucun résultat n'est renvoyé
if ($result) {
    $returnValueName = @{
        0 = 'Successful completion, no reboot required'
        1 = 'Successful completion, reboot required'
        64 = 'Method not supported on this platform'
        65 = 'Unknown failure'
        66 = 'Invalid subnet mask'
        67 = 'An error occurred while processing an Instance that was returned'
        68 = 'Invalid input parameter'
        69 = 'More than 5 gateways specified'
        70 = 'Invalid IP address'
        71 = 'Invalid gateway IP address'
        72 = 'An error occurred while accessing the Registry for the…'
        73 = 'Invalid domain name'
        74 = 'Invalid host name'
        75 = 'No primary/secondary WINS server defined'
        76 = 'Invalid file'
        77 = 'Invalid system path'
        78 = 'File copy failed'
        79 = 'Invalid security parameter'
        80 = 'Unable to configure TCP/IP service'
        81 = 'Unable to configure DHCP service'
        82 = 'Unable to renew DHCP lease'
        83 = 'Unable to release DHCP lease'
        84 = 'IP not enabled on adapter'
        85 = 'IPX not enabled on adapter'
        86 = 'Frame/network number bounds error'
        87 = 'Invalid frame type'
        88 = 'Invalid network number'
        89 = 'Duplicate network number'
        90 = 'Parameter out of bounds'
        91 = 'Access denied'
        92 = 'Out of memory'
        93 = 'Already exists'
        94 = 'Path, file or object not found'
        95 = 'Unable to notify service'
        96 = 'Unable to notify DNS service'
        97 = 'Interface not configurable'
        98 = 'Not all DHCP leases could be released/renewed'
        100 = 'DHCP not enabled on adapter'
    }
    $returnValueName[[int]$result.ReturnValue]
}

Cette méthode peut modifier le système. Le paramètre -WhatIf affiche l'opération sans l'exécuter : retirez-le seulement après vérification.

SetDefaultTOS statique#

Obsolète. Cette méthode définit la valeur par défaut du type de service (TOS) dans l'en-tête des paquets IP sortants.

uint32 SetDefaultTOS([in] uint8 DefaultTOS);

Paramètres

ParamètreTypeSensDescription
DefaultTOSuint8entrée

Valeur de type de service (TOS) placée dans l'en-tête des paquets IP sortants. Pour la définition des valeurs, consultez RFC 791.

Codes de retour

ValeurLibelléDescription
0Successful completion, no reboot required
1Successful completion, reboot required
64Method not supported on this platform
65Unknown failure
66Invalid subnet mask
67An error occurred while processing an Instance that was returned
68Invalid input parameter
69More than 5 gateways specifiedPlus de cinq passerelles spécifiées.
70Invalid IP address
71Invalid gateway IP address
72An error occurred while accessing the Registry for the requested information
73Invalid domain name
74Invalid host name
75No primary/secondary WINS server definedAucun serveur WINS principal ou secondaire défini.
76Invalid file
77Invalid system path
78File copy failed
79Invalid security parameter
80Unable to configure TCP/IP service
81Unable to configure DHCP service
82Unable to renew DHCP lease
83Unable to release DHCP lease
84IP not enabled on adapter
85IPX not enabled on adapter
86Frame/network number bounds errorErreur de limite de trame ou de numéro de réseau.
87Invalid frame type
88Invalid network number
89Duplicate network number
90Parameter out of bounds
91Access denied
92Out of memory
93Already exists
94Path, file or object not foundChemin, fichier ou objet introuvable.
95Unable to notify service
96Unable to notify DNS service
97Interface not configurable
98Not all DHCP leases could be released/renewedTous les baux DHCP n'ont pas pu être libérés ou renouvelés.
100DHCP not enabled on adapter
101..4294967295Other

Appeler la méthode SetDefaultTOS

à vérifier avant exécution
# Attention : cette méthode peut modifier le système. -WhatIf affiche l'opération sans l'exécuter.
$methodParameters = @{
    ClassName  = 'Win32_NetworkAdapterConfiguration'
    MethodName = 'SetDefaultTOS'
    Arguments  = @{ DefaultTOS = 0 }
    WhatIf     = $true  # Retirez cette ligne pour exécuter réellement la méthode
}
$result = Invoke-CimMethod @methodParameters

# Avec -WhatIf, rien n'est exécuté et aucun résultat n'est renvoyé
if ($result) {
    $returnValueName = @{
        0 = 'Successful completion, no reboot required'
        1 = 'Successful completion, reboot required'
        64 = 'Method not supported on this platform'
        65 = 'Unknown failure'
        66 = 'Invalid subnet mask'
        67 = 'An error occurred while processing an Instance that was returned'
        68 = 'Invalid input parameter'
        69 = 'More than 5 gateways specified'
        70 = 'Invalid IP address'
        71 = 'Invalid gateway IP address'
        72 = 'An error occurred while accessing the Registry for the…'
        73 = 'Invalid domain name'
        74 = 'Invalid host name'
        75 = 'No primary/secondary WINS server defined'
        76 = 'Invalid file'
        77 = 'Invalid system path'
        78 = 'File copy failed'
        79 = 'Invalid security parameter'
        80 = 'Unable to configure TCP/IP service'
        81 = 'Unable to configure DHCP service'
        82 = 'Unable to renew DHCP lease'
        83 = 'Unable to release DHCP lease'
        84 = 'IP not enabled on adapter'
        85 = 'IPX not enabled on adapter'
        86 = 'Frame/network number bounds error'
        87 = 'Invalid frame type'
        88 = 'Invalid network number'
        89 = 'Duplicate network number'
        90 = 'Parameter out of bounds'
        91 = 'Access denied'
        92 = 'Out of memory'
        93 = 'Already exists'
        94 = 'Path, file or object not found'
        95 = 'Unable to notify service'
        96 = 'Unable to notify DNS service'
        97 = 'Interface not configurable'
        98 = 'Not all DHCP leases could be released/renewed'
        100 = 'DHCP not enabled on adapter'
    }
    $returnValueName[[int]$result.ReturnValue]
}

Cette méthode peut modifier le système. Le paramètre -WhatIf affiche l'opération sans l'exécuter : retirez-le seulement après vérification.

SetDefaultTTL statique#

Définit la valeur TTL (Time to Live) par défaut dans l'en-tête des paquets IP sortants.

uint32 SetDefaultTTL([in] uint8 DefaultTTL);

Paramètres

ParamètreTypeSensDescription
DefaultTTLuint8entrée

Valeur de durée de vie (TTL) définie dans l'en-tête des paquets IP sortants. La valeur par défaut est 32. Plage valide : 1 - 255

Codes de retour

ValeurLibelléDescription
0Successful completion, no reboot required
1Successful completion, reboot required
64Method not supported on this platform
65Unknown failure
66Invalid subnet mask
67An error occurred while processing an Instance that was returned
68Invalid input parameter
69More than 5 gateways specifiedPlus de cinq passerelles spécifiées.
70Invalid IP address
71Invalid gateway IP address
72An error occurred while accessing the Registry for the requested information
73Invalid domain name
74Invalid host name
75No primary/secondary WINS server definedAucun serveur WINS principal ou secondaire défini.
76Invalid file
77Invalid system path
78File copy failed
79Invalid security parameter
80Unable to configure TCP/IP service
81Unable to configure DHCP service
82Unable to renew DHCP lease
83Unable to release DHCP lease
84IP not enabled on adapter
85IPX not enabled on adapter
86Frame/network number bounds errorErreur de limite de trame ou de numéro de réseau.
87Invalid frame type
88Invalid network number
89Duplicate network number
90Parameter out of bounds
91Access denied
92Out of memory
93Already exists
94Path, file or object not foundChemin, fichier ou objet introuvable.
95Unable to notify service
96Unable to notify DNS service
97Interface not configurable
98Not all DHCP leases could be released/renewedTous les baux DHCP n'ont pas pu être libérés ou renouvelés.
100DHCP not enabled on adapter
101..4294967295Other

Appeler la méthode SetDefaultTTL

à vérifier avant exécution
# Attention : cette méthode peut modifier le système. -WhatIf affiche l'opération sans l'exécuter.
$methodParameters = @{
    ClassName  = 'Win32_NetworkAdapterConfiguration'
    MethodName = 'SetDefaultTTL'
    Arguments  = @{ DefaultTTL = 0 }
    WhatIf     = $true  # Retirez cette ligne pour exécuter réellement la méthode
}
$result = Invoke-CimMethod @methodParameters

# Avec -WhatIf, rien n'est exécuté et aucun résultat n'est renvoyé
if ($result) {
    $returnValueName = @{
        0 = 'Successful completion, no reboot required'
        1 = 'Successful completion, reboot required'
        64 = 'Method not supported on this platform'
        65 = 'Unknown failure'
        66 = 'Invalid subnet mask'
        67 = 'An error occurred while processing an Instance that was returned'
        68 = 'Invalid input parameter'
        69 = 'More than 5 gateways specified'
        70 = 'Invalid IP address'
        71 = 'Invalid gateway IP address'
        72 = 'An error occurred while accessing the Registry for the…'
        73 = 'Invalid domain name'
        74 = 'Invalid host name'
        75 = 'No primary/secondary WINS server defined'
        76 = 'Invalid file'
        77 = 'Invalid system path'
        78 = 'File copy failed'
        79 = 'Invalid security parameter'
        80 = 'Unable to configure TCP/IP service'
        81 = 'Unable to configure DHCP service'
        82 = 'Unable to renew DHCP lease'
        83 = 'Unable to release DHCP lease'
        84 = 'IP not enabled on adapter'
        85 = 'IPX not enabled on adapter'
        86 = 'Frame/network number bounds error'
        87 = 'Invalid frame type'
        88 = 'Invalid network number'
        89 = 'Duplicate network number'
        90 = 'Parameter out of bounds'
        91 = 'Access denied'
        92 = 'Out of memory'
        93 = 'Already exists'
        94 = 'Path, file or object not found'
        95 = 'Unable to notify service'
        96 = 'Unable to notify DNS service'
        97 = 'Interface not configurable'
        98 = 'Not all DHCP leases could be released/renewed'
        100 = 'DHCP not enabled on adapter'
    }
    $returnValueName[[int]$result.ReturnValue]
}

Cette méthode peut modifier le système. Le paramètre -WhatIf affiche l'opération sans l'exécuter : retirez-le seulement après vérification.

SetDNSDomain #

Définit le domaine DNS.

uint32 SetDNSDomain([in] string DNSDomain);

Paramètres

ParamètreTypeSensDescription
DNSDomainstringentrée

Domaine auquel le DNS est associé, représenté par un nom d'organisation suivi d'un point et d'une extension indiquant le type d'organisation.

Exemple : "microsoft.com"

Codes de retour

ValeurLibelléDescription
0Successful completion, no reboot required
1Successful completion, reboot required
64Method not supported on this platform
65Unknown failure
66Invalid subnet mask
67An error occurred while processing an Instance that was returned
68Invalid input parameter
69More than 5 gateways specifiedPlus de cinq passerelles spécifiées.
70Invalid IP address
71Invalid gateway IP address
72An error occurred while accessing the Registry for the requested information
73Invalid domain name
74Invalid host name
75No primary/secondary WINS server definedAucun serveur WINS principal ou secondaire défini.
76Invalid file
77Invalid system path
78File copy failed
79Invalid security parameter
80Unable to configure TCP/IP service
81Unable to configure DHCP service
82Unable to renew DHCP lease
83Unable to release DHCP lease
84IP not enabled on adapter
85IPX not enabled on adapter
86Frame/network number bounds errorErreur de limite de trame ou de numéro de réseau.
87Invalid frame type
88Invalid network number
89Duplicate network number
90Parameter out of bounds
91Access denied
92Out of memory
93Already exists
94Path, file or object not foundChemin, fichier ou objet introuvable.
95Unable to notify service
96Unable to notify DNS service
97Interface not configurable
98Not all DHCP leases could be released/renewedTous les baux DHCP ne peuvent pas être libérés ou renouvelés.
100DHCP not enabled on adapter
101..4294967295Other

Appeler la méthode SetDNSDomain

à vérifier avant exécution
# Attention : cette méthode peut modifier le système. -WhatIf affiche l'opération sans l'exécuter.
# Instance cible
$instance = Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Filter 'IPEnabled = TRUE'
$methodParameters = @{
    InputObject = $instance
    MethodName  = 'SetDNSDomain'
    Arguments   = @{ DNSDomain = 'Example' }
    WhatIf      = $true  # Retirez cette ligne pour exécuter réellement la méthode
}
$result = Invoke-CimMethod @methodParameters

# Avec -WhatIf, rien n'est exécuté et aucun résultat n'est renvoyé
if ($result) {
    $returnValueName = @{
        0 = 'Successful completion, no reboot required'
        1 = 'Successful completion, reboot required'
        64 = 'Method not supported on this platform'
        65 = 'Unknown failure'
        66 = 'Invalid subnet mask'
        67 = 'An error occurred while processing an Instance that was returned'
        68 = 'Invalid input parameter'
        69 = 'More than 5 gateways specified'
        70 = 'Invalid IP address'
        71 = 'Invalid gateway IP address'
        72 = 'An error occurred while accessing the Registry for the…'
        73 = 'Invalid domain name'
        74 = 'Invalid host name'
        75 = 'No primary/secondary WINS server defined'
        76 = 'Invalid file'
        77 = 'Invalid system path'
        78 = 'File copy failed'
        79 = 'Invalid security parameter'
        80 = 'Unable to configure TCP/IP service'
        81 = 'Unable to configure DHCP service'
        82 = 'Unable to renew DHCP lease'
        83 = 'Unable to release DHCP lease'
        84 = 'IP not enabled on adapter'
        85 = 'IPX not enabled on adapter'
        86 = 'Frame/network number bounds error'
        87 = 'Invalid frame type'
        88 = 'Invalid network number'
        89 = 'Duplicate network number'
        90 = 'Parameter out of bounds'
        91 = 'Access denied'
        92 = 'Out of memory'
        93 = 'Already exists'
        94 = 'Path, file or object not found'
        95 = 'Unable to notify service'
        96 = 'Unable to notify DNS service'
        97 = 'Interface not configurable'
        98 = 'Not all DHCP leases could be released/renewed'
        100 = 'DHCP not enabled on adapter'
    }
    $returnValueName[[int]$result.ReturnValue]
}

Cette méthode peut modifier le système. Le paramètre -WhatIf affiche l'opération sans l'exécuter : retirez-le seulement après vérification.

SetDNSServerSearchOrder #

Définit l'ordre de recherche des serveurs sous forme de tableau d'éléments.

uint32 SetDNSServerSearchOrder([in] string[] DNSServerSearchOrder);

Paramètres

ParamètreTypeSensDescription
DNSServerSearchOrderstring[]entrée

Liste des adresses IP de serveurs à interroger pour les serveurs DNS.

Exemple : 130.215.24.1 ou 157.54.164.1

Codes de retour

ValeurLibelléDescription
0Successful completion, no reboot required
1Successful completion, reboot required
64Method not supported on this platform
65Unknown failure
66Invalid subnet mask
67An error occurred while processing an Instance that was returned
68Invalid input parameter
69More than 5 gateways specified
70Invalid IP address
71Invalid gateway IP address
72An error occurred while accessing the Registry for the requested information
73Invalid domain name
74Invalid host name
75No primary/secondary WINS server defined
76Invalid file
77Invalid system path
78File copy failed
79Invalid security parameter
80Unable to configure TCP/IP service
81Unable to configure DHCP service
82Unable to renew DHCP lease
83Unable to release DHCP lease
84IP not enabled on adapter
85IPX not enabled on adapter
86Frame/network number bounds error
87Invalid frame type
88Invalid network number
89Duplicate network number
90Parameter out of bounds
91Access denied
92Out of memory
93Already exists
94Path, file or object not found
95Unable to notify service
96Unable to notify DNS service
97Interface not configurable
98Not all DHCP leases could be released/renewed
100DHCP not enabled on adapter
101..4294967295Other

Appeler la méthode SetDNSServerSearchOrder

à vérifier avant exécution
# Attention : cette méthode peut modifier le système. -WhatIf affiche l'opération sans l'exécuter.
# Instance cible
$instance = Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Filter 'IPEnabled = TRUE'
$methodParameters = @{
    InputObject = $instance
    MethodName  = 'SetDNSServerSearchOrder'
    Arguments   = @{ DNSServerSearchOrder = @('Example') }
    WhatIf      = $true  # Retirez cette ligne pour exécuter réellement la méthode
}
$result = Invoke-CimMethod @methodParameters

# Avec -WhatIf, rien n'est exécuté et aucun résultat n'est renvoyé
if ($result) {
    $returnValueName = @{
        0 = 'Successful completion, no reboot required'
        1 = 'Successful completion, reboot required'
        64 = 'Method not supported on this platform'
        65 = 'Unknown failure'
        66 = 'Invalid subnet mask'
        67 = 'An error occurred while processing an Instance that was returned'
        68 = 'Invalid input parameter'
        69 = 'More than 5 gateways specified'
        70 = 'Invalid IP address'
        71 = 'Invalid gateway IP address'
        72 = 'An error occurred while accessing the Registry for the…'
        73 = 'Invalid domain name'
        74 = 'Invalid host name'
        75 = 'No primary/secondary WINS server defined'
        76 = 'Invalid file'
        77 = 'Invalid system path'
        78 = 'File copy failed'
        79 = 'Invalid security parameter'
        80 = 'Unable to configure TCP/IP service'
        81 = 'Unable to configure DHCP service'
        82 = 'Unable to renew DHCP lease'
        83 = 'Unable to release DHCP lease'
        84 = 'IP not enabled on adapter'
        85 = 'IPX not enabled on adapter'
        86 = 'Frame/network number bounds error'
        87 = 'Invalid frame type'
        88 = 'Invalid network number'
        89 = 'Duplicate network number'
        90 = 'Parameter out of bounds'
        91 = 'Access denied'
        92 = 'Out of memory'
        93 = 'Already exists'
        94 = 'Path, file or object not found'
        95 = 'Unable to notify service'
        96 = 'Unable to notify DNS service'
        97 = 'Interface not configurable'
        98 = 'Not all DHCP leases could be released/renewed'
        100 = 'DHCP not enabled on adapter'
    }
    $returnValueName[[int]$result.ReturnValue]
}

Cette méthode peut modifier le système. Le paramètre -WhatIf affiche l'opération sans l'exécuter : retirez-le seulement après vérification.

SetDNSSuffixSearchOrder statique#

Définit l'ordre de recherche des suffixes sous forme de tableau d'éléments.

uint32 SetDNSSuffixSearchOrder([in] string[] DNSDomainSuffixSearchOrder);

Paramètres

ParamètreTypeSensDescription
DNSDomainSuffixSearchOrderstring[]entrée

Liste des suffixes de serveur à interroger pour les serveurs DNS. L'emplacement du suffixe DNS dans le Registre est HKEY_LOCAL_MACHINE\System\CurrentControlSet\Services\Tcpip|NameServer

Exemple : "suffix1.company.com", "suffix2.company.com"

Codes de retour

ValeurLibelléDescription
0Successful completion, no reboot required
1Successful completion, reboot required
64Method not supported on this platform
65Unknown failure
66Invalid subnet mask
67An error occurred while processing an Instance that was returned
68Invalid input parameter
69More than 5 gateways specifiedPlus de cinq passerelles spécifiées.
70Invalid IP address
71Invalid gateway IP address
72An error occurred while accessing the Registry for the requested information
73Invalid domain name
74Invalid host name
75No primary/secondary WINS server definedAucun serveur WINS principal ou secondaire défini.
76Invalid file
77Invalid system path
78File copy failed
79Invalid security parameter
80Unable to configure TCP/IP service
81Unable to configure DHCP service
82Unable to renew DHCP lease
83Unable to release DHCP lease
84IP not enabled on adapter
85IPX not enabled on adapter
86Frame/network number bounds errorErreur de limite de trame ou de numéro de réseau.
87Invalid frame type
88Invalid network number
89Duplicate network number
90Parameter out of bounds
91Access denied
92Out of memory
93Already exists
94Path, file or object not foundChemin, fichier ou objet introuvable.
95Unable to notify service
96Unable to notify DNS service
97Interface not configurable
98Not all DHCP leases could be released/renewedTous les baux DHCP ne sont pas libérés ni renouvelés.
100DHCP not enabled on adapter
101..4294967295Other

Appeler la méthode SetDNSSuffixSearchOrder

à vérifier avant exécution
# Attention : cette méthode peut modifier le système. -WhatIf affiche l'opération sans l'exécuter.
$methodParameters = @{
    ClassName  = 'Win32_NetworkAdapterConfiguration'
    MethodName = 'SetDNSSuffixSearchOrder'
    Arguments  = @{ DNSDomainSuffixSearchOrder = @('Example') }
    WhatIf     = $true  # Retirez cette ligne pour exécuter réellement la méthode
}
$result = Invoke-CimMethod @methodParameters

# Avec -WhatIf, rien n'est exécuté et aucun résultat n'est renvoyé
if ($result) {
    $returnValueName = @{
        0 = 'Successful completion, no reboot required'
        1 = 'Successful completion, reboot required'
        64 = 'Method not supported on this platform'
        65 = 'Unknown failure'
        66 = 'Invalid subnet mask'
        67 = 'An error occurred while processing an Instance that was returned'
        68 = 'Invalid input parameter'
        69 = 'More than 5 gateways specified'
        70 = 'Invalid IP address'
        71 = 'Invalid gateway IP address'
        72 = 'An error occurred while accessing the Registry for the…'
        73 = 'Invalid domain name'
        74 = 'Invalid host name'
        75 = 'No primary/secondary WINS server defined'
        76 = 'Invalid file'
        77 = 'Invalid system path'
        78 = 'File copy failed'
        79 = 'Invalid security parameter'
        80 = 'Unable to configure TCP/IP service'
        81 = 'Unable to configure DHCP service'
        82 = 'Unable to renew DHCP lease'
        83 = 'Unable to release DHCP lease'
        84 = 'IP not enabled on adapter'
        85 = 'IPX not enabled on adapter'
        86 = 'Frame/network number bounds error'
        87 = 'Invalid frame type'
        88 = 'Invalid network number'
        89 = 'Duplicate network number'
        90 = 'Parameter out of bounds'
        91 = 'Access denied'
        92 = 'Out of memory'
        93 = 'Already exists'
        94 = 'Path, file or object not found'
        95 = 'Unable to notify service'
        96 = 'Unable to notify DNS service'
        97 = 'Interface not configurable'
        98 = 'Not all DHCP leases could be released/renewed'
        100 = 'DHCP not enabled on adapter'
    }
    $returnValueName[[int]$result.ReturnValue]
}

Cette méthode peut modifier le système. Le paramètre -WhatIf affiche l'opération sans l'exécuter : retirez-le seulement après vérification.

SetDynamicDNSRegistration #

Indique l'inscription dynamique DNS des adresses IP pour cet adaptateur lié à IP.

uint32 SetDynamicDNSRegistration([in] boolean FullDNSRegistrationEnabled, [in] boolean DomainDNSRegistrationEnabled);

Paramètres

ParamètreTypeSensDescription
FullDNSRegistrationEnabledbooleanentrée

Si true, les adresses IP de cette connexion sont enregistrées dans le DNS sous le nom DNS complet de l'ordinateur. Le nom DNS complet de l'ordinateur s'affiche sous l'onglet Identification réseau du Panneau de configuration système.

DomainDNSRegistrationEnabledbooleanentrée

Si true, les adresses IP de cette connexion sont enregistrées sous le nom de domaine de cette connexion, en plus d'être enregistrées sous le nom DNS complet de l'ordinateur. Le nom de domaine de cette connexion est défini à l'aide de la méthode SetDNSDomain ou attribué par DHCP. Le nom enregistré est le nom d'hôte de l'ordinateur auquel le nom de domaine est ajouté. Ce paramètre n'a de sens que lorsque *FullDNSRegistrationEnabled* est activé. La valeur par défaut est false.

Codes de retour

ValeurLibelléDescription
0Successful completion, no reboot required
1Successful completion, reboot required
64Method not supported on this platform
65Unknown failure
66Invalid subnet mask
67An error occurred while processing an Instance that was returned
68Invalid input parameter
69More than 5 gateways specifiedPlus de cinq passerelles spécifiées.
70Invalid IP address
71Invalid gateway IP address
72An error occurred while accessing the Registry for the requested information
73Invalid domain name
74Invalid host name
75No primary/secondary WINS server definedAucun serveur WINS principal ou secondaire défini.
76Invalid file
77Invalid system path
78File copy failed
79Invalid security parameter
80Unable to configure TCP/IP service
81Unable to configure DHCP service
82Unable to renew DHCP lease
83Unable to release DHCP lease
84IP not enabled on adapter
85IPX not enabled on adapter
86Frame/network number bounds errorErreur de limite de trame ou de numéro de réseau.
87Invalid frame type
88Invalid network number
89Duplicate network number
90Parameter out of bounds
91Access denied
92Out of memory
93Already exists
94Path, file or object not foundChemin, fichier ou objet introuvable.
95Unable to notify service
96Unable to notify DNS service
97Interface not configurable
98Not all DHCP leases could be released/renewedTous les baux DHCP n'ont pas pu être libérés ou renouvelés.
100DHCP not enabled on adapter
101..4294967295Other

Appeler la méthode SetDynamicDNSRegistration

à vérifier avant exécution
# Attention : cette méthode peut modifier le système. -WhatIf affiche l'opération sans l'exécuter.
# Instance cible
$instance = Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Filter 'IPEnabled = TRUE'
$methodParameters = @{
    InputObject = $instance
    MethodName  = 'SetDynamicDNSRegistration'
    Arguments   = @{
        FullDNSRegistrationEnabled   = $false
        DomainDNSRegistrationEnabled = $false
    }
    WhatIf      = $true  # Retirez cette ligne pour exécuter réellement la méthode
}
$result = Invoke-CimMethod @methodParameters

# Avec -WhatIf, rien n'est exécuté et aucun résultat n'est renvoyé
if ($result) {
    $returnValueName = @{
        0 = 'Successful completion, no reboot required'
        1 = 'Successful completion, reboot required'
        64 = 'Method not supported on this platform'
        65 = 'Unknown failure'
        66 = 'Invalid subnet mask'
        67 = 'An error occurred while processing an Instance that was returned'
        68 = 'Invalid input parameter'
        69 = 'More than 5 gateways specified'
        70 = 'Invalid IP address'
        71 = 'Invalid gateway IP address'
        72 = 'An error occurred while accessing the Registry for the…'
        73 = 'Invalid domain name'
        74 = 'Invalid host name'
        75 = 'No primary/secondary WINS server defined'
        76 = 'Invalid file'
        77 = 'Invalid system path'
        78 = 'File copy failed'
        79 = 'Invalid security parameter'
        80 = 'Unable to configure TCP/IP service'
        81 = 'Unable to configure DHCP service'
        82 = 'Unable to renew DHCP lease'
        83 = 'Unable to release DHCP lease'
        84 = 'IP not enabled on adapter'
        85 = 'IPX not enabled on adapter'
        86 = 'Frame/network number bounds error'
        87 = 'Invalid frame type'
        88 = 'Invalid network number'
        89 = 'Duplicate network number'
        90 = 'Parameter out of bounds'
        91 = 'Access denied'
        92 = 'Out of memory'
        93 = 'Already exists'
        94 = 'Path, file or object not found'
        95 = 'Unable to notify service'
        96 = 'Unable to notify DNS service'
        97 = 'Interface not configurable'
        98 = 'Not all DHCP leases could be released/renewed'
        100 = 'DHCP not enabled on adapter'
    }
    $returnValueName[[int]$result.ReturnValue]
}

Cette méthode peut modifier le système. Le paramètre -WhatIf affiche l'opération sans l'exécuter : retirez-le seulement après vérification.

SetForwardBufferMemory statique#

Spécifie la quantité de mémoire qu'IP alloue pour stocker les données des paquets dans la file d'attente de paquets du routeur.

uint32 SetForwardBufferMemory([in] uint32 ForwardBufferMemory);

Paramètres

ParamètreTypeSensDescription
ForwardBufferMemoryuint32entrée

Taille, en octets, de la file d'attente de paquets du routeur utilisée pour stocker les données des paquets. La valeur par défaut est 74240 (cinquante paquets de 1480 octets, arrondie à un multiple de 256).

Codes de retour

ValeurLibelléDescription
0Successful completion, no reboot required
1Successful completion, reboot required
64Method not supported on this platform
65Unknown failure
66Invalid subnet mask
67An error occurred while processing an Instance that was returned
68Invalid input parameter
69More than 5 gateways specifiedPlus de cinq passerelles spécifiées.
70Invalid IP address
71Invalid gateway IP address
72An error occurred while accessing the Registry for the requested information
73Invalid domain name
74Invalid host name
75No primary/secondary WINS server definedAucun serveur WINS principal ou secondaire défini.
76Invalid file
77Invalid system path
78File copy failed
79Invalid security parameter
80Unable to configure TCP/IP service
81Unable to configure DHCP service
82Unable to renew DHCP lease
83Unable to release DHCP lease
84IP not enabled on adapter
85IPX not enabled on adapter
86Frame/network number bounds errorErreur de limite de trame ou de numéro de réseau.
87Invalid frame type
88Invalid network number
89Duplicate network number
90Parameter out of bounds
91Access denied
92Out of memory
93Already exists
94Path, file or object not foundChemin, fichier ou objet introuvable.
95Unable to notify service
96Unable to notify DNS service
97Interface not configurable
98Not all DHCP leases could be released/renewedTous les baux DHCP n'ont pas pu être libérés ou renouvelés.
100DHCP not enabled on adapter
101..4294967295Other

Appeler la méthode SetForwardBufferMemory

à vérifier avant exécution
# Attention : cette méthode peut modifier le système. -WhatIf affiche l'opération sans l'exécuter.
$methodParameters = @{
    ClassName  = 'Win32_NetworkAdapterConfiguration'
    MethodName = 'SetForwardBufferMemory'
    Arguments  = @{ ForwardBufferMemory = 0 }
    WhatIf     = $true  # Retirez cette ligne pour exécuter réellement la méthode
}
$result = Invoke-CimMethod @methodParameters

# Avec -WhatIf, rien n'est exécuté et aucun résultat n'est renvoyé
if ($result) {
    $returnValueName = @{
        0 = 'Successful completion, no reboot required'
        1 = 'Successful completion, reboot required'
        64 = 'Method not supported on this platform'
        65 = 'Unknown failure'
        66 = 'Invalid subnet mask'
        67 = 'An error occurred while processing an Instance that was returned'
        68 = 'Invalid input parameter'
        69 = 'More than 5 gateways specified'
        70 = 'Invalid IP address'
        71 = 'Invalid gateway IP address'
        72 = 'An error occurred while accessing the Registry for the…'
        73 = 'Invalid domain name'
        74 = 'Invalid host name'
        75 = 'No primary/secondary WINS server defined'
        76 = 'Invalid file'
        77 = 'Invalid system path'
        78 = 'File copy failed'
        79 = 'Invalid security parameter'
        80 = 'Unable to configure TCP/IP service'
        81 = 'Unable to configure DHCP service'
        82 = 'Unable to renew DHCP lease'
        83 = 'Unable to release DHCP lease'
        84 = 'IP not enabled on adapter'
        85 = 'IPX not enabled on adapter'
        86 = 'Frame/network number bounds error'
        87 = 'Invalid frame type'
        88 = 'Invalid network number'
        89 = 'Duplicate network number'
        90 = 'Parameter out of bounds'
        91 = 'Access denied'
        92 = 'Out of memory'
        93 = 'Already exists'
        94 = 'Path, file or object not found'
        95 = 'Unable to notify service'
        96 = 'Unable to notify DNS service'
        97 = 'Interface not configurable'
        98 = 'Not all DHCP leases could be released/renewed'
        100 = 'DHCP not enabled on adapter'
    }
    $returnValueName[[int]$result.ReturnValue]
}

Cette méthode peut modifier le système. Le paramètre -WhatIf affiche l'opération sans l'exécuter : retirez-le seulement après vérification.

SetGateways #

Spécifie une liste de passerelles pour acheminer les paquets destinés à un sous-réseau différent de celui auquel cet adaptateur est connecté.

uint32 SetGateways([in] string[] DefaultIPGateway, [in] uint16[] GatewayCostMetric);

Paramètres

ParamètreTypeSensDescription
DefaultIPGatewaystring[]entrée

Liste des adresses IP des passerelles vers lesquelles les paquets réseau sont acheminés.

GatewayCostMetricuint16[]entrée

Attribue une valeur comprise entre 1 et 9999, utilisée pour calculer les routes les plus rapides et les plus fiables. Les valeurs de ce paramètre correspondent aux valeurs du paramètre *DefaultIPGateway*. La valeur par défaut pour une passerelle est 1.

Codes de retour

ValeurLibelléDescription
0Successful completion, no reboot required
1Successful completion, reboot required
64Method not supported on this platformMéthode non prise en charge lorsque la carte réseau est en mode DHCP.
65Unknown failure
66Invalid subnet mask
67An error occurred while processing an Instance that was returned
68Invalid input parameter
69More than 5 gateways specified
70Invalid IP address
71Invalid gateway IP address
72An error occurred while accessing the Registry for the requested information
73Invalid domain name
74Invalid host name
75No primary/secondary WINS server defined
76Invalid file
77Invalid system path
78File copy failed
79Invalid security parameter
80Unable to configure TCP/IP service
81Unable to configure DHCP service
82Unable to renew DHCP lease
83Unable to release DHCP lease
84IP not enabled on adapter
85IPX not enabled on adapter
86Frame/network number bounds error
87Invalid frame type
88Invalid network number
89Duplicate network number
90Parameter out of bounds
91Access denied
92Out of memory
93Already exists
94Path, file or object not found
95Unable to notify service
96Unable to notify DNS service
97Interface not configurable
98Not all DHCP leases could be released/renewed
100DHCP not enabled on adapter
101..4294967295Other

Appeler la méthode SetGateways

à vérifier avant exécution
# Attention : cette méthode peut modifier le système. -WhatIf affiche l'opération sans l'exécuter.
# Instance cible
$instance = Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Filter 'IPEnabled = TRUE'
$methodParameters = @{
    InputObject = $instance
    MethodName  = 'SetGateways'
    Arguments   = @{
        DefaultIPGateway  = @('Example')
        GatewayCostMetric = @(0)
    }
    WhatIf      = $true  # Retirez cette ligne pour exécuter réellement la méthode
}
$result = Invoke-CimMethod @methodParameters

# Avec -WhatIf, rien n'est exécuté et aucun résultat n'est renvoyé
if ($result) {
    $returnValueName = @{
        0 = 'Successful completion, no reboot required'
        1 = 'Successful completion, reboot required'
        64 = 'Method not supported on this platform'
        65 = 'Unknown failure'
        66 = 'Invalid subnet mask'
        67 = 'An error occurred while processing an Instance that was returned'
        68 = 'Invalid input parameter'
        69 = 'More than 5 gateways specified'
        70 = 'Invalid IP address'
        71 = 'Invalid gateway IP address'
        72 = 'An error occurred while accessing the Registry for the…'
        73 = 'Invalid domain name'
        74 = 'Invalid host name'
        75 = 'No primary/secondary WINS server defined'
        76 = 'Invalid file'
        77 = 'Invalid system path'
        78 = 'File copy failed'
        79 = 'Invalid security parameter'
        80 = 'Unable to configure TCP/IP service'
        81 = 'Unable to configure DHCP service'
        82 = 'Unable to renew DHCP lease'
        83 = 'Unable to release DHCP lease'
        84 = 'IP not enabled on adapter'
        85 = 'IPX not enabled on adapter'
        86 = 'Frame/network number bounds error'
        87 = 'Invalid frame type'
        88 = 'Invalid network number'
        89 = 'Duplicate network number'
        90 = 'Parameter out of bounds'
        91 = 'Access denied'
        92 = 'Out of memory'
        93 = 'Already exists'
        94 = 'Path, file or object not found'
        95 = 'Unable to notify service'
        96 = 'Unable to notify DNS service'
        97 = 'Interface not configurable'
        98 = 'Not all DHCP leases could be released/renewed'
        100 = 'DHCP not enabled on adapter'
    }
    $returnValueName[[int]$result.ReturnValue]
}

Cette méthode peut modifier le système. Le paramètre -WhatIf affiche l'opération sans l'exécuter : retirez-le seulement après vérification.

SetIGMPLevel statique#

Définit la mesure dans laquelle le système prend en charge la multidiffusion IP et participe au protocole IGMP (Internet Group Management Protocol).

uint32 SetIGMPLevel([in] uint8 IGMPLevel);

Paramètres

ParamètreTypeSensDescription
IGMPLeveluint8entrée

Codes de retour

ValeurLibelléDescription
0Successful completion, no reboot required
1Successful completion, reboot required
64Method not supported on this platform
65Unknown failure
66Invalid subnet mask
67An error occurred while processing an Instance that was returned
68Invalid input parameter
69More than 5 gateways specifiedPlus de cinq passerelles spécifiées.
70Invalid IP address
71Invalid gateway IP address
72An error occurred while accessing the Registry for the requested information
73Invalid domain name
74Invalid host name
75No primary/secondary WINS server definedAucun serveur WINS principal ou secondaire défini.
76Invalid file
77Invalid system path
78File copy failed
79Invalid security parameter
80Unable to configure TCP/IP service
81Unable to configure DHCP service
82Unable to renew DHCP lease
83Unable to release DHCP lease
84IP not enabled on adapter
85IPX not enabled on adapter
86Frame/network number bounds errorErreur de limite de trame ou de numéro de réseau.
87Invalid frame type
88Invalid network number
89Duplicate network number
90Parameter out of bounds
91Access denied
92Out of memory
93Already exists
94Path, file or object not foundChemin, fichier ou objet introuvable.
95Unable to notify service
96Unable to notify DNS service
97Interface not configurable
98Not all DHCP leases could be released/renewedTous les baux DHCP n'ont pas pu être libérés ou renouvelés.
100DHCP not enabled on adapter
101..4294967295Other

Appeler la méthode SetIGMPLevel

à vérifier avant exécution
# Attention : cette méthode peut modifier le système. -WhatIf affiche l'opération sans l'exécuter.
$methodParameters = @{
    ClassName  = 'Win32_NetworkAdapterConfiguration'
    MethodName = 'SetIGMPLevel'
    Arguments  = @{ IGMPLevel = 1 }
    WhatIf     = $true  # Retirez cette ligne pour exécuter réellement la méthode
}
$result = Invoke-CimMethod @methodParameters

# Avec -WhatIf, rien n'est exécuté et aucun résultat n'est renvoyé
if ($result) {
    $returnValueName = @{
        0 = 'Successful completion, no reboot required'
        1 = 'Successful completion, reboot required'
        64 = 'Method not supported on this platform'
        65 = 'Unknown failure'
        66 = 'Invalid subnet mask'
        67 = 'An error occurred while processing an Instance that was returned'
        68 = 'Invalid input parameter'
        69 = 'More than 5 gateways specified'
        70 = 'Invalid IP address'
        71 = 'Invalid gateway IP address'
        72 = 'An error occurred while accessing the Registry for the…'
        73 = 'Invalid domain name'
        74 = 'Invalid host name'
        75 = 'No primary/secondary WINS server defined'
        76 = 'Invalid file'
        77 = 'Invalid system path'
        78 = 'File copy failed'
        79 = 'Invalid security parameter'
        80 = 'Unable to configure TCP/IP service'
        81 = 'Unable to configure DHCP service'
        82 = 'Unable to renew DHCP lease'
        83 = 'Unable to release DHCP lease'
        84 = 'IP not enabled on adapter'
        85 = 'IPX not enabled on adapter'
        86 = 'Frame/network number bounds error'
        87 = 'Invalid frame type'
        88 = 'Invalid network number'
        89 = 'Duplicate network number'
        90 = 'Parameter out of bounds'
        91 = 'Access denied'
        92 = 'Out of memory'
        93 = 'Already exists'
        94 = 'Path, file or object not found'
        95 = 'Unable to notify service'
        96 = 'Unable to notify DNS service'
        97 = 'Interface not configurable'
        98 = 'Not all DHCP leases could be released/renewed'
        100 = 'DHCP not enabled on adapter'
    }
    $returnValueName[[int]$result.ReturnValue]
}

Cette méthode peut modifier le système. Le paramètre -WhatIf affiche l'opération sans l'exécuter : retirez-le seulement après vérification.

SetIPConnectionMetric #

Définit la métrique de routage associée à cet adaptateur lié à IP.

uint32 SetIPConnectionMetric([in] uint32 IPConnectionMetric);

Paramètres

ParamètreTypeSensDescription
IPConnectionMetricuint32entrée

Indique le coût d'utilisation des routes configurées pour cet adaptateur lié à IP. La valeur est pondérée pour ces routes dans la table de routage IP. Si plusieurs routes existent vers une destination dans la table de routage, la route ayant la métrique la plus faible est utilisée. La plage de valeurs valides est comprise entre 1 et 9999. La valeur par défaut est 1.

Codes de retour

ValeurLibelléDescription
0Successful completion, no reboot required
1Successful completion, reboot required
64Method not supported on this platform
65Unknown failure
66Invalid subnet mask
67An error occurred while processing an Instance that was returned
68Invalid input parameter
69More than 5 gateways specifiedPlus de cinq passerelles spécifiées.
70Invalid IP address
71Invalid gateway IP address
72An error occurred while accessing the Registry for the requested information
73Invalid domain name
74Invalid host name
75No primary/secondary WINS server definedAucun serveur WINS principal ou secondaire défini.
76Invalid file
77Invalid system path
78File copy failed
79Invalid security parameter
80Unable to configure TCP/IP service
81Unable to configure DHCP service
82Unable to renew DHCP lease
83Unable to release DHCP lease
84IP not enabled on adapter
85IPX not enabled on adapter
86Frame/network number bounds errorErreur de limite de trame ou de numéro de réseau.
87Invalid frame type
88Invalid network number
89Duplicate network number
90Parameter out of bounds
91Access denied
92Out of memory
93Already exists
94Path, file or object not foundChemin, fichier ou objet introuvable.
95Unable to notify service
96Unable to notify DNS service
97Interface not configurable
98Not all DHCP leases could be released/renewedTous les baux DHCP n'ont pas pu être libérés ou renouvelés.
100DHCP not enabled on adapter
101..4294967295Other

Appeler la méthode SetIPConnectionMetric

à vérifier avant exécution
# Attention : cette méthode peut modifier le système. -WhatIf affiche l'opération sans l'exécuter.
# Instance cible
$instance = Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Filter 'IPEnabled = TRUE'
$methodParameters = @{
    InputObject = $instance
    MethodName  = 'SetIPConnectionMetric'
    Arguments   = @{ IPConnectionMetric = 0 }
    WhatIf      = $true  # Retirez cette ligne pour exécuter réellement la méthode
}
$result = Invoke-CimMethod @methodParameters

# Avec -WhatIf, rien n'est exécuté et aucun résultat n'est renvoyé
if ($result) {
    $returnValueName = @{
        0 = 'Successful completion, no reboot required'
        1 = 'Successful completion, reboot required'
        64 = 'Method not supported on this platform'
        65 = 'Unknown failure'
        66 = 'Invalid subnet mask'
        67 = 'An error occurred while processing an Instance that was returned'
        68 = 'Invalid input parameter'
        69 = 'More than 5 gateways specified'
        70 = 'Invalid IP address'
        71 = 'Invalid gateway IP address'
        72 = 'An error occurred while accessing the Registry for the…'
        73 = 'Invalid domain name'
        74 = 'Invalid host name'
        75 = 'No primary/secondary WINS server defined'
        76 = 'Invalid file'
        77 = 'Invalid system path'
        78 = 'File copy failed'
        79 = 'Invalid security parameter'
        80 = 'Unable to configure TCP/IP service'
        81 = 'Unable to configure DHCP service'
        82 = 'Unable to renew DHCP lease'
        83 = 'Unable to release DHCP lease'
        84 = 'IP not enabled on adapter'
        85 = 'IPX not enabled on adapter'
        86 = 'Frame/network number bounds error'
        87 = 'Invalid frame type'
        88 = 'Invalid network number'
        89 = 'Duplicate network number'
        90 = 'Parameter out of bounds'
        91 = 'Access denied'
        92 = 'Out of memory'
        93 = 'Already exists'
        94 = 'Path, file or object not found'
        95 = 'Unable to notify service'
        96 = 'Unable to notify DNS service'
        97 = 'Interface not configurable'
        98 = 'Not all DHCP leases could be released/renewed'
        100 = 'DHCP not enabled on adapter'
    }
    $returnValueName[[int]$result.ReturnValue]
}

Cette méthode peut modifier le système. Le paramètre -WhatIf affiche l'opération sans l'exécuter : retirez-le seulement après vérification.

SetIPUseZeroBroadcast statique#

Définit l'utilisation de la diffusion zéro IP.

uint32 SetIPUseZeroBroadcast([in] boolean IPUseZeroBroadcast);

Paramètres

ParamètreTypeSensDescription
IPUseZeroBroadcastbooleanentrée

Si true, la diffusion IP zéro est utilisée. La valeur par défaut est false.

Codes de retour

ValeurLibelléDescription
0Successful completion, no reboot required
1Successful completion, reboot required
64Method not supported on this platform
65Unknown failure
66Invalid subnet mask
67An error occurred while processing an Instance that was returned
68Invalid input parameter
69More than 5 gateways specifiedPlus de cinq passerelles spécifiées.
70Invalid IP address
71Invalid gateway IP address
72An error occurred while accessing the Registry for the requested information
73Invalid domain name
74Invalid host name
75No primary/secondary WINS server definedAucun serveur WINS principal ou secondaire défini.
76Invalid file
77Invalid system path
78File copy failed
79Invalid security parameter
80Unable to configure TCP/IP service
81Unable to configure DHCP service
82Unable to renew DHCP lease
83Unable to release DHCP lease
84IP not enabled on adapter
85IPX not enabled on adapter
86Frame/network number bounds errorErreur de limite de trame ou de numéro de réseau.
87Invalid frame type
88Invalid network number
89Duplicate network number
90Parameter out of bounds
91Access denied
92Out of memory
93Already exists
94Path, file or object not foundChemin, fichier ou objet introuvable.
95Unable to notify service
96Unable to notify DNS service
97Interface not configurable
98Not all DHCP leases could be released/renewedTous les baux DHCP n'ont pas pu être libérés ou renouvelés.
100DHCP not enabled on adapter
101..4294967295Other

Appeler la méthode SetIPUseZeroBroadcast

à vérifier avant exécution
# Attention : cette méthode peut modifier le système. -WhatIf affiche l'opération sans l'exécuter.
$methodParameters = @{
    ClassName  = 'Win32_NetworkAdapterConfiguration'
    MethodName = 'SetIPUseZeroBroadcast'
    Arguments  = @{ IPUseZeroBroadcast = $false }
    WhatIf     = $true  # Retirez cette ligne pour exécuter réellement la méthode
}
$result = Invoke-CimMethod @methodParameters

# Avec -WhatIf, rien n'est exécuté et aucun résultat n'est renvoyé
if ($result) {
    $returnValueName = @{
        0 = 'Successful completion, no reboot required'
        1 = 'Successful completion, reboot required'
        64 = 'Method not supported on this platform'
        65 = 'Unknown failure'
        66 = 'Invalid subnet mask'
        67 = 'An error occurred while processing an Instance that was returned'
        68 = 'Invalid input parameter'
        69 = 'More than 5 gateways specified'
        70 = 'Invalid IP address'
        71 = 'Invalid gateway IP address'
        72 = 'An error occurred while accessing the Registry for the…'
        73 = 'Invalid domain name'
        74 = 'Invalid host name'
        75 = 'No primary/secondary WINS server defined'
        76 = 'Invalid file'
        77 = 'Invalid system path'
        78 = 'File copy failed'
        79 = 'Invalid security parameter'
        80 = 'Unable to configure TCP/IP service'
        81 = 'Unable to configure DHCP service'
        82 = 'Unable to renew DHCP lease'
        83 = 'Unable to release DHCP lease'
        84 = 'IP not enabled on adapter'
        85 = 'IPX not enabled on adapter'
        86 = 'Frame/network number bounds error'
        87 = 'Invalid frame type'
        88 = 'Invalid network number'
        89 = 'Duplicate network number'
        90 = 'Parameter out of bounds'
        91 = 'Access denied'
        92 = 'Out of memory'
        93 = 'Already exists'
        94 = 'Path, file or object not found'
        95 = 'Unable to notify service'
        96 = 'Unable to notify DNS service'
        97 = 'Interface not configurable'
        98 = 'Not all DHCP leases could be released/renewed'
        100 = 'DHCP not enabled on adapter'
    }
    $returnValueName[[int]$result.ReturnValue]
}

Cette méthode peut modifier le système. Le paramètre -WhatIf affiche l'opération sans l'exécuter : retirez-le seulement après vérification.

SetIPXFrameTypeNetworkPairs #

Définit les paires de numéros de réseau et de trames IPX (Internetworking Packet Exchange) pour cet adaptateur réseau.

uint32 SetIPXFrameTypeNetworkPairs([in] string[] IPXNetworkNumber, [in] uint32[] IPXFrameType);

Paramètres

ParamètreTypeSensDescription
IPXNetworkNumberstring[]entrée

Tableau de caractères qui identifie de manière unique un adaptateur sur le système informatique. Le transport NetWare Link (NWLink) compatible IPX/SPX de Windows 2000 et de Windows NT 3.51 ou version ultérieure utilise deux types différents de numéros de réseau. Ce numéro est parfois appelé numéro de réseau externe. Il doit être unique pour chaque segment réseau. Les valeurs de cette liste de chaînes doivent avoir une valeur correspondante dans le paramètre IPXFrameType, qui identifie le type de trame de paquet utilisé pour ce réseau.

IPXFrameTypeuint32[]entrée

Tableau d'entiers d'identificateurs de type de trame. Les valeurs de ce tableau correspondent aux éléments du paramètre *IPXNetworkNumber*.

Codes de retour

ValeurLibelléDescription
0Successful completion, no reboot required
1Successful completion, reboot required
64Method not supported on this platform
65Unknown failure
66Invalid subnet mask
67An error occurred while processing an Instance that was returned
68Invalid input parameter
69More than 5 gateways specified
70Invalid IP address
71Invalid gateway IP address
72An error occurred while accessing the Registry for the requested information
73Invalid domain name
74Invalid host name
75No primary/secondary WINS server defined
76Invalid file
77Invalid system path
78File copy failed
79Invalid security parameter
80Unable to configure TCP/IP service
81Unable to configure DHCP service
82Unable to renew DHCP lease
83Unable to release DHCP lease
84IP not enabled on adapter
85IPX not enabled on adapter
86Frame/network number bounds error
87Invalid frame type
88Invalid network number
89Duplicate network number
90Parameter out of bounds
91Access denied
92Out of memory
93Already exists
94Path, file or object not found
95Unable to notify service
96Unable to notify DNS service
97Interface not configurable
98Not all DHCP leases could be released/renewed
100DHCP not enabled on adapter
101–4294967295Other

Appeler la méthode SetIPXFrameTypeNetworkPairs

à vérifier avant exécution
# Attention : cette méthode peut modifier le système. -WhatIf affiche l'opération sans l'exécuter.
# Instance cible
$instance = Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Filter 'IPEnabled = TRUE'
$methodParameters = @{
    InputObject = $instance
    MethodName  = 'SetIPXFrameTypeNetworkPairs'
    Arguments   = @{
        IPXNetworkNumber = @('Example')
        IPXFrameType     = @(1)
    }
    WhatIf      = $true  # Retirez cette ligne pour exécuter réellement la méthode
}
$result = Invoke-CimMethod @methodParameters

# Avec -WhatIf, rien n'est exécuté et aucun résultat n'est renvoyé
if ($result) {
    $returnValueName = @{
        0 = 'Successful completion, no reboot required'
        1 = 'Successful completion, reboot required'
        64 = 'Method not supported on this platform'
        65 = 'Unknown failure'
        66 = 'Invalid subnet mask'
        67 = 'An error occurred while processing an Instance that was returned'
        68 = 'Invalid input parameter'
        69 = 'More than 5 gateways specified'
        70 = 'Invalid IP address'
        71 = 'Invalid gateway IP address'
        72 = 'An error occurred while accessing the Registry for the…'
        73 = 'Invalid domain name'
        74 = 'Invalid host name'
        75 = 'No primary/secondary WINS server defined'
        76 = 'Invalid file'
        77 = 'Invalid system path'
        78 = 'File copy failed'
        79 = 'Invalid security parameter'
        80 = 'Unable to configure TCP/IP service'
        81 = 'Unable to configure DHCP service'
        82 = 'Unable to renew DHCP lease'
        83 = 'Unable to release DHCP lease'
        84 = 'IP not enabled on adapter'
        85 = 'IPX not enabled on adapter'
        86 = 'Frame/network number bounds error'
        87 = 'Invalid frame type'
        88 = 'Invalid network number'
        89 = 'Duplicate network number'
        90 = 'Parameter out of bounds'
        91 = 'Access denied'
        92 = 'Out of memory'
        93 = 'Already exists'
        94 = 'Path, file or object not found'
        95 = 'Unable to notify service'
        96 = 'Unable to notify DNS service'
        97 = 'Interface not configurable'
        98 = 'Not all DHCP leases could be released/renewed'
        100 = 'DHCP not enabled on adapter'
    }
    $returnValueName[[int]$result.ReturnValue]
}

Cette méthode peut modifier le système. Le paramètre -WhatIf affiche l'opération sans l'exécuter : retirez-le seulement après vérification.

SetIPXVirtualNetworkNumber #

Définit le numéro de réseau virtuel IPX (Internetworking Packet Exchange) sur le système informatique cible.

uint32 SetIPXVirtualNetworkNumber([in] string IPXVirtualNetNumber);

Paramètres

ParamètreTypeSensDescription
IPXVirtualNetNumberstringentrée

Numéro de réseau virtuel de ce système.

Codes de retour

ValeurLibelléDescription
0Successful completion, no reboot required
1Successful completion, reboot required
64Method not supported on this platform
65Unknown failure
66Invalid subnet mask
67An error occurred while processing an Instance that was returned
68Invalid input parameter
69More than 5 gateways specified
70Invalid IP address
71Invalid gateway IP address
72An error occurred while accessing the Registry for the requested information
73Invalid domain name
74Invalid host name
75No primary/secondary WINS server defined
76Invalid file
77Invalid system path
78File copy failed
79Invalid security parameter
80Unable to configure TCP/IP service
81Unable to configure DHCP service
82Unable to renew DHCP lease
83Unable to release DHCP lease
84IP not enabled on adapter
85IPX not enabled on adapter
86Frame/network number bounds error
87Invalid frame type
88Invalid network number
89Duplicate network number
90Parameter out of bounds
91Access denied
92Out of memory
93Already exists
94Path, file or object not found
95Unable to notify service
96Unable to notify DNS service
97Interface not configurable
98Not all DHCP leases could be released/renewed
100DHCP not enabled on adapter
101–4294967295Other

Appeler la méthode SetIPXVirtualNetworkNumber

à vérifier avant exécution
# Attention : cette méthode peut modifier le système. -WhatIf affiche l'opération sans l'exécuter.
# Instance cible
$instance = Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Filter 'IPEnabled = TRUE'
$methodParameters = @{
    InputObject = $instance
    MethodName  = 'SetIPXVirtualNetworkNumber'
    Arguments   = @{ IPXVirtualNetNumber = 'Example' }
    WhatIf      = $true  # Retirez cette ligne pour exécuter réellement la méthode
}
$result = Invoke-CimMethod @methodParameters

# Avec -WhatIf, rien n'est exécuté et aucun résultat n'est renvoyé
if ($result) {
    $returnValueName = @{
        0 = 'Successful completion, no reboot required'
        1 = 'Successful completion, reboot required'
        64 = 'Method not supported on this platform'
        65 = 'Unknown failure'
        66 = 'Invalid subnet mask'
        67 = 'An error occurred while processing an Instance that was returned'
        68 = 'Invalid input parameter'
        69 = 'More than 5 gateways specified'
        70 = 'Invalid IP address'
        71 = 'Invalid gateway IP address'
        72 = 'An error occurred while accessing the Registry for the…'
        73 = 'Invalid domain name'
        74 = 'Invalid host name'
        75 = 'No primary/secondary WINS server defined'
        76 = 'Invalid file'
        77 = 'Invalid system path'
        78 = 'File copy failed'
        79 = 'Invalid security parameter'
        80 = 'Unable to configure TCP/IP service'
        81 = 'Unable to configure DHCP service'
        82 = 'Unable to renew DHCP lease'
        83 = 'Unable to release DHCP lease'
        84 = 'IP not enabled on adapter'
        85 = 'IPX not enabled on adapter'
        86 = 'Frame/network number bounds error'
        87 = 'Invalid frame type'
        88 = 'Invalid network number'
        89 = 'Duplicate network number'
        90 = 'Parameter out of bounds'
        91 = 'Access denied'
        92 = 'Out of memory'
        93 = 'Already exists'
        94 = 'Path, file or object not found'
        95 = 'Unable to notify service'
        96 = 'Unable to notify DNS service'
        97 = 'Interface not configurable'
        98 = 'Not all DHCP leases could be released/renewed'
        100 = 'DHCP not enabled on adapter'
    }
    $returnValueName[[int]$result.ReturnValue]
}

Cette méthode peut modifier le système. Le paramètre -WhatIf affiche l'opération sans l'exécuter : retirez-le seulement après vérification.

SetKeepAliveInterval statique#

Définit l'intervalle séparant les retransmissions Keep Alive jusqu'à la réception d'une réponse.

uint32 SetKeepAliveInterval([in] uint32 KeepAliveInterval);

Paramètres

ParamètreTypeSensDescription
KeepAliveIntervaluint32entrée

Valeur, en millisecondes, de l'intervalle séparant les retransmissions Keep Alive jusqu'à réception d'une réponse.

Codes de retour

ValeurLibelléDescription
0Successful completion, no reboot required
1Successful completion, reboot required
64Method not supported on this platform
65Unknown failure
66Invalid subnet mask
67An error occurred while processing an Instance that was returned
68Invalid input parameter
69More than 5 gateways specifiedPlus de cinq passerelles spécifiées.
70Invalid IP address
71Invalid gateway IP address
72An error occurred while accessing the Registry for the requested information
73Invalid domain name
74Invalid host name
75No primary/secondary WINS server definedAucun serveur WINS principal ou secondaire défini.
76Invalid file
77Invalid system path
78File copy failed
79Invalid security parameter
80Unable to configure TCP/IP service
81Unable to configure DHCP service
82Unable to renew DHCP lease
83Unable to release DHCP lease
84IP not enabled on adapter
85IPX not enabled on adapter
86Frame/network number bounds errorErreur de limite de trame ou de numéro de réseau.
87Invalid frame type
88Invalid network number
89Duplicate network number
90Parameter out of bounds
91Access denied
92Out of memory
93Already exists
94Path, file or object not foundChemin, fichier ou objet introuvable.
95Unable to notify service
96Unable to notify DNS service
97Interface not configurable
98Not all DHCP leases could be released/renewedTous les baux DHCP n'ont pas pu être libérés ou renouvelés.
100DHCP not enabled on adapter
101..4294967295Other

Appeler la méthode SetKeepAliveInterval

à vérifier avant exécution
# Attention : cette méthode peut modifier le système. -WhatIf affiche l'opération sans l'exécuter.
$methodParameters = @{
    ClassName  = 'Win32_NetworkAdapterConfiguration'
    MethodName = 'SetKeepAliveInterval'
    Arguments  = @{ KeepAliveInterval = 0 }
    WhatIf     = $true  # Retirez cette ligne pour exécuter réellement la méthode
}
$result = Invoke-CimMethod @methodParameters

# Avec -WhatIf, rien n'est exécuté et aucun résultat n'est renvoyé
if ($result) {
    $returnValueName = @{
        0 = 'Successful completion, no reboot required'
        1 = 'Successful completion, reboot required'
        64 = 'Method not supported on this platform'
        65 = 'Unknown failure'
        66 = 'Invalid subnet mask'
        67 = 'An error occurred while processing an Instance that was returned'
        68 = 'Invalid input parameter'
        69 = 'More than 5 gateways specified'
        70 = 'Invalid IP address'
        71 = 'Invalid gateway IP address'
        72 = 'An error occurred while accessing the Registry for the…'
        73 = 'Invalid domain name'
        74 = 'Invalid host name'
        75 = 'No primary/secondary WINS server defined'
        76 = 'Invalid file'
        77 = 'Invalid system path'
        78 = 'File copy failed'
        79 = 'Invalid security parameter'
        80 = 'Unable to configure TCP/IP service'
        81 = 'Unable to configure DHCP service'
        82 = 'Unable to renew DHCP lease'
        83 = 'Unable to release DHCP lease'
        84 = 'IP not enabled on adapter'
        85 = 'IPX not enabled on adapter'
        86 = 'Frame/network number bounds error'
        87 = 'Invalid frame type'
        88 = 'Invalid network number'
        89 = 'Duplicate network number'
        90 = 'Parameter out of bounds'
        91 = 'Access denied'
        92 = 'Out of memory'
        93 = 'Already exists'
        94 = 'Path, file or object not found'
        95 = 'Unable to notify service'
        96 = 'Unable to notify DNS service'
        97 = 'Interface not configurable'
        98 = 'Not all DHCP leases could be released/renewed'
        100 = 'DHCP not enabled on adapter'
    }
    $returnValueName[[int]$result.ReturnValue]
}

Cette méthode peut modifier le système. Le paramètre -WhatIf affiche l'opération sans l'exécuter : retirez-le seulement après vérification.

SetKeepAliveTime statique#

Définit la fréquence à laquelle TCP tente de vérifier qu'une connexion inactive est toujours disponible en envoyant un paquet Keep Alive.

uint32 SetKeepAliveTime([in] uint32 KeepAliveTime);

Paramètres

ParamètreTypeSensDescription
KeepAliveTimeuint32entrée

Intervalle, en millisecondes, pendant lequel TCP attend avant de vérifier qu'une connexion inactive est toujours disponible.

Codes de retour

ValeurLibelléDescription
0Successful completion, no reboot required
1Successful completion, reboot required
64Method not supported on this platform
65Unknown failure
66Invalid subnet mask
67An error occurred while processing an Instance that was returned
68Invalid input parameter
69More than 5 gateways specifiedPlus de cinq passerelles spécifiées.
70Invalid IP address
71Invalid gateway IP address
72An error occurred while accessing the Registry for the requested information
73Invalid domain name
74Invalid host name
75No primary/secondary WINS server definedAucun serveur WINS principal ou secondaire défini.
76Invalid file
77Invalid system path
78File copy failed
79Invalid security parameter
80Unable to configure TCP/IP service
81Unable to configure DHCP service
82Unable to renew DHCP lease
83Unable to release DHCP lease
84IP not enabled on adapter
85IPX not enabled on adapter
86Frame/network number bounds errorErreur de limite de trame ou de numéro de réseau.
87Invalid frame type
88Invalid network number
89Duplicate network number
90Parameter out of bounds
91Access denied
92Out of memory
93Already exists
94Path, file or object not foundChemin, fichier ou objet introuvable.
95Unable to notify service
96Unable to notify DNS service
97Interface not configurable
98Not all DHCP leases could be released/renewedTous les baux DHCP n'ont pas pu être libérés ou renouvelés.
100DHCP not enabled on adapter
101..4294967295Other

Appeler la méthode SetKeepAliveTime

à vérifier avant exécution
# Attention : cette méthode peut modifier le système. -WhatIf affiche l'opération sans l'exécuter.
$methodParameters = @{
    ClassName  = 'Win32_NetworkAdapterConfiguration'
    MethodName = 'SetKeepAliveTime'
    Arguments  = @{ KeepAliveTime = 0 }
    WhatIf     = $true  # Retirez cette ligne pour exécuter réellement la méthode
}
$result = Invoke-CimMethod @methodParameters

# Avec -WhatIf, rien n'est exécuté et aucun résultat n'est renvoyé
if ($result) {
    $returnValueName = @{
        0 = 'Successful completion, no reboot required'
        1 = 'Successful completion, reboot required'
        64 = 'Method not supported on this platform'
        65 = 'Unknown failure'
        66 = 'Invalid subnet mask'
        67 = 'An error occurred while processing an Instance that was returned'
        68 = 'Invalid input parameter'
        69 = 'More than 5 gateways specified'
        70 = 'Invalid IP address'
        71 = 'Invalid gateway IP address'
        72 = 'An error occurred while accessing the Registry for the…'
        73 = 'Invalid domain name'
        74 = 'Invalid host name'
        75 = 'No primary/secondary WINS server defined'
        76 = 'Invalid file'
        77 = 'Invalid system path'
        78 = 'File copy failed'
        79 = 'Invalid security parameter'
        80 = 'Unable to configure TCP/IP service'
        81 = 'Unable to configure DHCP service'
        82 = 'Unable to renew DHCP lease'
        83 = 'Unable to release DHCP lease'
        84 = 'IP not enabled on adapter'
        85 = 'IPX not enabled on adapter'
        86 = 'Frame/network number bounds error'
        87 = 'Invalid frame type'
        88 = 'Invalid network number'
        89 = 'Duplicate network number'
        90 = 'Parameter out of bounds'
        91 = 'Access denied'
        92 = 'Out of memory'
        93 = 'Already exists'
        94 = 'Path, file or object not found'
        95 = 'Unable to notify service'
        96 = 'Unable to notify DNS service'
        97 = 'Interface not configurable'
        98 = 'Not all DHCP leases could be released/renewed'
        100 = 'DHCP not enabled on adapter'
    }
    $returnValueName[[int]$result.ReturnValue]
}

Cette méthode peut modifier le système. Le paramètre -WhatIf affiche l'opération sans l'exécuter : retirez-le seulement après vérification.

SetMTU statique#

Définit l'unité de transmission maximale (MTU) par défaut pour une interface réseau. Cette méthode n'est pas prise en charge.

uint32 SetMTU([in] uint32 MTU);

Paramètres

ParamètreTypeSensDescription
MTUuint32entrée

Unité de transmission maximale (MTU) par défaut pour une interface réseau. La plage de cette valeur s'étend de la taille minimale de paquet (68) à la MTU prise en charge par le réseau sous-jacent.

Codes de retour

ValeurLibelléDescription
0Successful completion, no reboot requiredExécution réussie. Aucun redémarrage n'est nécessaire.
1Successful completion, reboot requiredExécution réussie. Un redémarrage est nécessaire.
64Method not supported on this platform
65Unknown failure
66Invalid subnet mask
67An error occurred while processing an Instance that was returned
68Invalid input parameter
69More than 5 gateways specifiedPlus de cinq passerelles spécifiées.
70Invalid IP address
71Invalid gateway IP address
72An error occurred while accessing the Registry for the requested information
73Invalid domain name
74Invalid host name
75No primary/secondary WINS server definedAucun serveur WINS principal ou secondaire défini.
76Invalid file
77Invalid system path
78File copy failed
79Invalid security parameter
80Unable to configure TCP/IP service
81Unable to configure DHCP service
82Unable to renew DHCP lease
83Unable to release DHCP lease
84IP not enabled on adapter
85IPX not enabled on adapter
86Frame/network number bounds errorErreur de limite de trame ou de numéro de réseau.
87Invalid frame type
88Invalid network number
89Duplicate network number
90Parameter out of bounds
91Access denied
92Out of memory
93Already exists
94Path, file or object not foundChemin, fichier ou objet introuvable.
95Unable to notify service
96Unable to notify DNS service
97Interface not configurable
98Not all DHCP leases could be released/renewedTous les baux DHCP ne peuvent pas être libérés ou renouvelés.
100DHCP not enabled on adapterDHCP n'est pas activé sur la carte réseau.
101..4294967295Other

Appeler la méthode SetMTU

à vérifier avant exécution
# Attention : cette méthode peut modifier le système. -WhatIf affiche l'opération sans l'exécuter.
$methodParameters = @{
    ClassName  = 'Win32_NetworkAdapterConfiguration'
    MethodName = 'SetMTU'
    Arguments  = @{ MTU = 0 }
    WhatIf     = $true  # Retirez cette ligne pour exécuter réellement la méthode
}
$result = Invoke-CimMethod @methodParameters

# Avec -WhatIf, rien n'est exécuté et aucun résultat n'est renvoyé
if ($result) {
    $returnValueName = @{
        0 = 'Successful completion, no reboot required'
        1 = 'Successful completion, reboot required'
        64 = 'Method not supported on this platform'
        65 = 'Unknown failure'
        66 = 'Invalid subnet mask'
        67 = 'An error occurred while processing an Instance that was returned'
        68 = 'Invalid input parameter'
        69 = 'More than 5 gateways specified'
        70 = 'Invalid IP address'
        71 = 'Invalid gateway IP address'
        72 = 'An error occurred while accessing the Registry for the…'
        73 = 'Invalid domain name'
        74 = 'Invalid host name'
        75 = 'No primary/secondary WINS server defined'
        76 = 'Invalid file'
        77 = 'Invalid system path'
        78 = 'File copy failed'
        79 = 'Invalid security parameter'
        80 = 'Unable to configure TCP/IP service'
        81 = 'Unable to configure DHCP service'
        82 = 'Unable to renew DHCP lease'
        83 = 'Unable to release DHCP lease'
        84 = 'IP not enabled on adapter'
        85 = 'IPX not enabled on adapter'
        86 = 'Frame/network number bounds error'
        87 = 'Invalid frame type'
        88 = 'Invalid network number'
        89 = 'Duplicate network number'
        90 = 'Parameter out of bounds'
        91 = 'Access denied'
        92 = 'Out of memory'
        93 = 'Already exists'
        94 = 'Path, file or object not found'
        95 = 'Unable to notify service'
        96 = 'Unable to notify DNS service'
        97 = 'Interface not configurable'
        98 = 'Not all DHCP leases could be released/renewed'
        100 = 'DHCP not enabled on adapter'
    }
    $returnValueName[[int]$result.ReturnValue]
}

Cette méthode peut modifier le système. Le paramètre -WhatIf affiche l'opération sans l'exécuter : retirez-le seulement après vérification.

SetNumForwardPackets statique#

Définit le nombre d'en-têtes de paquets IP alloués pour la file d'attente de paquets du routeur.

uint32 SetNumForwardPackets([in] uint32 NumForwardPackets);

Paramètres

ParamètreTypeSensDescription
NumForwardPacketsuint32entrée

Nombre d'en-têtes de paquets IP alloués pour la file d'attente de paquets du routeur. Il doit être au moins égal à la valeur de la propriété ForwardBufferMemory divisée par la taille maximale des données IP des réseaux connectés au routeur. Il ne doit pas être supérieur à la valeur ForwardBufferMemory divisée par 256, car chaque paquet nécessite au moins 256 octets de mémoire tampon de transfert. Le nombre optimal de paquets transférés pour une taille donnée de ForwardBufferMemory dépend du type de trafic transporté sur le réseau et se situe entre ces deux valeurs. Si le routeur est désactivé, ce paramètre est ignoré et aucun en-tête n'est alloué. Plage valide : 1 - 0xFFFFFFFE.

Codes de retour

ValeurLibelléDescription
0Successful completion, no reboot required
1Successful completion, reboot required
64Method not supported on this platform
65Unknown failure
66Invalid subnet mask
67An error occurred while processing an Instance that was returned
68Invalid input parameter
69More than 5 gateways specifiedPlus de cinq passerelles spécifiées.
70Invalid IP address
71Invalid gateway IP address
72An error occurred while accessing the Registry for the requested information
73Invalid domain name
74Invalid host name
75No primary/secondary WINS server definedAucun serveur WINS principal ou secondaire défini.
76Invalid file
77Invalid system path
78File copy failed
79Invalid security parameter
80Unable to configure TCP/IP service
81Unable to configure DHCP service
82Unable to renew DHCP lease
83Unable to release DHCP lease
84IP not enabled on adapter
85IPX not enabled on adapter
86Frame/network number bounds errorErreur de limite de trame ou de numéro de réseau.
87Invalid frame type
88Invalid network number
89Duplicate network number
90Parameter out of bounds
91Access denied
92Out of memory
93Already exists
94Path, file or object not foundChemin, fichier ou objet introuvable.
95Unable to notify service
96Unable to notify DNS service
97Interface not configurable
98Not all DHCP leases could be released/renewedTous les baux DHCP n'ont pas pu être libérés ou renouvelés.
100DHCP not enabled on adapter
101..4294967295Other

Appeler la méthode SetNumForwardPackets

à vérifier avant exécution
# Attention : cette méthode peut modifier le système. -WhatIf affiche l'opération sans l'exécuter.
$methodParameters = @{
    ClassName  = 'Win32_NetworkAdapterConfiguration'
    MethodName = 'SetNumForwardPackets'
    Arguments  = @{ NumForwardPackets = 0 }
    WhatIf     = $true  # Retirez cette ligne pour exécuter réellement la méthode
}
$result = Invoke-CimMethod @methodParameters

# Avec -WhatIf, rien n'est exécuté et aucun résultat n'est renvoyé
if ($result) {
    $returnValueName = @{
        0 = 'Successful completion, no reboot required'
        1 = 'Successful completion, reboot required'
        64 = 'Method not supported on this platform'
        65 = 'Unknown failure'
        66 = 'Invalid subnet mask'
        67 = 'An error occurred while processing an Instance that was returned'
        68 = 'Invalid input parameter'
        69 = 'More than 5 gateways specified'
        70 = 'Invalid IP address'
        71 = 'Invalid gateway IP address'
        72 = 'An error occurred while accessing the Registry for the…'
        73 = 'Invalid domain name'
        74 = 'Invalid host name'
        75 = 'No primary/secondary WINS server defined'
        76 = 'Invalid file'
        77 = 'Invalid system path'
        78 = 'File copy failed'
        79 = 'Invalid security parameter'
        80 = 'Unable to configure TCP/IP service'
        81 = 'Unable to configure DHCP service'
        82 = 'Unable to renew DHCP lease'
        83 = 'Unable to release DHCP lease'
        84 = 'IP not enabled on adapter'
        85 = 'IPX not enabled on adapter'
        86 = 'Frame/network number bounds error'
        87 = 'Invalid frame type'
        88 = 'Invalid network number'
        89 = 'Duplicate network number'
        90 = 'Parameter out of bounds'
        91 = 'Access denied'
        92 = 'Out of memory'
        93 = 'Already exists'
        94 = 'Path, file or object not found'
        95 = 'Unable to notify service'
        96 = 'Unable to notify DNS service'
        97 = 'Interface not configurable'
        98 = 'Not all DHCP leases could be released/renewed'
        100 = 'DHCP not enabled on adapter'
    }
    $returnValueName[[int]$result.ReturnValue]
}

Cette méthode peut modifier le système. Le paramètre -WhatIf affiche l'opération sans l'exécuter : retirez-le seulement après vérification.

SetPMTUBHDetect statique#

Active la détection des routeurs de trou noir.

uint32 SetPMTUBHDetect([in] boolean PMTUBHDetectEnabled);

Paramètres

ParamètreTypeSensDescription
PMTUBHDetectEnabledbooleanentrée

Si true, TCP tente de détecter les trous noirs et d'acheminer les paquets par différents chemins réseau.

Codes de retour

ValeurLibelléDescription
0Successful completion, no reboot required
1Successful completion, reboot required
64Method not supported on this platform
65Unknown failure
66Invalid subnet mask
67An error occurred while processing an Instance that was returned
68Invalid input parameter
69More than 5 gateways specifiedPlus de cinq passerelles spécifiées.
70Invalid IP address
71Invalid gateway IP address
72An error occurred while accessing the Registry for the requested information
73Invalid domain name
74Invalid host name
75No primary/secondary WINS server definedAucun serveur WINS principal ou secondaire défini.
76Invalid file
77Invalid system path
78File copy failed
79Invalid security parameter
80Unable to configure TCP/IP service
81Unable to configure DHCP service
82Unable to renew DHCP lease
83Unable to release DHCP lease
84IP not enabled on adapter
85IPX not enabled on adapter
86Frame/network number bounds errorErreur de limite de trame ou de numéro de réseau.
87Invalid frame type
88Invalid network number
89Duplicate network number
90Parameter out of bounds
91Access denied
92Out of memory
93Already exists
94Path, file or object not foundChemin, fichier ou objet introuvable.
95Unable to notify service
96Unable to notify DNS service
97Interface not configurable
98Not all DHCP leases could be released/renewedTous les baux DHCP n'ont pas pu être libérés ou renouvelés.
100DHCP not enabled on adapter
101..4294967295Other

Appeler la méthode SetPMTUBHDetect

à vérifier avant exécution
# Attention : cette méthode peut modifier le système. -WhatIf affiche l'opération sans l'exécuter.
$methodParameters = @{
    ClassName  = 'Win32_NetworkAdapterConfiguration'
    MethodName = 'SetPMTUBHDetect'
    Arguments  = @{ PMTUBHDetectEnabled = $false }
    WhatIf     = $true  # Retirez cette ligne pour exécuter réellement la méthode
}
$result = Invoke-CimMethod @methodParameters

# Avec -WhatIf, rien n'est exécuté et aucun résultat n'est renvoyé
if ($result) {
    $returnValueName = @{
        0 = 'Successful completion, no reboot required'
        1 = 'Successful completion, reboot required'
        64 = 'Method not supported on this platform'
        65 = 'Unknown failure'
        66 = 'Invalid subnet mask'
        67 = 'An error occurred while processing an Instance that was returned'
        68 = 'Invalid input parameter'
        69 = 'More than 5 gateways specified'
        70 = 'Invalid IP address'
        71 = 'Invalid gateway IP address'
        72 = 'An error occurred while accessing the Registry for the…'
        73 = 'Invalid domain name'
        74 = 'Invalid host name'
        75 = 'No primary/secondary WINS server defined'
        76 = 'Invalid file'
        77 = 'Invalid system path'
        78 = 'File copy failed'
        79 = 'Invalid security parameter'
        80 = 'Unable to configure TCP/IP service'
        81 = 'Unable to configure DHCP service'
        82 = 'Unable to renew DHCP lease'
        83 = 'Unable to release DHCP lease'
        84 = 'IP not enabled on adapter'
        85 = 'IPX not enabled on adapter'
        86 = 'Frame/network number bounds error'
        87 = 'Invalid frame type'
        88 = 'Invalid network number'
        89 = 'Duplicate network number'
        90 = 'Parameter out of bounds'
        91 = 'Access denied'
        92 = 'Out of memory'
        93 = 'Already exists'
        94 = 'Path, file or object not found'
        95 = 'Unable to notify service'
        96 = 'Unable to notify DNS service'
        97 = 'Interface not configurable'
        98 = 'Not all DHCP leases could be released/renewed'
        100 = 'DHCP not enabled on adapter'
    }
    $returnValueName[[int]$result.ReturnValue]
}

Cette méthode peut modifier le système. Le paramètre -WhatIf affiche l'opération sans l'exécuter : retirez-le seulement après vérification.

SetPMTUDiscovery statique#

Active la découverte de l'unité de transmission maximale (MTU).

uint32 SetPMTUDiscovery([in] boolean PMTUDiscoveryEnabled);

Paramètres

ParamètreTypeSensDescription
PMTUDiscoveryEnabledbooleanentrée

Si true, TCP est activé pour tenter de détecter l'unité de transmission maximale (MTU), c'est-à-dire la taille de paquet la plus grande sur le chemin vers un hôte distant. La valeur par défaut est true.

Codes de retour

ValeurLibelléDescription
0Successful completion, no reboot required
1Successful completion, reboot required
64Method not supported on this platform
65Unknown failure
66Invalid subnet mask
67An error occurred while processing an Instance that was returned
68Invalid input parameter
69More than 5 gateways specifiedPlus de cinq passerelles spécifiées.
70Invalid IP address
71Invalid gateway IP address
72An error occurred while accessing the Registry for the requested information
73Invalid domain name
74Invalid host name
75No primary/secondary WINS server definedAucun serveur WINS principal ou secondaire défini.
76Invalid file
77Invalid system path
78File copy failed
79Invalid security parameter
80Unable to configure TCP/IP service
81Unable to configure DHCP service
82Unable to renew DHCP lease
83Unable to release DHCP lease
84IP not enabled on adapter
85IPX not enabled on adapter
86Frame/network number bounds errorErreur de limite de trame ou de numéro de réseau.
87Invalid frame type
88Invalid network number
89Duplicate network number
90Parameter out of bounds
91Access denied
92Out of memory
93Already exists
94Path, file or object not foundChemin, fichier ou objet introuvable.
95Unable to notify service
96Unable to notify DNS service
97Interface not configurable
98Not all DHCP leases could be released/renewedTous les baux DHCP n'ont pas pu être libérés ou renouvelés.
100DHCP not enabled on adapter
101..4294967295Other

Appeler la méthode SetPMTUDiscovery

à vérifier avant exécution
# Attention : cette méthode peut modifier le système. -WhatIf affiche l'opération sans l'exécuter.
$methodParameters = @{
    ClassName  = 'Win32_NetworkAdapterConfiguration'
    MethodName = 'SetPMTUDiscovery'
    Arguments  = @{ PMTUDiscoveryEnabled = $false }
    WhatIf     = $true  # Retirez cette ligne pour exécuter réellement la méthode
}
$result = Invoke-CimMethod @methodParameters

# Avec -WhatIf, rien n'est exécuté et aucun résultat n'est renvoyé
if ($result) {
    $returnValueName = @{
        0 = 'Successful completion, no reboot required'
        1 = 'Successful completion, reboot required'
        64 = 'Method not supported on this platform'
        65 = 'Unknown failure'
        66 = 'Invalid subnet mask'
        67 = 'An error occurred while processing an Instance that was returned'
        68 = 'Invalid input parameter'
        69 = 'More than 5 gateways specified'
        70 = 'Invalid IP address'
        71 = 'Invalid gateway IP address'
        72 = 'An error occurred while accessing the Registry for the…'
        73 = 'Invalid domain name'
        74 = 'Invalid host name'
        75 = 'No primary/secondary WINS server defined'
        76 = 'Invalid file'
        77 = 'Invalid system path'
        78 = 'File copy failed'
        79 = 'Invalid security parameter'
        80 = 'Unable to configure TCP/IP service'
        81 = 'Unable to configure DHCP service'
        82 = 'Unable to renew DHCP lease'
        83 = 'Unable to release DHCP lease'
        84 = 'IP not enabled on adapter'
        85 = 'IPX not enabled on adapter'
        86 = 'Frame/network number bounds error'
        87 = 'Invalid frame type'
        88 = 'Invalid network number'
        89 = 'Duplicate network number'
        90 = 'Parameter out of bounds'
        91 = 'Access denied'
        92 = 'Out of memory'
        93 = 'Already exists'
        94 = 'Path, file or object not found'
        95 = 'Unable to notify service'
        96 = 'Unable to notify DNS service'
        97 = 'Interface not configurable'
        98 = 'Not all DHCP leases could be released/renewed'
        100 = 'DHCP not enabled on adapter'
    }
    $returnValueName[[int]$result.ReturnValue]
}

Cette méthode peut modifier le système. Le paramètre -WhatIf affiche l'opération sans l'exécuter : retirez-le seulement après vérification.

SetTcpipNetbios #

Définit le fonctionnement par défaut de NetBIOS sur TCP/IP.

uint32 SetTcpipNetbios([in] uint32 TcpipNetbiosOptions);

Paramètres

ParamètreTypeSensDescription
TcpipNetbiosOptionsuint32entrée

Valeur qui spécifie les paramètres possibles liés à NetBIOS sur TCP/IP.

Codes de retour

ValeurLibelléDescription
0Successful completion, no reboot requiredExécution réussie. Aucun redémarrage requis.
1Successful completion, reboot requiredExécution réussie. Redémarrage requis.
64Method not supported on this platform
65Unknown failure
66Invalid subnet mask
67An error occurred while processing an Instance that was returned
68Invalid input parameter
69More than 5 gateways specifiedPlus de cinq passerelles spécifiées.
70Invalid IP address
71Invalid gateway IP address
72An error occurred while accessing the Registry for the requested information
73Invalid domain name
74Invalid host name
75No primary/secondary WINS server definedAucun serveur WINS principal ou secondaire défini.
76Invalid file
77Invalid system path
78File copy failed
79Invalid security parameter
80Unable to configure TCP/IP service
81Unable to configure DHCP service
82Unable to renew DHCP lease
83Unable to release DHCP lease
84IP not enabled on adapter
85IPX not enabled on adapter
86Frame/network number bounds errorErreur de limite de trame ou de numéro de réseau.
87Invalid frame type
88Invalid network number
89Duplicate network number
90Parameter out of bounds
91Access denied
92Out of memory
93Already exists
94Path, file or object not foundChemin, fichier ou objet introuvable.
95Unable to notify service
96Unable to notify DNS service
97Interface not configurable
98Not all DHCP leases could be released/renewedTous les baux DHCP ne peuvent pas être libérés ou renouvelés.
100DHCP not enabled on adapter
101..4294967295Other

Appeler la méthode SetTcpipNetbios

à vérifier avant exécution
# Attention : cette méthode peut modifier le système. -WhatIf affiche l'opération sans l'exécuter.
# Instance cible
$instance = Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Filter 'IPEnabled = TRUE'
$methodParameters = @{
    InputObject = $instance
    MethodName  = 'SetTcpipNetbios'
    Arguments   = @{ TcpipNetbiosOptions = 1 }
    WhatIf      = $true  # Retirez cette ligne pour exécuter réellement la méthode
}
$result = Invoke-CimMethod @methodParameters

# Avec -WhatIf, rien n'est exécuté et aucun résultat n'est renvoyé
if ($result) {
    $returnValueName = @{
        0 = 'Successful completion, no reboot required'
        1 = 'Successful completion, reboot required'
        64 = 'Method not supported on this platform'
        65 = 'Unknown failure'
        66 = 'Invalid subnet mask'
        67 = 'An error occurred while processing an Instance that was returned'
        68 = 'Invalid input parameter'
        69 = 'More than 5 gateways specified'
        70 = 'Invalid IP address'
        71 = 'Invalid gateway IP address'
        72 = 'An error occurred while accessing the Registry for the…'
        73 = 'Invalid domain name'
        74 = 'Invalid host name'
        75 = 'No primary/secondary WINS server defined'
        76 = 'Invalid file'
        77 = 'Invalid system path'
        78 = 'File copy failed'
        79 = 'Invalid security parameter'
        80 = 'Unable to configure TCP/IP service'
        81 = 'Unable to configure DHCP service'
        82 = 'Unable to renew DHCP lease'
        83 = 'Unable to release DHCP lease'
        84 = 'IP not enabled on adapter'
        85 = 'IPX not enabled on adapter'
        86 = 'Frame/network number bounds error'
        87 = 'Invalid frame type'
        88 = 'Invalid network number'
        89 = 'Duplicate network number'
        90 = 'Parameter out of bounds'
        91 = 'Access denied'
        92 = 'Out of memory'
        93 = 'Already exists'
        94 = 'Path, file or object not found'
        95 = 'Unable to notify service'
        96 = 'Unable to notify DNS service'
        97 = 'Interface not configurable'
        98 = 'Not all DHCP leases could be released/renewed'
        100 = 'DHCP not enabled on adapter'
    }
    $returnValueName[[int]$result.ReturnValue]
}

Cette méthode peut modifier le système. Le paramètre -WhatIf affiche l'opération sans l'exécuter : retirez-le seulement après vérification.

SetTcpMaxConnectRetransmissions statique#

Définit le nombre de tentatives de retransmission d'une demande de connexion par TCP avant l'abandon.

uint32 SetTcpMaxConnectRetransmissions([in] uint32 TcpMaxConnectRetransmissions);

Paramètres

ParamètreTypeSensDescription
TcpMaxConnectRetransmissionsuint32entrée

Nombre de tentatives de retransmission d'une demande de connexion par TCP avant l'abandon. La plage de valeurs valides est comprise entre 0 et 0xFFFFFFFF.

Codes de retour

ValeurLibelléDescription
0Successful completion, no reboot required
1Successful completion, reboot required
64Method not supported on this platform
65Unknown failure
66Invalid subnet mask
67An error occurred while processing an Instance that was returned
68Invalid input parameter
69More than 5 gateways specifiedPlus de cinq passerelles spécifiées.
70Invalid IP address
71Invalid gateway IP address
72An error occurred while accessing the Registry for the requested information
73Invalid domain name
74Invalid host name
75No primary/secondary WINS server definedAucun serveur WINS principal ou secondaire défini.
76Invalid file
77Invalid system path
78File copy failed
79Invalid security parameter
80Unable to configure TCP/IP service
81Unable to configure DHCP service
82Unable to renew DHCP lease
83Unable to release DHCP lease
84IP not enabled on adapter
85IPX not enabled on adapter
86Frame/network number bounds errorErreur de limite de trame ou de numéro de réseau.
87Invalid frame type
88Invalid network number
89Duplicate network number
90Parameter out of bounds
91Access denied
92Out of memory
93Already exists
94Path, file or object not foundChemin, fichier ou objet introuvable.
95Unable to notify service
96Unable to notify DNS service
97Interface not configurable
98Not all DHCP leases could be released/renewedTous les baux DHCP n'ont pas pu être libérés ou renouvelés.
100DHCP not enabled on adapter
101..4294967295Other

Appeler la méthode SetTcpMaxConnectRetransmissions

à vérifier avant exécution
# Attention : cette méthode peut modifier le système. -WhatIf affiche l'opération sans l'exécuter.
$methodParameters = @{
    ClassName  = 'Win32_NetworkAdapterConfiguration'
    MethodName = 'SetTcpMaxConnectRetransmissions'
    Arguments  = @{ TcpMaxConnectRetransmissions = 0 }
    WhatIf     = $true  # Retirez cette ligne pour exécuter réellement la méthode
}
$result = Invoke-CimMethod @methodParameters

# Avec -WhatIf, rien n'est exécuté et aucun résultat n'est renvoyé
if ($result) {
    $returnValueName = @{
        0 = 'Successful completion, no reboot required'
        1 = 'Successful completion, reboot required'
        64 = 'Method not supported on this platform'
        65 = 'Unknown failure'
        66 = 'Invalid subnet mask'
        67 = 'An error occurred while processing an Instance that was returned'
        68 = 'Invalid input parameter'
        69 = 'More than 5 gateways specified'
        70 = 'Invalid IP address'
        71 = 'Invalid gateway IP address'
        72 = 'An error occurred while accessing the Registry for the…'
        73 = 'Invalid domain name'
        74 = 'Invalid host name'
        75 = 'No primary/secondary WINS server defined'
        76 = 'Invalid file'
        77 = 'Invalid system path'
        78 = 'File copy failed'
        79 = 'Invalid security parameter'
        80 = 'Unable to configure TCP/IP service'
        81 = 'Unable to configure DHCP service'
        82 = 'Unable to renew DHCP lease'
        83 = 'Unable to release DHCP lease'
        84 = 'IP not enabled on adapter'
        85 = 'IPX not enabled on adapter'
        86 = 'Frame/network number bounds error'
        87 = 'Invalid frame type'
        88 = 'Invalid network number'
        89 = 'Duplicate network number'
        90 = 'Parameter out of bounds'
        91 = 'Access denied'
        92 = 'Out of memory'
        93 = 'Already exists'
        94 = 'Path, file or object not found'
        95 = 'Unable to notify service'
        96 = 'Unable to notify DNS service'
        97 = 'Interface not configurable'
        98 = 'Not all DHCP leases could be released/renewed'
        100 = 'DHCP not enabled on adapter'
    }
    $returnValueName[[int]$result.ReturnValue]
}

Cette méthode peut modifier le système. Le paramètre -WhatIf affiche l'opération sans l'exécuter : retirez-le seulement après vérification.

SetTcpMaxDataRetransmissions statique#

Définit le nombre de fois où TCP retransmet un segment de données individuel avant d'abandonner la connexion.

uint32 SetTcpMaxDataRetransmissions([in] uint32 TcpMaxDataRetransmissions);

Paramètres

ParamètreTypeSensDescription
TcpMaxDataRetransmissionsuint32entrée

Nombre de fois où TCP retransmet un segment de données individuel avant d'abandonner la connexion. Plage valide : 0 - 0xFFFFFFFF.

Codes de retour

ValeurLibelléDescription
0Successful completion, no reboot required
1Successful completion, reboot required
64Method not supported on this platform
65Unknown failure
66Invalid subnet mask
67An error occurred while processing an Instance that was returned
68Invalid input parameter
69More than 5 gateways specifiedPlus de cinq passerelles spécifiées.
70Invalid IP address
71Invalid gateway IP address
72An error occurred while accessing the Registry for the requested information
73Invalid domain name
74Invalid host name
75No primary/secondary WINS server definedAucun serveur WINS principal ou secondaire défini.
76Invalid file
77Invalid system path
78File copy failed
79Invalid security parameter
80Unable to configure TCP/IP service
81Unable to configure DHCP service
82Unable to renew DHCP lease
83Unable to release DHCP lease
84IP not enabled on adapter
85IPX not enabled on adapter
86Frame/network number bounds errorErreur de limite de trame ou de numéro de réseau.
87Invalid frame type
88Invalid network number
89Duplicate network number
90Parameter out of bounds
91Access denied
92Out of memory
93Already exists
94Path, file or object not foundChemin, fichier ou objet introuvable.
95Unable to notify service
96Unable to notify DNS service
97Interface not configurable
98Not all DHCP leases could be released/renewedTous les baux DHCP n'ont pas pu être libérés ou renouvelés.
100DHCP not enabled on adapter
101..4294967295Other

Appeler la méthode SetTcpMaxDataRetransmissions

à vérifier avant exécution
# Attention : cette méthode peut modifier le système. -WhatIf affiche l'opération sans l'exécuter.
$methodParameters = @{
    ClassName  = 'Win32_NetworkAdapterConfiguration'
    MethodName = 'SetTcpMaxDataRetransmissions'
    Arguments  = @{ TcpMaxDataRetransmissions = 0 }
    WhatIf     = $true  # Retirez cette ligne pour exécuter réellement la méthode
}
$result = Invoke-CimMethod @methodParameters

# Avec -WhatIf, rien n'est exécuté et aucun résultat n'est renvoyé
if ($result) {
    $returnValueName = @{
        0 = 'Successful completion, no reboot required'
        1 = 'Successful completion, reboot required'
        64 = 'Method not supported on this platform'
        65 = 'Unknown failure'
        66 = 'Invalid subnet mask'
        67 = 'An error occurred while processing an Instance that was returned'
        68 = 'Invalid input parameter'
        69 = 'More than 5 gateways specified'
        70 = 'Invalid IP address'
        71 = 'Invalid gateway IP address'
        72 = 'An error occurred while accessing the Registry for the…'
        73 = 'Invalid domain name'
        74 = 'Invalid host name'
        75 = 'No primary/secondary WINS server defined'
        76 = 'Invalid file'
        77 = 'Invalid system path'
        78 = 'File copy failed'
        79 = 'Invalid security parameter'
        80 = 'Unable to configure TCP/IP service'
        81 = 'Unable to configure DHCP service'
        82 = 'Unable to renew DHCP lease'
        83 = 'Unable to release DHCP lease'
        84 = 'IP not enabled on adapter'
        85 = 'IPX not enabled on adapter'
        86 = 'Frame/network number bounds error'
        87 = 'Invalid frame type'
        88 = 'Invalid network number'
        89 = 'Duplicate network number'
        90 = 'Parameter out of bounds'
        91 = 'Access denied'
        92 = 'Out of memory'
        93 = 'Already exists'
        94 = 'Path, file or object not found'
        95 = 'Unable to notify service'
        96 = 'Unable to notify DNS service'
        97 = 'Interface not configurable'
        98 = 'Not all DHCP leases could be released/renewed'
        100 = 'DHCP not enabled on adapter'
    }
    $returnValueName[[int]$result.ReturnValue]
}

Cette méthode peut modifier le système. Le paramètre -WhatIf affiche l'opération sans l'exécuter : retirez-le seulement après vérification.

SetTcpNumConnections statique#

Définit le nombre maximal de connexions que TCP peut avoir ouvertes simultanément.

uint32 SetTcpNumConnections([in] uint32 TcpNumConnections);

Paramètres

ParamètreTypeSensDescription
TcpNumConnectionsuint32entrée

Nombre maximal de connexions que TCP peut avoir ouvertes simultanément. La plage de valeurs valides est comprise entre 0 et 0xFFFFFE.

Codes de retour

ValeurLibelléDescription
0Successful completion, no reboot required
1Successful completion, reboot required
64Method not supported on this platform
65Unknown failure
66Invalid subnet mask
67An error occurred while processing an Instance that was returned
68Invalid input parameter
69More than 5 gateways specifiedPlus de cinq passerelles spécifiées.
70Invalid IP address
71Invalid gateway IP address
72An error occurred while accessing the Registry for the requested information
73Invalid domain name
74Invalid host name
75No primary/secondary WINS server definedAucun serveur WINS principal ou secondaire défini.
76Invalid file
77Invalid system path
78File copy failed
79Invalid security parameter
80Unable to configure TCP/IP service
81Unable to configure DHCP service
82Unable to renew DHCP lease
83Unable to release DHCP lease
84IP not enabled on adapter
85IPX not enabled on adapter
86Frame/network number bounds errorErreur de limite de trame ou de numéro de réseau.
87Invalid frame type
88Invalid network number
89Duplicate network number
90Parameter out of bounds
91Access denied
92Out of memory
93Already exists
94Path, file or object not foundChemin, fichier ou objet introuvable.
95Unable to notify service
96Unable to notify DNS service
97Interface not configurable
98Not all DHCP leases could be released/renewedTous les baux DHCP n'ont pas pu être libérés ou renouvelés.
100DHCP not enabled on adapter
101..4294967295Other

Appeler la méthode SetTcpNumConnections

à vérifier avant exécution
# Attention : cette méthode peut modifier le système. -WhatIf affiche l'opération sans l'exécuter.
$methodParameters = @{
    ClassName  = 'Win32_NetworkAdapterConfiguration'
    MethodName = 'SetTcpNumConnections'
    Arguments  = @{ TcpNumConnections = 0 }
    WhatIf     = $true  # Retirez cette ligne pour exécuter réellement la méthode
}
$result = Invoke-CimMethod @methodParameters

# Avec -WhatIf, rien n'est exécuté et aucun résultat n'est renvoyé
if ($result) {
    $returnValueName = @{
        0 = 'Successful completion, no reboot required'
        1 = 'Successful completion, reboot required'
        64 = 'Method not supported on this platform'
        65 = 'Unknown failure'
        66 = 'Invalid subnet mask'
        67 = 'An error occurred while processing an Instance that was returned'
        68 = 'Invalid input parameter'
        69 = 'More than 5 gateways specified'
        70 = 'Invalid IP address'
        71 = 'Invalid gateway IP address'
        72 = 'An error occurred while accessing the Registry for the…'
        73 = 'Invalid domain name'
        74 = 'Invalid host name'
        75 = 'No primary/secondary WINS server defined'
        76 = 'Invalid file'
        77 = 'Invalid system path'
        78 = 'File copy failed'
        79 = 'Invalid security parameter'
        80 = 'Unable to configure TCP/IP service'
        81 = 'Unable to configure DHCP service'
        82 = 'Unable to renew DHCP lease'
        83 = 'Unable to release DHCP lease'
        84 = 'IP not enabled on adapter'
        85 = 'IPX not enabled on adapter'
        86 = 'Frame/network number bounds error'
        87 = 'Invalid frame type'
        88 = 'Invalid network number'
        89 = 'Duplicate network number'
        90 = 'Parameter out of bounds'
        91 = 'Access denied'
        92 = 'Out of memory'
        93 = 'Already exists'
        94 = 'Path, file or object not found'
        95 = 'Unable to notify service'
        96 = 'Unable to notify DNS service'
        97 = 'Interface not configurable'
        98 = 'Not all DHCP leases could be released/renewed'
        100 = 'DHCP not enabled on adapter'
    }
    $returnValueName[[int]$result.ReturnValue]
}

Cette méthode peut modifier le système. Le paramètre -WhatIf affiche l'opération sans l'exécuter : retirez-le seulement après vérification.

SetTcpUseRFC1122UrgentPointer statique#

Spécifie si TCP utilise la spécification RFC 1122 pour les données urgentes ou le mode utilisé par les systèmes dérivés de Berkeley Software Design (BSD).

uint32 SetTcpUseRFC1122UrgentPointer([in] boolean TcpUseRFC1122UrgentPointer);

Paramètres

ParamètreTypeSensDescription
TcpUseRFC1122UrgentPointerbooleanentrée

Si true, TCP utilise la spécification RFC 1122. Si false, les données urgentes sont envoyées selon le mode utilisé par les systèmes dérivés de BSD.

Codes de retour

ValeurLibelléDescription
0Successful completion, no reboot required
1Successful completion, reboot required
64Method not supported on this platform
65Unknown failure
66Invalid subnet mask
67An error occurred while processing an Instance that was returned
68Invalid input parameter
69More than 5 gateways specifiedPlus de cinq passerelles spécifiées.
70Invalid IP address
71Invalid gateway IP address
72An error occurred while accessing the Registry for the requested information
73Invalid domain name
74Invalid host name
75No primary/secondary WINS server definedAucun serveur WINS principal ou secondaire défini.
76Invalid file
77Invalid system path
78File copy failed
79Invalid security parameter
80Unable to configure TCP/IP service
81Unable to configure DHCP service
82Unable to renew DHCP lease
83Unable to release DHCP lease
84IP not enabled on adapter
85IPX not enabled on adapter
86Frame/network number bounds errorErreur de limite de trame ou de numéro de réseau.
87Invalid frame type
88Invalid network number
89Duplicate network number
90Parameter out of bounds
91Access denied
92Out of memory
93Already exists
94Path, file or object not foundChemin, fichier ou objet introuvable.
95Unable to notify service
96Unable to notify DNS service
97Interface not configurable
98Not all DHCP leases could be released/renewedTous les baux DHCP n'ont pas pu être libérés ou renouvelés.
100DHCP not enabled on adapter
101..4294967295Other

Appeler la méthode SetTcpUseRFC1122UrgentPointer

à vérifier avant exécution
# Attention : cette méthode peut modifier le système. -WhatIf affiche l'opération sans l'exécuter.
$methodParameters = @{
    ClassName  = 'Win32_NetworkAdapterConfiguration'
    MethodName = 'SetTcpUseRFC1122UrgentPointer'
    Arguments  = @{ TcpUseRFC1122UrgentPointer = $false }
    WhatIf     = $true  # Retirez cette ligne pour exécuter réellement la méthode
}
$result = Invoke-CimMethod @methodParameters

# Avec -WhatIf, rien n'est exécuté et aucun résultat n'est renvoyé
if ($result) {
    $returnValueName = @{
        0 = 'Successful completion, no reboot required'
        1 = 'Successful completion, reboot required'
        64 = 'Method not supported on this platform'
        65 = 'Unknown failure'
        66 = 'Invalid subnet mask'
        67 = 'An error occurred while processing an Instance that was returned'
        68 = 'Invalid input parameter'
        69 = 'More than 5 gateways specified'
        70 = 'Invalid IP address'
        71 = 'Invalid gateway IP address'
        72 = 'An error occurred while accessing the Registry for the…'
        73 = 'Invalid domain name'
        74 = 'Invalid host name'
        75 = 'No primary/secondary WINS server defined'
        76 = 'Invalid file'
        77 = 'Invalid system path'
        78 = 'File copy failed'
        79 = 'Invalid security parameter'
        80 = 'Unable to configure TCP/IP service'
        81 = 'Unable to configure DHCP service'
        82 = 'Unable to renew DHCP lease'
        83 = 'Unable to release DHCP lease'
        84 = 'IP not enabled on adapter'
        85 = 'IPX not enabled on adapter'
        86 = 'Frame/network number bounds error'
        87 = 'Invalid frame type'
        88 = 'Invalid network number'
        89 = 'Duplicate network number'
        90 = 'Parameter out of bounds'
        91 = 'Access denied'
        92 = 'Out of memory'
        93 = 'Already exists'
        94 = 'Path, file or object not found'
        95 = 'Unable to notify service'
        96 = 'Unable to notify DNS service'
        97 = 'Interface not configurable'
        98 = 'Not all DHCP leases could be released/renewed'
        100 = 'DHCP not enabled on adapter'
    }
    $returnValueName[[int]$result.ReturnValue]
}

Cette méthode peut modifier le système. Le paramètre -WhatIf affiche l'opération sans l'exécuter : retirez-le seulement après vérification.

SetTcpWindowSize statique#

Définit la taille maximale de la fenêtre de réception TCP proposée par le système.

uint32 SetTcpWindowSize([in] uint16 TcpWindowSize);

Paramètres

ParamètreTypeSensDescription
TcpWindowSizeuint16entrée

Taille maximale de la fenêtre de réception TCP proposée par le système. La plage de valeurs valides, en octets, est comprise entre 0 et 65535.

Codes de retour

ValeurLibelléDescription
0Successful completion, no reboot required
1Successful completion, reboot required
64Method not supported on this platform
65Unknown failure
66Invalid subnet mask
67An error occurred while processing an Instance that was returned
68Invalid input parameter
69More than 5 gateways specifiedPlus de cinq passerelles spécifiées.
70Invalid IP address
71Invalid gateway IP address
72An error occurred while accessing the Registry for the requested information
73Invalid domain name
74Invalid host name
75No primary/secondary WINS server definedAucun serveur WINS principal ou secondaire défini.
76Invalid file
77Invalid system path
78File copy failed
79Invalid security parameter
80Unable to configure TCP/IP service
81Unable to configure DHCP service
82Unable to renew DHCP lease
83Unable to release DHCP lease
84IP not enabled on adapter
85IPX not enabled on adapter
86Frame/network number bounds errorErreur de limite de trame ou de numéro de réseau.
87Invalid frame type
88Invalid network number
89Duplicate network number
90Parameter out of bounds
91Access denied
92Out of memory
93Already exists
94Path, file or object not foundChemin, fichier ou objet introuvable.
95Unable to notify service
96Unable to notify DNS service
97Interface not configurable
98Not all DHCP leases could be released/renewedTous les baux DHCP n'ont pas pu être libérés ou renouvelés.
100DHCP not enabled on adapter
101..4294967295Other

Appeler la méthode SetTcpWindowSize

à vérifier avant exécution
# Attention : cette méthode peut modifier le système. -WhatIf affiche l'opération sans l'exécuter.
$methodParameters = @{
    ClassName  = 'Win32_NetworkAdapterConfiguration'
    MethodName = 'SetTcpWindowSize'
    Arguments  = @{ TcpWindowSize = 0 }
    WhatIf     = $true  # Retirez cette ligne pour exécuter réellement la méthode
}
$result = Invoke-CimMethod @methodParameters

# Avec -WhatIf, rien n'est exécuté et aucun résultat n'est renvoyé
if ($result) {
    $returnValueName = @{
        0 = 'Successful completion, no reboot required'
        1 = 'Successful completion, reboot required'
        64 = 'Method not supported on this platform'
        65 = 'Unknown failure'
        66 = 'Invalid subnet mask'
        67 = 'An error occurred while processing an Instance that was returned'
        68 = 'Invalid input parameter'
        69 = 'More than 5 gateways specified'
        70 = 'Invalid IP address'
        71 = 'Invalid gateway IP address'
        72 = 'An error occurred while accessing the Registry for the…'
        73 = 'Invalid domain name'
        74 = 'Invalid host name'
        75 = 'No primary/secondary WINS server defined'
        76 = 'Invalid file'
        77 = 'Invalid system path'
        78 = 'File copy failed'
        79 = 'Invalid security parameter'
        80 = 'Unable to configure TCP/IP service'
        81 = 'Unable to configure DHCP service'
        82 = 'Unable to renew DHCP lease'
        83 = 'Unable to release DHCP lease'
        84 = 'IP not enabled on adapter'
        85 = 'IPX not enabled on adapter'
        86 = 'Frame/network number bounds error'
        87 = 'Invalid frame type'
        88 = 'Invalid network number'
        89 = 'Duplicate network number'
        90 = 'Parameter out of bounds'
        91 = 'Access denied'
        92 = 'Out of memory'
        93 = 'Already exists'
        94 = 'Path, file or object not found'
        95 = 'Unable to notify service'
        96 = 'Unable to notify DNS service'
        97 = 'Interface not configurable'
        98 = 'Not all DHCP leases could be released/renewed'
        100 = 'DHCP not enabled on adapter'
    }
    $returnValueName[[int]$result.ReturnValue]
}

Cette méthode peut modifier le système. Le paramètre -WhatIf affiche l'opération sans l'exécuter : retirez-le seulement après vérification.

SetWINSServer #

Définit les serveurs WINS (Windows Internet Naming Service) principal et secondaire sur cet adaptateur réseau lié à TCP/IP.

uint32 SetWINSServer([in] string WINSPrimaryServer, [in] string WINSSecondaryServer);

Paramètres

ParamètreTypeSensDescription
WINSPrimaryServerstringentrée

Adresse IP du serveur WINS principal.

Remarque : vérifiez toujours la validité de cette adresse IP lorsqu'elle provient d'une source inconnue ou non fiable.

WINSSecondaryServerstringentrée

Adresse IP du serveur WINS secondaire.

Remarque : vérifiez toujours la validité de cette adresse IP lorsqu'elle provient d'une source inconnue ou non fiable.

Codes de retour

ValeurLibelléDescription
0Successful completion, no reboot required
1Successful completion, reboot required
64Method not supported on this platform
65Unknown failure
66Invalid subnet mask
67An error occurred while processing an Instance that was returned
68Invalid input parameter
69More than 5 gateways specifiedPlus de cinq passerelles spécifiées.
70Invalid IP address
71Invalid gateway IP address
72An error occurred while accessing the Registry for the requested information
73Invalid domain name
74Invalid host name
75No primary/secondary WINS server definedAucun serveur WINS principal ou secondaire défini.
76Invalid file
77Invalid system path
78File copy failed
79Invalid security parameter
80Unable to configure TCP/IP service
81Unable to configure DHCP service
82Unable to renew DHCP lease
83Unable to release DHCP lease
84IP not enabled on adapter
85IPX not enabled on adapter
86Frame/network number bounds errorErreur de limite de trame ou de numéro de réseau.
87Invalid frame type
88Invalid network number
89Duplicate network number
90Parameter out of bounds
91Access denied
92Out of memory
93Already exists
94Path, file or object not foundChemin, fichier ou objet introuvable.
95Unable to notify service
96Unable to notify DNS service
97Interface not configurable
98Not all DHCP leases could be released/renewedTous les baux DHCP n'ont pas pu être libérés ou renouvelés.
100DHCP not enabled on adapter
101..4294967295Other

Appeler la méthode SetWINSServer

à vérifier avant exécution
# Attention : cette méthode peut modifier le système. -WhatIf affiche l'opération sans l'exécuter.
# Instance cible
$instance = Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Filter 'IPEnabled = TRUE'
$methodParameters = @{
    InputObject = $instance
    MethodName  = 'SetWINSServer'
    Arguments   = @{
        WINSPrimaryServer   = 'Example'
        WINSSecondaryServer = 'Example'
    }
    WhatIf      = $true  # Retirez cette ligne pour exécuter réellement la méthode
}
$result = Invoke-CimMethod @methodParameters

# Avec -WhatIf, rien n'est exécuté et aucun résultat n'est renvoyé
if ($result) {
    $returnValueName = @{
        0 = 'Successful completion, no reboot required'
        1 = 'Successful completion, reboot required'
        64 = 'Method not supported on this platform'
        65 = 'Unknown failure'
        66 = 'Invalid subnet mask'
        67 = 'An error occurred while processing an Instance that was returned'
        68 = 'Invalid input parameter'
        69 = 'More than 5 gateways specified'
        70 = 'Invalid IP address'
        71 = 'Invalid gateway IP address'
        72 = 'An error occurred while accessing the Registry for the…'
        73 = 'Invalid domain name'
        74 = 'Invalid host name'
        75 = 'No primary/secondary WINS server defined'
        76 = 'Invalid file'
        77 = 'Invalid system path'
        78 = 'File copy failed'
        79 = 'Invalid security parameter'
        80 = 'Unable to configure TCP/IP service'
        81 = 'Unable to configure DHCP service'
        82 = 'Unable to renew DHCP lease'
        83 = 'Unable to release DHCP lease'
        84 = 'IP not enabled on adapter'
        85 = 'IPX not enabled on adapter'
        86 = 'Frame/network number bounds error'
        87 = 'Invalid frame type'
        88 = 'Invalid network number'
        89 = 'Duplicate network number'
        90 = 'Parameter out of bounds'
        91 = 'Access denied'
        92 = 'Out of memory'
        93 = 'Already exists'
        94 = 'Path, file or object not found'
        95 = 'Unable to notify service'
        96 = 'Unable to notify DNS service'
        97 = 'Interface not configurable'
        98 = 'Not all DHCP leases could be released/renewed'
        100 = 'DHCP not enabled on adapter'
    }
    $returnValueName[[int]$result.ReturnValue]
}

Cette méthode peut modifier le système. Le paramètre -WhatIf affiche l'opération sans l'exécuter : retirez-le seulement après vérification.

Remarques

The Win32_NetworkAdapterConfiguration class is derived from CIM_Setting.

Héritage

Chaîne des superclasses

  1. CIM_Setting
  2. Win32_NetworkAdapterConfiguration

Sous-classes connues

Aucune sous-classe connue.

Prérequis

Espace de noms
root/cimv2
Client minimum
Windows Vista
Serveur minimum
Windows Server 2008
Fournisseur
CIMWin32
Fichier MOF
CIMWin32.mof
DLL
CIMWin32.dll
Qualificateurs de classe

Dynamic Provider("CIMWin32") UUID("{8502C515-5FBB-11D2-AAC1-006008C78BC7}") AMENDMENT

Source Microsoft

Source : Microsoft Learn

Les descriptions, propriétés et méthodes proviennent de la documentation Microsoft (dépôt MicrosoftDocs/win32), publiée sous licence CC BY 4.0. La mise en forme et les traductions sont propres à ce site ; les exemples PowerShell y sont rédigés.