NSX

Add multiple static routes to all your NSX-v edges

When you have NSX running on a vSAN stretched cluster over two datacenters, or a Cross vCenter NSX setup over multiple datacenters you probably need static routes for the networks behind the DLR to keep the routing tables alive on the physical network routers when a datacenter failover occurs. I am working at a customer where I needed to add 10 static routes to 20 different ESG’s. It’s obvious that I didn’t want to add them manually. Therefore I created a script to put in the static routes in the edges for me. This may come in handy for somebody else.

Requirements:
– Powershell (5.1)
– PowerCLI
– PowerNSX

(more…)

NSX-v backup retention script

The NSX-v manager is not being backed up via snapshot-based backups. This isn’t officially supported. Therefore a file/configuration based backup method used to backup the configuration of your NSX manager periodically.

Unfortunately, there is no retention setting available in the NSX manager so if you are not careful the backup directory will grow in a rapid fashion and fill up your disk very fast. Via this easy script I’ve written, you can enable backup retention for your NSX-v backup files. (more…)

Automate NSX with Powershell without using the PowerNSX module

Currently, I’m working on a migration project where we are migrating VMs from a non-NSX legacy environment to a brand new NSX-enabled infrastructure. During the migration, I needed to apply NSX Security Tags in the destination environment. The tags needed to be applied based on the environment type e.g. Production and Development. And  I thought; Yeah! PowerNSX is going to make my life more easier now.

(more…)