Set Interfaces IPv4
Set IPv4 network configuration for specific network interface.
Request
URLURL
Path Parameters
Path Parameters
Network interface to update, for example, “nic0”. The parameter must be an identifier for the resource type: com.vmware.appliance.networking.interfaces.
Header Parameters
Header Parameters
Required session ID, acquired from Create Session API under CIS product
vmware-api-session-id example
"b00db39f948d13ea1e59b4d6fce56389"
Request Body
The IPv4 Network configuration to set.
{
"mode": "DHCP"
}
The Ipv4.Mode enumerated type defines different IPv4 address assignment modes.
DHCP : The IPv4 address is automatically assigned by a DHCP server.
STATIC : The IPv4 address is static.
UNCONFIGURED : The IPv4 protocol is not configured.
Possible values are: DHCP , STATIC , UNCONFIGURED
The IPv4 address, for example, “10.20.80.191”. This field is optional and it is only relevant when the value of Ipv4.Config.mode is STATIC.
The IPv4 address of the default gateway. This configures the global default gateway on the appliance with the specified gateway address and interface. This gateway replaces the existing default gateway configured on the appliance. However, if the gateway address is link-local, then it is added for that interface. This does not support configuration of multiple global default gateways through different interfaces. If unset, the defaultGateway was never set.
The IPv4 CIDR prefix, for example, 24. See http://www.oav.net/mirrors/cidr.html for netmask-to-prefix conversion. This field is optional and it is only relevant when the value of Ipv4.Config.mode is STATIC.
Authentication
Errors
Errors
com.vmware.vapi.std.errors.resource_busy : if the specified NIC is busy. | com.vmware.vapi.std.errors.error : Generic error.
‘Default’ means this response is used for all HTTP codes that are not covered individually for this operation.
Code Samples
cURL Command
Vendor Extensions
x-vmw-doc-deprecated-method: put
x-vmw-doc-deprecated-path: /rest/appliance/networking/interfaces/{interface_name}/ipv4
x-vmw-doc-operation: set