Error on job syspolicy_purge_history

Oopps! Upgrade your browser pretty please.Oopps! Upgrade your browser pretty please.

Recently after installing a SQL Server 2008 clustered instance, I noticed that the job syspolicy_purge_history failed.

The error message was: The job script encountered the following errors.

These errors did not stop the script:  A job step received an error at line 1 in a PowerShell script. The corresponding line is ‘(Get-Item SQLSERVER:SQLPolicyNodename).EraseSystemHealthPhantomRecords()’. Correct the script and reschedule the job.

For some reason, the job was set up by the SQL Server Setup to reference the name of one of the physical nodes in the cluster instead of the virtual name of the clustered instance. The solution is simply to edit the job and chenge from the node name to the virtual instance name.