WMI or Windows Management Instrumentation is a database that stores meta-information and definitions for WMI classes. It lets administrators manage different Windows Environments including the Remote Systems. If the WMI Repository gets corrupted, the WMI Service will not work properly. Sometimes you may get Incorrect credentials, Insufficient permissions, or Access denied errors with WMI while connecting to the Remote Server. In this article, we will see some solutions that may help you fix the WMI Repository reset failed, Error 0x80070005, 0x8007041B, 0x80041003. The description of these error messages shows either an “Access denied” or an “Access is denied” message.
WMI Repository reset failed, Error 0x80070005, 0x8007041B, 0x80041003
These errors occur either due to the DCOM-level permission issues or WMI permission issues. Before we discuss the possible solutions to fix these errors, let’s have a look at complete error messages:
WMI repository verification failed
Error code: 0x80041003
Facility: WMI
Description: Access deniedWMI repository verification failed
Error code: 0x80041003
Facility: WMI
Description: Access deniedWMI repository reset failed
Error code: 0x80070005
Facility: Win32
Description: Access is denied.
The above error messages display the error code along with Facility and Description.
The Facility: Win32 indicates that it is a DCOM-level security permission issue. It means that the account that you are using to connect to the remote server does not have DCOM-level security permissions to access the remote device via WMI.
The Facility: WIM indicates that it is a WMI-level security permission issue. It means that the account that you are using to access the WMI Namespace does not have the WMI-level security permissions.
To fix these problems, here are some solutions that you can try.
- Clean WBEM Repository
- Rebuild the WMI Values
- Check DCOM permissions
Let’s see how to perform these fixes.
1] Clean WBEM Repository
Clean the WBEM Repository and see if it fixes the problem. The steps for this are written below.
Launch the Command Prompt as administrator. Type the following command and press Enter.
net stop winmgmt
Select Y to accept (if you are asked to do so). Wait till the command is executed successfully.
Now, copy the following command and paste it into the Command Prompt, and hit Enter.
C:\Windows\System32\wbem\Repository*
Select Y to accept (if you are asked to do so). Type Exit and press Enter. This will close the Command Prompt.
Restart your computer. After restarting your computer, wait for a few minutes and check if the issue is fixed.
If this does not fix the problem, rebuilding the WMI Values may help.
2] Rebuild the WMI Values
As explained earlier, these errors occur when the user has not the permission to perform an operation in WMI. Rebuilding the WMI Values can fix this problem.
Open Notepad on your Windows machine. Now, copy and paste the following command into it.
@echo on cd /d c:\temp if not exist %windir%\system32\wbem goto TryInstall cd /d %windir%\system32\wbem net stop winmgmt winmgmt /kill if exist Rep_bak rd Rep_bak /s /q rename Repository Rep_bak for %%i in (*.dll) do RegSvr32 -s %%i for %%i in (*.exe) do call :FixSrv %%i for %%i in (*.mof,*.mfl) do Mofcomp %%i net start winmgmt goto End :FixSrv if /I (%1) == (wbemcntl.exe) goto SkipSrv if /I (%1) == (wbemtest.exe) goto SkipSrv if /I (%1) == (mofcomp.exe) goto SkipSrv %1 /Regserver :SkipSrv goto End :TryInstall if not exist wmicore.exe goto End wmicore /s net start winmgmt :End
Save the file as WMI.bat and close the Notepad. Now, run the WMI.bat file as administrator. For this, right-click on the WMI.bat file and select the Run as administrator option. This will rebuild the WMI Values.
After performing a rebuild attempt on WMI Values, follow the steps below to check the WMI permissions:
Right-click on This PC icon on your desktop and select Manage. This will launch the Computer Management Panel.
Double-click on Computer Management (Local) on the left side to expand it. After that, expand Services and Applications by double-clicking on it. Now, right-click on WMI Control and select Properties. The WMI Control Properties dialog box will appear.
Select the Security tab and expand the Root folder. After that, select the Security subfolder and then click on the Security button on the bottom right side. This will bring the Security for ROOT dialog box on your screen.
The following permissions should be enabled for the Authenticated Users.
- Execute Methods
- Provider Write
- Enable Account
Click OK to close the Security for ROOT dialog box. Close the Computer Management panel and restart your computer. Now, check if the issue persists.
3] Check DCOM permissions
Follow the steps to check and modify the DCOM permissions.
Click Windows Search and type Dcomcnfg. Select the Dcomcnfg app from the search results.
Go to “Component Services > Computers > My Computer.” Right-click on My Computer and select Properties. The My Computer Properties dialog box will appear. Select the COM Security tab.
Click on the Edit Limits button under the Access Permissions section. This will open the Access Permission dialog box. Select the Everyone user group and check if the following permissions are granted to it or not:
- Local Access
- Remote Access
If the Allow checkbox is not selected for both the above-mentioned permissions, select them and click OK.
On the My Computer Properties dialog box, click on the Edit Limits button under the Launch and Activation Permissions section. Select the Everyone user group and check if the following permissions are allowed or not:
- Local Launch
- Local Activation
If the Allow checkbox is not selected for both the above-mentioned permissions, select them and click OK.
Click Apply and then OK to close the My Computer Properties dialog box.
Now, in the Computer Services window, go to “Component Services > Computers > My Computer > DCOM Config.” Scroll down the right side and locate Windows Management and Instrumentation. Once you find it, right-click on it and select Properties.
Select the Security tab and click on the Edit button under the Launch and Activation Permissions section. Select Administrators under the user group and check if the following permissions are allowed to it or not.
- Local Launch
- Remote Launch
- Local Activation
- Remote Activation
If the checkboxes are not selected, select them and click OK.
Read: Fix WMI Provider Host (WmiPrvSE.exe) High CPU Usage.
How do I repair or fully rebuild the Windows WMI Repository?
If WMI Repository is corrupted, you will receive various errors depending on what activity you are doing at that time. WMI has a self-recovery mode. When WMI detects the repository corruption, the self-recovery mode will be activated automatically. WMI looks for the backup images in the system created by the VSS backup mechanism and applies the AutoRestore approach to restore the valid images (if possible).
If the self-recovery mode fails to recover the corrupted Windows WMI repository, you will receive several error messages that indicate the WMI repository is corrupted. In such a case, you can repair or rebuild the Windows WMI Repository manually by executing a command in an elevated Command Prompt.
How do I know if my WMI is corrupted?
If WMI is corrupted, you will receive some errors and permission issues with WMI. In such a case, you will see the following errors and symptoms on your computer:
- Unable to connect to rootdefault or rootcimv2 namespaces. Fails returning error code 0x80041002 pointing to WBEM_E_NOT_FOUND.
- When you receive the “WMI. Not Found” error or your computer hangs on opening the properties of Computer Management (Local).
- 0x80041010 WBEM_E_INVALID_CLASS.
- Schemas/Objects missing.
- Strange connection/operation errors (0x8007054e).
- Your system hangs every time you use the wbemtest utility.
The above errors are the symptoms of WMI corruption. Therefore, to confirm the WMI corruption, you have to run the following command in an elevated Command Prompt.
winmgmt /verifyrepository
After running the above command, if you receive the message “repository is not consistent,” WMI is corrupted. If you receive the message “repository is consistent,” the repository does not have an issue. In this case, there is something else causing the issue.
Hope this helps.
Read next: Fix Windows Management Instrumentation error 1083.