Set-VMHostNetwork
This cmdlet updates the specified virtual network. The service console and the VMkernel are often not connected to the same network, and therefore each needs its own gateway information. A gateway is needed for connectivity to machines not on the same IP subnet as the service console or VMkernel.
Syntax
[-ConsoleGateway <String>]
[-ConsoleGatewayDevice <String>]
[-ConsoleV6Gateway <String>]
[-ConsoleV6GatewayDevice <String>]
[-DnsAddress <String[]>]
[-DnsDhcpDevice <Object>]
[-DnsFromDhcp <Boolean>]
[-DomainName <String>]
[-HostName <String>]
[-IPv6Enabled <Boolean>]
[-SearchDomain <String[]>]
[-VMKernelGateway <String>]
[-VMKernelGatewayDevice <String>]
[-VMKernelV6Gateway <String>]
[-VMKernelV6GatewayDevice <String>]
[CommonParameters]
Parameters
Required | Parameter Name | Type | Position | Features | Description |
---|---|---|---|---|---|
required |
|
VMHostNetworkInfo[] | named |
|
Specifies the host network you want to configure. | optional |
|
String | named |
|
Specifies a new console gateway. | optional |
|
String | named |
|
Specifies a new console gateway device. | optional |
|
String | named |
|
Specifies a console V6 gateway address. Not supported on ESXi. | optional |
|
String | named |
|
Specifies a console V6 gateway device. Not supported on ESXi. | optional |
|
String[] | named |
|
Specifies a new DNS address. | optional |
|
Object | named |
|
This parameter is mandatory if the value of the DnsFromDhcp parameter is 'true'. Otherwise, it is disregarded. If the DnsDhcpDevice parameter is set, the Dhcp DNS of the service console or VMKernel network adapter will override the system DNS. The parameter takes a ServiceConsoleNIC object, a VMKernelNIC object in case of an ESX visor, or the NIC name as a string. | optional |
|
Boolean | named |
|
Indicates that you want to obtain the network settings from a Dhcp server. | optional |
|
String | named |
|
Specifies a new domain name. | optional |
|
String | named |
|
Specifies a new host name. | optional |
|
Boolean | named |
|
Indicates that IPv6 configuration is enabled. Setting this parameter to $false deactivates the ConsoleV6Gateway, ConsoleV6GatewayDevice, and VMKernelV6Gateway parameters. IPv6 is supported only on vCenter 4.1 and ESX 4.1 or later. To use IPv6 on ESX, you must restart the host after enabling IPv6. | optional |
|
String[] | named |
|
Specifies a new search domain. | optional |
|
String | named |
|
Specifies a new kernel gateway. | optional |
|
String | named |
|
Specifies a new kernel gateway device. | optional |
|
String | named |
|
Specifies a VMKernel V6 gateway address. This parameter is supported only on ESX hosts. | optional |
|
String | named |
|
Specifies a VMKernel V6 gateway device. This parameter is supported only on ESX hosts. |
Output
VMware.VimAutomation.ViCore.Types.V1.Host.Networking.VMHostNetworkInfo
Examples
Example 1
Gets the network configuration of the virtual machine host named Host. Sets the virtual machine kernel gateway, the domain name, the host name, and the Dhcp of the network.
Example 2
Enables IPv6 support on the Host host and restarts the host.
Example 3
Configures the IPv6 console default gateway on the Host host.
Example 4
Configures the IPv6 VMKernel default gateway on the Host host.
Related Commands
VMHost
VMHostAccount
VMHostAdvancedConfiguration
VMHostAuthentication
VMHostAvailableTimeZone
VMHostDiagnosticPartition
VMHostDisk
VMHostDiskPartition
VMHostFirewallDefaultPolicy
VMHostFirewallException
VMHostFirmware
VMHostHardware
VMHostHba
VMHostModule
VMHostNetwork
VMHostNetworkAdapter
VMHostNetworkStack
VMHostNtpServer
VMHostPatch
VMHostPciDevice
VMHostProfile
VMHostProfileCompliance
VMHostProfileImageCacheConfiguration
VMHostProfileRequiredInput
VMHostProfileStorageDeviceConfiguration
VMHostProfileUserConfiguration
VMHostProfileVmPortGroupConfiguration
VMHostRoute
VMHostService
VMHostSnmp
VMHostStartPolicy
VMHostStorage