alanrenouf / vcheck-vsphere Goto Github PK
View Code? Open in Web Editor NEWvCheck Daily Report for vSphere
License: MIT License
vCheck Daily Report for vSphere
License: MIT License
Just a thought, since there have been a number of release lately it may be worth starting to tag releases:
http://git-scm.com/book/en/Git-Basics-Tagging
This could then replace the changelog.txt file that gets forgotten about occasionally, and gives us more of an idea what has changes between versions.
when running vCheck for the first time, some of the default values have a space before, or after, or both.
This is not a problem for integer, but for strings the match or notmatch operators don't work.
Example : I use the default value provided for 62 Unwanted Virtual Hardware which is [ VirtualUSBController|VirtualParallelPort|VirtualSerialPort]
so the generated var $unwantedHadware in the script is " VirtualUSBController|VirtualParallelPort|VirtualSerialPort" instead of "VirtualUSBController|VirtualParallelPort|VirtualSerialPort"
and then the script reports nothing because of the match operator not matching.
Default values provided during first run should be [something](not [ something] or [ something ]).
Adding as an enhancement until someone has time to look at it- if there is benefit to it?
I feel like the functionality of the following plugins should be merged into the main vCheck script:
Plugins Not up to date or installed.ps1
Report on Plugins.ps1
We could then have a GlobalVariables.ps1 entry to determine if they are appended to the report.
This would mean that if these plugins are updated, there is no need to update across all vCheck projects. This also means that plugins in the plugins directory only refer to information about that particular environment (i.e. vSphere/Exchange/etc), whereas these plugins refer more to the vCheck environment.
If these plugins are to be useful, the plugins.xml also needs to be updated when plugins are updated or added:
http://www.virtu-al.net/vcheck/plugins/plugins.xml
What do you think?
I'm sure this has been thought about before but...wouldn't it be nice to have some sort of organization to the plugins?
I'm not sure of the best way to do this, maybe a numbering scheme that would group similar plugins?
For Example:
100-199 - All vCenter related plugins
200-299 - All Host related plugins
300-399 - All Cluster related plugins
400-499 - All VM related plugins
etc
Far from perfect but would at least keep the major categories together.
A more drastic approach may be to add a category/group to each plugin defining the output order.
Thoughts?
We have moved to vCentre 5.1 and upgraded our HOST from 4.1 to ESXi5.1. We moved our vCheck as well. The issue we are having is under Hardware status warnings/errors we are seeing alerts status (Yellow) but in vCentre under Hardware Status the sensors are all normal
VMs with hardware version 10 return 0 and so are listed if we set to check vms prior to hardware version 10.
Unexpected Token "isnotnullempty" in expression or statement
51 Syslog Name.ps1: line13 character:256
I need to provide multiple users in which these scripts will not check for snapshots for users listed.
Is this how it should be formatted?
$snapshotUserException = "s-veeam, domain\username"
or should we modify the get-view statement to take multiple variables?
$snapshotUserException1 = "s-veeam"
$snapshotUserException2 = "domain\username"
(($_.userName -notmatch $snapshotUserException1) -or ($_.userName -notmatch $snapshotUserException2))
Running this script on a vcenter with several clusters, only the last cluster collected by Get-Cluster is displayed in report.
I think $problemDatastores is erased each time a cluster is processed by foreach iteration, then only the last cluster is kept.
Unexpected token '.5' in expression or statement.
At c:\vCheck-vSphere-master\Plugins\52 Datastore Consistency.ps1:30 char:23
Just adding these as possible enhancements, if someone has time to look at them. Otherwise I'll get to them at some point...
We should be aiming on moving all style-related variables to the style files. This will require less configuration on first run, and greater separation of script logic and markup.
Remove style variables from GlobalVariables.ps1 and push to style .ps1 files:
$Colour1
$Colour2
$TitleTxtColour
Should also remove the "00 1st Plugin - Select Report Header Image.ps1" file and incorporate this into style files. We can also remove the Headers directory and all headers it contains (or move them to "default" style).
Something that I found useful in our environment, posting here to see if there is any value in merging to vCheck.
The basic idea is that the vCheck.ps1 has been extended to allow table formatting rules to be passed along to it. These rules are defined in the plugin (see 03 Datastore Information.ps1 for example). Formatting can be applied to Cells, Rows, or Columns.
Can be grabbed from here (only datastores report has been modified at this stage)
https://github.com/Sneddo/vCheck-vSphere
It may not be as easy to use as possible (i.e. perhaps this could be defined in a similar fashion to settings?), but the basic idea is there.
Not sure if this is correct way of asking for an enhancement, but..
We use Zerto as a DR replication tool and the helper VM's always clutter the vCheck report. Would it be possible to add a VM name filter to plugins 27, 66 and 100?
These are the plugins for VM Tools Issues, Misnamed VM's and VM's with CPU and Memory Reservations.
Please point me in the right direction if this is not the correct forum.
I am currently testing with only two plugins:
I am getting the following message with latest version of vCheck:
You cannot call a method on a null-valued expression.
At ... vCheck.ps1:289 char:25
$type = $path.substring($path.LastIndexOf(".")+1)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
I keep getting these errors -- quite a few of them. Here are some examples:
2:48:59 PM .. start calculating VMs needing snapshot consolidation by Luc Dekens, Frederic Martin v1.2
Exception calling "Add" with "2" argument(s): "Item has already been added. Key in dictionary: 'HostSystem-host-116' Key being
added: 'HostSystem-host-116'"
At C:\Users\xxx\Downloads\vCheck-vSphere-master (1)\vCheck-vSphere-master\Plugins\45 VMs needing snapshot
consolidation.ps1:5 char:17
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Exception calling "Add" with "2" argument(s): "Item has already been added. Key in dictionary: 'HostSystem-host-1648' Key being
added: 'HostSystem-host-1648'"
At C:\Users\xxx\Downloads\vCheck-vSphere-master (1)\vCheck-vSphere-master\Plugins\45 VMs needing snapshot
consolidation.ps1:5 char:17
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Exception calling "Add" with "2" argument(s): "Item has already been added. Key in dictionary: 'HostSystem-host-1700' Key being
added: 'HostSystem-host-1700'"
At C:\Users\xxx\Downloads\vCheck-vSphere-master (1)\vCheck-vSphere-master\Plugins\45 VMs needing snapshot
consolidation.ps1:5 char:17
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
The term 'Get-VDSwitch' is not recognized as the name of a cmdlet, function, script file, or operable program.
The term 'Get-VDPortgroup' is not recognized as the name of a cmdlet, function, script file, or operable program.
Just flagging this as a "Todo" item...
On long reports it can be a bit tedious navigating. I'm suggesting we include a table of contents (enabled by global variable), and have "back to top" links for each plugin to allow quick navigation.
This could possibly be expanded in future releases to include a summary section. e.g. instead of just linking to the plugin section by name "Datastore Information", link using the Plugin title "Datastores (Less than 25% Free) : 118". This will require a bit more work and changes to style handling.
I get some errors when running vCheck.ps1, installed it today from GIT so latest version.
....
15:46:35 ..finished calculating Datastores with Storage IO Control Disabled by Robert van den Nieuwendijk v1,1
15:46:35 ..finished calculating VMs by Operating System by Raymond v1,1
15:46:35 ..finished calculating Unwanted virtual hardware found by Frederic Martin v1,1
Cannot convert argument "_this", with value: "VimApi_50.ManagedObjectReference", for "SearchDatastoreSubFolders_Task" t
o type "VimApi_51.ManagedObjectReference": "Cannot convert the "VimApi_50.ManagedObjectReference" value of type "VimApi
_50.ManagedObjectReference" to type "VimApi_51.ManagedObjectReference"."
At C:\temp\vCheck-vSphere-master\Plugins\64 Snapshots Oversize.ps1:44 char:4
$taskMoRef = $dsb.Client.VimService.SearchDatastoreSubFolders_Task($dsBrowse ...
Exception calling "WaitForTask" with "1" argument(s): "Value cannot be null.
Parameter name: moRef"
At C:\temp\vCheck-vSphere-master\Plugins\64 Snapshots Oversize.ps1:45 char:13
$task = [VMware.Vim.VIConvert]::ToVim($dsb.WaitForTask([VMware.Vim.V ...
- CategoryInfo : NotSpecified: (:) [], MethodInvocationException
- FullyQualifiedErrorId : ArgumentNullException
Cannot convert argument "_this", with value: "VimApi_50.ManagedObjectReference", for "SearchDatastoreSubFolders_Task" t
o type "VimApi_51.ManagedObjectReference": "Cannot convert the "VimApi_50.ManagedObjectReference" value of type "VimApi
_50.ManagedObjectReference" to type "VimApi_51.ManagedObjectReference"."
At C:\temp\vCheck-vSphere-master\Plugins\64 Snapshots Oversize.ps1:44 char:4
$taskMoRef = $dsb.Client.VimService.SearchDatastoreSubFolders_Task($dsBrowse ...
Exception calling "WaitForTask" with "1" argument(s): "Value cannot be null.
Parameter name: moRef"
At C:\temp\vCheck-vSphere-master\Plugins\64 Snapshots Oversize.ps1:45 char:13
$task = [VMware.Vim.VIConvert]::ToVim($dsb.WaitForTask([VMware.Vim.V ...
- CategoryInfo : NotSpecified: (:) [], MethodInvocationException
- FullyQualifiedErrorId : ArgumentNullException
Cannot convert argument "_this", with value: "VimApi_50.ManagedObjectReference", for "SearchDatastoreSubFolders_Task" t
o type "VimApi_51.ManagedObjectReference": "Cannot convert the "VimApi_50.ManagedObjectReference" value of type "VimApi
_50.ManagedObjectReference" to type "VimApi_51.ManagedObjectReference"."
At C:\temp\vCheck-vSphere-master\Plugins\64 Snapshots Oversize.ps1:44 char:4
$taskMoRef = $dsb.Client.VimService.SearchDatastoreSubFolders_Task($dsBrowse ...
Exception calling "WaitForTask" with "1" argument(s): "Value cannot be null.
Parameter name: moRef"
At C:\temp\vCheck-vSphere-master\Plugins\64 Snapshots Oversize.ps1:45 char:13
$task = [VMware.Vim.VIConvert]::ToVim($dsb.WaitForTask([VMware.Vim.V ...
- CategoryInfo : NotSpecified: (:) [], MethodInvocationException
- FullyQualifiedErrorId : ArgumentNullException
Cannot convert argument "_this", with value: "VimApi_50.ManagedObjectReference", for "SearchDatastoreSubFolders_Task" t
o type "VimApi_51.ManagedObjectReference": "Cannot convert the "VimApi_50.ManagedObjectReference" value of type "VimApi
_50.ManagedObjectReference" to type "VimApi_51.ManagedObjectReference"."
At C:\temp\vCheck-vSphere-master\Plugins\64 Snapshots Oversize.ps1:44 char:4
$taskMoRef = $dsb.Client.VimService.SearchDatastoreSubFolders_Task($dsBrowse ...
Exception calling "WaitForTask" with "1" argument(s): "Value cannot be null.
Parameter name: moRef"
At C:\temp\vCheck-vSphere-master\Plugins\64 Snapshots Oversize.ps1:45 char:13
$task = [VMware.Vim.VIConvert]::ToVim($dsb.WaitForTask([VMware.Vim.V ...
- CategoryInfo : NotSpecified: (:) [], MethodInvocationException
- FullyQualifiedErrorId : ArgumentNullException
Cannot convert argument "_this", with value: "VimApi_50.ManagedObjectReference", for "SearchDatastoreSubFolders_Task" t
o type "VimApi_51.ManagedObjectReference": "Cannot convert the "VimApi_50.ManagedObjectReference" value of type "VimApi
_50.ManagedObjectReference" to type "VimApi_51.ManagedObjectReference"."
At C:\temp\vCheck-vSphere-master\Plugins\64 Snapshots Oversize.ps1:44 char:4
$taskMoRef = $dsb.Client.VimService.SearchDatastoreSubFolders_Task($dsBrowse ...
Exception calling "WaitForTask" with "1" argument(s): "Value cannot be null.
Parameter name: moRef"
At C:\temp\vCheck-vSphere-master\Plugins\64 Snapshots Oversize.ps1:45 char:13
$task = [VMware.Vim.VIConvert]::ToVim($dsb.WaitForTask([VMware.Vim.V ...
- CategoryInfo : NotSpecified: (:) [], MethodInvocationException
- FullyQualifiedErrorId : ArgumentNullException
15:46:40 ..finished calculating Snapshots Oversize by Raphael Schitz v1,1
15:46:40 ..finished calculating Mis-named virtual machines by Frederic Martin v1,1
15:46:40 ..finished calculating Host Build versions in use by Frederic Martin v1,1
15:46:45 ..finished calculating Disk Max Total Latency by Raphael Schitz, Frederic Martin v1,1
This one is a long way off, but I think we should aim to support graphs as an output now that the resource code is pretty much done. Probably a 7.x release goal, but logging to get ideas flowing.
Will need to investigate different graphing APIs.
From memory Google has one that you can specify the graph parameters via URL, and we can download the resulting image to include in the report, or include in img tags.
maxsamples value is set to 10000 in theses two scripts, instead of using the global var $MaxSampleVIEvent
So when you configure report to display last past 5 days for example, you don't see everything.
This is failing on VMs that have spaces in the name. I have vCenter Operations Manager loaded, and the OVF File places the VMs in a vApp and names them "Analytics VM" and "UI VM" similar problems with HyTrust VMs, and other OVF created VMs that have their own naming convention.
There is a
-replace " ",""
in there. What was the intent of that?
This plugin throws divide by 0 errors if you have a cluster with no vm's in it. I'm using powercli 5.1.
Attempted to divide by zero.
At D:\71 Capacity Planning.ps1:25 char:36
$VmCpuAverage = $CluCpuUsageAvg/ <<<< (Get-Cluster $cluv.name|Get
Attempted to divide by zero.
At D:\71 Capacity Planning.ps1:36 char:36
$VmMemAverage = $CluMemUsageAvg/ <<<< (Get-Cluster $cluv.name|Get
I'm curious as to what to do about this error.
12:44:24 AM ..start calculating Datastore Consistency by Robert Sexstone v1.2.5
parsing ":local|datastore" - Quantifier {x,y} following nothing.
At C:\Users\xxx\Downloads\vCheck-vSphere-master-2014-02-06\vCheck-vSphere-master\Plugins\52 Datastore Consistency.ps1:23
char:33
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
I get quite a few of these errors. Does there need to be some logic added to see if problemDatastores actually has something in it? Or is there something else wrong with the way the match is constructed?
It looks like there should be this
if ($problemDatastores -ne $null) {
}
put around line 23 of the current version.
When I ran this on a single datacenter there were no errors. When I expanded my selection to multiple datacenters I get this:
6:21:22 PM ..start calculating ESXi Inode Exhaustion by Matthias Koehler v1.0
Get-EsxCli : 2/6/2014 6:22:39 PM Get-EsxCli Thread failed to start.
At C:\Users\xxxx\Downloads\vCheck-vSphere-master-2014-02-06\vCheck-vSphere-master\Plugins\101 ESXi Inode Usage.ps1:7 char:12
$EsxCli = Get-EsxCli -VMHost $_
~~~~~~~~~~~~~~~~~~~~~
At this point the execution of vCheck seems to have come to a sudden stop.
Any suggestions about what might be the issue?
We have 4 Datastore Clusters in our enviroment but there is only 1 reported by vCheck.
Number of Clusters: 5
Number of Datastore Clusters: 1
Number of Datastores: 52
Any idea what that that could be?
It used to work great when i was running vCenter Server 5.0 on windows, but doesn't' work anymore since i upgraded to vCSA 5.5.
Powershell reports a null object value for line 14.
Blank line between last setting and "#End of Settings" causes an equal sign to appear on line 5 after running vcheck -config.
The term '=' is not recognized as the name of a cmdlet, function, script file,
or operable program. Check the spelling of the name, or if a path was included,
verify that the path is correct and try again.
At D:\77 Lost access to volume.ps1:5 char:2
My apologies for not understanding how GitHub works...
Issue - script is pulling legit files
Example - You have a VM named 'abc-abc-abcabc' which will result in a valid vmdk file named 'abc-abc-abcabc.vmdk' and will be identified improperly as a phantom vmdk.
A simple fix seems to be to replace:
if ($theVMdisk.Filename -like "*-??????.vmdk"){
with:
if ($theVMdisk.Filename -match "-\d{6}.vmdk"){
This way it is looking for 6 digits as opposed to 6 characters
Hi Alan,
On this plugin I have an error due to illegal characters on line 10 which appear in place of simple quote.
Kindest Regards,
Greg.
Just logging this so i remember to make this change, was thinking it would be cool to either have the output telling us how many plugins have run, this is useful when watching it run.....
[1 of 109] 5:25:35 PM ..start calculating s/vMotion Information by Alan Renouf v1.0
Or what would be cooler is if we could get write-progress to add the status bar. Must look into this when its not 3:30 AM!
$Title = "Security settings of Distibuted Virtual Switches"
$Header = "Security settings of Distibuted Virtual Switches"
$Comments = "Security settings of Distibuted Virtual Switches, further information is available here."
$Display = "Table"
$Author = "Fred Witteman"
$Version = 1.0
$dvSwitchSecurity = (Get-View -ViewType VmwareDistributedVirtualSwitch -Property Name,Config.DefaultPortConfig | `
Select-Object -Property Name,
@{N="Allow Promiscuous";E= {$.Config.DefaultPortConfig.SecurityPolicy.AllowPromiscuous.Value}},
@{N="Allow MAC Address Change";E= {$.Config.DefaultPortConfig.SecurityPolicy.MacChanges.Value}},
@{N="Allow Forged Transmits";E= {$_.Config.DefaultPortConfig.SecurityPolicy.ForgedTransmits.Value}})
@($dvSwitchSecurity)
All of my ESX Hosts have 5 or 6 vswitch, and all of these vswitch and their port group have security policies set to reject.
Don't know why but when running this script, it reports that all vSwitch2 for all hosts have their 3 security policies set to accept ...
When using "thick" as $diskformat, EagerZeroedThick format disks are not returned.
Replacing -eq $diskformat with -match $dsikformat would do the trick.
Cannot convert argument "0", with value: "VimApi_50.ManagedObjectReference", for "SearchDatastoreSubFolders_Task" to type "VimApi_51.ManagedObjectReference": "Cannot convert the "VimApi_50.ManagedObjectReference" value of type "VimApi_50.
ManagedObjectReference" to type "VimApi_51.ManagedObjectReference"."
At C:\vCheck\Plugins\64 Snapshots Oversize.ps1:44 char:71
$taskMoRef = $dsb.Client.VimService.SearchDatastoreSubFolders_Task <<<< ($dsBrowserMoRef, $dir, $searchSpec)
Exception calling "WaitForTask" with "1" argument(s): "Value cannot be null.
Parameter name: moRef"
At C:\vCheck\Plugins\64 Snapshots Oversize.ps1:45 char:67
$task = [VMware.Vim.VIConvert]::ToVim($dsb.WaitForTask <<<< ([VMware.Vim.VIConvert]::ToVim($taskMoRef)))
$DSDoNotInclude =":local|datastore"
How can this be a valid match expression? "*" is not allowed to be the 1st character of a regex unless it is quoted. I'm getting errors:
parsing ":local|datastore" - Quantifier {x,y} following nothing.
At \YYY\Users\xxx\PowerShell\vCheck\vCheck-vSphere-master-2014-02-21\Plugins\52 Datastore Consistency.ps1:23 char:33
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Does this string actually work for anyone? Or is everyone replacing it with their own valid string?
Just wanted to post a comment on the recent email changes.
Course I love the progress(!), but it's not without a bit of issues.
For example, the new format is pretty much unreadable via Gmail and Lotus Notes (which happen to be the way I read daily reports).
I do understand formatting HTML emails across different clients is a very difficult task. Just wanted to make everyone aware...as unfortunately, not everyone uses Exchange/Outlook (boy I miss those days!!).
The fix me for so far has been to switch to using an attachment, which isn't quite as convenient but works well.
This report took 1580.7 minutes to run all checks.
The following plugins took longer than 60 seconds to run, there may be a way to optimize these or remove them if not needed
79 Find VMs in uncontrolled snapshot mode.ps1 65309.3
33 VM CPU Usage.ps1 10618.72
32 VM CPU Percent RDY.ps1 6150.4
72 s-vMotion Information.ps1 3273.73
36 Host Alarms.ps1 2446.52
How can I best go about getting some insight into how these run times might be reduced? It seems crazy that these plugins should take this long. Perhaps there is a different way to get the results for these plugins? I ran this against an environment with approximately 2200 VMs on 75 hosts across 12 clusters
$Title = "Security settings of Portgroups of Distibuted Virtual Switches"
$Header = "Security settings of Portgroups of Distibuted Virtual Switches"
$Comments = "Security settings o fPortgroups of Distibuted Virtual Switches, further information is available here."
$Display = "Table"
$Author = "Fred Witteman"
$Version = 1.0
$dvSwitchnames=Get-View -ViewType VmwareDistributedVirtualSwitch -Property Name,Portgroup | Select *
foreach($dvSwitchnames.Name in $dvSwitchnames){
$dvSwitchPortgroupSecurity+=Get-View $dvSwitchnames.Portgroup | %{$_ | Select-Object -Property @{N="dvSwitch";E={$dvSwitchnames.Name}},Name,
@{N="Allow Promiscuous";E={$.Config.DefaultPortConfig.SecurityPolicy.AllowPromiscuous.Value}},
@{N="Allow MAC Address Change";E={$.Config.DefaultPortConfig.SecurityPolicy.MacChanges.Value}},
@{N="Allow Forged Transmits";E={$_.Config.DefaultPortConfig.SecurityPolicy.ForgedTransmits.Value}}
}
}
@($dvSwitchPortgroupSecurity)
Using 6.18... My HTML Report output is missing the descriptions of the values it's reporting making it seem like random numbers or just being spit out. For example:
I have spent hours trying to make sense of the code and have a much better understanding of how vCheck works, however I am no programmer and it's above my head. I wish I could figure it out and contribute back, I just don't have the skills necessary. Here is the HTML output for that section:
<div style='
BORDER-RIGHT: #bbbbbb 1px solid;
BORDER-TOP: #bbbbbb 1px solid;
PADDING-LEFT: 0px;
FONT-SIZE: 8pt;
MARGIN-BOTTOM: -1px;
PADDING-BOTTOM: 5px;
MARGIN-LEFT: 0px;
BORDER-LEFT: #bbbbbb 1px solid;
WIDTH: 95%;
COLOR: #000000;
MARGIN-RIGHT: 0px;
PADDING-TOP: 4px;
BORDER-BOTTOM: #bbbbbb 1px solid;
FONT-FAMILY: Tahoma;
POSITION: relative;
BACKGROUND-COLOR: #f9f9f9
'><table><tr><td>9</td><td>0</td><td>1</td><td>2</td><td>6</td><td>12</td><td>13</td><td>0</td><td>0</td><td>0</td></tr></table> <!-- CustomHeaderClose -->
</DIV>
Is there a reason why vCheckUtils.ps1 is double the size than the printable text?
The first 288 lines have content, but the remaining lines don't display.
Downloading the zipfile and opening the vCheckUtils.ps1 in wordPad displays lots or garbage (although notepad and ISE seem to display the correct lines of code - 288 lines)
The file size is also around double the size (19632 Bytes instead compared to 9815 Bytes when the code is just copied to a new file)
Hi Alan
On vCenter with complex structur, more than one datacenter, the report show twice "VMs with CPU or Memory Limits Configured".
I did not found yet the reason. Can you help me?
Thanks an Regards
Denis
Now that we are using the .NET mail code introduced for resource handling, we have some more configuration options which we should aim to support (mostly because it annoys me when I am required to authenticate on our internal Exchange server!):
I'd also like to try to flag configuration items with dependancies somehow- it doesn't make sense to force the user to configure SMTP settings if $SendEmail is $false for example. But this is a longer-term goal I think.
Using Get-VM instead of $VM
https://github.com/alanrenouf/vCheck-vSphere/search?q=get-vm&type=Code
Using Get-VMHost instead of $VMH
https://github.com/alanrenouf/vCheck-vSphere/search?q=Get-vmhost&type=Code
Using Get-Cluster instead of $Clusters
https://github.com/alanrenouf/vCheck-vSphere/search?q=Get-Cluster&type=Code
Using Get-Datastore instead of $Datastores
https://github.com/alanrenouf/vCheck-vSphere/search?q=Get-Datastore&type=Code
Are these error messages something I should do something about? Or is it something that needs attention in the way this plugin is coded?
3:54:40 AM ..start calculating vSwitch Security by Justin Mercier, Sam McGeown, John Sneddon v1.2
Add-PSSnapin : The Windows PowerShell snap-in 'VMware.VimAutomation.Vds' is not installed on this computer.
At C:\Users\xxx\Downloads\vCheck-vSphere-master-2014-02-06\vCheck-vSphere-master\Plugins\98 vSwitch Security.ps1:24 char:10
Add-PSSnapin VMware.VimAutomation.Vds
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Get-VDPortGroup : The term 'Get-VDPortGroup' is not recognized as the name of a cmdlet, function, script file, or operable
program. Check the spelling of the name, or if a path was included, verify that the path is correct and try again.
At C:\Users\xxx\Downloads\vCheck-vSphere-master-2014-02-06\vCheck-vSphere-master\Plugins\98 vSwitch Security.ps1:49 char:4
3:55:43 AM ..finished calculating vSwitch Security by Justin Mercier, Sam McGeown, John Sneddon v1.2
The name of the vcenter server is hardcoded in line 10 as lacvcenter1@443.
Get-ChildItem : Cannot find path '\lacvcenter1@443\datacenter\datastore23\server1
At D:\79 Find VMs in uncontrolled snapshot mode.p
s1:10 char:38
$fileList = Get-ChildItem <<<< "vmstores:\lacvcenter1@443\$dc\$P
Two things I'm hoping someone can help with when updating/modifying "79 Find VMs in uncontrolled snapshot mode.ps1"
Below is the full error:
Get-ChildItem : Cannot find path '\VC.local@443\Datacenter1\ABC\Datastore01\machine1' because it does not exist.
At D:\Plugins\79 Find VMs in uncontrolled snapshot mode.ps1:15 char:38
$fileList = Get-ChildItem <<<< "vmstores:\$gciloc\$dc\$Path"
Is there a simple fix? Thank you in advance.
I like to email the reports as well as save a copy in case I want to look back.
There seems to be only two ways to get the output saved to file
Else the output is not saved. It appears the path is verified (line 530) but no Out-File occurs unless one of the two options above are triggered.
Not sure when this changed, just getting around to all the new improvements
I placed a vm in an esx local datastore to test this plugin output but it doesn't report anything.
It reports about VMTool issues on VMs PowerOff
I replaced
$.Guest.GuestState -eq "Running"
($.Guest.GuestState -eq "Running" -And $_.Runtime.PowerState -ne "poweredOff")
I use vCSA 5.5
I tried to turn on some security settings on various portgroups but nothing is reported.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.