Configuring OS Networking through Workflow Steps
This step works with or without an IP address management (IPAM) integration. With IPAM integration, currently only BlueCat™ IPAM is supported.
Required Credentials on Windows
The Configure OS Networking workflow step requires elevated privileges. For Windows, if the credentials used are those of a member of the administrator group, as opposed to the actual administrator account itself, you will likely need to disable UAC (user access control) on your templates.
Required Credentials on Linux
If you supply non-root-user credentials, the sudo command is used. When connecting with either VMware Tools or SSH (which is only useful for configuring secondary network interfaces), Commander supplies the password to the sudo command in advance, so there is no sudo prompt.
Ensure that the
sudoers file on the target VM doesn't contain the following line:
See Port Requirements.
Operating Systems Supported
This step is supported for:
- Windows 2012
- Windows 2008 R2
- SUSE Linux
- Red Hat Linux
- CentOS Linux
- Debian Linux
- Ubuntu Linux
- By default, the Configure OS Networking workflow step is supported only for Linux VMs with the SSH endpoint configured. Configure OS Networking steps executed on an Azure Windows VM will fail with the following error:
VM "<vm-name>" has no valid network address: can't run guest command.
Contact firstname.lastname@example.org to learn how to configure an advanced system property to change this behavior.
- If you experience issues when running the Configure OS Networking step on CentOS or Red Hat Linux, the OS may be caching MAC addresses. Try clearing the cache before configuring the workflow step; otherwise, if caching is occurring, the OS will try to create a new interface device.
To clear the MAC address cache, run the following command as root user:
# rm -f /etc/udev/rules.d/70-persistent-net
Guest Tools Requirements
- vCenter VMs: Guest Tools (either VMware Tools or Open Virtual Machine Tools) must be current and running, so that Commander can obtain the IP address and run the guest OS command.
- SCVMM VMs: The latest guest integration services is required to obtain the IP address. Commander uses WMI (for Windows) or SSH (for Linux) to run the command in the guest OS.
With a Configure OS Networking step, there are three ways for IP addresses to be assigned:
- From Commander IP Pool
With this option, you must configure IP pools.
When you select All Adapters from the Adapters drop-down menu, the workflow step retrieves the number of NICs from the VM, reserves the IP addresses from the IP pool, and assigns the IP addresses to the respective adapters in the target guest OS.
- From Deployment Parameters
Assign an IP address when the request is approved. When you choose this option:
- You can specify network settings in the workflow step itself.
- Administrators can specify network settings using deployment parameters (obtained either through substitution variables or REST API calls) when approving the request. With this option, an administrator must provide values for all settings which have not been defined in the Configure OS Networking step itself, plus the IP address(es); otherwise, the workflow step will fail.
Note: You can use REST API calls to assign IPs for completion workflows but not for command workflows because deployment parameters are associated with a specific component in a service in a request. This isn't the case with substitution variables.
Note that settings specified in the workflow step itself can be overridden by approval comments.
- From BlueCat™ IPAM
Create host records or DHCP reservations from BlueCat™ IPAM during provisioning. You must integrate Commanderwith a BlueCat™ server first. To set this up, see Integrating BlueCat™ IP Address Management.
The Subnet Mask, Gateway and DNS must be valid IPv4 IP addresses (IPv6 isn't supported).
When using this step for a change request workflow, note the following:
- For Linux, the
/etc/sysconfig/network-scripts/ifcfg-eth0(for example) are overwritten during a change request, so any previous configuration will be lost.
- Change requests are supported only for workflow steps that are configured to use approver comments (that is, from the Step Details section, you must choose Assign IP > When Approving a Request).
If a guest OS command succeeds, the comment log provides an audit record of what was run on the guest OS.
If a guest OS command run in a workflow step through VMware Tools, WMI or SSH fails, the command and its output from the guest OS is captured in the comment log. There's no need to go to the Commander log for this information. You can try to run the failed command outside of Commander to troubleshoot the step.
Note: For the Run Program workflow step, set the Program Output field to "Capture program output as comment". For the Configure Networking steps, program output is always captured as a comment.
For example, you go to Tools > Workflow Status and see that one of your workflows has an Error status, as shown below.
In this case, you can select the row in the table and click Manage Workflow to see details for the workflow. You can also click the Comments tab to see detailed troubleshooting information. For Guest OS steps, the full syntax of the command that failed is included.
You can click the Edit Step hyperlink to edit the failed workflow step.