Skip to content
Release: Australia · Updated: 2026-03-12 · Official documentation · View source

GCP virtual server pattern-based discovery

Discovery and Service Mapping Patterns finds GCP Virtual Machine (VM) instances and related resources on your cloud environment. Discovering some of these resources may require updating to the latest version of the Discovery and Service Mapping Patterns application from the ServiceNow Store.

Pattern-based discovery and mapping requirements

Verify the GCP discovery prerequisites section in Google Cloud Platform (GCP) Cloud discovery using Patterns.

Data collected by Discovery during horizontal discovery

Discovery populates the data in the CMDB when running the Google Cloud Platform (GCP) - Virtual Server pattern.

FieldDescription
Account Id [account_id]Name of the project used for the discovery.
Object ID [object_id]Name of the project used for the discovery.
Datacenter Type [datacenter_type]Datacenter type: Google Datacenter [cmdb_ci_google_datacenter].
FieldDescription
Name [name]Name of the availability zone.
Description [short_description]Description of the availability zone.
State [state]State of the Availability Zone. Possible values are Available or Terminated.
FieldDescription
Name [name]Datacenter or region name.
Region [region]Datacenter or region name.
Object ID [object_id]Unique identifier allocated by GCP for this resource.
Description [short_description]Datacenter or region description.
FieldDescription
Object ID \[object\_id\]Unique identifier for the VM instance.
VM Instance ID \[vm\_inst\_id\]Unique identifier for the VM instance.
Name \[name\]Name of the VM instance.
State \[state\]Operational state of the virtual machine.For example: On, Off, or Terminated.
Install Status \[install\_status\]Install status of the resource. Default value is Installed.
CPUs \[cpus\]Number of virtual CPUs \(vCPUs\) allocated to the instance.
Memory \(MB\) \[memory\]Amount of memory in megabytes \(MB\) allocated to the instance.
Termination Protection \[termination\_protection\]Indicates whether deletion protection is enabled and the instance can't be deleted.Possible values are true or false.
Disks \[disks\]Number of disks attached to the VM instance.
Disks size \(GB\) \[disks\_size\]Total size of all disks attached to the instance in gigabytes \(GB\).
Network adapters \[nics\]Number of network interfaces attached to the VM instance.
IP Address \[ip\_address\]Primary internal IP address of the instance.
FieldDescription
Object ID [object_id]Unique identifier for the instance template.
Name [name]Name of the instance template.
Description [short_description]Description of the template configuration.
FieldDescription
Object ID [object_id]Unique identifier combining VM ID and Network Interface Controller (NIC) name.
Name [name]Name of the network interface.
Private IP [private_ip]Primary internal IP address.
IP Address [ip_address]IP address of the network interface.
Public IP [public_ip]Public IP address of the network interface.
FieldDescription
Object ID [object_id]Unique identifier for the virtual NIC endpoint.
Name [name]Name of the virtual NIC endpoint.
Region [region]Region where the endpoint is located.
IP Address [ip_address]IP address of the endpoint.
FieldDescription
Object ID \[object\_id\]Unique identifier for the persistent disk volume.
Name \[name\]Name of the disk volume.
Volume ID \[volume\_id\]Volume identifier.
Storage type \[storage\_type\]Type of persistent disk.For example: pd-balanced, pd-ssd, or pd-standard.
Size bytes \[size\_bytes\]Size of the volume in bytes.
State \[state\]State of the volume.For example: Available, In Use, or Terminated.
Install Status \[install\_status\]Install status of the resource. Default value is Installed.
Description \[short\_description\]Description of the volume.
FieldDescription
Object ID [object_id]Unique identifier for the block storage endpoint.
Name [name]Name of the storage endpoint.
Host [host]VM instance name to which the disk is attached.
FieldDescription
Name \[name\]Name of the operating system \(OS\) image.
Object ID \[object\_id\]Unique identifier for the OS image.
Image Type \[image\_type\]Source type of the image.For example: RAW or machine.
Image Source \[image\_source\]Source of the image in the format: disk_name/disk_id or snapshot_name/snapshot_id.
FQDN \[fqdn\]Fully qualified domain name \(FQDN\) of the image resource.
Provider \[provider\]The cloud provider, which is GCP. This field is only populated in Cloud Image [cmdb_ci_cloud_os_image] table.

Note: When using the Image [cmdb_ci_os_template] table to store Cloud OS images, you may notice an unusually large number of records. To avoid this issue, you can store the discovered OS images in the Cloud Image [cmdb_ci_cloud_os_image] table. For more information, see Enable Cloud OS Image discovery.

FieldDescription
Object ID \[object\_id\]Unique identifier for the machine type.
Name \[name\]Name of the machine type. For example: n1-standard-4.
Short description \[short\_description\]Description of the machine type configuration.
vCPUs \[vcpus\]Number of vCPUs in the machine type.
Memory MB \[memory\_mb\]Amount of memory available in the machine type in MB.
Local storage GB \[local\_storage\_gb\]Amount of local storage space in GB.
Zone \[zone\]Availability zone where the machine type is available.For example: us-west4-b.
Provider \[provider\]The cloud provider, which is GCP. This field is only populated in Cloud Hardware Type [cmdb_ci_cloud_hardware_type] table.

Note: When using the Hardware Type [cmdb_ci_compute_template] table to store the hardware types, you may notice an unusually large number of records. To avoid this issue, you can store the discovered hardware types in the Cloud Hardware Type [cmdb_ci_cloud_hardware_type] table. For more information, see Enable the Cloud Hardware Type class extension.

CI relationships

The Google Cloud Platform (GCP) - Virtual Server pattern creates these relationships to support GCP Virtual Machine discovery.

CIRelationshipCI
Google Datacenter [cmdb_ci_google_datacenter]Hosted on::HostsCloud Service Account [cmdb_ci_cloud_service_account]
Google Datacenter [cmdb_ci_google_datacenter]Contains::Contained byAvailability Zone [cmdb_ci_availability_zone]
Virtual Machine Instance [cmdb_ci_vm_instance]Hosted on::HostsGoogle Datacenter [cmdb_ci_google_datacenter]
Availability Zone [cmdb_ci_availability_zone]Contains::Contained byVirtual Machine Instance [cmdb_ci_vm_instance]
Image [cmdb_ci_os_template] or Cloud Image [cmdb_ci_cloud_os_image]Hosted on::HostsCloud Service Account [cmdb_ci_cloud_service_account]
Hardware Type [cmdb_ci_compute_template] or Cloud Hardware Type [cmdb_ci_cloud_hardware_type]Hosted on::HostsGoogle Datacenter [cmdb_ci_google_datacenter]
Virtual Machine Instance [cmdb_ci_vm_instance]Provisioned From::ProvisionedHardware Type [cmdb_ci_compute_template] or Cloud Hardware Type [cmdb_ci_cloud_hardware_type]
Instance template [cmdb_ci_instance_template]Hosted on::HostsCloud Service Account [cmdb_ci_cloud_service_account]
Instance template [cmdb_ci_instance_template]Uses::Used byHardware Type [cmdb_ci_compute_template] or Cloud Hardware Type [cmdb_ci_cloud_hardware_type]
Instance template [cmdb_ci_instance_template]Uses::Used byImage [cmdb_ci_os_template] or Cloud Image [cmdb_ci_cloud_os_image]
VNIC Endpoint [cmdb_ci_endpoint_vnic]Implement End Point To::Implement End Point FromCloud Mgmt Network Interface [cmdb_ci_nic]
Virtual Machine Instance [cmdb_ci_vm_instance]Use End Point To::Use End Point FromVNIC Endpoint [cmdb_ci_endpoint_vnic]
Cloud Mgmt Network Interface [cmdb_ci_nic]Hosted on::HostsGoogle Datacenter [cmdb_ci_google_datacenter]
Storage Volume [cmdb_ci_storage_volume]Hosted on::HostsGoogle Datacenter [cmdb_ci_google_datacenter]
Availability Zone [cmdb_ci_availability_zone]Contains::Contained byStorage Volume [cmdb_ci_storage_volume]
Block Endpoint [cmdb_ci_endpoint_block]Implement End Point To::Implement End Point FromStorage Volume [cmdb_ci_storage_volume]
Virtual Machine Instance [cmdb_ci_vm_instance]Use End Point To::Use End Point FromBlock Endpoint [cmdb_ci_endpoint_block]
Key Value [cmdb_key_value]ReferencesVirtual Machine Instance [cmdb_ci_vm_instance]
Key Value [cmdb_key_value]ReferencesImage [cmdb_ci_os_template] or Cloud Image [cmdb_ci_cloud_os_image]

GCP label discovery

The pattern extension collects labels and populates them in two entries in the Key Value [cmdb_key_value] table. One entry references the Virtual Machine Instance table, the other entry references the Image or Cloud Image table.

FieldDescription
Key [key]Label name.
Value [value]Label value.
Configuration item [configuration_item]References the Virtual Machine Instance [cmdb_ci_vm_instance] table.
Configuration item [configuration_item]References the Image [cmdb_ci_os_template] or Cloud Image [cmdb_ci_cloud_os_image] table.

GCP BYOL discovery

The pattern extension section discovers the following license types for Windows and Red Hat Enterprise Linux (RHEL), and SQL Server VMs:

  • Bring Your Own License (BYOL)
  • License included

The pattern stores the license type and model in the Key Value [cmdb_key_value] table.

FieldDescription
Key \[key\]The license type key, which is one of the following:- Windows\_OS\_License\_Type\_automatic - RHEL\_OS\_License\_Type\_automatic - SQL\_Server\_License\_Type\_automatic
Value \[value\]The license model, which is one of the following:- BYOL - License Included
Configuration item \[configuration\_item\]References the Virtual Machine Instance \[cmdb\_ci\_vm\_instance\] table.

Parent Topic:Google Cloud Platform (GCP) Cloud discovery using Patterns