usmansultan
asked on
Running Scripts on VMWARE
I have to run a script on VMWare server, i have the instructions, i just need bit more guidance on how to run it...The instructions that i have are;
1. Copy the attached script to your vSphere (vCentre) server.
2. Change the extension of the file from .txt to .ps1
3. Open “vSphere PowerCLI”
4. Connect to vsphere server.
5. Change to directory with this script in it.
6. Type ./inventory.ps1
7. A file called inventory.csv is created (works for both Windows and Linux).
I want to go step by step, now in the first point it says i have to run script on vsphere? we have 8 VMware servers, all of them running ESX 3.5, so what do i have to do in the first step....
1. Copy the attached script to your vSphere (vCentre) server.
2. Change the extension of the file from .txt to .ps1
3. Open “vSphere PowerCLI”
4. Connect to vsphere server.
5. Change to directory with this script in it.
6. Type ./inventory.ps1
7. A file called inventory.csv is created (works for both Windows and Linux).
I want to go step by step, now in the first point it says i have to run script on vsphere? we have 8 VMware servers, all of them running ESX 3.5, so what do i have to do in the first step....
The vSphere PowerCLI can be on your local workstation. I'm not a CLI guru by any means, but there is a command (reference in CLI User's Guide) on what to type to connect to your vCenter Server server. Once connected via CLI, just do a 'CD' (change directory) command to the directory you placed the .txt/.ps1 file and follow the rest of the steps.
~coolsport00
~coolsport00
What is the version of your vCenter Server/ESX or ESXi hosts?
~coolsport00
~coolsport00
The Inventory PowerCLI script querys the VMware vSphere vCenter server which contains all the details about your ESX 3.5 servers and Virtual Machines and creates a nice CSV file.
Personally I prefer Veeam Reporter
download for free
http://www.veeam.com/vmware-esx-reporter-free.html
(it produces nice pictures for Management!)
Personally I prefer Veeam Reporter
download for free
http://www.veeam.com/vmware-esx-reporter-free.html
(it produces nice pictures for Management!)
The first thing you need to do after launching vSphere PowerCLI is to get a connection to a vCenter Server system or ESX host. To get started, call the Connect-VIServer cmdlet and specify the IP address or DNS name of your vCenter Server system or ESX host, the protocol (http or https), user name, and password.
Connect-VIServer –Server 10.22.36.36 –Protocol https –User admin –Password mypass
Connect-VIServer –Server 10.22.36.36 –Protocol https –User admin –Password mypass
to check you've connected and all is working type
Get-VM
Get-VM
ASKER
how can i found out which server is running VCenter, i have no documents to find out that information.....
ASKER
and how can i open the console for the servers which are running ESX server? i cant RDP in to those servers......
ASKER
I have downloaded and installed that tool, now how can i configure it to make it work?
Hi
Without most of that information, is pointless to run that scripts.
You can get the information witch host hold a VM. You get information by running a power shell script. But again, you need to connect to a vCenter.
But also you can use the perl VMware Scripts
http://www.vmware.com/support/developer/viperltoolkit/
Using vminfo.pl you can get lots of information. But also there is so many perl scritps to work and get many information.
Hope this can help
Jail
Without most of that information, is pointless to run that scripts.
You can get the information witch host hold a VM. You get information by running a power shell script. But again, you need to connect to a vCenter.
But also you can use the perl VMware Scripts
http://www.vmware.com/support/developer/viperltoolkit/
Using vminfo.pl you can get lots of information. But also there is so many perl scritps to work and get many information.
Hope this can help
Jail
You need to find your vCenter server, and also your ESX servers, you cannot RDP to ESX servers, but you can use ssh to connect to the console of them, if ssh has been enabled.
Do you use the vSphere vCenter Client GUI? You usually use it to connect to ESX hosts or vCenter server?
Do you use the vSphere vCenter Client GUI? You usually use it to connect to ESX hosts or vCenter server?
When you have found your vCenter and ESX servers, you can also run these
I would recommend and use the VMware Community PowerPack.
in combination with PowerGUI http://powergui.org/index.jspa
http://www.virtu-al.net/featured-scripts/vmware-powerpack/
This will give you all the information you need, (datastores, hba, LUNs) and has the ability to run your scripts on your VMs.
Let me know if you require help finding your servers!
I would recommend and use the VMware Community PowerPack.
in combination with PowerGUI http://powergui.org/index.jspa
http://www.virtu-al.net/featured-scripts/vmware-powerpack/
This will give you all the information you need, (datastores, hba, LUNs) and has the ability to run your scripts on your VMs.
Let me know if you require help finding your servers!
Do you have a vCenter Management Server?
ASKER
We dont have a VCentre or Vsphere, because there are six ESX servers, all of them are running ESX 3.5, and those ESX i can see the machines attached to them, but log in to them?
In that case you cannot use the script. Because that script needs to be run on the vCenter server.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
This question has been classified as abandoned and is closed as part of the Cleanup Program. See the recommendation for more details.
~coolsport00