ntshrui.dll corrupted file

DNC

New Member
Joined
Mar 11, 2017
So recently my computer has been getting this message when trying to open most programs:
"C:\WINDOWS\SYSTEM32\ntshrui.dll is either not designed to run on Windows or it contains an error. Try installing the program again using the original installation media or contact your system administrator or the software vendor for support. Error status 0xc000012f."
I've managed to run the file checker which tells me there's a corrupted file it cannot replace or fix, and whenever I go into the logs file it gives me a notepad file about 5000 lines long that I cannot interpret. Can anyone help?
 
" … recently my computer has been getting this message when trying to open most programs … "

the error-message displays while trying to access most programs …
has this behavior started happening only recently?
have you downloaded / installed any programs around same time?
did you upgrade from another os around same time?
are you only person operating the computer?
is this your home computer?
booting into safe-mode incurs same issue?​

ummm, dnc … is there a windows system-restore point you can go back to (before incident first materialized)? my thoughts are possible malware infection … and make sure you utilize a truly comprehensive approach. in this day 'n age … one cannot simply depend on norton or windows-defender as the only sentry … needs multi-transitional protocol. [i.e. malware 'n hijacking 'n ransomware 'n exploits 'n rootkits 'n hacked firmware all exist.]

hang tight, though … others will come along and offer additional opinions. while waiting, dnc … i'd suggest you read up on the above dangers … and take steps as preventive medicine.
 
Can you right click on the file and give us the file version info? If it's the latest build I can give you a copy of the file and walk you through replacing it.

  • You can also press [Windows key + r]
  • Type msinfo32
  • Expand the 'Software Environment' branch
  • Select 'Loaded Modules'
  • Scroll down to ntshrui to get the file information
 
Attached is a copy the file (same version)
Download and extract the file to your desktop

Instructions for replacing it.
  • Press [Windows Key]
  • Type powershell
  • Right click powershell and select "Run As Administrator"
  • If the prompt does not say C:\Windows\System32 type cd C:\Windows\System32
  • Now backup the security data of the file with $acl = Get-Acl .\ntshrui.dll
  • Now you need to take ownership of the file with takeown /F .\ntshrui.dll /A
  • Now set permissions on the file cacls .\ntshrui.dll /E /G Administrators:F
  • Now you should be able to delete the file Remove-Item -Path .\ntshrui.dll
  • Now copy the new file with Copy-Item -Path $env:USERPROFILE\Desktop\ntshrui.dll -Destination .\ntshrui.dll
  • Now restore the security meta data with Set-Acl -Path .\ntshrui.dll -AclObject $acl
 

Attachments

  • ntshrui.zip
    378.1 KB · Views: 349
When I try to do takeown /F .\ntshrui.dll/A it says it cannot find directory.
 
As far as I can tell I did everything right including the change permissions but when I ran the remove path command I got
Remove-Item : Cannot remove item C:\WINDOWS\system32\ntshrui.dll: Access to the path 'C:\WINDOWS\system32\ntshrui.dll
is denied.
At line:1 char:1
+ Remove-Item -Path .\ntshrui.dll
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : PermissionDenied: (C:\WINDOWS\system32\ntshrui.dll:FileInfo) [Remove-Item], Unauthorize
AccessException
+ FullyQualifiedErrorId : RemoveFileSystemItemUnAuthorizedAccess,Microsoft.PowerShell.Commands.RemoveItemCommand
 
As long as you take ownership and then set permissions you should be able to remove the file.
 
This is what I entered in:
PS C:\WINDOWS\system32> takeown /F .\ntshrui.dll /A

SUCCESS: The file (or folder): "C:\WINDOWS\system32\ntshrui.dll" now owned by the administrators group.
PS C:\WINDOWS\system32> cacls .\ntshrui.dll /E /G Administrators:F
processed file: C:\WINDOWS\system32\ntshrui.dll
PS C:\WINDOWS\system32> Remove-Item -Path .\ntshrui.dll
Remove-Item : Cannot remove item C:\WINDOWS\system32\ntshrui.dll: Access to the path 'C:\WINDOWS\system32\ntshrui.dll'
is denied.
At line:1 char:1
+ Remove-Item -Path .\ntshrui.dll
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : PermissionDenied: (C:\WINDOWS\system32\ntshrui.dll:FileInfo) [Remove-Item], Unauthorized
AccessException
+ FullyQualifiedErrorId : RemoveFileSystemItemUnAuthorizedAccess,Microsoft.PowerShell.Commands.RemoveItemCommand
PS C:\WINDOWS\system32>
Did I forget a space or something?
 
It looks correct. Try navigating to the file in explorer and deleting it that way, If you get a try agan, it may be locked by some process. You may need to use process explorer to kill the open handle to the process. Your other option would be to download a Linux distro such as Ubuntu and burn that to a disc or usb and boot the live ubuntu version. Then you can replace the file. If you replace it this way you'll have to manually add the correct permissions back to the file.
 
Sorry, I'm horrible with this kind of stuff. What do you mean by kill the open handle to the process?
 
You'll need to download process explorer and from the menu search for open handles/dlls and enter that file find the select the handle and remove the handle.
 
Hi,
Some good suggestions for you, but it's going to take some good computer skills to fix this one. You might take a look at this Post here I found that may help you if neemo's suggestions don't do it or you can't understand them: How To Fix Ntshrui.dll is Missing / Not Found Error

Some of these items for possible causes to this error Jack also mentioned in his Post.

P.S. Before you attempt further software repairs, we recommend that you FIRST BACKUP ALL OF YOUR PERSONAL DATA TO EXTERNAL MEDIA! THIS WOULD INCLUDE YOUR LIBRARY FOLDERS FOR DOCUMENTS, PHOTOS, MUSIC, VIDEOS, AND ANY SAVED E-MAILS OR ATTACHMENTS IN ORDER TO AVOID IRRETRIEVABLE DATA LOSS!!

Best of luck,:cheerful:
<<<<BIGBEARJEDI>>>>
 
Sorry, I was gone for a while, but when I tried removing the open handle to the process, I think I did something wrong with Windows Explorer because now it takes ten minutes to open on launch and I also can't search anything in the search windows bar at the bottom left.
 
*what I meant by takes ten minutes to open is, it boots up, but there's a black screen and the apps only show up after 10 minutes of loading.
 
Back
Top Bottom