Server Manager 2012 : Configuration refresh failed with the following error: Invalid class RRS feed

  • Question

  • When we start Server Manager on Server 2012 the flag lights up Red almost immediately with the error:

    Configuration refresh failed with the following error: Invalid class. 

    What we’ve tried so far:  

    sfc /scannow  [reported no errors]

    Dism /Online /Cleanup-Image /RestoreHealth [Completed to 100% ]

    Get-windowsfeature returns: Invalid class

    This is a file/print server, running DFS.   When running DFS Management from Server Manager we don’t see the Replication section at the bottom.  We can run MMC and manually add DFS Management then Replication shows up. 

    Where do I look to start diagnosing this error?

    Wednesday, October 16, 2013 12:23 PM


All replies

  • I wanted to put the fix that I found on this thread since it's the first one that comes up in a web search, but didn't have the answer on it.

    1. from current directory (C:\Windows\System32) I did: dir /a /S *.mof then all *.mof's in all subdirs were listet.

    All are some type like "FFA7CB08C2CC2CB2D3973F6214D0CCAF.mof"

    2. cd C:\Windows\System32\wbem\AutoRecover

    3. for /f %s in ('dir /b *.mof *.mfl') do mofcomp %s

    4. goto Servermanager, do Refresh - Ok.

    • Marked as answer by BScholl Saturday, November 16, 2013 3:13 AM
    Friday, November 15, 2013 3:52 PM
  • Thank you!
    • Proposed as answer by Randall Okwei Monday, October 5, 2015 4:20 AM
    Saturday, November 16, 2013 3:13 AM
  • This worked magic for my Failover Cluster! thanks!!
    Thursday, December 12, 2013 10:22 PM
  • Thank you! I started having this issue when I attempted to uninstall the Windows Deployment Services role and I was stuck!
    Friday, December 27, 2013 4:05 PM
  • Fixed for me, thank you so much! This problem has been plaguing us with a DC for months, and this has fixed it perfectly!
    Monday, June 16, 2014 10:57 AM
  • Thanks a lot. It saved my day.

    L. Arshath

    Wednesday, January 7, 2015 9:13 AM
  • Open Powershell with "Run As Admin"

    And run command ....

    Set-Item wsman:\localhost\Client\TrustedHosts YOURSERVERNAMEHERE -Concatenate -Force

    Thursday, February 5, 2015 3:30 PM
  • for /f %s in ('dir /b *.mof *.mfl') do mofcomp %s

    this did it for me - thanks so much for sharing!!

    • Proposed as answer by PedroTo Tuesday, December 6, 2016 10:44 AM
    Monday, March 9, 2015 6:41 PM

    I tried this
    2. cd C:\Windows\System32\wbem\AutoRecover3. for /f %s in ('dir /b *.mof *.mfl') do mofcomp %s

    and it worked great! Thank you so sooo much!

    Tuesday, May 19, 2015 1:02 PM
  • I stand corrected. That worked yesterday for the first refresh right after doing it, but then it went back to failing. Today it's not working at all.

    This server was recently promoted to being a Domain controller, I'd like to keep it in good health. :(

    Wednesday, May 20, 2015 12:48 PM
  • I am so glad that I found this post and your answers.  I was having a problem with a Windows Server 2012 system that would not let Windows Update get past "Searching for Updates".  This would just hang for days until I rebooted.  All of the other Windows Updates fixes did not work.  I was so close to rebuilding this server.

    After I ran through the steps outlined, I rebooted the server and all of a sudden the Windowes updates started working again.

    Thank you so very much!

    Tuesday, June 2, 2015 12:41 AM
  • Perfect!

    Works flawless with a HP ProLiant Cluster!


    Wednesday, September 9, 2015 9:18 AM
  • this worked on a dell t 610, although the scripts been running for hours now.  stuck on it seems

    C:\Windows\System32\wbem\AutoRecover>mofcomp AC3687DA2224C8ED35AB56C9861A0C4B.mof
    Microsoft (R) MOF Compiler Version 6.3.9600.16384
    Copyright (c) Microsoft Corp. 1997-2006. All rights reserved.
    Parsing MOF file: AC3687DA2224C8ED35AB56C9861A0C4B.mof
    MOF file has been successfully parsed
    Storing data in the repository...

    Ironically this also fixed my hyper-v management console remote, and scvmm errors.


    Sunday, October 4, 2015 9:48 PM
  • Thank you StuffNThings, it worked like a charm on a Windows Server 2012 R2 Foundation.

    My two cents:

    1) Never run the same command from %windir%\system32\wbem, do it just from AutoRecover dir, because in wbem there are several MOFs to uninstall WMI providers, and run a recursive mofcomp will completely blow up your WMI (it's the way I blew mine).

    2) During the recursive mofcomp the program hanged once registering a specific mof (which file name I do not remember, alas). Closing Server Manager was not enough, I had to kill WMIPrvSe.exe from Task Manager to unblock it. I tried before to stop the WMI Service - sorry, no luck! - my WMI was in a so bad state that was impossible to stop it from Service Manager. Once killed WMIPrvSe.exe, the recursive mofcomp finished in no time, and the problem was solved.

    Due to this problem I could not open Backupassist console (neither 8.4.4 or 9.0, reinstalling did not solve the issue). Clearly BA console relies on WMI, so when WMI was back in shape, BA console opened again.

    Note that in several threads they warned me to keep deleting the WMI repository as a last measure, because it causes weird behavior in programs. I resisted the temptation to rebuild it, and my patience was rewarded with the lean solution I found here.

    Monday, October 5, 2015 9:38 PM
  • Hope someone can help here still

    When I type #3 it gives me an errors until I do it like this

    for(/f %s in ('dir /b *.mof *.mfl') do mofcomp %s)

    Then I get >> and a flashing cursor for hours and nothing happens

    I need to get this fixed without doing a new install

    What am I doing wrong?

    Sunday, February 21, 2016 12:53 PM
  • Don't do it in Powershell, open a CMD window



    cd C:\Windows\System32\wbem\AutoRecover

    for /f %s in ('dir /b *.mof *.mfl') do mofcomp %s

    Ignore next few lines, this app likes to insert this most likely due to the for statement data

    <object data-extension-version="" data-install-updates-user-configuration="true" id="__symantecPKIClientMessenger" style="display:none;"></object>

    <object data-extension-version="" data-install-updates-user-configuration="true" id="__symantecPKIClientMessenger" style="display:none;"></object>
    • Edited by jbruns2010 Tuesday, March 1, 2016 3:20 PM
    Tuesday, March 1, 2016 3:19 PM
  • From current directory (C:\Windows\System32) I did: dir /a /S *.mof then all *.mof's in all subdirs were listet.

    All are some type like "FFA7CB08C2CC2CB2D3973F6214D0CCAF.mof"

    after that type cd C:\Windows\System32\wbem\AutoRecover

    after that type for /f %s in ('dir /b *.mof *.mfl') do mofcomp %s


    • Proposed as answer by Aanand Kumar Tuesday, March 1, 2016 3:29 PM
    Tuesday, March 1, 2016 3:29 PM
  • What people should be asking is why do the autorecover files have to be recompiled.  I believe I was able to recreate this issue.

    This was on 2012 and 2012R2 only.  2008R2 does not appear to be affected by this.

    1.  Navigate to C:\Windows\System32\wbem

    2.  Recompile all *.mof and *.mfl

    3.  Open ServerManager(SM).  This is where SM dies with invalid class


    1.  Navigate to C:\Windows\System32\wbem\AutoRecover

    2.  Recompile all *.mof and *.mfl

    3.  Open ServerManager.  SM is fixed

    <object data-extension-version="" data-install-updates-user-configuration="true" id="__symantecPKIClientMessenger" style="display:none;"></object>
    Tuesday, March 1, 2016 4:32 PM

    This worked for me and it solved my FILE SERVER RESOURCE MANAGER problem as well.  I posted the solution with a screen shot (and credit :) )


    Have a great day.

    Ian Matthews www.urtech.ca www.commodore.ca

    Tuesday, July 12, 2016 8:32 PM
  • I can confirm that recompiling .mof & .mlf files in $env:windir\System32\webem\AutoRecover\ fixes this. I did not recompile the files one level up, nor did I do a recursive search.. Thank you to the recent few who mentioned recompiling only the ones in the AutoRecover directory.

    I wrote this snippet in PowerShell, which fixed it for me. Proceed at your own risk:

    $AutoRecoverPath = "$env:windir\System32\wbem\AutoRecover\"
    Write-Output "Getting AutoRecover MOFs to recompile."
    $GetAutoRecoverMOFS = Get-ChildItem -Path $AutoRecoverPath | Where-Object { ($_.Extension -in ".mof", ".mfl") -and ($_.Name -notlike "*uninstall*") } | Sort-Object -Property Name
    Write-Output "Checking syntax of MOFS in $AutoRecoverPath"
    $c = 1
    foreach ($file in $GetAutoRecoverMOFS) {
    	$FileName = $file.Name
    	$FilePath = $file.FullName
    	Write-Output "Recompiling $FileName. $c of $($GetAutoRecoverMOFS.Count)."
    	C:\Windows\System32\wbem\mofcomp.exe -check $FilePath
    Write-Output "Recompiling MOFS in $AutoRecoverPath"
    $c = 1
    foreach ($file in $GetAutoRecoverMOFS) {
    	$FileName = $file.Name
    	$FilePath = $file.FullName
    	Write-Output "Recompiling $FileName. $c of $($GetAutoRecoverMOFS.Count)."
    	C:\Windows\System32\wbem\mofcomp.exe -autorecover $FilePath

    • Proposed as answer by ScottMetzel Thursday, August 25, 2016 5:54 PM
    • Edited by ScottMetzel Thursday, August 25, 2016 5:56 PM
    Monday, August 22, 2016 7:58 PM
  • Can you please explain line 3?

    an example would be great.


    Sunday, March 12, 2017 8:56 PM
  • Can you please explain line 3?

    an example would be great.


    Sure. Line 3 gets all .mof & .mfl files in %windir%\System32\wbem\AutoRecover\ where the file name does not include the word "uninstall", and sorts those results by the (file) name property.

    I should mention that doing any of this should be an absolute last ditch effort to resolve anything WMI-related, and to date I've only had to do this once. Typically, doing anything like this is unnecessary and probably isn't the root cause.

    Tuesday, March 14, 2017 2:02 AM
  • Thank you for this.  Saved me a lot of time.
    Monday, July 10, 2017 10:33 PM
  • Thanks a lot, it works!
    Friday, October 6, 2017 9:49 AM
  • You saved me a ton of work.  My fifteen year old domain in a computer lab was completely kaput.  I used csvde to save what I could and was ready to blow up the entire domain (I had already taken the BDC offline and could not re-add it to the domain).  There is a ton of work left to do, but at least I save recreating every computer and user in the school.

    Friday, October 13, 2017 6:32 PM
  • excuse my ignorance, I do not understand the command below to be typed.

    >>>      3. for /f %s in ('dir /b *.mof *.mfl') do mofcomp %s

    4. goto Servermanager, do Refresh - Ok.

    Monday, October 30, 2017 8:29 PM
  • worked get for me, Thank you
    Tuesday, November 28, 2017 10:16 PM
  • Works in Server 2016 too.


    Tuesday, February 27, 2018 10:38 AM
  • Great solution.

    Worked like a charm

    Server 2012 R2, error was:
    configuration refresh failed with the following error invalid class

    Thank you very much!!!


    Tuesday, July 24, 2018 12:48 PM
  • If above doesn't work, try this

    CD C:\Windows\System32\WBEM
    dir /b *.mof *.mfl | findstr /v /i uninstall > moflist.txt & for /F %s in (moflist.txt) do mofcomp %s


    Worked like a charm

    • Proposed as answer by Vivek123321 Thursday, November 8, 2018 11:02 PM
    Thursday, November 8, 2018 11:02 PM
  • this does not work for me 
    Saturday, December 1, 2018 2:08 PM
  • This fixed it for me!!.. Thank you
    Tuesday, April 2, 2019 5:39 AM
  • tks!

    Abraços, Marcelo Washington do Nascimento

    Tuesday, May 21, 2019 12:20 PM
  • I experienced the same issue after an in-place upgrade from 2012R2 to 2019. 

    Event Viewer: 

    Log Name: Microsoft-Windows-ServerManager-MultiMachine/Operational
    Invoke method error. Server: localhost, Namespace: root\microsoft\windows\servermanager, Class: MSFT_ServerManagerTasks, Method: GetServerInventory, Error: Invalid class 

    Based on the comment from BScholl I searched in the C:\Windows\System32\wbem\AutoRecover directory for "MST_ServerManagerTasks". 

    On my "Server 2019 Standard" the following files contained a reference to the "MSFT_ServerManagerTasks" class. 


    I then fixed the problem by running mofcomp on the relevant files. 

    Start CMD as administrator
    CD C:\Windows\System32\wbem\AutoRecover
    mofcomp 1A75D0C6C8797FE7E2BA5DB1C1C45E36.mof
    mofcomp 888AA37E798ACCB4B59BA10D5D95BEAB.mof
    mofcomp AC3687DA2224C8ED35AB56C9861A0C4B.mof
    mofcomp E0B2C6C98636BD24232F0D4B79550F05.mof

    Wednesday, October 9, 2019 9:20 AM
  • OS 2016.


    1. from current directory (C:\Windows\System32) I did: dir /a /S *.mof then all *.mof's in all subdirs were listet.

    All are some type like "FFA7CB08C2CC2CB2D3973F6214D0CCAF.mof"

    2. cd C:\Windows\System32\wbem\AutoRecover

    3. for /f %s in ('dir /b *.mof *.mfl') do mofcomp %s

    4. goto Servermanager, do Refresh - Ok.

    -- Found Invalid class error replaced with "Configuration refresh failed with the following error: The system cannot find file specified."

    -- Reboot, sfc scannow, chkdsk all workaround performed.

    -- Any suggestion/solution on this?

    Saturday, October 26, 2019 11:05 AM
  • Spot on. Thank you!

    Friday, February 7, 2020 3:08 PM
  • this is the only process that worked for me -- i.e. doing the "for /f %s in ('dir /b *.mof *.mfl') do mofcomp %s" in "C:\Windows\System32\wbem" first, and then doing it in C:\Windows\System32\wbem\AutoRecover 2nd.


    Wednesday, April 15, 2020 3:56 PM
  • Puedes ir a esta ruta:



    Renombrar la carpeta: ServerComponentCache por: ServerComponentCache-bak

    Reiniciar el server y listo

    Probamos que el Server Manager Funcione....

    Después de reiniciar en el regedit quedara algo asi:

    • Edited by gmorales Tuesday, May 5, 2020 9:27 PM
    Tuesday, May 5, 2020 8:22 PM