title: How to map Shared Drive for a service where the Service isn't logged in as System
body: <p>I have a glassfish service running as a non system user. Glassfish needs to access a shared drive. How do I mount the shared drive for the glassfish service. Also, I would like this to remount at restarting the server. </p>
  
  <p>I've found some things online, but everything is a few years old and/or geared towards system services, so I'm hoping there's newer information out there:</p>
  
  <p>This is what I started with, it's perfect, but it's geared toward system services. The drive isn't viewable to non system users:
  <a href="https://support.code42.com/CrashPlan/4/Backup/Backing_Up_A_Windows_Network_Drive" rel="nofollow noreferrer">https://support.code42.com/CrashPlan/4/Backup/Backing_Up_A_Windows_Network_Drive</a></p>
  
  <p>This is the question that has the most answers, but most of them are for system users, though the OP seems to not be using the System User. His chosen solution involves wrapping the service, but there's the implication that it needs to be run manually at each start up.
  <a href="https://stackoverflow.com/questions/182750/map-a-network-drive-to-be-used-by-a-service">Map a network drive to be used by a service</a></p>
  
  <p>This person has the same issue including non system users, but everyone says it's impossible(or an extremely bad idea) except for the last comment which doesn't really give instructions:
  <a href="https://stackoverflow.com/questions/3098486/cannot-access-files-on-drive-mapped-network-share-from-a-windows-service">Cannot access files on drive mapped network share from a Windows service</a></p>