Auto Discovery: Configure Virtual Machines
    • 18 Apr 2023
    • 2 Minutes to read
    • Dark
      Light
    • PDF

    Auto Discovery: Configure Virtual Machines

    • Dark
      Light
    • PDF

    Article summary

    Virtual Machines which are managed by VMWare vCenter or run on ESXi can be discovered and managed directly on Nodegrid. The process will regularly scan vCenter or the ESXi host and detect newly added Virtual Machines. The virtual machines can be added as type virtual_console_vmware or virtual_serial_port.

    NOTE
    The free version of ESXi is not supported.

    Step 1 – Create a Template Device

    The device must be created first. In this process, only enter the details listed.

    1. Go to Managed Devices :: Devices.
    2. Click Add.
    3. On Add dialog, enter Name (of the template).
    4. On Type drop-down, select virtual_console_vmware
    5. Enter IP Address, enter 127.0.0.1
    6. Enter Username, Password and Confirm Password.
      Alternatively, select Ask During Login checkbox (user credentials are entered during login).
    7. Select Mode Disabled checkbox (ensures device is not displayed on Access page).
    8. Click Save.

    CLI Procedure

    1. Go to /settings/devices
    2. Use the add command to create a new device.
    3. Use the set command to define the following settings:
      name
      type (virtual_console_vmware)
      ip_address as 127.0.0.1
      set mode to disabled
    4. Save the changes with commit.
    [admin@nodegrid /]# cd /settings/devices
    [admin@nodegrid devices]# add
    [admin@nodegrid {devices}]# set name=Virtual_Machine_Template
    [admin@nodegrid {devices}]# set type=virtual_console_vmware
    [admin@nodegrid {devices}]# set ip_address=192.168.2.151
    [admin@nodegrid {devices}]# set mode=disabled
    [admin@nodegrid {devices}]# commit
    

    Step 2 – Create a Discovery Rule

    1. Go to Managed Devices :: Auto Discovery :: Discovery Rules.
    2. Click Add.
    3. On Add dialog, enter Rule Name.
    4. On Status drop-down, select an item (Enabled, Disabled).
    5. In Discovery Method menu, select VM Manager.
    6. (optional) To filter the scan, enter Datacenter and Cluster.
    7. (optional) In Host or VM Identifier menu, enter parameter to further filter (if provided, part of port name must match value).
    8. On Action drop-down, select what to do when a new device is discovered - Clone (Mode: Enabled), Clone (Mode: On-Demand), Clone (Mode: Discovered), Discard Discovered Devices.
    9. On Clone from drop-down, select the template device created earlier.
    10. Click Save.

    CLI Procedure

    1. Go to /settings/auto_discovery/discovery_rules/
    2. Use the add command to create a Discovery Rule.
    3. Use the set command to define the following settings:
      rule_name for the Discovery Rule
      status for the discovered rule (enabled, disabled)
      method set to vm_manager
      Use datacenter and cluster to define filters based on Data Center and or Cluster
      host_identifier parameter (apply as a filter) (If a value is provided, part of the port name must match the value.)
    4. For action (enter action taken when a new device is discovered) (clone_mode_enabled, clone_mode_on-demand, clone_mode_discovered, discard_device).
    5. clone_from (template device created earlier).
    6. Save the changes with commit.
    [admin@nodegrid /]# cd /settings/auto_discovery/discovery_rules/
    [admin@nodegrid discovery_rules]# add
    [admin@nodegrid {discovery_rules}]# set rule_name=Virtual_Machine
    [admin@nodegrid {discovery_rules}]# set status=enabled
    [admin@nodegrid {discovery_rules}]# set method=vm_manager
    [admin@nodegrid {discovery_rules}]# set action=clone_mode_enabled
    [admin@nodegrid {discovery_rules}]# set clone_from=Vitual_Machine_Template
    [admin@nodegrid {discovery_rules}]# commit
    

    Step 3 – Define a VM Manager

    1. Go to Managed Devices :: Auto Discovery :: VM Managers.
    2. Click Add.
    3. On Add dialog, on VM Server, enter the vCenter/ESXi IP or FQDN.
    4. Enter Username.
    5. On Virtualization Type drop-down, select VMware.
    6. Enter Password and Confirm Password.
    7. Enter HTML console port (if needed).
    8. Click Save.

    The Nodegrid Platform connects to the vCenter or ESXi system.

    This process takes several minutes.

    CLI Procedure

    1. Go to /settings/auto_discovery/vm_managers/
    2. Use the add command to create a VM Manager.
    3. Use the set command to define the following settings:
      vm_server (vCenter/ESXi IP or FQDN)
      Define username and password
      Adjust the html_console_port (if needed)
    4. Save the changes with commit.
    [admin@nodegrid /]# cd /settings/auto_discovery/vm_managers/
    [admin@nodegrid vm_managers]# add
    [admin@nodegrid {vm_managers}]# set vm_server=vCenter
    [admin@nodegrid {vm_managers}]# set username=admin
    [admin@nodegrid {vm_managers}]# set password=password
    [admin@nodegrid {vm_managers}]# commit
    

    The Nodegrid Platform connects to the vCenter or ESXi system.

    This process takes several minutes.

    Step 4 – Enable Discover Virtual Machines

    1. Click on the newly created and connected VM Manager. 
    2. Select Discover Virtual Machines checkbox.
    3. On Discovery Polling Interval (minutes), enter a value.
    4. Click Save.

    CLI Procedure

    1. Log into the newly created VM Manager
    2. Enable Discover Virtual Machines option.
    3. Define the Data Center and Discovery Polling Interval.
    4. Save the changes with commit.
    [admin@nodegrid 192.168.2.217]# set html_console_port=7331,7343
    [admin@nodegrid 192.168.2.217]# set discover_virtual_machines=yes
    [admin@nodegrid 192.168.2.217]# set interval_in_minutes=15
    [admin@nodegrid 192.168.2.217]# set discovery_scope=Demo-DC!
    [admin@nodegrid 192.168.2.217]# commit
    



    Was this article helpful?

    ESC

    Eddy AI, facilitating knowledge discovery through conversational intelligence