VMware Cloud Community
codeace
Contributor
Contributor

No vSphere/vCenter, but want to script

Hello All,

Our current config:

ESX 3.5

No vSphere/vCenter - Expired trial & not interested in buying it

Vmware Virtual Infrastructure Client to manage hosts / networks / datastores

:Question:

How can we automate the following say write a script with corresponding necessary arguments to it

1. connecting a host to a different virtual switch?

2. adding or removing virtual switches?

I know the way to do the above tasks with the Virtual Infra Client gui, but want to use a script to do the same.Thanks,

ssk

ssk
Tags (2)
0 Kudos
5 Replies
mcowger
Immortal
Immortal

Doing this is actually a violation of the usage agreement. The API will kick back a 'RestrictedVersion' fault if you try it.

There are ways around it, but if you are really unwilling to pay for something that you should be paying for (you wouldn't ask a cabby for a free ride, would you)?, I'm sure you are clever enough to search for the answers.






--Matt
VCP, VCDX #52, Unix Geek, Storage Nerd

9773_9773.gif

--Matt VCDX #52 blog.cowger.us
0 Kudos
codeace
Contributor
Contributor

Thanks for that quick reply Matt!

I have no intentions of violating any policies. Since I am new to scripting, I was just curious to find if there is a way to do that. Also, we are using ESX just to run some research servers. So, we do not have the resouces to buy a vSphere/vCenter license. Sorry to have missed this point in the question.

Have a great day Smiley Happy

ssk

ssk
0 Kudos
chadwickking
Expert
Expert

Technically I think you could still use perl to do scripting on the host.

Cheers,

Chad King

VCP-410 | Server+

Twitter:

If you find this or any other answer useful please consider awarding points by marking the answer correct or helpful

Cheers, Chad King VCP4 Twitter: http://twitter.com/cwjking | virtualnoob.wordpress.com If you find this or any other answer useful please consider awarding points by marking the answer correct or helpful
0 Kudos
codeace
Contributor
Contributor

Hello Chad,

Ref: http://www.vmware.com/support/pubs/sdk_pubs.html

Here is what the above page says

>Infrastructure Management

VMware vSphere PowerCLI Documentation Windows PowerShell interfaces to VMware vSphere functionality. Two products are available: the VMware vSphere SDK for .NET, and the VMware vCenter Update Manager – PowerShell Library.

VMware vSphere SDK for Perl Client-side Perl framework that provides an easy-to-use scripting interface to the vSphere Web Services API.

VMware vSphere Web Services SDK Sample code, WSDLs, and documentation for creating Java and C# client applications that can leverage the Web-services based vSphere Web Services API for managing, monitoring, and controlling the life-cycle of all VMware vSphere components.

VMware CIM APIs Common Information Model (CIM) APIs. View virtual machines and resources using profiles defined by the Storage Management Initiative Specification (SMI-S). Manage hosts using the System Management Architecture for Server Hardware (SMASH) standard.

VMware vSphere Management Assistant (vMA) Virtual machine with prepackaged software, a logging component, and an authentication component for non-interactive login. Perform most ESX service console tasks, and run scripts and agents to manage ESX/ESXi hosts.

As you can see, it's very clear that anything that I would like to do with configuring (via scripting) needs a vSphere license.

Thanks,

ssk

ssk
0 Kudos
chadwickking
Expert
Expert

I could see your point in regards with making calls to API's but that doesn't mean that you couldn't at least run a local perl script to do some of the automation - you could even copy it out to the host and then kick off the process remotely/interactive. I must've thought we were doing that in our environement but maybe I was mistaken. Sorry about that I must of gotten confused Smiley Sad

Happens from time to time...bummer.






Cheers,

Chad King

VCP-410 | Server+

Twitter: http://twitter.com/cwjking

If you find this or any other answer useful please consider awarding points by marking the answer correct or helpful

Cheers, Chad King VCP4 Twitter: http://twitter.com/cwjking | virtualnoob.wordpress.com If you find this or any other answer useful please consider awarding points by marking the answer correct or helpful
0 Kudos