To enroll a gateway, you must first create a device template.

Prerequisites

You must have the CREATE_DEVICE_TEMPLATE permission to perform this operation.

Procedure

  1. From the VMware Pulse IoT Center UI, go to Inventory > Device Templates.
    The Inventory - Device Templates screen is displayed.
  2. Click CREATE.
    The Create Device Template wizard is displayed.
  3. In the Details step, enter the template name and select the device type. To associate an image with the device, click UPLOAD IMAGE. Click Next.
  4. In the Properties step, perform the following steps:
    1. Under System Properties, enter the system property for your device. System Properties are the properties that are collected from the device and sent to the VMware Pulse IoT Center server. The IoTC Agent collects these properties automatically or the client code supplies them. To add more properties, click + Add.
      Note: The default system properties are pre-populated and you cannot delete them.
    2. Under Custom Properties, enter the custom property and value for your device. Custom Properties are the default properties and values that are associated with all the devices of this template. These properties are used for querying information or for sending configuration files to the devices. These properties are not collected from the device and can be edited on the server. To add more properties and values, click + Add.
    3. Click Next.
  5. In the Metrics step, select the metrics that you want to collect. The CPU-Usage, Memory-Usage, and Disk-Usage metrics are added by default if you select Gateway as your device. To add more metrics, click + Add and enter the following information:
    • Display Name - Display name of the metric.
    • Value Type - Boolean, Integer, Double, or String.
    • Unit - Enter the unit of measurement. Ensure that the unit is the same as the one collected from the device.
    Note:
    • The Metric Name and Value Type collected from the device must match the Allowed Metrics configuration. Else, the configuration is rejected.
    • The default metrics are pre-populated. You can delete them or add new metrics as required.
    If you have selected Gateway as your device, perform the next steps. If you have selected Thing as your device, go to the last step.
  6. In the Connected Device Templates step, add the thing device template that can be connected to this template. Click Add Template, select the connected device template, and click Next.
  7. In the Commands step, click Add Command.
    1. Select the following Type of commands that you want to run on your device:
      • Client Command - Set a command to communicate with the connected devices in your gateway. For example, you can set a command to turn on the LED that is connected to the gateway when an alert is raised. As a system administrator, you can set a list of allowed client identifiers to be used by the client application when initializing a session with the VMware Pulse IoTC Agent. Ensure that the client identifier you enter matches the client identifier value in the operating system. You can add a client command for both gateway and thing devices. For a sample use case of using client commands, see the Container Management Sample Use Case section.
      • Custom Command - Set a custom command. For example, set a command to configure the IP address of the device or enable DHCP.
        Note:
        • You must enter the full path of the command. For example, enter /usr/bin/cp instead of cp.
        • You can add multiple comma-separated arguments for a command.
      • File Upload - Set a command to upload log files to the agent. The File Upload command takes multiple file paths in one argument. The IoTC Agent archives the files and uploads them to the VMware Pulse IoT Center server as a .zip file. Administrators can download the .zip file and extract its content.
      • Reboot - Set a command to reboot the device.
      • SSH - Set a command to enable or disable SSH on the device.
      • SSH, Reboot, and File Upload commands run with root user privileges.
      • Custom Command can run with root user or iotc-user privileges.
      Note:
      • If you select the Run with root privilege option, the command runs with root user privilege on the gateway.
      • If you do not select the Run with root privilege option, the command runs with iotc user privilege on the gateway.

      For an example of using custom commands to redirect an output file, see Redirecting an Output Using Custom Commands. To run custom commands, enter the command name and command information under Custom Command. To add more commands, click Add Command and click Next

    2. In the Name text box, enter the name of the command.
    3. Enter the Client Identifier.
    4. In the Arguments step, enter the Name and Value of the argument and click DONE.
      Note:
      • Custom and Client Commands can have the placeholders as part of the command argument values.
      • The Value of the argument must be entered in the format ${<placeholder>}, where placeholder must be one of the system property name. The VMware Pulse IoTC agent parses and replaces the placeholder with the corresponding system property value.
  8. In the Enrollment Provider step, perform the following steps:
    1. Select the Provider Type from the drop-down menu.
      • Token Based - Creates a single-use device credential with signature and expire-time verification.
      • Property Based - Creates a single-use device credential with a device identity value verification.
      • TPM Based - Creates a single use device credential with a Trusted Platform Module (TPM) identity value verification.
    2. Under Provider Config:
      • If you have selected Token Based as the provider type, enter the expiry time of the device credential and select the interval from the drop-down menu.
      • If you have selected Property Based as the provider type, enter the identity key. The device presents the value of this identity key during onboarding.
      • If you have selected TPM Based as the provider type, select Requires Whitelisting if you want to whitelist the gateways for an automatic enrollment.
      Note: Basic authentication is enabled by default.
  9. Click NEXT.
  10. In the Settings step, configure the IoTC Agent settings for your devices. These settings are applied when you onboard new devices.
    • Agent log level - Select the logging level for collecting the IoTC Agent logs from a device.
    • Maximum number of clients - Enter the maximum number of SDK clients that can communicate through the IoTC Agent with the VMware Pulse IoT Center server.
    • Command fetch interval (seconds) - Enter the time interval for the VMware IoTC Agent to fetch commands from the VMware Pulse IoT Center server.
      Note: The maximum value for the command fetch interval is 43200 seconds. The minimum value is 10 seconds and the default value for the command fetch interval is 30 seconds. If the time interval is not within the specified range, an error message is displayed.
    • Metrics interval (seconds) - Enter the time interval between 60 and 43200 seconds for transmitting metrics from the IoTC Agent to the VMware Pulse IoT Center server.
      Note: The minimum value for the metrics interval is 60 seconds and the default value for the metric interval is 300 seconds. If the time interval is not within the specified range, an error message is displayed.
    • Server Request Timeout (seconds) - Enter the timeout value between 60 and 3600 seconds for requests from the IoTC Agent to the VMware Pulse IoT Center server.
      Note: The minimum value for the timeout is 60 seconds and the default value for the timeout is 300 seconds. If the time interval is not within the specified range, an error message is displayed.
    • Network Bandwidth - Enter the maximum network bandwidth allowed on the device for the IoTC Agent. The data rate is in Bytes per second (B/s). The value 0 denotes unlimited network bandwidth.
      Note: The minimum value required for network bandwidth is 2500 bytes/second and the default value is 0.
    • In the Forward Proxy step, click Add to enter the HTTP Proxy details.
      • Server IP - Enter the IP address
      • Port - Enter the Port Number
      • User Name - Enter your user name
      • Password - Enter the password
    • Click DONE.
    Note:

    You can add multiple HTTP Proxy settings. These proxy settings details are stored in the VMware Pulse IoTC Agent configuration file. The VMware Pulse IoTC Agent uses these proxy settings to connect to the server for enrolling a gateway. The proxy settings details are then sent to the gateway while enrolling a device or every time the template is modified. The VMware Pulse IoTC agent selects the first working proxy server from the list of proxy servers and updates that in the VMware Pulse IoTC Agent configuration file.

    If the current proxy server stops working, it fetches the next working proxy server. For enrollment, if the VMware Pulse IoTC Agent cannot connect to the VMware Pulse IoT server without connecting to the proxy server, then you must manually enter the working proxy server details in the VMware Pulse IoTC agent configuration file.

  11. Click NEXT.
  12. In the Review step, verify that the information that you have entered is correct. Click SAVE.

Results

You have successfully created a device template. You can view your device template in the Devices - Device Templates page.

What to do next

Download and install the VMware Pulse IoTC Agent. For more information, see Install the VMware Pulse IoTC Agent on a Linux Gateway.