steampipe plugin install oci

Table: oci_core_local_peering_gateway - Query OCI Core Local Peering Gateways using SQL

A Local Peering Gateway (LPG) in Oracle Cloud Infrastructure (OCI) is a regional object that represents a local VCN peering relationship. It allows the peering of VCNs in the same region, enabling the VCNs to function as a single, unified network without routing traffic over the internet or through a router. The LPG is a key component of the VCN peering architecture within OCI, facilitating the exchange of private network traffic between VCNs.

Table Usage Guide

The oci_core_local_peering_gateway table provides insights into Local Peering Gateways within Oracle Cloud Infrastructure's Core Services. As a network administrator, explore gateway-specific details through this table, including associated VCNs, lifecycle states, and associated metadata. Utilize it to uncover information about peering gateways, such as those associated with specific VCNs, the lifecycle state of each gateway, and the verification of peering relationships.

Examples

Basic info

Explore the status of local peering gateways within your Oracle Cloud Infrastructure network to manage and optimize connections between virtual cloud networks. This is vital for ensuring smooth data transfer and maintaining network performance.

select
name,
id,
vcn_id,
lifecycle_state
from
oci_core_local_peering_gateway;
select
name,
id,
vcn_id,
lifecycle_state
from
oci_core_local_peering_gateway;

List available LPGs

Discover the segments that have local peering gateways in an available state, enabling you to manage and optimize network connectivity within your virtual cloud network.

select
name,
id,
vcn_id,
lifecycle_state
from
oci_core_local_peering_gateway
where
lifecycle_state = 'AVAILABLE';
select
name,
id,
vcn_id,
lifecycle_state
from
oci_core_local_peering_gateway
where
lifecycle_state = 'AVAILABLE';

List LPGs which are not connected to any peer

Explore which Local Peering Gateways (LPGs) are not connected to any peer. This can help in identifying isolated network segments, which could be a potential security risk or a misconfiguration.

select
name,
id,
vcn_id,
lifecycle_state
from
oci_core_local_peering_gateway
where
peering_status = 'NEW';
select
name,
id,
vcn_id,
lifecycle_state
from
oci_core_local_peering_gateway
where
peering_status = 'NEW';

Schema for oci_core_local_peering_gateway

NameTypeOperatorsDescription
_ctxjsonbSteampipe context in JSON form, e.g. connection_name.
compartment_idtext=The OCID of the compartment in Tenant in which the resource is located.
defined_tagsjsonbDefined tags for resource. Defined tags are set up in your tenancy by an administrator. Only users granted permission to work with the defined tags can apply them to resources.
freeform_tagsjsonbFree-form tags for resource. This tags can be applied by any user with permissions on the resource.
idtext=The LPG's Oracle ID
is_cross_tenancy_peeringbooleanWhether the VCN at the other end of the peering is in a different tenancy.
lifecycle_statetextThe LPG's current lifecycle state.
nametextA user-friendly name. Does not have to be unique, and it's changeable.
peer_advertised_cidrcidrThe smallest aggregate CIDR that contains all the CIDR routes advertised by the VCN at the other end of the peering from this LPG.
peer_advertised_cidr_detailsjsonbThe specific ranges of IP addresses available on or via the VCN at the other end of the peering from this LPG.
peering_statustextWhether the LPG is peered with another LPG.
peering_status_detailstextAdditional information regarding the peering status.
regiontextThe OCI region in which the resource is located.
route_table_idtextThe OCID of the route table the LPG is using.
tagsjsonbA map of tags for the resource.
tenant_idtextThe OCID of the Tenant in which the resource is located.
tenant_nametextThe name of the Tenant in which the resource is located.
time_createdtimestamp with time zoneThe date and time the LPG was created.
titletextTitle of the resource.
vcn_idtext=The OCID of the VCN that uses the LPG.

Export

This table is available as a standalone Exporter CLI. Steampipe exporters are stand-alone binaries that allow you to extract data using Steampipe plugins without a database.

You can download the tarball for your platform from the Releases page, but it is simplest to install them with the steampipe_export_installer.sh script:

/bin/sh -c "$(curl -fsSL https://steampipe.io/install/export.sh)" -- oci

You can pass the configuration to the command with the --config argument:

steampipe_export_oci --config '<your_config>' oci_core_local_peering_gateway