The mechanism to cache snapins has been changed do the volatile nature of some snapins which caused PowerShell and the caching process to terminate prematurely. This is way we provide a pre-cache of snapins. Modules on the other hand do not suffer from the same limitations.
David
PowerCLI cmdlets are not displayed in autocomplete
Forum rules
DO NOT POST SUBSCRIPTION NUMBERS, LICENSE KEYS OR ANY OTHER LICENSING INFORMATION IN THIS FORUM.
Only the original author and our tech personnel can reply to a topic that is created in this forum. If you find a topic that relates to an issue you are having, please create a new topic and reference the other in your post.
DO NOT POST SUBSCRIPTION NUMBERS, LICENSE KEYS OR ANY OTHER LICENSING INFORMATION IN THIS FORUM.
Only the original author and our tech personnel can reply to a topic that is created in this forum. If you find a topic that relates to an issue you are having, please create a new topic and reference the other in your post.
Re: PowerCLI cmdlets are not displayed in autocomplete
What version is the vmware.vimautomation.core snapin on your machine?
I see we do have a precache file for it.
David
I see we do have a precache file for it.
David
David
SAPIEN Technologies, Inc.
SAPIEN Technologies, Inc.
Re: PowerCLI cmdlets are not displayed in autocomplete
Can you check if you have these files?
C:\ProgramData\SAPIEN\CachedData 2014\Local Machine\ModuleCacheV2\VMware.VimAutomation.Core.5.1.0.0.cmdlets
C:\ProgramData\SAPIEN\CachedData 2014\Local Machine\ModuleCacheV2\VMware.VimAutomation.Core.5.1.0.0.syntax
C:\ProgramData\SAPIEN\CachedData 2014\Local Machine\ModuleCacheV2\VMware.VimAutomation.Core.5.1.0.0.alias
And does it match your installed version?
David
C:\ProgramData\SAPIEN\CachedData 2014\Local Machine\ModuleCacheV2\VMware.VimAutomation.Core.5.1.0.0.cmdlets
C:\ProgramData\SAPIEN\CachedData 2014\Local Machine\ModuleCacheV2\VMware.VimAutomation.Core.5.1.0.0.syntax
C:\ProgramData\SAPIEN\CachedData 2014\Local Machine\ModuleCacheV2\VMware.VimAutomation.Core.5.1.0.0.alias
And does it match your installed version?
David
David
SAPIEN Technologies, Inc.
SAPIEN Technologies, Inc.
Re: PowerCLI cmdlets are not displayed in autocomplete
David,
I do have those files on my machine.
I am not sure what you mean by my installed version. I have PowerCLI 5.0.1 and those cmdlets look like PowerCLI 5.1
Is that what you're asking? I could drop 5.1 on my development environment and just be sensitive to using the 5.0 cmdlets, but my production environment will have PowerCLI 5.0.
Is there any way I can get the Precached for 5.0?
I do have those files on my machine.
I am not sure what you mean by my installed version. I have PowerCLI 5.0.1 and those cmdlets look like PowerCLI 5.1
Is that what you're asking? I could drop 5.1 on my development environment and just be sensitive to using the 5.0 cmdlets, but my production environment will have PowerCLI 5.0.
Is there any way I can get the Precached for 5.0?
Re: PowerCLI cmdlets are not displayed in autocomplete
Ok that is it. The version you have doesn't match our cached version.
Try this:
Go to the following folder:
C:\ProgramData\SAPIEN\CachedData 2014\Local Machine
Open or create the snapins.cache file for the platform desired.
For example, for PowerShell V3 64 Bit the file will be named:
PowerShell64V3.Snapins.Cache
Add the following lines:
VMware.VimAutomation.Core|5.1.0.0 |
VMware.VimAutomation.License|1.0.0.0|
VMware.DeployAutomation|5.1.0.1786|
VMware.VimAutomation.Vds5.1.0.0 |
If you already have entries, update the version numbers to match the pre-cache version listed above.
Then save the file.
Do the same for the other platforms if necessary, such as PowerShell32V3.Snapins.Cache.
Now run the following in a command line or PowerShell.
CacheBuilder64.exe /ASSEMBLEONLY
CacheBuilder32.exe /ASSEMBLEONLY
Note: The cachebuilder64.exe and cachebuilder32.exe are located in the same directory as PowerShell Studio.
Then open PowerShell Studio and the snapins should appear in the PowerShell Browser (Object Browser Panel).
David
Try this:
Go to the following folder:
C:\ProgramData\SAPIEN\CachedData 2014\Local Machine
Open or create the snapins.cache file for the platform desired.
For example, for PowerShell V3 64 Bit the file will be named:
PowerShell64V3.Snapins.Cache
Add the following lines:
VMware.VimAutomation.Core|5.1.0.0 |
VMware.VimAutomation.License|1.0.0.0|
VMware.DeployAutomation|5.1.0.1786|
VMware.VimAutomation.Vds5.1.0.0 |
If you already have entries, update the version numbers to match the pre-cache version listed above.
Then save the file.
Do the same for the other platforms if necessary, such as PowerShell32V3.Snapins.Cache.
Now run the following in a command line or PowerShell.
CacheBuilder64.exe /ASSEMBLEONLY
CacheBuilder32.exe /ASSEMBLEONLY
Note: The cachebuilder64.exe and cachebuilder32.exe are located in the same directory as PowerShell Studio.
Then open PowerShell Studio and the snapins should appear in the PowerShell Browser (Object Browser Panel).
David
David
SAPIEN Technologies, Inc.
SAPIEN Technologies, Inc.
Re: PowerCLI cmdlets are not displayed in autocomplete
David,
That fixed it! Thank you so much for your help.
Maureen
That fixed it! Thank you so much for your help.
Maureen
Re: PowerCLI cmdlets are not displayed in autocomplete
Important Note: Version 4.1.56 of PowerShell Studio 2014 changes the location of the cache to the following user specific folder:
C:\Users\<username>\AppData\Roaming\SAPIEN\CachedData 2014\
You will need to manually re-add the snapins after installing this update.
David
C:\Users\<username>\AppData\Roaming\SAPIEN\CachedData 2014\
You will need to manually re-add the snapins after installing this update.
David
David
SAPIEN Technologies, Inc.
SAPIEN Technologies, Inc.
Re: PowerCLI cmdlets are not displayed in autocomplete
I am experiencing the same issue. Did you get this resolved?