» Publishers, Monetize your RSS feeds with FeedShow: More infos (Show/Hide Ads)
forgot to add category Perl
New page
In order to install the [http://bit.ly/vGhettoGUI vGhetto client] and to be able to run all of its accompanied scripts, you'll have to install the VI Perl Toolkit.
So follow the installation tips for that here [[Install the VI Perl Toolkit on OS X]]
==== Graphical environment ====
The vGhetto client uses a graphical user interface and because of that, it has a dependency on the X11 server.
Starting with OS X Leopard, this is included in the default install of OS X. So unless you are experiencing some real problems getting things to work I would not update X11 server. It is added to the steps below because you might have to redo it depending on your current setup.
==== Install module Tk ====
vGhetto uses the perl module Tk for the graphical environment, so this is one of the main dependencies.
You can install it by running:
cpan Tk
During the install you'll see many displays popup to test the functionality from tk, that's normal.
If you are extremely lucky it ends with OK..., but if you are like me you'll get:
Failed Test Stat Wstat Total Fail Failed List of Failed
-------------------------------------------------------------------------------
t/canvas.t 1 256 158 1 0.63% 84
t/coloreditor.t 255 65280 8 11 137.50% 3-8
t/wm-tcl.t 1 256 315 1 0.32% 240
(37 subtests UNEXPECTEDLY SUCCEEDED), 2 tests and 161 subtests skipped.
Failed 3/62 test scripts, 95.16% okay. 8/3686 subtests failed, 99.78% okay.
make: *** [test_dynamic] Error 255
/usr/bin/make test -- NOT OK
Running make install
make test had returned bad status, won't install without force
''' If that's your result too, then skip the next few steps as it is expected that a few test scripts will fail '''
Turns out I still had an X11 Server installed from tiger.
XQuartz 2.1.6 (xorg-server 1.4.2-apple33
So from the DVD, go to option installs and select Optional Installs.mpkg :
In the applications part select X11.
===== Remove X11 =====
Messed it up, got confused, want to start over?
Before you start deleting anything, make sure you have a Leopard's installation DVD available and downloaded the latest X11 package from the Xquartz Project.
* Delete pretty much all X11 from you system, and let it forget its receipts:
Code:
sudo rm -rf /usr/X11 /usr/X11R6
sudo pkgutil --forget com.apple.pkg.X11DocumentationLeo
sudo pkgutil --forget com.apple.pkg.X11User
sudo pkgutil --forget com.apple.pkg.X11SDKLeo
sudo pkgutil --forget org.x.X11.pkg
* Install X11User.pkg from Leopard's installation DVD, which is in /Volumes/Mac OS X Install DVD/Optional Install/Optional Installs.mpkg
* Install X11SDK.pkg from Leopard's installation DVD, which is in /Volumes/Mac OS X Install DVD/Optional Installs/Xcode Tools/Packages/
* Install [http://xquartz.macosforge.org/trac/wiki/Releases the latest X11 package] release from the Xquartz Project.
===== Install Tk second try =====
After installing X11 2.4.0 from the xquartz project, trying to install Tk gives even more errors:
(32 subtests UNEXPECTEDLY SUCCEEDED), 2 tests and 173 subtests skipped.
Failed 22/62 test scripts, 64.52% okay. 1258/3686 subtests failed, 65.87% okay.
make: *** [test_dynamic] Error 255
/usr/bin/make test -- NOT OK
Running make install
make test had returned bad status, won't install without force
===== Install Tk third try =====
So much fun, after following the complete removal steps from X11 and only installing the default Leopard parts (not the quartz update) and rerunning the cpan Tk setup. Now I'm getting:
(37 subtests UNEXPECTEDLY SUCCEEDED), 2 tests and 161 subtests skipped.
Failed 4/62 test scripts, 93.55% okay. 9/3686 subtests failed, 99.76% okay.
make: *** [test_dynamic] Error 255
/usr/bin/make test -- NOT OK
Running make install
make test had returned bad status, won't install without force
Well maybe having 4 failed tests is not so bad?
==== Force feeding tk-perl ====
If you scroll up on the part where we're trying to install Tk via cpan, then you'll see right at the top something along these lines:
/Users/topaz/.cpan/sources/authors/id/S/SR/SREZIC/Tk-804.028.tar.gz
So our Tk version is Tk-804.028
Move to our build folder:
cd /Users/topaz/.cpan/build/Tk-804.028
Now install by running:
sudo make install
If there's no complaint after that, you should be OK
==== time-modules ====
cpan Time::ParseDate
This should install the time-modules library and if it works OK, you should see this step end with:
Appending installation info to /Library/Perl/Updates/5.8.8/darwin-thread-multi-2level/perllocal.pod
/usr/bin/make install -- OK
==== Done ====
That's it. With all of these requirements in place, you should now be able to run the vGhetto client directly from OS X by running:
./vGhetto.pl
(You might have to make vGhetto.pl executable first by executing "chmod +x vGhetto.pl" )
[[Category: Perl]]
| ← Older revision | Revision as of 09:57, 14 March 2010 | ||
| Line 5: | Line 5: | ||
[[Install the VI Perl Toolkit on OS X]] | [[Install the VI Perl Toolkit on OS X]] | ||
| + | |||
| + | [[Install vGhetto on OS X]] | ||
==== Scripts ==== | ==== Scripts ==== | ||
Completely removed the MacPorts steps as they didn't turn out to work
| ← Older revision | Revision as of 09:15, 14 March 2010 | ||
| (One intermediate revision not shown) | |||
| Line 2: | Line 2: | ||
'' by Wil van Antwerpen '' | '' by Wil van Antwerpen '' | ||
| - | + | This document describes the preferred way on how-to get the VI Perl Toolkit working on OS X. | |
| - | + | We are doing this by using the CPAN functionality of Perl which is already installed on your Mac. | |
| - | I will | + | I will walk you through how-to set this up from the start using the CPAN Network. |
| - | + | ''' We have also tried to do this by using [http://www.macports.org/ MacPorts]. but as it turns out MacPorts will give you problems due to it changing paths and installing its own complete perl environment. For now we are not aware of a way to use the toolkit using Macports. ''' | |
| - | + | ||
| - | + | ||
== Installing Developer Tools == | == Installing Developer Tools == | ||
| - | The VI Perl Toolkit needs to get a few extra modules added to the current perl setup that is by default installed on Mac OS X. In order to get these modules we use CPAN | + | The VI Perl Toolkit needs to get a few extra modules added to the current perl setup that is by default installed on Mac OS X. In order to get these modules we use CPAN. |
| - | + | CPAN has some prerequisites of its own that we are going to have to satisfy first. | |
| - | + | The main issue is that your system must have "make" installed. | |
The most straightforward way to get that package installed is to take your original OS X installation disk and install Developer Tools (XcodeTools.mpkg) which can be found under Option Installs on the DVD. | The most straightforward way to get that package installed is to take your original OS X installation disk and install Developer Tools (XcodeTools.mpkg) which can be found under Option Installs on the DVD. | ||
Just keep the default settings and you'll be fine. | Just keep the default settings and you'll be fine. | ||
| - | It is a bit big though (over 2GB) so it is a steep requirement for just getting the VI Perl toolkit to work OK. If you don't have the space, the part that is needed is the BSD "make" command and a number of other commands. It should be sufficient to install the UNIX Development Support (or BSD SDK) sub-package of the Developer Tools. | + | It is a bit big though (over 2GB) so it is a steep requirement for just getting the VI Perl toolkit to work OK. If you don't have the space, the part from the developer tools that is needed is the BSD "make" command and a number of other commands. It should be sufficient to install the UNIX Development Support (or BSD SDK) sub-package of the Developer Tools. |
== Getting the Perl VI Toolkit SDK == | == Getting the Perl VI Toolkit SDK == | ||
| Line 40: | Line 38: | ||
Warning: prerequisite UUID 0.03 not found. | Warning: prerequisite UUID 0.03 not found. | ||
Writing Makefile for VIPerlToolkit | Writing Makefile for VIPerlToolkit | ||
| - | The warnings we see here are the modules we need to install | + | The warnings we see here are the modules we need to install for perl that are missing in order for getting the toolkit to work. |
So we are going to install these modules first, before we can continue with our main installation. | So we are going to install these modules first, before we can continue with our main installation. | ||
== Installing missing perl dependencies == | == Installing missing perl dependencies == | ||
| - | So now we need to setup CPAN | + | So now we need to setup CPAN unless you already have CPAN working, in that case you can skip the installation part. |
=== CPAN: Is /usr/local setup? === | === CPAN: Is /usr/local setup? === | ||
By default cpan will try to install some documentation under the /usr/local folder, so this folder has to exist and it needs to have the correct ownership privileges setup. | By default cpan will try to install some documentation under the /usr/local folder, so this folder has to exist and it needs to have the correct ownership privileges setup. | ||
| - | + | Check if the folder already exists: | |
$ ls /usr/ | $ ls /usr/ | ||
X11 bin lib sbin standalone | X11 bin lib sbin standalone | ||
| Line 58: | Line 56: | ||
$ sudo mkdir /usr/local | $ sudo mkdir /usr/local | ||
Password: | Password: | ||
| - | So now we | + | So now we created the folder, but as you will see it is owned by root and we can't install our packages in there unless we allow our user. |
$ ls -alh /usr/local | $ ls -alh /usr/local | ||
total 0 | total 0 | ||
| Line 71: | Line 69: | ||
=== CPAN: Configuration === | === CPAN: Configuration === | ||
| - | With the developer tools setup | + | With the developer tools setup you now have to configure CPAN. You can also use this step if you want to change your CPAN configuration. |
| - | Configuring CPAN makes sure that the tools | + | Configuring CPAN makes sure that the tools find the necessary commands on your system (make et al). To do that, run: |
perl -MCPAN -e shell | perl -MCPAN -e shell | ||
| Line 93: | Line 91: | ||
=== CPAN: Installing the VI Perl Toolkit dependencies === | === CPAN: Installing the VI Perl Toolkit dependencies === | ||
| - | Now we'll get the missing dependencies by running them one by one. We could add all of these on a single line, but we want it to be easy to see if the install was successful | + | Now we'll get the missing dependencies by running them one by one. We could add all of these on a single line, but we want it to be easy to see if the install was successful. This is why we are running them one by one. |
cpan Class::MethodMaker | cpan Class::MethodMaker | ||
this should now end with: | this should now end with: | ||
| Line 111: | Line 109: | ||
cpan UUID | cpan UUID | ||
Which down here installed fine too, so now we can finally get back to installing the VI Perl Toolkit. | Which down here installed fine too, so now we can finally get back to installing the VI Perl Toolkit. | ||
| - | |||
| - | |||
| - | |||
| - | |||
| - | |||
| - | |||
| - | |||
| - | |||
| - | |||
| - | |||
| - | |||
| - | |||
| - | |||
| - | |||
| - | |||
| - | |||
| - | |||
| - | |||
== Install VI Perl Toolkit == | == Install VI Perl Toolkit == | ||
| Line 138: | Line 118: | ||
That UUID is not yet version 0.03 seems to be OK (On Snow Leopard it is 0.04) | That UUID is not yet version 0.03 seems to be OK (On Snow Leopard it is 0.04) | ||
| - | With this version of the toolkit, there are no tests defined for the make file so install it directly: | + | With this version of the toolkit, there are no tests defined for the make file so we are going to install it directly: |
sudo make install | sudo make install | ||
highlighted to NOT use MacPorts
| ← Older revision | Revision as of 21:00, 12 March 2010 | ||
| Line 9: | Line 9: | ||
Obviously, you will only need to use one of these methods in order to use the Toolkit. | Obviously, you will only need to use one of these methods in order to use the Toolkit. | ||
| - | + | ''' I SUGGEST USING THE CPAN METHOD and not install MacPorts if you can as MacPorts will give you problems due to it changing paths and installing its own complete perl environment. I will remove the MacPort parts of the notes ASAP. ''' | |
== Installing Developer Tools == | == Installing Developer Tools == | ||
blocked [[Jennnyjordan (Talk | contribs)]] with an expiry time of infinite (account creation disabled) Spamming links to external sites: user removed existing content and overwrote it with spam
New page
Reverted edits by Jennnyjordan (Talk) to last version by Wila
| ← Older revision | Revision as of 11:11, 3 March 2010 | ||
| Line 1: | Line 1: | ||
| - | + | ==== vimsh hostsvc/net/config_load ==== | |
| - | + | Usage: config_load filename | |
| + | |||
| + | Loads a network configuration from a file and updates it. | ||
| + | |||
| + | [[Category: Vimsh]] | ||
| ← Older revision | Revision as of 21:37, 2 March 2010 | ||
| Line 22: | Line 22: | ||
* [http://www.hypervisor.fr/?p=1687 Move your templates] | * [http://www.hypervisor.fr/?p=1687 Move your templates] | ||
| + | * [http://www.vmwarescripting.com/index.php/topic,1302.0.html Add/Change DNS suffix's on your ESX hosts] | ||
[[Category: PowerCLI]][[Category: Host Management]] | [[Category: PowerCLI]][[Category: Host Management]] | ||
| ← Older revision | Revision as of 21:37, 2 March 2010 | ||
| Line 22: | Line 22: | ||
* [http://www.hypervisor.fr/?p=1687 Move your templates] | * [http://www.hypervisor.fr/?p=1687 Move your templates] | ||
| + | * [http://www.vmwarescripting.com/index.php/topic,1302.0.html Add/Change DNS suffix's on your ESX hosts] | ||
[[Category: PowerCLI]][[Category: Host Management]] | [[Category: PowerCLI]][[Category: Host Management]] | ||
| ← Older revision | Revision as of 20:12, 2 March 2010 | ||
| Line 1: | Line 1: | ||
| - | + | '''Guidelines on writing Essays''' | |
| - | + | I found this site that help me through writing [http://www.research-service.com research papers] for my reports | |
| - | + | ||
| - | + | ||
| - | + | ||
| - | + | ||
| ← Older revision | Revision as of 20:12, 2 March 2010 | ||
| Line 1: | Line 1: | ||
| - | + | '''Guidelines on writing Essays''' | |
| - | + | I found this site that help me through writing [http://www.research-service.com research papers] for my reports | |
| - | + | ||
| - | + | ||
| - | + | ||
| - | + | ||
Added some more links for the ToDo list..
| ← Older revision | Revision as of 21:45, 28 February 2010 | ||
| Line 2: | Line 2: | ||
Because of that I've had little time to process the scripts that have been published. | Because of that I've had little time to process the scripts that have been published. | ||
But that doesn't mean I didn't keep a record of them :) | But that doesn't mean I didn't keep a record of them :) | ||
| - | So until I get a bit more time, here's the list of scripts... (It will | + | So until I get a bit more time, here's the list of scripts... (It will grow some more before it gets shorter again) |
| - | |||
[http://professionalvmware.com/2008/12/vmware-vix-changing-ips-of-a-guest-vm/ VMware VIX – Changing IP’s of a Guest VM] | [http://professionalvmware.com/2008/12/vmware-vix-changing-ips-of-a-guest-vm/ VMware VIX – Changing IP’s of a Guest VM] | ||
| Line 26: | Line 25: | ||
[http://communities.vmware.com/docs/DOC-10859 Creating vSphere Client Plug In - Tech Ex Developer Day Session] | [http://communities.vmware.com/docs/DOC-10859 Creating vSphere Client Plug In - Tech Ex Developer Day Session] | ||
| - | |||
| - | |||
[http://www.virtu-al.net/2009/10/12/powercli-more-hal-information/ PowerCLI: More HAL Information] | [http://www.virtu-al.net/2009/10/12/powercli-more-hal-information/ PowerCLI: More HAL Information] | ||
| Line 36: | Line 33: | ||
[http://ict-freak.nl/2009/10/05/powercli-check-cpumemory-hot-add/ PowerCLI: Check CPU/Memory Hot Add] | [http://ict-freak.nl/2009/10/05/powercli-check-cpumemory-hot-add/ PowerCLI: Check CPU/Memory Hot Add] | ||
| - | |||
| - | |||
[http://poshcode.org/1337 Get-SerialNumber] | [http://poshcode.org/1337 Get-SerialNumber] | ||
[http://www.virtu-al.net/2009/09/23/powercli-how-many-vms-on-your-datastores/ PowerCLI: How many VMs on your Datastores ?] | [http://www.virtu-al.net/2009/09/23/powercli-how-many-vms-on-your-datastores/ PowerCLI: How many VMs on your Datastores ?] | ||
| - | |||
| - | |||
| - | |||
| - | |||
| - | |||
| - | |||
[http://blogs.vmware.com/vipowershell/2009/08/how-to-list-datastores-that-are-on-shared-storage.html How to list datastores and VMs that are on shared storage.] | [http://blogs.vmware.com/vipowershell/2009/08/how-to-list-datastores-that-are-on-shared-storage.html How to list datastores and VMs that are on shared storage.] | ||
| - | |||
| - | |||
[http://www.virtu-al.net/2009/08/17/powercli-reading-host-log-files/ PowerCLI: Reading host log files] | [http://www.virtu-al.net/2009/08/17/powercli-reading-host-log-files/ PowerCLI: Reading host log files] | ||
| Line 66: | Line 53: | ||
[http://www.ntpro.nl/blog/archives/1296-Ruby-sample-code-and-library-for-VI-SDK.html Ruby sample code and library for VI SDK] | [http://www.ntpro.nl/blog/archives/1296-Ruby-sample-code-and-library-for-VI-SDK.html Ruby sample code and library for VI SDK] | ||
| - | |||
| - | |||
[http://ict-freak.nl/2009/10/09/powercli-virtual-machine-disk-vmdk-info/ PowerCLI: Virtual Machine Disk (VMDK) info] | [http://ict-freak.nl/2009/10/09/powercli-virtual-machine-disk-vmdk-info/ PowerCLI: Virtual Machine Disk (VMDK) info] | ||
| Line 74: | Line 59: | ||
[http://poshcode.org/1384 Get-Hostname] | [http://poshcode.org/1384 Get-Hostname] | ||
| - | |||
| - | |||
[http://blogs.vmware.com/vipowershell/2009/10/when-was-the-last-time-that-vm-was-powered-on.html When was the last time that VM was powered on?] | [http://blogs.vmware.com/vipowershell/2009/10/when-was-the-last-time-that-vm-was-powered-on.html When was the last time that VM was powered on?] | ||
| + | |||
| + | [http://halr9000.com/article/828 Adding Port Groups with PowerCLI] | ||
| + | |||
| + | [http://professionalvmware.com/2009/11/disabling-copy-paste-the-powercli-way/ Disabling Copy Paste – The PowerCLI way] | ||
| + | |||
| + | [http://www.virtu-al.net/2009/10/26/workstation-server-audit-script-v3/ Workstation & Server Audit Script V3] | ||
| + | |||
| + | [http://lucd.info/?p=859 Thick to Thin with PowerCLI and the SDK] | ||
| + | |||
| + | [http://professionalvmware.com/2009/10/a-quick-powercli-lesson-digging-for-info-who-powered-off-that-vm/ A Quick PowerCLI Lesson – Digging for Info (Who Powered Off that VM)] | ||
| + | |||
| + | [http://www.virtu-al.net/2009/10/19/powercli-mass-vm-portgroup-change/ PowerCLI: Mass VM Portgroup Change] | ||
| + | |||
| + | [http://www.virtu-al.net/2009/11/10/powercli-where-do-i-start/ PowerCLI – Where do I start ?!] | ||
| + | |||
| + | [http://vinternals.com/esxi-mastery/ ESXi Mastery] | ||
| + | |||
| + | [http://www.virtu-al.net/2009/10/30/powercli-vsphere-license-export/ PowerCLI: vSphere License Export] | ||
| + | |||
| + | [http://www.peetersonline.nl/index.php/vmware/report-vsphere-alarms-with-powershell/ Report vSphere Alarms with Powershell] | ||
| + | |||
| + | [http://www.virtu-al.net/2009/10/28/powercli-listing-cluster-primary-ha-nodes/ PowerCLI: Listing Cluster Primary HA Nodes] | ||
| + | |||
| + | [http://ict-freak.nl/2009/11/17/powercli-one-liner-to-get-vms-clusters-esx-hosts-and-datastores/ PowerCLI: One-Liner to get VMs, Clusters, ESX Hosts and Datastores] | ||
| + | |||
| + | [http://www.vmware.com/support/developer/windowstoolkit/wintk40u1/html/index.html vSphere PowerCLI 4.0 Update 1 Cmdlets Reference] | ||
| + | |||
| + | [http://communities.vmware.com/thread/235164 PowerCLI Poster] | ||
| + | |||
| + | [http://ict-freak.nl/2010/01/21/powercli-move-template/ PowerCLI: Move-Template] | ||
| + | |||
| + | [http://ict-freak.nl/2010/01/27/move-template-integrated-into-the-vesi/ Move-Template integrated into the VESI] | ||
| + | |||
| + | [http://ict-freak.nl/2010/01/28/backup-and-restore-drs-rules-with-the-vesi/ Backup and Restore DRS Rules with the VESI] | ||
| + | |||
| + | [http://www.virtu-al.net/2010/02/09/powercli-how-many-hbas/ PowerCLI: How many HBA’s ?] | ||
| + | |||
| + | [http://get-admin.com/blog/?p=941 PowerCLI: Remove SMVI snapshots] | ||
| + | |||
| + | [http://get-admin.com/blog/?p=954 PowerShell: Custom Types, and Formatting] | ||
| + | |||
| + | [http://searchvmware.techtarget.com/generic/0,295582,sid179_gci1381348,00.html Using PowerShell and PowerCLI to work with host servers] | ||
| + | |||
| + | ==== Perl ==== | ||
| + | |||
| + | [http://communities.vmware.com/docs/DOC-11135 findVMsWithRDMs.pl] | ||
| + | |||
| + | [http://communities.vmware.com/docs/DOC-11003 vmISOManagement.pl] | ||
| + | |||
| + | [http://communities.vmware.com/docs/DOC-10974 rdmManagmement.pl] | ||
| + | |||
| + | [http://communities.vmware.com/docs/DOC-11000 upgradeVMVirtualHardware.pl] | ||
| + | |||
| + | [http://communities.vmware.com/docs/DOC-11221 configureAdvHAClusterOptions.pl] | ||
| + | |||
| + | [http://communities.vmware.com/docs/DOC-11213 addExistingVMDKToVM.pl] | ||
| + | |||
| + | [http://communities.vmware.com/docs/DOC-11054 listHAClusterNodes.pl] | ||
| + | |||
| + | [http://communities.vmware.com/docs/DOC-10866 setUserDatastorePermission.pl] | ||
[http://communities.vmware.com/docs/DOC-10847 pluginExtensionManager.pl] | [http://communities.vmware.com/docs/DOC-10847 pluginExtensionManager.pl] | ||
| - | [http:// | + | [http://communities.vmware.com/docs/DOC-10883 useVIFastpassOnvMAToRunPerlScriptWithoutClearTextPassword.pl] |
| + | [http://communities.vmware.com/docs/DOC-10807 getVMsPerDatastore.pl] | ||
| + | |||
| + | [http://communities.vmware.com/docs/DOC-10809 generateVMRemoteConsoleURL.pl] | ||
| + | |||
| + | [http://communities.vmware.com/docs/DOC-10777 getVMThinProvisionedSavings.pl] | ||
| + | |||
| + | [http://communities.vmware.com/docs/DOC-10552 getShareableAndNonSharDatastore.pl] | ||
| + | |||
| + | [http://communities.vmware.com/docs/DOC-10885 getVMDiskInfo.pl] | ||
[[Category: ToDo]] | [[Category: ToDo]] | ||
Added some more links for the ToDo list..
| ← Older revision | Revision as of 21:45, 28 February 2010 | ||
| Line 2: | Line 2: | ||
Because of that I've had little time to process the scripts that have been published. | Because of that I've had little time to process the scripts that have been published. | ||
But that doesn't mean I didn't keep a record of them :) | But that doesn't mean I didn't keep a record of them :) | ||
| - | So until I get a bit more time, here's the list of scripts... (It will | + | So until I get a bit more time, here's the list of scripts... (It will grow some more before it gets shorter again) |
| - | |||
[http://professionalvmware.com/2008/12/vmware-vix-changing-ips-of-a-guest-vm/ VMware VIX – Changing IP’s of a Guest VM] | [http://professionalvmware.com/2008/12/vmware-vix-changing-ips-of-a-guest-vm/ VMware VIX – Changing IP’s of a Guest VM] | ||
| Line 26: | Line 25: | ||
[http://communities.vmware.com/docs/DOC-10859 Creating vSphere Client Plug In - Tech Ex Developer Day Session] | [http://communities.vmware.com/docs/DOC-10859 Creating vSphere Client Plug In - Tech Ex Developer Day Session] | ||
| - | |||
| - | |||
[http://www.virtu-al.net/2009/10/12/powercli-more-hal-information/ PowerCLI: More HAL Information] | [http://www.virtu-al.net/2009/10/12/powercli-more-hal-information/ PowerCLI: More HAL Information] | ||
| Line 36: | Line 33: | ||
[http://ict-freak.nl/2009/10/05/powercli-check-cpumemory-hot-add/ PowerCLI: Check CPU/Memory Hot Add] | [http://ict-freak.nl/2009/10/05/powercli-check-cpumemory-hot-add/ PowerCLI: Check CPU/Memory Hot Add] | ||
| - | |||
| - | |||
[http://poshcode.org/1337 Get-SerialNumber] | [http://poshcode.org/1337 Get-SerialNumber] | ||
[http://www.virtu-al.net/2009/09/23/powercli-how-many-vms-on-your-datastores/ PowerCLI: How many VMs on your Datastores ?] | [http://www.virtu-al.net/2009/09/23/powercli-how-many-vms-on-your-datastores/ PowerCLI: How many VMs on your Datastores ?] | ||
| - | |||
| - | |||
| - | |||
| - | |||
| - | |||
| - | |||
[http://blogs.vmware.com/vipowershell/2009/08/how-to-list-datastores-that-are-on-shared-storage.html How to list datastores and VMs that are on shared storage.] | [http://blogs.vmware.com/vipowershell/2009/08/how-to-list-datastores-that-are-on-shared-storage.html How to list datastores and VMs that are on shared storage.] | ||
| - | |||
| - | |||
[http://www.virtu-al.net/2009/08/17/powercli-reading-host-log-files/ PowerCLI: Reading host log files] | [http://www.virtu-al.net/2009/08/17/powercli-reading-host-log-files/ PowerCLI: Reading host log files] | ||
| Line 66: | Line 53: | ||
[http://www.ntpro.nl/blog/archives/1296-Ruby-sample-code-and-library-for-VI-SDK.html Ruby sample code and library for VI SDK] | [http://www.ntpro.nl/blog/archives/1296-Ruby-sample-code-and-library-for-VI-SDK.html Ruby sample code and library for VI SDK] | ||
| - | |||
| - | |||
[http://ict-freak.nl/2009/10/09/powercli-virtual-machine-disk-vmdk-info/ PowerCLI: Virtual Machine Disk (VMDK) info] | [http://ict-freak.nl/2009/10/09/powercli-virtual-machine-disk-vmdk-info/ PowerCLI: Virtual Machine Disk (VMDK) info] | ||
| Line 74: | Line 59: | ||
[http://poshcode.org/1384 Get-Hostname] | [http://poshcode.org/1384 Get-Hostname] | ||
| - | |||
| - | |||
[http://blogs.vmware.com/vipowershell/2009/10/when-was-the-last-time-that-vm-was-powered-on.html When was the last time that VM was powered on?] | [http://blogs.vmware.com/vipowershell/2009/10/when-was-the-last-time-that-vm-was-powered-on.html When was the last time that VM was powered on?] | ||
| + | |||
| + | [http://halr9000.com/article/828 Adding Port Groups with PowerCLI] | ||
| + | |||
| + | [http://professionalvmware.com/2009/11/disabling-copy-paste-the-powercli-way/ Disabling Copy Paste – The PowerCLI way] | ||
| + | |||
| + | [http://www.virtu-al.net/2009/10/26/workstation-server-audit-script-v3/ Workstation & Server Audit Script V3] | ||
| + | |||
| + | [http://lucd.info/?p=859 Thick to Thin with PowerCLI and the SDK] | ||
| + | |||
| + | [http://professionalvmware.com/2009/10/a-quick-powercli-lesson-digging-for-info-who-powered-off-that-vm/ A Quick PowerCLI Lesson – Digging for Info (Who Powered Off that VM)] | ||
| + | |||
| + | [http://www.virtu-al.net/2009/10/19/powercli-mass-vm-portgroup-change/ PowerCLI: Mass VM Portgroup Change] | ||
| + | |||
| + | [http://www.virtu-al.net/2009/11/10/powercli-where-do-i-start/ PowerCLI – Where do I start ?!] | ||
| + | |||
| + | [http://vinternals.com/esxi-mastery/ ESXi Mastery] | ||
| + | |||
| + | [http://www.virtu-al.net/2009/10/30/powercli-vsphere-license-export/ PowerCLI: vSphere License Export] | ||
| + | |||
| + | [http://www.peetersonline.nl/index.php/vmware/report-vsphere-alarms-with-powershell/ Report vSphere Alarms with Powershell] | ||
| + | |||
| + | [http://www.virtu-al.net/2009/10/28/powercli-listing-cluster-primary-ha-nodes/ PowerCLI: Listing Cluster Primary HA Nodes] | ||
| + | |||
| + | [http://ict-freak.nl/2009/11/17/powercli-one-liner-to-get-vms-clusters-esx-hosts-and-datastores/ PowerCLI: One-Liner to get VMs, Clusters, ESX Hosts and Datastores] | ||
| + | |||
| + | [http://www.vmware.com/support/developer/windowstoolkit/wintk40u1/html/index.html vSphere PowerCLI 4.0 Update 1 Cmdlets Reference] | ||
| + | |||
| + | [http://communities.vmware.com/thread/235164 PowerCLI Poster] | ||
| + | |||
| + | [http://ict-freak.nl/2010/01/21/powercli-move-template/ PowerCLI: Move-Template] | ||
| + | |||
| + | [http://ict-freak.nl/2010/01/27/move-template-integrated-into-the-vesi/ Move-Template integrated into the VESI] | ||
| + | |||
| + | [http://ict-freak.nl/2010/01/28/backup-and-restore-drs-rules-with-the-vesi/ Backup and Restore DRS Rules with the VESI] | ||
| + | |||
| + | [http://www.virtu-al.net/2010/02/09/powercli-how-many-hbas/ PowerCLI: How many HBA’s ?] | ||
| + | |||
| + | [http://get-admin.com/blog/?p=941 PowerCLI: Remove SMVI snapshots] | ||
| + | |||
| + | [http://get-admin.com/blog/?p=954 PowerShell: Custom Types, and Formatting] | ||
| + | |||
| + | [http://searchvmware.techtarget.com/generic/0,295582,sid179_gci1381348,00.html Using PowerShell and PowerCLI to work with host servers] | ||
| + | |||
| + | ==== Perl ==== | ||
| + | |||
| + | [http://communities.vmware.com/docs/DOC-11135 findVMsWithRDMs.pl] | ||
| + | |||
| + | [http://communities.vmware.com/docs/DOC-11003 vmISOManagement.pl] | ||
| + | |||
| + | [http://communities.vmware.com/docs/DOC-10974 rdmManagmement.pl] | ||
| + | |||
| + | [http://communities.vmware.com/docs/DOC-11000 upgradeVMVirtualHardware.pl] | ||
| + | |||
| + | [http://communities.vmware.com/docs/DOC-11221 configureAdvHAClusterOptions.pl] | ||
| + | |||
| + | [http://communities.vmware.com/docs/DOC-11213 addExistingVMDKToVM.pl] | ||
| + | |||
| + | [http://communities.vmware.com/docs/DOC-11054 listHAClusterNodes.pl] | ||
| + | |||
| + | [http://communities.vmware.com/docs/DOC-10866 setUserDatastorePermission.pl] | ||
[http://communities.vmware.com/docs/DOC-10847 pluginExtensionManager.pl] | [http://communities.vmware.com/docs/DOC-10847 pluginExtensionManager.pl] | ||
| - | [http:// | + | [http://communities.vmware.com/docs/DOC-10883 useVIFastpassOnvMAToRunPerlScriptWithoutClearTextPassword.pl] |
| + | [http://communities.vmware.com/docs/DOC-10807 getVMsPerDatastore.pl] | ||
| + | |||
| + | [http://communities.vmware.com/docs/DOC-10809 generateVMRemoteConsoleURL.pl] | ||
| + | |||
| + | [http://communities.vmware.com/docs/DOC-10777 getVMThinProvisionedSavings.pl] | ||
| + | |||
| + | [http://communities.vmware.com/docs/DOC-10552 getShareableAndNonSharDatastore.pl] | ||
| + | |||
| + | [http://communities.vmware.com/docs/DOC-10885 getVMDiskInfo.pl] | ||
[[Category: ToDo]] | [[Category: ToDo]] | ||
Added some more links for the ToDo list..
| ← Older revision | Revision as of 21:45, 28 February 2010 | ||
| Line 2: | Line 2: | ||
Because of that I've had little time to process the scripts that have been published. | Because of that I've had little time to process the scripts that have been published. | ||
But that doesn't mean I didn't keep a record of them :) | But that doesn't mean I didn't keep a record of them :) | ||
| - | So until I get a bit more time, here's the list of scripts... (It will | + | So until I get a bit more time, here's the list of scripts... (It will grow some more before it gets shorter again) |
| - | |||
[http://professionalvmware.com/2008/12/vmware-vix-changing-ips-of-a-guest-vm/ VMware VIX – Changing IP’s of a Guest VM] | [http://professionalvmware.com/2008/12/vmware-vix-changing-ips-of-a-guest-vm/ VMware VIX – Changing IP’s of a Guest VM] | ||
| Line 26: | Line 25: | ||
[http://communities.vmware.com/docs/DOC-10859 Creating vSphere Client Plug In - Tech Ex Developer Day Session] | [http://communities.vmware.com/docs/DOC-10859 Creating vSphere Client Plug In - Tech Ex Developer Day Session] | ||
| - | |||
| - | |||
[http://www.virtu-al.net/2009/10/12/powercli-more-hal-information/ PowerCLI: More HAL Information] | [http://www.virtu-al.net/2009/10/12/powercli-more-hal-information/ PowerCLI: More HAL Information] | ||
| Line 36: | Line 33: | ||
[http://ict-freak.nl/2009/10/05/powercli-check-cpumemory-hot-add/ PowerCLI: Check CPU/Memory Hot Add] | [http://ict-freak.nl/2009/10/05/powercli-check-cpumemory-hot-add/ PowerCLI: Check CPU/Memory Hot Add] | ||
| - | |||
| - | |||
[http://poshcode.org/1337 Get-SerialNumber] | [http://poshcode.org/1337 Get-SerialNumber] | ||
[http://www.virtu-al.net/2009/09/23/powercli-how-many-vms-on-your-datastores/ PowerCLI: How many VMs on your Datastores ?] | [http://www.virtu-al.net/2009/09/23/powercli-how-many-vms-on-your-datastores/ PowerCLI: How many VMs on your Datastores ?] | ||
| - | |||
| - | |||
| - | |||
| - | |||
| - | |||
| - | |||
[http://blogs.vmware.com/vipowershell/2009/08/how-to-list-datastores-that-are-on-shared-storage.html How to list datastores and VMs that are on shared storage.] | [http://blogs.vmware.com/vipowershell/2009/08/how-to-list-datastores-that-are-on-shared-storage.html How to list datastores and VMs that are on shared storage.] | ||
| - | |||
| - | |||
[http://www.virtu-al.net/2009/08/17/powercli-reading-host-log-files/ PowerCLI: Reading host log files] | [http://www.virtu-al.net/2009/08/17/powercli-reading-host-log-files/ PowerCLI: Reading host log files] | ||
| Line 66: | Line 53: | ||
[http://www.ntpro.nl/blog/archives/1296-Ruby-sample-code-and-library-for-VI-SDK.html Ruby sample code and library for VI SDK] | [http://www.ntpro.nl/blog/archives/1296-Ruby-sample-code-and-library-for-VI-SDK.html Ruby sample code and library for VI SDK] | ||
| - | |||
| - | |||
[http://ict-freak.nl/2009/10/09/powercli-virtual-machine-disk-vmdk-info/ PowerCLI: Virtual Machine Disk (VMDK) info] | [http://ict-freak.nl/2009/10/09/powercli-virtual-machine-disk-vmdk-info/ PowerCLI: Virtual Machine Disk (VMDK) info] | ||
| Line 74: | Line 59: | ||
[http://poshcode.org/1384 Get-Hostname] | [http://poshcode.org/1384 Get-Hostname] | ||
| - | |||
| - | |||
[http://blogs.vmware.com/vipowershell/2009/10/when-was-the-last-time-that-vm-was-powered-on.html When was the last time that VM was powered on?] | [http://blogs.vmware.com/vipowershell/2009/10/when-was-the-last-time-that-vm-was-powered-on.html When was the last time that VM was powered on?] | ||
| + | |||
| + | [http://halr9000.com/article/828 Adding Port Groups with PowerCLI] | ||
| + | |||
| + | [http://professionalvmware.com/2009/11/disabling-copy-paste-the-powercli-way/ Disabling Copy Paste – The PowerCLI way] | ||
| + | |||
| + | [http://www.virtu-al.net/2009/10/26/workstation-server-audit-script-v3/ Workstation & Server Audit Script V3] | ||
| + | |||
| + | [http://lucd.info/?p=859 Thick to Thin with PowerCLI and the SDK] | ||
| + | |||
| + | [http://professionalvmware.com/2009/10/a-quick-powercli-lesson-digging-for-info-who-powered-off-that-vm/ A Quick PowerCLI Lesson – Digging for Info (Who Powered Off that VM)] | ||
| + | |||
| + | [http://www.virtu-al.net/2009/10/19/powercli-mass-vm-portgroup-change/ PowerCLI: Mass VM Portgroup Change] | ||
| + | |||
| + | [http://www.virtu-al.net/2009/11/10/powercli-where-do-i-start/ PowerCLI – Where do I start ?!] | ||
| + | |||
| + | [http://vinternals.com/esxi-mastery/ ESXi Mastery] | ||
| + | |||
| + | [http://www.virtu-al.net/2009/10/30/powercli-vsphere-license-export/ PowerCLI: vSphere License Export] | ||
| + | |||
| + | [http://www.peetersonline.nl/index.php/vmware/report-vsphere-alarms-with-powershell/ Report vSphere Alarms with Powershell] | ||
| + | |||
| + | [http://www.virtu-al.net/2009/10/28/powercli-listing-cluster-primary-ha-nodes/ PowerCLI: Listing Cluster Primary HA Nodes] | ||
| + | |||
| + | [http://ict-freak.nl/2009/11/17/powercli-one-liner-to-get-vms-clusters-esx-hosts-and-datastores/ PowerCLI: One-Liner to get VMs, Clusters, ESX Hosts and Datastores] | ||
| + | |||
| + | [http://www.vmware.com/support/developer/windowstoolkit/wintk40u1/html/index.html vSphere PowerCLI 4.0 Update 1 Cmdlets Reference] | ||
| + | |||
| + | [http://communities.vmware.com/thread/235164 PowerCLI Poster] | ||
| + | |||
| + | [http://ict-freak.nl/2010/01/21/powercli-move-template/ PowerCLI: Move-Template] | ||
| + | |||
| + | [http://ict-freak.nl/2010/01/27/move-template-integrated-into-the-vesi/ Move-Template integrated into the VESI] | ||
| + | |||
| + | [http://ict-freak.nl/2010/01/28/backup-and-restore-drs-rules-with-the-vesi/ Backup and Restore DRS Rules with the VESI] | ||
| + | |||
| + | [http://www.virtu-al.net/2010/02/09/powercli-how-many-hbas/ PowerCLI: How many HBA’s ?] | ||
| + | |||
| + | [http://get-admin.com/blog/?p=941 PowerCLI: Remove SMVI snapshots] | ||
| + | |||
| + | [http://get-admin.com/blog/?p=954 PowerShell: Custom Types, and Formatting] | ||
| + | |||
| + | [http://searchvmware.techtarget.com/generic/0,295582,sid179_gci1381348,00.html Using PowerShell and PowerCLI to work with host servers] | ||
| + | |||
| + | ==== Perl ==== | ||
| + | |||
| + | [http://communities.vmware.com/docs/DOC-11135 findVMsWithRDMs.pl] | ||
| + | |||
| + | [http://communities.vmware.com/docs/DOC-11003 vmISOManagement.pl] | ||
| + | |||
| + | [http://communities.vmware.com/docs/DOC-10974 rdmManagmement.pl] | ||
| + | |||
| + | [http://communities.vmware.com/docs/DOC-11000 upgradeVMVirtualHardware.pl] | ||
| + | |||
| + | [http://communities.vmware.com/docs/DOC-11221 configureAdvHAClusterOptions.pl] | ||
| + | |||
| + | [http://communities.vmware.com/docs/DOC-11213 addExistingVMDKToVM.pl] | ||
| + | |||
| + | [http://communities.vmware.com/docs/DOC-11054 listHAClusterNodes.pl] | ||
| + | |||
| + | [http://communities.vmware.com/docs/DOC-10866 setUserDatastorePermission.pl] | ||
[http://communities.vmware.com/docs/DOC-10847 pluginExtensionManager.pl] | [http://communities.vmware.com/docs/DOC-10847 pluginExtensionManager.pl] | ||
| - | [http:// | + | [http://communities.vmware.com/docs/DOC-10883 useVIFastpassOnvMAToRunPerlScriptWithoutClearTextPassword.pl] |
| + | [http://communities.vmware.com/docs/DOC-10807 getVMsPerDatastore.pl] | ||
| + | |||
| + | [http://communities.vmware.com/docs/DOC-10809 generateVMRemoteConsoleURL.pl] | ||
| + | |||
| + | [http://communities.vmware.com/docs/DOC-10777 getVMThinProvisionedSavings.pl] | ||
| + | |||
| + | [http://communities.vmware.com/docs/DOC-10552 getShareableAndNonSharDatastore.pl] | ||
| + | |||
| + | [http://communities.vmware.com/docs/DOC-10885 getVMDiskInfo.pl] | ||
[[Category: ToDo]] | [[Category: ToDo]] | ||
Adding PowerCLI onelines for host network information (virtu-al)
| ← Older revision | Revision as of 21:28, 28 February 2010 | ||
| Line 1: | Line 1: | ||
==== Host Configuration ==== | ==== Host Configuration ==== | ||
* [http://www.peetersonline.nl/index.php/vmware/oneliner-service-console-ip-with-powercli/ Oneliner: Service Console IP with PowerCLI] | * [http://www.peetersonline.nl/index.php/vmware/oneliner-service-console-ip-with-powercli/ Oneliner: Service Console IP with PowerCLI] | ||
| + | |||
| + | * [http://www.virtu-al.net/2009/09/21/powercli-one-liners-checking-host-network-information/ List all ESX Hosts and their Service console information] | ||
| + | |||
| + | * [http://www.virtu-al.net/2009/09/21/powercli-one-liners-checking-host-network-information/ List all ESX Hosts and their VMotion Enabled Networks] | ||
* [http://www.peetersonline.nl/index.php/vmware/checking-vmware-ntp-configuration-with-powershell/ Checking VMware NTP configuration with Powershell] | * [http://www.peetersonline.nl/index.php/vmware/checking-vmware-ntp-configuration-with-powershell/ Checking VMware NTP configuration with Powershell] | ||
| Line 17: | Line 21: | ||
* [http://www.hypervisor.fr/?p=1687 Move your templates] | * [http://www.hypervisor.fr/?p=1687 Move your templates] | ||
| + | |||
| + | |||
[[Category: PowerCLI]][[Category: Host Management]] | [[Category: PowerCLI]][[Category: Host Management]] | ||
Adding PowerCLI onelines for host network information (virtu-al)
| ← Older revision | Revision as of 21:28, 28 February 2010 | ||
| Line 1: | Line 1: | ||
==== Host Configuration ==== | ==== Host Configuration ==== | ||
* [http://www.peetersonline.nl/index.php/vmware/oneliner-service-console-ip-with-powercli/ Oneliner: Service Console IP with PowerCLI] | * [http://www.peetersonline.nl/index.php/vmware/oneliner-service-console-ip-with-powercli/ Oneliner: Service Console IP with PowerCLI] | ||
| + | |||
| + | * [http://www.virtu-al.net/2009/09/21/powercli-one-liners-checking-host-network-information/ List all ESX Hosts and their Service console information] | ||
| + | |||
| + | * [http://www.virtu-al.net/2009/09/21/powercli-one-liners-checking-host-network-information/ List all ESX Hosts and their VMotion Enabled Networks] | ||
* [http://www.peetersonline.nl/index.php/vmware/checking-vmware-ntp-configuration-with-powershell/ Checking VMware NTP configuration with Powershell] | * [http://www.peetersonline.nl/index.php/vmware/checking-vmware-ntp-configuration-with-powershell/ Checking VMware NTP configuration with Powershell] | ||
| Line 17: | Line 21: | ||
* [http://www.hypervisor.fr/?p=1687 Move your templates] | * [http://www.hypervisor.fr/?p=1687 Move your templates] | ||
| + | |||
| + | |||
[[Category: PowerCLI]][[Category: Host Management]] | [[Category: PowerCLI]][[Category: Host Management]] | ||
Adding PowerCLI onelines for host network information (virtu-al)
| ← Older revision | Revision as of 21:28, 28 February 2010 | ||
| Line 1: | Line 1: | ||
==== Host Configuration ==== | ==== Host Configuration ==== | ||
* [http://www.peetersonline.nl/index.php/vmware/oneliner-service-console-ip-with-powercli/ Oneliner: Service Console IP with PowerCLI] | * [http://www.peetersonline.nl/index.php/vmware/oneliner-service-console-ip-with-powercli/ Oneliner: Service Console IP with PowerCLI] | ||
| + | |||
| + | * [http://www.virtu-al.net/2009/09/21/powercli-one-liners-checking-host-network-information/ List all ESX Hosts and their Service console information] | ||
| + | |||
| + | * [http://www.virtu-al.net/2009/09/21/powercli-one-liners-checking-host-network-information/ List all ESX Hosts and their VMotion Enabled Networks] | ||
* [http://www.peetersonline.nl/index.php/vmware/checking-vmware-ntp-configuration-with-powershell/ Checking VMware NTP configuration with Powershell] | * [http://www.peetersonline.nl/index.php/vmware/checking-vmware-ntp-configuration-with-powershell/ Checking VMware NTP configuration with Powershell] | ||
| Line 17: | Line 21: | ||
* [http://www.hypervisor.fr/?p=1687 Move your templates] | * [http://www.hypervisor.fr/?p=1687 Move your templates] | ||
| + | |||
| + | |||
[[Category: PowerCLI]][[Category: Host Management]] | [[Category: PowerCLI]][[Category: Host Management]] | ||
New page
'' by Wil van Antwerpen ''
Basically there are two ways in which you can get the VI Perl Toolkit working on OS X.
One way is by using the CPAN functionality of Perl which is already installed on your Mac and the other way is by using [http://www.macports.org/ MacPorts].
I will first walk you through how-to this using the CPAN Network and then show you how to get it working using macports.
Obviously, you will only need to use one of these methods in order to use the Toolkit.
FOR THE MOMENT I SUGGEST USING THE CPAN METHOD as MacPorts is still giving me problems.
== Installing Developer Tools ==
The VI Perl Toolkit needs to get a few extra modules added to the current perl setup that is by default installed on Mac OS X. In order to get these modules we use CPAN or macPorts.
Both have some prerequisites of their own and in this case it is the same for both.
Your system must have "make" installed.
The most straightforward way to get that package installed is to take your original OS X installation disk and install Developer Tools (XcodeTools.mpkg) which can be found under Option Installs on the DVD.
Just keep the default settings and you'll be fine.
It is a bit big though (over 2GB) so it is a steep requirement for just getting the VI Perl toolkit to work OK. If you don't have the space, the part that is needed is the BSD "make" command and a number of other commands. It should be sufficient to install the UNIX Development Support (or BSD SDK) sub-package of the Developer Tools.
== Getting the Perl VI Toolkit SDK ==
First step is to download the latest perl SDK from:
http://communities.vmware.com/community/developer/forums/vsphere_sdk_perl
for both OS X Leopard and Snow Leopard I downloaded the same 32 bits .tar.gz linux installer.
After downloading unpack the archive by running
tar -xvzf VMware-vSphere-SDK-for-Perl-4.0.0-161974.i386.tar.gz
from the command line.
cd into the new vmware-vsphere-cli-distrib/ folder
cd vmware-vsphere-cli-distrib/
and run:
perl MakeFile.pl
this will most likely return the following warnings:
Warning: prerequisite Class::MethodMaker 2.08 not found.
Warning: prerequisite Crypt::SSLeay 0.51 not found.
Warning: prerequisite SOAP::Lite 0.67 not found.
Warning: prerequisite UUID 0.03 not found.
Writing Makefile for VIPerlToolkit
The warnings we see here are the modules we need to install in perl that are missing for the toolkit to work.
So we are going to install these modules first, before we can continue with our main installation.
== Installing missing perl dependencies ==
So now we need to setup CPAN or MacPorts unless you already have it working, in that case you can skip the installation part.
=== CPAN: Is /usr/local setup? ===
By default cpan will try to install some documentation under the /usr/local folder, so this folder has to exist and it needs to have the correct ownership privileges setup.
See if the folder already exists:
$ ls /usr/
X11 bin lib sbin standalone
X11R6 include libexec share
In my case it isn't there yet, so create it:
$ mkdir /usr/local
mkdir: /usr/local: Permission denied
Ha!.. you can't create the folder unless you have elevated rights (of course)
$ sudo mkdir /usr/local
Password:
So now we create the folder, but as you will see its owned by root and we can't install our packages in there unless we allow our user.
$ ls -alh /usr/local
total 0
drwxr-xr-x 2 root wheel 68B Feb 27 01:06 .
drwxr-xr-x@ 12 root wheel 408B Feb 27 01:06 ..
In my case the username is "topaz", replace "topaz" with your username below:
$ sudo chown topaz:topaz /usr/local
$ ls -alh /usr/local
total 0
drwxr-xr-x 2 topaz topaz 68B Feb 27 01:06 .
drwxr-xr-x@ 12 topaz topaz 408B Feb 27 01:06 ..
=== CPAN: Configuration ===
With the developer tools setup now you have to configure CPAN. You can also use this step if you want to change your CPAN configuration.
Configuring CPAN makes sure that the tools finds the necessary commands on your system (make et al). To do that, run:
perl -MCPAN -e shell
cpan> o conf init
This throws up a bunch of questions.
/Users/topaz/.cpan/CPAN/MyConfig.pm initialized.
CPAN is the world-wide archive of perl resources. It consists of about 100 sites that all replicate the same contents all around the globe. Many countries have at least one CPAN site already. The resources found on CPAN are easily accessible with the CPAN.pm module. If you want to use CPAN.pm, you have to configure it properly.
If you do not want to enter a dialog now, you can answer 'no' to this question and I'll try to autoconfigure. (Note: you can revisit this dialog anytime later by typing 'o conf init' at the cpan prompt.)
Are you ready for manual configuration? [yes]
You can take the defaults for pretty much all of them, so just press enter.
It is fine if the configuration script doesn't find programs for things like lynx, wget, ncftp, ftp etcetera...
The main things to select are country to download from and the site(s) which you want to use for the repositories. Just make the most logical selections here.
=== CPAN: Installing the VI Perl Toolkit dependencies ===
Now we'll get the missing dependencies by running them one by one. We could add all of these on a single line, but we want it to be easy to see if the install was successful so we are running them one by one.
cpan Class::MethodMaker
this should now end with:
Appending installation info to /Library/Perl/Updates/5.8.8/darwin-thread-multi-2level/perllocal.pod
/usr/bin/make install -- OK
So continue with the next one:
cpan Crypt::SSLeay
Just choose the defaults if questions are asked. As long as it ends like the previous package you are fine.
Next up is:
cpan SOAP::Lite
Same same, choose defaults. In my setup it nagged that I missed out on some dependencies of its own and if I wanted to add those.. Sure.. let the installer add anything it suggests.
Finally:
cpan UUID
Which down here installed fine too, so now we can finally get back to installing the VI Perl Toolkit.
=== Setting up MacPorts ===
Go to the [http://www.macports.org/install.php Macports install page] and download the .dmg file for your environment and run the installer.
=== MacPorts: Installing the VI Perl Toolkit dependencies ===
sudo port install p5-class-methodmaker
On my Snow Leopard machine, this dragged in a complete new version of Perl (5.8.9), very nice.
Then we need Crypt::SSLeay
sudo port install p5-crypt-ssleay
and SOAP::Lite
sudo port install p5-soap-lite
Finally UUID
sudo port install p5-uuid
Now as I said it pulled in its own perl environment... so it turns out that we need to add another module which is missing.
sudo part install p5-xml-libxml
Woww this was quick and we can now get back to installing the VI Perl Toolkit, but first close your terminal as you need to restart that one in order to use the new Perl version installed in /opt/local/bin instead of the default one which is still in /usr/bin
== Install VI Perl Toolkit ==
Now go back to the folder where you unpacked the VI Perl Toolkit:
perl MakeFile.pl
Warning: prerequisite UUID 0.03 not found. We have 0.020.
Writing Makefile for VIPerlToolkit
That UUID is not yet version 0.03 seems to be OK (On Snow Leopard it is 0.04)
With this version of the toolkit, there are no tests defined for the make file so install it directly:
sudo make install
Password:
Manifying blib/man3/VMware::VIM25Runtime.3pm
Manifying blib/man3/VMware::VIM2Stub.3pm
Manifying blib/man3/VMware::VIM25Stub.3pm
Manifying blib/man3/VMware::VIM2Runtime.3pm
Installing /Library/Perl/5.8.8/vmware-install.pl
Installing /Library/Perl/5.8.8/VMware/VICommon.pm
Installing /Library/Perl/5.8.8/VMware/VICredStore.pm
....
many more lines here
....
Installing /usr/share/doc/vmware-viperl/doc/samples/vm/vmregister.pl
Installing /usr/share/doc/vmware-viperl/doc/samples/vm/vmunregister.pl
Installing /usr/share/doc/vmware-viperl/doc/samples/WSMan/checksensorhealth.pl
Installing /usr/share/doc/vmware-viperl/doc/samples/WSMan/firmwarerevisions.pl
Installing /usr/share/doc/vmware-viperl/doc/samples/WSMan/listfrus.pl
Installing /usr/share/doc/vmware-viperl/doc/samples/WSMan/listpowersupplies.pl
and that's how a successful Perl Toolkit install looks like.
If you want you can now delete your unpacked setup files and VI Perl tar.gz file.
You may want to keep the makefile around if you later want to uninstall this.
== Uninstall Developer Tools and cleaning up CPAN ==
If you want to uninstall the Developer Tools, you need to run the command:
/Developer/Library/uninstall-devtools --mode=all
Be aware that you can then no longer use CPAN or Macports to extend your system!
From CPAN you can remove an installed module by running a clean command.
Such as:
cpan clean Class::MethodMaker
This is a troubleshoot step and sometimes needed if a module gets stuck while trying to install it.
Again don't remove any module your install depends on.
If CPAN still gives problems, then you can remove your local CPAN configuration and cache directory by running:
rm -r ~/.cpan
== External link ==
The following link turned out to be very helpful while I was trying to get this to work:
[http://itknowledgeexchange.techtarget.com/virtualization-pro/managing-vi3-from-os-x-1051-leopard/ Managing VMware Infrastructure 3 (VI3) from OS X (10.5.1 Leopard)]
[[Category: Perl]]
| ← Older revision | Revision as of 16:49, 27 February 2010 | ||
| Line 4: | Line 4: | ||
[http://www.perl.org/docs.html Perl.org Online Documentation] | [http://www.perl.org/docs.html Perl.org Online Documentation] | ||
| + | [[Install the VI Perl Toolkit on OS X]] | ||
==== Scripts ==== | ==== Scripts ==== | ||
| ← Older revision | Revision as of 16:49, 27 February 2010 | ||
| Line 4: | Line 4: | ||
[http://www.perl.org/docs.html Perl.org Online Documentation] | [http://www.perl.org/docs.html Perl.org Online Documentation] | ||
| + | [[Install the VI Perl Toolkit on OS X]] | ||
==== Scripts ==== | ==== Scripts ==== | ||








