Chef Selenium: WmiLite:WmiException on Windows Server 2008

0

On Windows 2008 & 2008 R2 the following exception is thrown during Chef selenium_node installation:

FATAL: WmiLite::WmiException: An error occurred connecting to the WMI service for namespace 'root/cimv2'.
The namespace may not be valid, access may not be allowed to the WMI service, or the WMI service may not be available.
(in OLE method `ConnectServer': )
OLE error code:800705AF in SWbemLocator
The paging file is too small for this operation to complete.
HRESULT error code:0x80020009
Exception occurred.

The error does NOT occur on Windows 2012 & 2012 R2.

selenium
wmi
chef-infra
selenium-grid
asked on Stack Overflow Apr 30, 2015 by Dennis Hoer • edited Apr 30, 2015 by Dennis Hoer

1 Answer

0

From https://github.com/chef/knife-windows#nodes:

The Chef and Ohai gem installations (that occur during bootstrap) take more memory than the default 150MB WinRM allocates per shell on older versions of Windows (prior to Windows Server 2012) -- this can slow down bootstrap. Optionally increase the memory limit to 300MB with the following command:

winrm set winrm/config/winrs @{MaxMemoryPerShellMB="300"}

Also note:

Windows 2008R2 and earlier versions require an extra configuration for MaxTimeoutms to avoid WinRM::WinRMHTTPTransportError: Bad HTTP response error while bootstrapping. It should be atleast 300000.

winrm set winrm/config @{MaxTimeoutms=300000}
answered on Stack Overflow Apr 30, 2015 by Dennis Hoer

User contributions licensed under CC BY-SA 3.0