Member-only story

How to extract the Ip-Address and Network data from Google Compute Instances across all projects in a GCP Org to a CSV file

Rajathithan Rajasekar
2 min readMar 11, 2021

--

Photo by Kevin Ku from Pexels

In my previous post on extracting compute engine inventory , I have not included the details on how to extract the network and ip address details , the link to my previous post is given below,

In this post, I have provided the details on how to extract the network, subnetwork, private-ip (Internal Ip) and public-ip ( External Ip) address details of all the compute engines across all the projects in your GCP org.

Please note that you should have org admin privileges to run the shell script successfully and to extract all the project details under your GCP org. The python script uses the compute engine’s REST Get api method to extract the ip address details.

Also note that the shell script and python script is run from the cloud shell environment , so it can easily authorize your credentials.

Once the csv file is generated in your cloudshell, you can download the file to your desktop and open it in…

--

--

Rajathithan Rajasekar
Rajathithan Rajasekar

Written by Rajathithan Rajasekar

I like to write code in Python . Interested in cloud , dataAnalysis, computerVision, ML and deepLearning. https://rajathithanrajasekar.medium.com/membership

No responses yet