So, you may have already read Nick Weaver’s most excellent blog on UBERshell – a Powershell snap-in for the Celerra UBER VSA. Althoug I am new to Powershell (and by extension UBERshell as well), ‘back in the day’ I was a mad scripting fiend… As a Citrix administrator I authored many hundreds of compatibility scripts for Terminal Server and Citrix MetaFrame/Presentation Server/XenApp.
With Powershell automation available to both the storage layer as well as the VMware layer, it only makes sense that we try to create some scripts for automatic storage provisioning from the Celerra to a VMware vSphere Farm. With that in mind, I humbly submit my very first Powershell scripts to do just that:
Both scripts accomplish the same set of tasks:
- EMC Unified Storage Operations
- allow user to select storage pool, datamover
- allow user to set new file system name, size, lun
- create new file system, mount, export
- VMware vSphere operations
- connect to vcenter
- walk through farm, add new NAS datastore on every host
Version 1 of the script requires you (the user) to know all the names, and manually type them into variables. Version 2 of the script tries to help you out a bit by enumerating the resources, automatically selecting the data mover / storage pool if possible, and presenting a list of resources when it can’t.
It all works flawlessly in my lab – I would love to hear your experiences… Something is bound to break (it is my first attempt at scripting with Powershell, after all).