spjeff / spbestwarmup

Tired of waiting for SharePoint pages to load? Want something easy to support? That works on all versions? This warmup script is for you!
2 stars 0 forks source link

Password Auto detect fails; script stops #12

Closed crossan007 closed 7 years ago

crossan007 commented 7 years ago

Password auto detect attempt fails on server 2008R2 / SharePoint 2010.

image

crossan007 commented 7 years ago

This script requires PowerShell 3.0 + for Get-CIMInstance to work.

spjeff commented 7 years ago

Hi Charles,

Which version of PowerShell is running? ($host.version) I don't have Server 2008R2 to test with.

crossan007 commented 7 years ago

PS2.0 is "out of box" on Server 2008R2. It's trivial to upgrade WMF (and PowerShell) to 5.1.

crossan007 commented 7 years ago

I should have seen this before upgrading PowerShell...

https://support.microsoft.com/en-us/help/2796733/sharepoint-2010-management-shell-does-not-load-with-windows-powershell-3.0.

It seems that PS3.0 cannot be used to manage SP2010, but I think this script depends on SP3.0+.

spjeff commented 7 years ago

How about another way to read IIS WAMUserName/WAMUserPass? Does this run OK on Server 2008R2?

$tmp = Get-WMIObject -class IISApplicationPoolSetting -namespace "root\microsoftiisv2" -computer $env:computername $tmp | select WAM* |ft -a

crossan007 commented 7 years ago

This call works

crossan007 commented 7 years ago

Looks like get-CimInstance is used twice in the script - the other place is for setting up scheduled tasks.

spjeff commented 7 years ago

Yes, sure does. How does this look? Updated and saved a commit.

https://github.com/spjeff/spbestwarmup/commit/123aae91c6c8c488c1ce5c55006880c5190c7cbc

spjeff commented 7 years ago

Believe this is now resolved. Closing.