Configure VxFlex / ScaleIO API with Python

Today I wanted to share with you my contribution to a project I have been working on within the IaC Avengers team. By the way, the Avengers team is an initiative that we have created internally at DellEMC in APJ to create materials and workshops to help customers of our traditional block storage products to fast-track their automation journey. Internal IT teams are under pressure to transform the way their enterprise infrastructure is delivered to the business to match the agility and self service capabilities that their internal customers experience in public cloud. The mission of the IaC Avengers team is to help customers in that journey

The project I am referring to today was dubbed "Project Rocket", like the Racoon in the Avengers movies ... indeed, by choosing Avengers as the team name, we get access to almost unlimited cool project names, specially after the "Endgame" movie!

Project Rocket was a prototype that set dynamic per VM IO limits in VxFlex (formerly ScaleIO). This requires to leverage both the vCenter API and the VxFlex API. I worked on the VxFlex API creating a series of Python functions that my colleague and fellow Avenger, Dennis Lao could leverage.
The code is available at:

https://github.com/cermegno/VxFlex-Python

VxFlex uses basic authentication for the "/login" uri and returns a token. This token is then used along with the user name to make any subsequent API calls. The most relevant functions for project Rocket were:

  • Get all volumes QoS information
  • Get all volumes with no IO limits
  • Set IO limits for the load that an SDC generates to a particular volume

As vSphere uses vMotion, HA or DRS to move Virtual Machines around, the shares change and it is necessary to adjust the IO limits. With Project Rocket those VM moves and trigger the adjustment of IO limits in the VxFlex cluster

The library also uses the VxFlex API to provide a couple of functions to:

  • Create a new volume in the cluster
  • Map a volume to an SDC (VxFlex client)

Dennis got the lion share of the project. He has published his work internally and might do some external post soon. For the time being you can see his code in here

https://github.com/oldsienna/dynamiciops

Comments

  1. Very nice blog, you have provided very informative piece of content. Thanks for sharing.
    Read my Blog: Python for Data Engineering: Why Do Data Engineers Use Python?

    ReplyDelete

Post a Comment

Popular posts from this blog

Sending PowerStore alerts via SNMP

Sending PowerStore logs to Syslog

Electronic Nose - eNose