Granny's Programming Pearls
"inside of every large program is a small program struggling to get out"
JavaRanch.com/granny.jsp
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Unable to Access Files In Network Mapped Drive

 
Veerendranag Banka
Greenhorn
Posts: 19
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
[size=12]Hai,
Iam Veerendranag I have a Problem that Tomcat 6 windows Service Local System Account Unable To Access The Files In The Network Mapped Drive,
How To Make Tomcat6 Windows Service Make Access To The Files Using Only Local System Account Instead Of Domain Name Can I do Any Configurations for
That,Any Help is Appreciated.
Regards,
Veerendranag
 
Paul Clapham
Sheriff
Posts: 21322
32
Eclipse IDE Firefox Browser MySQL Database
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Well, first of all a Windows service doesn't have any mapped drives. So if when you sign on you see your N drive mapped to \\server\whatever, don't assume that a Windows service sees that as well. It doesn't. So your code is going to have to use the UNC path \\server\whatever\thing and not the mapped version N:\thing.

And second of all a Windows service can't access files via a UNC path unless it is running under a specific user ID which has access to that UNC path. Those local system accounts don't work for that.

This is true for all Windows services, not just for Tomcat running as a Windows service.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic