jsn / ServiceNow, simplified.
AustraliaREFERENCE GUIDE

OpenStack resource discovery

On this page

OpenStack resource discovery

The ServiceNow Discovery application uses OpenStack resource discovery patterns to find OpenStack resources through REST API calls. Discovering some of these resources might require updating to the latest version of the Discovery and Service Mapping Patterns application from the ServiceNow Store.

Discovery uses OpenStack resource discovery patterns to run horizontal discovery.

Starting with the Discovery and Service Mapping Patterns August 2024 store release, OpenStack resource discovery patterns support both private and public cloud discovery.

Request apps on the Store

Visit the ServiceNow Store to view all the available apps, and for information about submitting requests to the store. For cumulative release notes information for all released apps, see the ServiceNow Store version history release notes.

Prerequisites

  • OpenStack requirements

    • In the OpenStack Identity service catalog, find the access URL that is used as the OpenStack identity service endpoint. For example: https://<openstack dns>:<port>.

    • Configure an OpenStack user with permissions to generate a project scope token. Setting Domain ID, User Name, Project Name, and Password values is required for generating a token.

    • In the OpenStack Identity service catalog, find the access URL that is used as the OpenStack identity service endpoint. For example: https://<openstack dns>:<port>.

    • Configure an OpenStack user with permissions to generate a project scope token. Setting Domain ID, User Name, Project Name, and Password values is required for generating a token.

  • MID Server requirements

    Deploy and connect a dedicated MID Server for cloud discovery.

    The dedicated MID Server must have access to OpenStack and an open port for each OpenStack service to be discovered.

  • Credentials

    On the ServiceNow AI Platform, create OpenStack credentials for the ServiceNow cloud service account. Enter the Domain ID, User Name, Project Name, and Password values you've configured in OpenStack requirements. For more information, see Create and test your credentials.

  • Service account

    On the ServiceNow AI Platform, configure a ServiceNow cloud service account using the created OpenStack credentials and the OpenStack datacenter details. In the Account Id field, provide the Project ID of the OpenStack Project to be discovered.

  • Create a discovery schedule

    For more information, see Create an OpenStack Discovery schedule in Discovery Admin Workspace.

  • Create an automatic discovery schedule for OpenStack service accounts—for private cloud only

    Create an automatic serverless discovery schedule for OpenStack service accounts using the OpenStack - Discover Service Accounts pattern. For more information, see the Auto Cloud discovery schedule for Open stack [KB1638685] article in the Now Support Knowledge Base.

  • (Optional) Populate Service Account and Logical Datacenter fields in cloud CIs

    Starting with Discovery and Service Mapping Patterns version 1.30.2, you can improve query performance by populating Service Account and Logical Datacenter fields directly in cloud CIs. For more information, see {Improved query performance with direct field population in CI tables}[].

Data collected by Discovery during horizontal discovery

Discovery populates the data in the CMDB when running the OpenStack resource discovery patterns.

<table id=“table_bph_wsf_ccc”><thead><tr><th>

Field

</th><th>

Description

</th></tr></thead><tbody><tr><td>

Object ID [object_id]

</td><td>

Server UUID.

</td></tr><tr><td>

Name [name]

</td><td>

Server name.

</td></tr><tr><td>

Status [status]

</td><td>

Server status.

</td></tr><tr><td>

Description [short_description]

</td><td>

(Optional) Server description.

</td></tr><tr><td>

CPUs [cpus]

</td><td>

Number of virtual CPUs (vCPUs) from the Flavor that the VM instance is provisioned with.

</td></tr><tr><td>

Disks [disks]

</td><td>

Number of all managed volumes by Cinder that are returned from the VM instance.

</td></tr><tr><td>

Disks size (GB) [disk_size]

</td><td>

Total amount of all managed volumes by Cinder that are used by the VM instance measured in gigabytes (GB).

</td></tr><tr><td>

Memory (MB) [memory]

</td><td>

The ram value from the Flavor that the VM instance is provisioned with, measured in megabytes (MB).

</td></tr><tr><td>

Network adapters [nics]

</td><td>

Number of unique interfaces configured in the VM instance.

</td></tr><tr><td>

State [state]

</td><td>

Mapped status value returned for the VM instance. The OpenStack Server statuses and their related ServiceNow State values are:

  • ACTIVE: on

  • RESCUED: on

  • PAUSED: paused

  • SUSPENDED: off

  • STOPPED: off

  • SOFT_DELETED: terminated

  • HARD_DELETED: terminated

  • RESIZED: off

  • ERROR: error

  • INITIALIZED: starting

For any status value not listed, the default value is off.

</td></tr></tbody> </table>|Field|Description| |—–|———–| |Object ID [object_id]|Keypair UUID.| |Name [name]|Keypair name that is used to reference it.| |Finger print [finger_print]|Keypair fingerprint.|

Field Description Object ID [object_id] Load balancer ID. Name [name] Human-readable resource name. Description [short_description] (Optional) Human-readable resource description. Install Status [install_status] Resource provisioning status. Operational Status [operational_status] Resource operational status. Field Description Object ID [object_id] Listener ID. Name [name] Human-readable name of the resource. Install Status [install_status] Provisioning status of the resource. Listener Protocol [listener_protocol] Protocol for the resource. One of HTTP, HTTPS, TCP, TERMINATED_HTTPS, or UDP. Listener Port [listener_port] Protocol port number for the resource. Operational status [operational_status] Resource operational status. Description [short_description] (Optional) Human-readable resource description. Field Description Object ID [object_id] Pool ID. Name [name] Human-readable resource name. Install Status [install_status] Resource provisioning status. Operational Status [operational_status] Resource operational status. Description [short_description] (Optional) Human-readable resource description. Load Balancing Method [load_balancing_method] Load balancing algorithm for the pool. One of these values: LEAST_CONNECTIONS, ROUND_ROBIN, SOURCE_IP, or SOURCE_IP_PORT. Field Description Object ID [object_id] Pool member ID. Name [name] Human-readable resource name. Install Status [install_status] Resource provisioning status. IP address [ip_address] Back-end member server IP address. Field Description Object ID [object_id] Volume UUID. Name [name] Volume name. Status [status] Volume status. Description [short_description] (Optional) Human-readable description. Storage type [storage_type] Associated volume type. Field Description Object ID [object_id] Volume UUID. Name [name] Volume name. Status [status] Volume status. Description [short_description] (Optional) Human-readable description. Field Description Object ID [object_id] User-defined image UUID. Name [name] Image name. The value can be null (the JSON Null data type). Status [status] Image status. Field Description Object ID [object_id] Network ID. Name [name] Human-readable network name. Operational Status [operational_status] Network status. Possible values: ACTIVE, DOWN, BUILD, or ERROR. Description [short_description] (Optional) Human-readable description. Field Description Object ID [object_id] Subnet ID. Name [name] Human-readable resource name. DHCP enabled [is_dhcp_enabled] Whether DHCP is enabled or disabled for the subnet. Description [short_description] (Optional) Human-readable description. Field Description Object ID [object_id] Security group ID. Name [name] Human-readable resource name. Description [short_description] (Optional) Human-readable description.

<table id=“table_rrs_xsf_ccc”><thead><tr><th>

Field

</th><th>

Description

</th></tr></thead><tbody><tr><td>

Name [name]

</td><td>

This field has the same value as the object_id field.

</td></tr><tr><td>

Object ID [object_id]

</td><td>

Security group rule ID.

</td></tr><tr><td>

Description [short_description]

</td><td>

(Optional) Human-readable description.

</td></tr><tr><td>

Ethertype [ethertype]

</td><td>

Ethertype. Must be IPv4 or IPv6. Addresses represented in CIDR must match the ingress or egress rules.

</td></tr><tr><td>

Port range max [port_range_max]

</td><td>

The last port of the range to which the rule applies. This value is the maximum port number in the range that is matched by the security group rule. - If the protocol is TCP, UDP, DCCP, SCTP or UDP-Lite, this value must be greater than or equal to the port_range_min attribute value. - If the protocol is ICMP, this value must be an ICMP code.

</td></tr><tr><td>

Port range min [port_range_min]

</td><td>

The first port of the range to which the rule applies. This value is the minimum port number in the range that is matched by the security group rule.- If the protocol is TCP, UDP, DCCP, SCTP or UDP-Lite, this value must be less than or equal to the port_range_max attribute value. - If the protocol is ICMP, this value must be an ICMP type.

</td></tr></tbody> </table><table id=“table_i5t_xsf_ccc”><thead><tr><th>

Field

</th><th>

Description

</th></tr></thead><tbody><tr><td>

Object ID [object_id]

</td><td>

Domain ID.

</td></tr><tr><td>

Name [name]

</td><td>

Domain name.

</td></tr><tr><td>

Description [short_description]

</td><td>

(Optional) Human-readable description.

</td></tr><tr><td>

Enabled [enabled]

</td><td>

Defines whether the domain is enabled or disabled.- True - The domain is enabled. - False - The domain is disabled.

</td></tr></tbody> </table><table id=“table_nv5_xsf_ccc”><thead><tr><th>

Field

</th><th>

Description

</th></tr></thead><tbody><tr><td>

Object ID [object_id]

</td><td>

Service ID.

</td></tr><tr><td>

Name [name]

</td><td>

Service name.

</td></tr><tr><td>

Description [short_description]

</td><td>

(Optional) Human-readable description.

</td></tr><tr><td>

Type [type]

</td><td>

Service type. Describes the API implemented by the service. Possible values: Compute, ec2, identity, image, network, or volume.

</td></tr><tr><td>

Catalog enabled [enabled]

</td><td>

Defines whether the service and its endpoints appear in the service catalog.- True - The service and its endpoints appear in the service catalog. - False - The service and its endpoints do not appear in the service catalog.

</td></tr></tbody> </table><table id=“table_jzv_xsf_ccc”><thead><tr><th>

Field

</th><th>

Description

</th></tr></thead><tbody><tr><td>

Object ID [object_id]

</td><td>

Endpoint ID.

</td></tr><tr><td>

Name [name]

</td><td>

Service name.

</td></tr><tr><td>

Interface [interface]

</td><td>

Interface type that describes the visibility of the endpoint. Possible values:- Public - Visible by end users on a publicly available network interface. - Internal - Visible by end users on an unmetered internal network interface. - Admin - Visible by administrative users on a secure network interface.

</td></tr><tr><td>

Catalog enabled [enabled]

</td><td>

Defines whether the service and its endpoints appear in the service catalog.- True - The service and its endpoints appear in the service catalog. - False - The service and its endpoints do not appear in the service catalog.

</td></tr></tbody> </table>|Field|Description| |—–|———–| |Name [name]|The name field of OpenStack Flavor.| |Object ID [object_id]|The id field of OpenStack Flavor.| |vCPUs [vcpus]|The vcpus field of OpenStack Flavor.| |Memory MB [memory_mb]|The ram field of OpenStack Flavor.| |Local Storage GB [local_storage_gb]|The disk field of OpenStack Flavor.|

The discovered data includes the OpenStack Hypervisor View [cmdb_ci_openstack_hypervisor_view] table and its fields for private cloud only.

Field Description Name [name] Concatenated value of hypervisor_type and hypervisor_hostname fields. For example: [email protected]. IP Address [ip_address] The value of host_ip field. Hypervisor technology [hypervisor_technology] The value of hypervisor_type field. Object ID [object_id] The value of id field. State [state] The value of state field. Version [version] The value of hypervisor_version field.

The Dependency Views map shows all discovered OpenStack resources in your organization that are available through REST API calls and the relationships between them.

[Omitted image “openstack-network-dependency.PNG”] Alt text: CIs and connections on a Dependency Views map

[Omitted image “openstack-VM-dependency.PNG”] Alt text: CIs and connections on a Dependency Views map

CI relationships

The relationships listed in the following table are created to support OpenStack resource discovery.

CI Relationship CI cmdb_ci_openstack_datacenter Hosted on::Hosts cmdb_ci_cloud_service_account cmdb_ci_cloud_openstack_service Hosted on::Hosts cmdb_ci_cloud_service_account cmdb_ci_cloud_openstack_endpoint Use endpoint to::Use endpoint from cmdb_ci_cloud_openstack_service cmdb_ci_cloud_openstack_endpoint Hosted on::Hosts cmdb_ci_openstack_datacenter cmdb_ci_cloud_openstack_domain Owns::Owned by cmdb_ci_cloud_service_account cmdb_ci_network Hosted on::Hosts cmdb_ci_openstack_datacenter cmdb_ci_network Contains::Contained by cmdb_ci_cloud_subnet cmdb_ci_compute_security_group Hosted on::Hosts cmdb_ci_openstack_datacenter cmdb_ci_compute_security_group Contains::Contained by cmdb_ci_compute_security_group_rule cmdb_ci_cloud_load_balancer Hosted on::Hosts cmdb_ci_openstack_datacenter cmdb_ci_cloud_load_balancer Contains::Contained by cmdb_ci_lb_listener cmdb_ci_lb_pool Hosted on::Hosts cmdb_ci_cloud_load_balancer cmdb_ci_lb_pool Owns::Owned by cmdb_ci_lb_pool_member cmdb_ci_storage_volume Hosted on::Hosts cmdb_ci_openstack_datacenter cmdb_ci_vm_instance Uses::Used by cmdb_ci_storage_volume cmdb_ci_storage_vol_snapshot Hosted on::Hosts cmdb_ci_openstack_datacenter cmdb_ci_storage_vol_snapshot Provisioned from::Provisioned cmdb_ci_storage_volume cmdb_ci_vm_instance Hosted on::Hosts cmdb_ci_openstack_datacenter cmdb_ci_cloud_key_pair Hosted on::Hosts cmdb_ci_openstack_datacenter cmdb_ci_os_template Hosted on::Hosts cmdb_ci_openstack_datacenter cmdb_ci_vm_instance Provisioned from::Provisioned cmdb_ci_os_template cmdb_ci_vm_instance Virtualized by::Virtualizes cmdb_ci_server

The relationships listed in the following table are created to support OpenStack resource discovery in private cloud only.

CI Relationship CI cmdb_ci_vm_instance Registered on::Has registered cmdb_ci_openstack_hypervisor_view cmdb_ci_openstack_hypervisor_view Hosted on::Hosts cmdb_ci_openstack_datacenter cmdb_ci_openstack_hypervisor_view Uses::Hosts Used by cmdb_ci_server

Parent Topic:Available cloud discovery patterns

Keep exploring.

Find another answer, or bring this documentation into your own tools.