-
Notifications
You must be signed in to change notification settings - Fork 88
DefaultGatewayAddress
dscbot edited this page Jun 7, 2024
·
6 revisions
Parameter | Attribute | DataType | Description | Allowed Values |
---|---|---|---|---|
InterfaceAlias | Key | String | Alias of the network interface for which the default gateway address is set. | |
AddressFamily | Key | String | IP address family. |
IPv4 , IPv6
|
Address | Write | String | The desired default gateway address - if not provided default gateway will be removed. |
The resource is responsible for creating and managing the Default Gateway for an interface on a node.
Remove the IPv4 default gateway from the network interface 'Ethernet'.
Configuration DefaultGatewayAddress_RemoveDefaultGateway_Config
{
Import-DscResource -Module NetworkingDsc
Node localhost
{
DefaultGatewayAddress RemoveDefaultGateway
{
InterfaceAlias = 'Ethernet'
AddressFamily = 'IPv4'
}
}
}
Set the IPv4 default gateway of the network interface 'Ethernet' to '192.168.1.1'.
Configuration DefaultGatewayAddress_SetDefaultGateway_Config
{
Import-DscResource -Module NetworkingDsc
Node localhost
{
DefaultGatewayAddress SetDefaultGateway
{
Address = '192.168.1.1'
InterfaceAlias = 'Ethernet'
AddressFamily = 'IPv4'
}
}
}
- DefaultGatewayAddress
- DnsClientGlobalSetting
- DnsConnectionSuffix
- DnsServerAddress
- Firewall
- FirewallProfile
- HostsFile
- IPAddress
- IPAddressOption
- NetAdapterAdvancedProperty
- NetAdapterBinding
- NetAdapterLso
- NetAdapterName
- NetAdapterRdma
- NetAdapterRsc
- NetAdapterRss
- NetAdapterState
- NetBios
- NetConnectionProfile
- NetIPInterface
- NetworkTeam
- NetworkTeamInterface
- ProxySettings
- Route
- WaitForNetworkTeam
- WinsServerAddress
- WinsSetting