Jump to content

FNIS Not working Error(5) invalid namespace


Recommended Posts

Posted (edited)

I keep getting this error and I can't get FNIS to work. I also had Skyrim backed up on a external hard drive with mods, which I am using. I don't know if that might be causing issues?

 

Help is greatly appreciated!

 

 

fnis 1.png

fnis 2.png

Edited by Jenova23
Posted

A few things come to mind:

  1. Your "start in" directory is empty. Set it to the path where the FNIS exe is.
  2. Remove all FNIS animation mods and add them back until it breaks again. (I'd do this last, because it sounds like a lot of annoying work)
  3. Get ProcMon from Sysinternals (Microsoft) and make sure there's no file IO errors. (advanced users only)
Posted (edited)

You might need to start the exe as administrator.

You might be missing .NET Framework 4.x (https://dotnet.microsoft.com/en-us/download/dotnet-framework)

You might need to move your Skyrim directory / you might need to move your FNIS folder.

 

See the FAQ on the Nexus page and try your luck according to the suggested resolutions: https://www.nexusmods.com/skyrimspecialedition/mods/3038?tab=description

 

Also think about this quote from the FAQ:

Quote

All error codes greater than 2000 are logical errors found by the Generator. Errors less than 2000 are reported by Windows. Most of the reports should be self-explanatory. Before you can work with FNIS, you need to solve all errors shown in the textfield. Also look at the warnings. They can also indicate problems that prevent FNIS from working properly (like incompatibilities).

 

Edited by myDNS
Posted

Running something as administrator is not only dangerous but just a way to sweep the issue under the rug.

If the framework was missing, the application wouldn't start at all.

If error codes <2000 are from Windows then 5 is ERROR_ACCESS_DENIED. "Invalid namespace" makes no sense in that context.

 

If its indeed having problems with access, running as admin may work. You may also be having issues with the mo2 vfs, especially if your mo2 mods directory is on a different physical drive to where your skyrim is. My understanding is that this is not supported and isn't supposed to work (it does, but that's a long story). Same may be true for vortex. Access errors will show up in procmon if you're good with computers or willing to learn.

  • 4 months later...
Posted (edited)
23 minutes ago, ezrken said:

so you ever got around this I don't wanna use nemesis and lose creature animation and i have too many animations for the basic fnis 

 

Grab Procmon from Sysinternals (Microsoft) and find out what's returning error code 5 (ERROR_ACCESS_DENIED).

 

Edit: If you can't read the log, filter it for process name "GenerateFNISforUsers.exe" and upload it here. Save the log with only filtered events (not all events). Should be relatively safe then; or message it to me privately.

Edited by traison
Posted (edited)

Using ezrken's procmon log and the decompiled source code of FNIS 7.6 I think I've found where it stops working, however unfortuantely I do not yet know why. ezrken's log contained a couple of entries that resulted in ERROR_ACCESS_DENIED. These were from wbem (WMI) and can be ignored - I have them as well, and my FNIS is working.

 

It goes through the DisplayLoadCTDrelevantData() method, which creates and writes to the temporary_logs\FNISListCollect.txt file, but after that it just dies. The next line after this method is checking whether meshes\\actors\\character\\animations\\FNIS_PCEA2 exists, and this never happens in ezrken's log. I had a quick look through the CRL implementation of FileSystemProxy.DirectoryExists and there didn't appear to be any WMI related calls there, just good old winapi. Despite what I said earlier about this being irrlevant, I did it beacuse the terminology used in the error message ("namespace") could fit WMI.

 

Going to have to take a closer look at DisplayLoadCTDrelevantData... there's something I'm missing here.

Edited by traison
Posted (edited)

Just noticed ezrken's log shows it doesn't actually write to FNISListCollect.txt, it only flushes it at the end before closing the handle. This does not leave many lines of code where it could have possibly broken.

 

I realize the decompiler does not produce a 1:1 copy of the original source code, but considering the error message, and what is before the first line that writes to that txt file it does make sense:

 ComputerInfo info = MyProject.Computer.Info;

 

Where ComputerInfo (Microsoft.VisualBasic.Devices.ComputerInfo) is a class for querying WMI for computer information. The class name used is "Win32_OperatingSystem". It is wrapped in a System.Management.ManagementPath. CreateWbemPath is used, and this returns an IWbemPath etc. etc. etc.

 

Point is, you have an issue with your WMI. For some reason trying to open Win32_OperatingSystem throws an ACCESS DENIED error from WMI. You'll have to google this, as I do not recall ever seeing this before. I'll try to provide more info if its needed. I personally run Windows as a member of the Users group, I am not an Administrator, nor Power User on my system. This is not a matter of having to be UAC elevated for FNIS to work for instance, which is no doubt going to be the most common answer you'll see. It may solve your issue, but there's obvious drawbacks to consider when doing that.

 

Edit: Could it be some silly Anti-Virus thing? Tried disabling that?

Edited by traison
Posted

i followed this

https://techcommunity.microsoft.com/t5/ask-the-performance-team/wmi-repository-corruption-or-not/ba-p/375484

and then

https://answers.microsoft.com/en-us/windows/forum/all/how-to-resolve-access-denied-for/be77d603-9e64-402a-abfe-2d9fac19a425

 

in short 

 

i made a txt file

 

@echo off
sc config winmgmt start= disabled
net stop winmgmt /y
%systemdrive%
cd %windir%\system32\wbem
for /f %%s in ('dir /b *.dll') do regsvr32 /s %%s
wmiprvse /regserver
winmgmt /regserver
sc config winmgmt start= auto
net start winmgmt
for /f %%s in ('dir /s /b *.mof *.mfl') do mofcomp %%s

 

turned it into a bat file and ran it

 

then I ended up running these 3 commands from the command prompt with admin rights

 

winmgmt /verifyrepository

Winmgmt /resetrepositoy

net localgroup "Administrators" "NT Authority\Service" /add

 

and then i restarted the pc

 

I do not know which one of this solved the issue but it did

 

thanks traison 

 

I found the solution when I googled  "trying to open Win32_OperatingSystem throws an ACCESS DENIED error from WMI"

now can run fnis fine again

 

I know this is just a symptom and the problem is in somewhere in my windows, on a more calm day when I have the time I'll reinstall windows again maybe even try that cool looking windows 11

Posted

This is probably mentioned in the links above, as I recall reading this (and the same instructions) while googling this myself, but I'll mention it again just for posterioty. Maybe save someone a headache later:

 

Winmgmt /resetrepositoy

 

This can apparently do more damage than it fixes.

 

You may have a working FNIS, but something else seemingly entirely unrelated stops working. I can't personally say what this *something* might be, I never recall seeing a program that registers a new WMI provider, but I suppose why not, they probably exist. I do not have a better suggestion though, except for maybe trying to do something with wmimgmt.msc. I had a look at that option myself but at first glance couldn't really work out where "Win32_OperatingSystem" was supposed to be. I'm not familiar enough with WMI at this point.

  • 1 year later...
Posted
11 hours ago, Grymbels said:

Sorry for the necromancy, but was a conclusive fix for this ever found? I've tried these solutions other than the procmon but I'm still getting the error.

This may be the push I needed to give Pandora a try though.

 

Well procmon is not a solution but rather a diagnostics utility, and in this case it wouldn't be showing anything related to WMI permissions. I'm not familiar enough with WMI to suggest what to do next, but I'd say the general gist of it is that you have something that has altered permissions to WMI objects. Anti-virus or some kind of anti-"information leak" utility could make sense: lock access to computer information to prevent "Google Desktop" (just an example) from identifying who you are etc. wmimgmg.msc as far as I know is the management utility for WMI, but beyond that you're on your own.

 

The information @ezrken posted above seems quite viable, however I'd definitely create a full system drive backup before executing any of that.

  • 6 months later...
Posted

I opened another thread about this and I'm cross posting my solution here because I believe this thread is more visible:
 

I found a more user-friendly version, for anyone running into this issue in the future. I followed the guides outlined here in this walkthrough:
https://kb.sambapos.com/en/11-5-how-to-resolve-invalid-class-error/

The above link is not a walkthrough specifically for FNIS, mind you, just another company who has run into the same problem. Their solution was a bit easier for me than trusting a bat file.
 

I followed Method 2 of that link and it started working again. In case that link gets taken down, the steps are this:

 

  1. Enter Windows Start > Services > Services Application > Windows Management Instrumentation service. Stop the service.

  2. Navigate to C:\Windows\system32\wbem\. Find the repository folder. Rename that folder to repository_old. (This backs up the folder, and a new one will be generated when you start the service again. You can actually use this method with a lot of files when modding Skyrim, too :) )

  3. Go back to Services and Start the Windows Management Instrumentation again. This should generate a new repository folder.


That's all it took to get me back up and running again! There's further methods on that link others can try if that doesn't work. The core problem seems to be the same. Invalid Class seems to be indicative of a WMI corruption, or a not running WMI service.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...