Like my scripts ?

If you donate a value of £0.00 GBP or more then we will create a link to a site of your choice. For this to work you must click the Return button on the PayPal page after you have completed the donation.

Display Preference:
Optional URL:

At the moment I am saving for a test environment at home as believe it or not most of my scripts are written in my lunch break or by using a friends test system over a slow link, just think of what I could achieve with my own system !

Anyway, I was actually asked by someone if I had a donate button so please do not think me cheeky for adding this, if you would like to show your appreciation then please go ahead, it would really be appreciated, if not just leave a nice comment as these are also very gratefully received.

  • #1 written by 5truja
    about 7 months ago

    I did try to import you scripts in a Echo Shell. It is imported there and I have vCenter as as managed host. Your powerpack is directly under root. When I try to perform anything I get Dialog box saying that connection is not established and that I should connect to some managed host (which is allready connected). Any answers?

  • #2 written by Virtu-Al
    about 7 months ago

    Yeah sorry I need to add a further check in there for the version of PowerCLI, you will need to install PowerCLI 4.0 U1 for this to work, please note that PowerCLU 4.0 U1 does not need ESX 4.0 U1 you can use it against previous versions !

    Hope this helps.

    Alan

  • #3 written by 5truja
    about 7 months ago

    I was conviced that I allready had CLI U1 installed but I was wrong :-( . I installed it and it works great. And it’s a great stuff.

    Kind regards
    5truja

  • #4 written by Virtu-Al
    about 7 months ago

    Glad it worked out ok

  • #5 written by Tim Maes
    about 4 months ago

    Great script Al.
    I have code that was added for orphaned vm which was added to version 3. It would be great if you would consider adding to you version stream so I don’t have to update every time you release a new version.

    This is from version 3.x
    # Orphaned VM’s
    $ShowOrphaned = $true

    # —- Orphaned VMs’
    If ( $showOrphaned ) {
    Write-CustomOut “..Checking for Orphaned VMs’”
    $myCol = @()
    $arrUsedDisks = $fullvmAll | % {$_.Layout} | %{$_.Disk} | % {$_.DiskFile}
    foreach ($strDatastore in $Datastores)
    {
    Write-CustomOut “…searching: $($strDatastore.Name)”
    If ( $($strDatastore.Name) -notlike “SOE” ) {
    $ds = Get-Datastore -Name $strDatastore.Name | % {Get-View $_.Id}
    $fileQueryFlags = New-Object VMware.Vim.FileQueryFlags
    $fileQueryFlags.FileSize = $true
    $fileQueryFlags.FileType = $true
    $fileQueryFlags.Modification = $true
    $searchSpec = New-Object VMware.Vim.HostDatastoreBrowserSearchSpec
    $searchSpec.details = $fileQueryFlags
    $searchSpec.matchPattern = “*.vmdk”
    $searchSpec.sortFoldersFirst = $true
    $dsBrowser = Get-View $ds.browser
    $rootPath = “["+$ds.summary.Name+"]”
    $searchResult = $dsBrowser.SearchDatastoreSubFolders($rootPath, $searchSpec)

    foreach ($folder in $searchResult)
    {
    foreach ($fileResult in $folder.File)
    {
    if ($fileResult.Path)
    {
    Write-Verbose “….Path: $($folder.FolderPath) $($fileResult.Path)” #Change to verbose
    if (-not ($arrUsedDisks -contains ($folder.FolderPath + $fileResult.Path))){
    Write-CustomOut “…..Found orphaned VMDK: $($folder.FolderPath) $($fileResult.Path)”
    $row = “” | Select DS, Path, File, Size, ModDate
    $row.DS = $strDatastore.Name
    $row.Path = $folder.FolderPath
    $row.File = $fileResult.Path
    $row.Size = $fileResult.FileSize
    $row.ModDate = $fileResult.Modification
    #$row.Host = (Get-View $ds.Host[0].Key).Name
    $myCol += $row
    }
    }
    }
    }
    } else {
    Write-CustomOut “….Skipping datatore”
    }
    }

    $myReport += get-sectionheader “orphaned” “Orphaned VMs’ : $($myCol.Count)”
    If (($myCol | Measure-Object).count -gt 0) {
    $MyReport += InsertCustomTable $myCol
    } else {
    $myReport += “No Orphaned VM’s”
    }
    $myReport += get-sectionheaderClose
    }

  • #6 written by Mike Semon
    about 2 months ago

    You guys are awesome. I have been using your reporting scripts. Keep up the good work.

    -Mike

  • #7 written by tien lam nguyen
    about 1 month ago

    Hi, There

    your script is great. I have been using it forthe last week.

    I would like to make a suggestion. Under the snapshots section I would be nice if we could get the amount in MB of the autual size of the snapshots.

    Right now we only get the total amount of disk size

  • #8 written by Cyril
    about 1 month ago

    Awesome site Al. I have been playing with your scripts and impressed my colleagues with the results. you make me look good :-)
    I use your vCheck regularly and was wondering how to add something to it.
    I would like to monitor my LUN space. something to tell me how much space I have left per LUN, wich one is over-provisioned…
    Thanks

  • #9 written by LP
    about 1 week ago

    Hi Al,

    First of all kudos for the excellent job you guys have been doing.

    I was trying to use the script “who created the VM” posted by you. Unfortunately, all its shows is CreatedBy “unknown” and CreatedOn “Unknown”. Only a couple of VMs out of the bunch shows the users and the date created.

    I must be doing something wrong here.

    Any reason as to why the output shows “unknown” or suggestions for the script to produce the desired result.

    Appreciate your help in advance.

    Regards,
    LP

  • #10 written by Daniel
    about 6 days ago

    Hello Al,

    i´m a new to powershell and have a simple (or dumb) question:

    I want to set the corestorage claimrule vor my ESXi host to round robin.

    In the past i used following command on the ESX SC:

    esxcli nmp satp setdefaultpsp –satp VMW_SATP_DEFAULT_AA –VMW_PSP_RR

    Can you please tell me how i can manage this for an ESXi host with Powershell?

    Thank you and regards

    Daniel