Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / .NET Framework / New Users / July 2007

Tip: Looking for answers? Try searching our database.

Windowsservice an Mapped Drive

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Mathias Fritsch - 06 Jul 2007 09:12 GMT
My service runs under a Domain Account mydomain\myuser.
If I log into my system under this mydomain\myuser I have acces to a
mapped drive x:\ which is mapped to \\mydomain\mymachine\myfolder.

The service can acces \\mydomain\mymachine\myfolder but not x:\.
A winform application which I start when logged in as mydomain\myuser
has access to x.

Any ideas?

Mathias Fritsch
Daniel Bass - 06 Jul 2007 09:31 GMT
This is not the fact that you have access rights or don't, but that a mapped
drive only exists when you are logged in. A mapped drive is tied to a user's
profile, which is not used by a service running as that user.

If I were you I'd keep reference the path with the fully qualified UNC
anyway.

Cheers.
Dan.

> My service runs under a Domain Account mydomain\myuser.
> If I log into my system under this mydomain\myuser I have acces to a
[quoted text clipped - 7 lines]
>
> Mathias Fritsch
Michael Nemtsev - 06 Jul 2007 09:37 GMT
Hello Daniel,

Your system account, which is used to start service, has no rights to the
mapped drive
U need to use your accound credentials with impersonalisation to start service
and then you get access to the mapped drive

---
WBR,  Michael  Nemtsev [.NET/C# MVP].  
My blog: http://spaces.live.com/laflour
Team blog: http://devkids.blogspot.com/

"The greatest danger for most of us is not that our aim is too high and we
miss it, but that it is too low and we reach it" (c) Michelangelo

DB> This is not the fact that you have access rights or don't, but that
DB> a mapped drive only exists when you are logged in. A mapped drive is
DB> tied to a user's profile, which is not used by a service running as
DB> that user.
DB>
DB> If I were you I'd keep reference the path with the fully qualified
DB> UNC anyway.
DB>
DB> Cheers.
DB> Dan.
DB> "Mathias Fritsch" <mathiasfritsch@gmx.de> wrote in message
DB> news:1183709535.182484.264890@w3g2000hsg.googlegroups.com...
DB>
>> My service runs under a Domain Account mydomain\myuser.
>> If I log into my system under this mydomain\myuser I have acces to a
[quoted text clipped - 5 lines]
>>
>> Mathias Fritsch
Mathias Fritsch - 09 Jul 2007 13:24 GMT
Daniel,

I didnt know that. Now the service creates the mapped drive and
everything works great.
Thank you

Mathias

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.