I am a beginner novice.
After days of searching ....
I put together a small powershell script (as shown below) to check the page file, / PAE switch, / 3GB switch, SQL maximum RAM, min. RAM I run this on 1 server.
If I want to run it on many servers (from .txt), how can I change it? How can I change it to search for the contents of the boot.ini file for this server?
clear $strComputer="." $PageFile=Get-WmiObject Win32_PageFile -ComputerName $strComputer Write-Host "Page File Size in MB: " ($PageFile.Filesize/(1024*1024)) $colItems=Get-WmiObject Win32_PhysicalMemory -Namespace root\CIMv2 -ComputerName $strComputer $total=0 foreach ($objItem in $colItems) { $total=$total+ $objItem.Capacity } $isPAEEnabled =Get-WmiObject Win32_OperatingSystem -ComputerName $strComputer Write-Host "Is PAE Enabled: " $isPAEEnabled.PAEEnabled Write-Host "Is /3GB Enabled: " | Get-Content C:\boot.ini | Select-String "/3GB" -Quiet
Any comments on how this can be improved?
Thanks in advance
source share