Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I'm using a service which stores data on disk. The service is running as "local system account".

Where is the stored data for that system user?

I'm thinking about C:\Documents and Settings\Default User but I'm not sure about that.

Can someone confirm that?

share|improve this question
add comment

6 Answers

up vote 39 down vote accepted

The data you are looking should not, by default, be located in "C:\Documents and Settings\Default User". That is the location of the default user profile, which is the template for new user profiles. Its only function is to be copied to a new folder for use as a user profile when a user logs onto the computer for the first time.

If the service is following Microsoft's guidelines, it will be storing data in the application data folder (%APPDATA%) or the local application data folder (%LOCALAPPDATA% on Windows Vista and later). It should not use the My Documents or Documents folders, but you might want to check there as well.

On a typical installation of Windows XP or Windows Server 2003, check the following locations for application data for programs running as Local System (NT AUTHORITY\SYSTEM):

  • C:\Windows\system32\config\systemprofile\Application Data\Vendor\Program
  • C:\Windows\system32\config\systemprofile\Local Settings\Application Data\Vendor\Program
  • C:\Windows\system32\config\systemprofile\My Documents

On a typical installation of Windows Vista and later versions, check the following locations for application data for programs running as Local System (NT AUTHORITY\SYSTEM):

  • C:\Windows\system32\config\systemprofile\AppData\Roaming\Vendor\Program
  • C:\Windows\system32\config\systemprofile\AppData\Local\Vendor\Program
  • C:\Windows\system32\config\systemprofile\AppData\LocalLow\Vendor\Program
  • C:\Windows\system32\config\systemprofile\Documents

Of course, substitute the appropriate vendor name and program name for Vendor and Program.

share|improve this answer
7  
For 32-bit processes running on 64-bit versions of Windows, check under 'C:\Windows\SysWOW64' instead. –  bricelam Mar 9 '13 at 0:58
1  
Also see the answer here: stackoverflow.com/questions/3637605/… –  stolsvik Jul 24 '13 at 8:18
add comment

Go to Sysinternals and download procmon. You will need to know the name of the exe that the service runs as. Then you can use the filter in procmon to only list those activities generated by that application.

You should now be able to run through the list and determine which file this application is using (NOTE: After several minutes of logging, you can use the file menu to stop monitoring)

The entire Sysinternal suite can be downloaded as a single zip file and you may find other utils in the kit that can be helpfull.

share|improve this answer
add comment

If your service uses standard APIs for getting the user's default directories (configuration and application data), the files will be saved in the Default User's folder, for example:

C:\Documents and Settings\Default User\Local Settings\

So, I would confirm your assumption. I checked that on a service I wrote which runs as Local System Account.

share|improve this answer
    
+1: At least for one program I use, this worked, whereas the C:\Windows\system32\config\systemprofile\... options did not on Windows Server 2003 SP2. –  Kev Feb 18 '10 at 14:29
add comment

I have used a service running as the 'Local System' account and user data is stored in:

c:\Documents and Settings\LocalService

This is a hidden folder and took me a while to find it. Hope this helps.

share|improve this answer
add comment

Default User is the "template" that is used for creating new account "homes" in Windows. Local System Account does not live there. I may be mistaken, but as I understand it, "LSA" has no "home" to speak of, it's strictly an authentication-based account.

share|improve this answer
add comment

On XP there is a "System Profile" located at C:\WINDOWS\system32\config\systemprofile

I thought that was where the Local System acct was located. The Network Service and Local Service accounts both have hidden profiles in the Documents and Settings folder.

The Default User folder is typically used as the base folder that new user accounts are created from. So if a new user were to log on to a system for the first time. Their settings would be copied from the Default User profile initially.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.