Hi all,
I need to access a memory mapped file from one of my routes in my Web API. Using the normal IIS worker settings I have no luck and my service always returns "File not found". I tried to add the prefix "Global/" but still no luck.
After reading many hours on the web I learned that I need to change the Identity of the IIS worker. So, just for testing purposes I changed the worker identity to the Administrator account. I uploaded a picture here:
But still no luck. Does anyone here know how to configure IIS correctly?
Here is how I access the Memory Mapped File using c#:
string Message = ""; try { string MMF_In_Name = "Global\\MMF_Name"; MemoryMappedFile MMF_In = MemoryMappedFile.OpenExisting(MMF_In_Name); Messages.Add("Connected to MMF"); } catch (Exception ex) { Messages.Add(ex.Message); }
I have double checked the name of the memory mapped file and it's correct. A command line tool run as Administrator works as expected.
I'm using IIS 8.5 on Windows Server 2012.
Thanks,
Christian