OBLYTECH Logo
OBLYTECH Logo

ServiceNow Cloud Discovery for GCP, Alibaba Cloud and OCI

Cloud discovery for Google Cloud Platform, Alibaba Cloud and Oracle Cloud Infrastructure (OCI) follows one chain. A dedicated MID Server reaches the cloud, a credential record holds API access, a service account identifies the project, account or compartment, and a Discovery schedule runs the collection. Each provider has its own steps, but the order stays the same.

Prepare the platform before connecting a provider

Start with the applications the patterns depend on. For Google Cloud Platform the minimum versions are Discovery and Service Mapping Patterns 1.8.0, CMDB CI Class Models 1.49.0 and Visibility Content 6.13.0. The OCI setup also needs Cloud Access Interface 1.0.0 or later. Some newer resource patterns might require the latest release of the patterns application from the ServiceNow Store, so check the installed versions first. For the general Discovery setup steps, see the Discovery tool setup guide.

Use a MID Server dedicated to cloud discovery, with 16 cores, 8 GB of RAM and 4 GB of memory allocated to the Java Virtual Machine. Deploy it with internet access and give it the Cloud Management capability, because the schedule forms list validated, running servers with that capability. The server must also reach the IP ranges you intend to discover.

The person running the setup needs the discovery_admin role. The Cloud Discovery patterns spreadsheet lists pattern names, types and CI classes, and it shows which REST API permissions to grant. New patterns become available quarterly, so check periodically that you have the latest version of the Cloud Discovery patterns spreadsheet.

Connect Google Cloud Platform

In the Google Cloud console, open IAM, select the member ServiceNow will use, choose Edit, set the role to Viewer and save.

Next, create the Google API credentials under Discovery, then Credentials. For the wider Google Cloud integration setup, see the Google Cloud integration guide. Select New, choose Google API Credentials, then either import the JSON file that Google emails to you using Import JSON File and Upload Credential Data, or complete the form by hand and submit it.

To discover BigQuery and Bigtable, open All, then Discovery, then MID Server, then Properties, and set sn_itom_pattern.google_dbservice_table_collection to True.

GCP discovery covers global resources such as static external IP addresses, global HTTP load balancers, images, subnets, snapshots, instance templates, VPC networks and firewalls. It also covers regional resources such as regional static IPs, regional HTTP and TCP/UDP load balancers, managed instance groups and persistent disks. The pattern families include BigQuery, Bigtable, Cloud Firestore, Cloud SQL, Firebase Realtime Database, Spanner, storage, networking, SSH keys stored in project metadata and virtual server instances.

Connect Alibaba Cloud

Create a RAM user or RAM role in the Alibaba Cloud console with the permissions the MID Server needs to reach the resources you plan to discover. Collect the AccessKey ID and AccessKey secret, and confirm the user has at least read-only access to all Alibaba Cloud services.

In the platform, go to All, then Discovery, then Credentials, select New and choose Alibaba Cloud API Credentials. The form takes a unique name, an Active switch, the AccessKey ID and the AccessKey secret. Submit it, then set up the Alibaba Cloud service account before scheduling.

When you create the schedule, choose Alibaba as the provider. An existing account fills in the account name, account ID, the GovCloud region option and the datacenter URL. A new account needs a name and an ID. The Alibaba patterns cover availability zones, hardware types, OS images, datacenters, service account validation, storage volumes and virtual machines.

Connect Oracle Cloud Infrastructure

Install or update four applications first: Cloud Access Interface, Visibility Content, CMDB CI Class Models and Discovery and Service Mapping Patterns. The OCI user needs an API signing key and the IAM policies that allow read access, and at least read-only access to all Oracle services.

From the Oracle Cloud console, collect the tenancy OCID, the user OCID, the key fingerprint and the private key. The private key must be in RSA format, so convert it if your key uses another format. Then go to All, then Discovery, then Credentials, select New and choose Oracle API Credentials. The form has Name, Active, Tenancy Id, User Id, Key Fingerprint and Private Key fields.

Create the OCI service account from the cloud service account list. Enter a name, paste the compartment OCID into Account ID, and enter the Datacenter URL. Set the Datacenter Type to OCI Datacenter. The compartment OCID sits under Identity and Security, then Compartments. The datacenter URL follows a service-and-region pattern in three variants: commercial, GovCloud and UK Sovereign Cloud. GovCloud accounts need patterns 1.29.0 or later, and UK Sovereign Cloud accounts need 1.35.1.

Build the discovery schedule

The schedule form is shared across providers. Open Workspaces, then Discovery Admin Workspace, then Schedules, select New Discovery from the header and choose Cloud-based discovery. Name the schedule so the provider is obvious later.

Choose a MID Server as a cluster, let the platform select one automatically, or search for a specific server. Clusters provide failover protection and load balancing between servers.

Pick an existing cloud account or add a new one. For a Google management account, or an Oracle compartment account, you can discover all projects or specific projects. Choose Add projects to pick names from the Discoverable Projects dialog. Include all linked regions or select specific ones, and use Refresh cloud regions if none appear.

The timing step offers a scheduled time, run on demand, run after series and a discovery timeout. On demand runs when triggered from the final step or from the Discover Now action in the Discovery Schedules table. Run after series chains the schedule behind an existing one. The timeout cancels a run that exceeds the runtime you set. Finish and run creates and starts the schedule. Finish creates it and leaves it in the table for later.

Version floors differ by provider. The GCP schedule needs Discovery Admin Workspace 1.11.0 or later, while the Alibaba schedule needs 1.13.0 or later and the OCI schedule needs Discovery Admin Workspace 1.13.0.

Provider Credential record Account identifier Workspace version
Google Cloud Platform Google API Credentials Project ID or folder ID 1.11.0 or later
Alibaba Cloud Alibaba Cloud API Credentials Account name and account ID 1.13.0 or later
Oracle Cloud Infrastructure Oracle API Credentials Compartment OCID and datacenter URL 1.13.0

For OCI there is a second route through logical datacenters. Go to Discovery, then Discovery Schedules, select Cloud Discovery and set the provider to OCI. On the Select Datacenters page, filter which logical datacenters to run.

Keep the CMDB current between runs

GCP changes can reach the CMDB without a full run. Enable the Cloud Logging API for the project under APIs and Services, then Library. Give the integration user a Logging role that grants the four OAuth scopes the page lists, including logging admin and logging read. When Google generates an event, the scheduled job GCP-Events-job passes it to the reconciliation engine, which updates the affected resources. Enable the event-driven discovery toggle on the GCP schedule to use this path.

The Should pull events checkbox on the Google Service Account page must be selected before datacenter discovery runs.

Direct field population addresses reporting speed. The Populate Service Account and LDC IN CMDB job fills the Service Account and Logical Datacenter fields in cloud CI tables, along with the Virtual Machine Object reference in the Hardware table. Without it, queries join through the relationship table, and on a large relationship table those joins can add query time. After you enable the feature from patterns 1.30.2 onward, the job fills these fields for existing CIs and newly discovered ones.

What OCI discovery records

OCI discovery writes records to the CI tables below.

CI table Main fields populated
Cloud database name, object ID, vendor, version, state
Image name, guest OS, version
Cloud service account account ID, is_master_account (true for the management account)
Network name, CIDR, domain name, state
NIC public IP, private IP, MAC address, primary flag, state
Storage volume volume ID, size, size in bytes, state
Subnet name, CIDR, domain name, state
Virtual machine name, CPUs, memory, state

Tags land in the key-value table. Relationships link the records too: a virtual machine is hosted on its datacenter, and a subnet is contained by its network. Service Mapping uses these relationships for tag-based service maps.

Frequently asked questions

Do I need one credential record per provider?

Each provider has its own credential form, so a Google API Credentials record is needed for GCP, an Alibaba Cloud API Credentials record for Alibaba, and an Oracle API Credentials record for OCI. Each schedule then points at the account that uses its credential.

Why are BigQuery or Bigtable resources missing from GCP results?

Check the MID Server property sn_itom_pattern.google_dbservice_table_collection. It must be set to True before those patterns discover BigQuery datasets and tables or Bigtable instances.

Can the setup handle GovCloud or sovereign accounts?

Yes, with version requirements. OCI supports GovCloud accounts from patterns 1.29.0 and UK Sovereign Cloud accounts from 1.35.1. For Alibaba, an existing account fills in whether GovCloud regions are discovered.

Does a GCP change need a full schedule run to reach the CMDB?

No, once Cloud Logging is enabled and events are being pulled. Lifecycle and configuration changes update the affected CIs as they arrive. A full run still gives the complete picture, so scheduled runs remain useful alongside event updates.