Windows OS

How to Fix “Windows Perflib error Event Error 1020 & 1008”

The “Windows Perflib error Event Error 1020 & 1008” can be faced when the PC or laptop is unable to locate the file specified upon a particular operation. This particular limitation is visible in the “Event Viewer Log” and can be encountered due to the list of counters being corrupt, a required DLL being disabled, or the contained malware.

This article will discuss the solutions to resolve the “Windows Perflib Event” limitation.

How to Fix “Windows Perflib error Event Error 1020 & 1008”?

To resolve the stated “Event” limitation, consider the following fixes:

Fix 1: Run “SFC” Scan

Running the “SFC(System File Checker)” scan is effective to locate and fix the infected/corrupted files. To run this scan, apply the below-provided steps.

Step 1: Run “Administrative Command Prompt”
Open the Command Prompt with “Administrative Privileges”:

Step 2: Run “SFC” Scan

Now, run the following command to execute the “sfc” scan:

>sfc /scannow

Fix 2: Initiate “DISM” Scan

DISM” scans can be considered as an alternative to the “sfc” scan. These scans are also effective in performing health scans by tracing broken files and fixing them. To run this particular scan, first of all, verify the system image’s health by entering the below-given command:

>DISM.exe /Online /Cleanup-image /Checkhealth

In the next step, initiate a scan for the health of the system image:

>DISM.exe /Online /Cleanup-image /Scanhealth

At last, complete the procedure by restoring the system image’s health by utilizing the provided command:

>DISM.exe /Online /Cleanup-image /Restorehealth

After applying all the steps, check out if the faced issue is streamlined. Else, head to the next fix.

Fix 3: Delete Registry Key

Deleting the value of the “Open” key can also help resolve the discussed event limitation by implementing the following steps.

Step 1: Switch to “Registry Editor”
First of all, navigate to “Registry Editor” by typing “regedit” in the below-given Run box:

Step 2: Create a Backup
Now, create a backup to retrieve the registry back to normal if some sort of abnormality occurs while making the changes in the registry. This can be achieved by simply opting for “File-> Export”:

Step 3: Navigate to “NET CLR Networking” Directory
Now, follow the below-provided path to locate the “Open” key:

>Computer\HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\.NET CLR Networking\Performance

In the above path, specify the path of the service you are facing issues. For instance, in this particular path, “.NET CLR Networking” is the problematic service.

Step 4: Delete the “Open” Key
Lastly, locate the “Open” key in the particular service, Right-click on it and trigger “Delete” to delete this key:

Now, restart the PC or laptop, and the discussed issue will likely sort out. Otherwise, move on to the next fix.

Fix 4: Re-register the DLL

Registering the DLL is an effective approach to add information to the “Registry”. Therefore, try re-registering the infected “dll” files to cope with the discussed limitation.

Step 1: Navigate to the “system32” Directory
Input the following command in the “Administrative Command Prompt” to switch to the stated directory:

>cd %SYSTEMROOT%\System32

For handling “Error 1020”, execute the below-given command:

>lodctr /r

To handle the appeared error in the terminal, input the following commands one-by-one to get rid of it:

>cd C:\Windows\SysWOW64
>lodctr /r

Now, to handle “Error 1008”, input the following command:

>lodctr /e: Perflib.dll

Note that “Perflib.dll” corresponds to the problematic file that will be replaced by your particular file causing issues:

Step 2: Resync Counter
Lastly, “resync” the counter with “Windows Management Instrumentation” by typing the below-provided command:

>WINMGMT.EXE /RESYNCPERF

Restart the PC/Laptop, and the discussed limitation will likely vanish.

Conclusion

To resolve the “Windows Perflib error Event Error 1020 & 1008“, run the “SFC” Scan, initiate the “DISM” scan, delete the registry key, or re-register the DLL. This write-up elaborated on the approaches to cope with the Windows Perflib event error.

About the author

Umar Hassan

I am a Front-End Web Developer. Being a technical author, I try to learn new things and adapt with them every day. I am passionate to write about evolving software tools and technologies and make it understandable for the end-user.