2

I'm logging using NLog in an Azure WebRole to the "%appdata%" folder.

But when I RDP into the Azure VM I can't find my log file anywhere -- %appdata% opens a folder the user I'm RDPed in as -- where is the appdata folder I should be looking for?

Not sure if it's relevant, but, I acquire the folder in C# via Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData) both in WebRole.cs and in Global.asax.cs. -- My service is set to run elevated (in the .csdef file).

It looks like my Site's application pool is being run by Network Service, and I think his %appdata% folder could be located at D:\Windows\ServiceProfiles\LocalService\AppData\Roaming, but I don't see my logging folder getting created there or any of my log files.

Is this the correct folder and it's a permissions issue (and how would I tell?), or is it getting redirected somewhere else (and if so, where)?

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.