VMware Cloud Community
sbeaver
Leadership
Leadership

Bluecat Proteus Workflows

I got the vCO Proteus plugin and the request and remove actions are working great but there is not much else with it.  Anyone else out there using Proteus and have any workflows they can share before I really get busy with this.  What I am really looking for is to query Proteus with a servername so I can get a list back and determine what the next number for that server name would be

I have this working well with QIP and wanted to check to see if there is anything out there so I do not re-invent the wheel

Thanks and Cheers!

Steve Beaver
VMware Communities User Moderator
VMware vExpert 2009 - 2020
VMware NSX vExpert - 2019 - 2020
====
Co-Author of "VMware ESX Essentials in the Virtual Data Center"
(ISBN:1420070274) from Auerbach
Come check out my blog: [www.virtualizationpractice.com/blog|http://www.virtualizationpractice.com/blog/]
Come follow me on twitter http://www.twitter.com/sbeaver

**The Cloud is a journey, not a project.**
6 Replies
Craig_G2
Hot Shot
Hot Shot

Your best bet is to have the Proteus API document as your bedtime reading for the new weeks. I found their API structure quite confusing at first... But even still I only use the addDeviceInstance & deleteDeviceInstance methods.. which have vRO counter parts.

I'd be interested in seeing how you get on with this!

sbeaver
Leadership
Leadership

Yeah those workflows work well and makes it seem like it should be no problem but alas not quite that way for me yet

Steve Beaver
VMware Communities User Moderator
VMware vExpert 2009 - 2020
VMware NSX vExpert - 2019 - 2020
====
Co-Author of "VMware ESX Essentials in the Virtual Data Center"
(ISBN:1420070274) from Auerbach
Come check out my blog: [www.virtualizationpractice.com/blog|http://www.virtualizationpractice.com/blog/]
Come follow me on twitter http://www.twitter.com/sbeaver

**The Cloud is a journey, not a project.**
0 Kudos
MikaelPareChabo
Enthusiast
Enthusiast

On my side, I'm using the "AddVMInstance" action. But I'm unable to add anything related to the hostname. If I do not use the "Viewname, domainName, hostname" attributes, I'm receiving an IP adresse without any problems...

But when I put values in those attributes, I got and error message :

ERROR: java.lang.reflect.InvocationTargetException (Workflow:DHCPReserved / Scriptable task (item2)#24)

Any advice ?

0 Kudos
sbeaver
Leadership
Leadership

I have not had any issues using the add or remove workflows as is out of the box but let me ask a couple of questions.  When in the process are you requesting the IP?  Based on the error message I would take a guess that you are "might" be requesting once the server is up and has received a DHCP address.  In my environment, during the building workflow stub the logic is applied to create the server name and once I have this I request the server IP before the server has even started the cloning process.  If that is not the case are you sure you are using the correct action?  Seeing DHCP in your error message drives me towards those questions.

Steve Beaver
VMware Communities User Moderator
VMware vExpert 2009 - 2020
VMware NSX vExpert - 2019 - 2020
====
Co-Author of "VMware ESX Essentials in the Virtual Data Center"
(ISBN:1420070274) from Auerbach
Come check out my blog: [www.virtualizationpractice.com/blog|http://www.virtualizationpractice.com/blog/]
Come follow me on twitter http://www.twitter.com/sbeaver

**The Cloud is a journey, not a project.**
0 Kudos
MikaelPareChabo
Enthusiast
Enthusiast

Hi sbeaver,

I created my one workflow script/workflow. I first ask for an IP address in the Bluecat and after I received it, I pass that value to another workflow, configuring it in the OS. The problem in the "viewName, domainName, hostName". Every value I've tried, it didn't work. If they are "null", I correctly receive an IP address...

Script

System.log("********** \n AssignationIP \n **********");

var allowDupHostOption;

if( allowDuplicateHostname )

{

  allowDupHostOption = "allowDuplicateHosts=true|";

}

else

{

    allowDupHostOption = "allowDuplicateHosts=false|";

}

if( viewName == null || viewName == "" )

{

  domainName = null;

  hostName = null;

  viewName = null;

}

var args = new Array( configName, null, "REQUEST_STATIC", ipRange, viewName, domainName, hostName, null, null, "excludeDHCPRange=true|" + allowDupHostOption );

var result;

System.debug( "calling addDeviceInstance with: " + args.toString() );

try

{

  result = BCNProteusAPI.call( profileName, "addDeviceInstance", args );

}

catch( err )

{

  System.log( "ERROR: " + err.message );

  throw( err );

}

if( result == null || result == "" )

{

  throw( "Call to Proteus addDeviceInstance failed." );

}

System.log(result);

IP1 = result.indexOf("ip=") + 3;

IP2 = result.indexOf("|netmask=");

netmask1 = result.indexOf("|netmask=") + 9;

netmask2 = result.indexOf("|gateway=");

Gateway1 = result.indexOf("|gateway=") + 9;

Gateway2 = result.length;

AdresseIP = result.substring(IP1,IP2);

TempAdresseIP = result.substring(IP1,IP2);

SubnetMask = result.substring(netmask1,netmask2);

Passerelle = result.substring(Gateway1,Gateway2);

System.log("Adresse IP: " + AdresseIP);

System.log("Subnetmask: " + SubnetMask);

System.log("Passerelle: " + Passerelle);

0 Kudos
sbeaver
Leadership
Leadership

Your using the Proteus configuration name for view_name correct?  In my environment that value is internal.  This is not the profile name that you set up with the plugin.  Just checking because that workflow worked right out of the box for me once I had verified the correct Proteus view name

Steve Beaver
VMware Communities User Moderator
VMware vExpert 2009 - 2020
VMware NSX vExpert - 2019 - 2020
====
Co-Author of "VMware ESX Essentials in the Virtual Data Center"
(ISBN:1420070274) from Auerbach
Come check out my blog: [www.virtualizationpractice.com/blog|http://www.virtualizationpractice.com/blog/]
Come follow me on twitter http://www.twitter.com/sbeaver

**The Cloud is a journey, not a project.**
0 Kudos