By default, the vCloud Availability Installer Appliance creates VMs with DHCP. You can apply static IP addresses by adding the --vm-address option to any command that deploys an OVF.

About this task

Depending on your environment topology, you may need to create several IP pools. For example, you might need to create one IP pool in the Resource vCenter Server, one in the Management vCenter Server, and another one in the Management vCenter Server for the vCloud Availability for vCloud Director Portal in the DMZ with different network settings. In the current example, we create an IP pool in the Resource vCenter Server. If necessary, repeat the procedure for your Management vCenter Server and the DMZ networks.

You must add an IP Pool and IP Range in the Management or Resource vCenter Server for the network that you want to manage. The IP Pool objects assign all network parameters to VMs, except the IP address. The IP Pool object also ensures that the desired IP is supported on the requested network.

Procedure

  1. List existing IP Pools, defined in your environment.

    Standard Command

    Command Using Registry

    # vcav ip-pool list \
    --vsphere-address=$VSPHERE01_ADDRESS \
    --vsphere-user=$SSO_USER \
    --vsphere-password-file=~/.ssh/.sso
    # vcav ip-pool list --vsphere=vsphere-01-name

    The system displays the following result if you have no IP pools.

    BackingDC
        No IP Pools
    VC4
        No IP Pools
  2. Create an IP pool.

    The values used in the following command are used as examples. Update the values in the command to match your environment.

    Standard Command

    Command Using Registry

    # vcav ip-pool create \
    --vsphere-address=$VSPHERE01_ADDRESS \
    --vsphere-user=$SSO_USER \
    --vsphere-password-file=~/.ssh/.sso \
    --datacenter=VC4 \
    --name=WDC3-Routed \
    --subnet=10.158.12.0 \
    --gateway=10.158.15.253 \
    --netmask=255.255.252.0 \
    "--dns=10.158.12.104,10.158.12.105" \
    "--networks=VM Network"
    # vcav ip-pool create \
    --vsphere=vsphere-01-name \
    --datacenter=VC4 \
    --name=WDC3-Routed \
    --subnet=10.158.12.0 \
    --gateway=10.158.15.253 \
    --netmask=255.255.252.0 \
    "--dns=10.158.12.104,10.158.12.105" \
    "--networks=VM Network" \
    

    You created an IP pool. Running the vcav ip-pool list command now brings the following output.

    BackingDC
        No IP Pools
    VC4
        WDC3-Routed
            Networks:     VM Network
            IPv4 Subnet:  10.158.12.0
            IPv4 Gateway: 10.158.15.253
            IPv4 Netmask: 255.255.252.0
            IPv4 DNS:     10.158.12.104, 10.158.12.105
            IPv4 DHCP:    False

  3. Associate the IP pool object with more networks.

    Standard Command

    Command Using Registry

    # vcav ip-pool update \
    --vsphere-address=$VSPHERE01_ADDRESS \
    --vsphere-user=$SSO_USER \
    --vsphere-password-file=~/.ssh/.sso \
    --datacenter=VC4 \
    --name=WDC3-Routed \
    "--networks=VM Network, Private Network"
    # vcav ip-pool update \
    --vsphere=vsphere-01-name \
    --datacenter=VC4 \
    --name=WDC3-Routed \
    "--networks=VM Network, Private Network"
    

    The associated networks are updated. Running the vcav ip-pool list command now results in the following output:

    BackingDC
        No IP Pools
    VC4
        WDC3-Routed
            Networks:     VM Network, Private Network
            IPv4 Subnet:  10.158.12.0
            IPv4 Gateway: 10.158.15.253
            IPv4 Netmask: 255.255.252.0
            IPv4 DNS:     10.158.12.104, 10.158.12.105
            IPv4 DHCP:    False

Results

You created an IP pool in your environment and can create VMs with static IP addresses by adding --vm-address in any command that deploys an OVF.