Install mapped drive as a service?

  • Thread starter Thread starter gscanga
  • Start date Start date
G

gscanga

Guest
Does anyone know if this is relatively easy to accomplish?

I'm trying to figure out if I can install a service on Windows 2003 that
will execute a net use command? So, this will allow a network drive to be
mapped without requiring a user to logon.

Thanks!
 
Re: Install mapped drive as a service?

Hello,

mapped drive are user based...how to get it if you are not the user who logs
on ?

I guess it's for a software installed on it ?
Can't it uses UNC path ?

--
Cordialement,
Mathieu CHATEAU
http://lordoftheping.blogspot.com


"gscanga" <gscanga@discussions.microsoft.com> wrote in message
news:E94CA756-9AC1-45B2-A75B-8AC1C6E7ADB3@microsoft.com...
> Does anyone know if this is relatively easy to accomplish?
>
> I'm trying to figure out if I can install a service on Windows 2003 that
> will execute a net use command? So, this will allow a network drive to be
> mapped without requiring a user to logon.
>
> Thanks!
>
 
Re: Install mapped drive as a service?

Well, the issue arose as a result of NFS (Network File Sharing) to a Unix
system. A DTS package taht's to run on the Windows system needs to see a
remote directory on the Unix system but simply typing "dir \\(unix
system)\directory" responds with 'Unknown username or bad password'. However,
once the command "net use z: \\(unix system)\directory" is given, it cmplets
successfully (obviously using the logged on users account) and THEN, the
"dir..." command works and displays the directory contents on the Unix system.

So, my thinking led me to installing the 'net use' command as service to
avoid having to have a user logged on to the Windows system.


"Mathieu CHATEAU" wrote:

> Hello,
>
> mapped drive are user based...how to get it if you are not the user who logs
> on ?
>
> I guess it's for a software installed on it ?
> Can't it uses UNC path ?
>
> --
> Cordialement,
> Mathieu CHATEAU
> http://lordoftheping.blogspot.com
>
>
> "gscanga" <gscanga@discussions.microsoft.com> wrote in message
> news:E94CA756-9AC1-45B2-A75B-8AC1C6E7ADB3@microsoft.com...
> > Does anyone know if this is relatively easy to accomplish?
> >
> > I'm trying to figure out if I can install a service on Windows 2003 that
> > will execute a net use command? So, this will allow a network drive to be
> > mapped without requiring a user to logon.
> >
> > Thanks!
> >

>
>
 
Re: Install mapped drive as a service?

If you do not have a user logged on, what access rights
should apply? Your question is equivalent to asking "How
do we open the bank's safe automatically in the morning
without an authorised person being present?" You don't!


"gscanga" <gscanga@discussions.microsoft.com> wrote in message
news:56E0485E-6EB0-43E6-830D-DC74FCB5965A@microsoft.com...
> Well, the issue arose as a result of NFS (Network File Sharing) to a Unix
> system. A DTS package taht's to run on the Windows system needs to see a
> remote directory on the Unix system but simply typing "dir \\(unix
> system)\directory" responds with 'Unknown username or bad password'.
> However,
> once the command "net use z: \\(unix system)\directory" is given, it
> cmplets
> successfully (obviously using the logged on users account) and THEN, the
> "dir..." command works and displays the directory contents on the Unix
> system.
>
> So, my thinking led me to installing the 'net use' command as service to
> avoid having to have a user logged on to the Windows system.
>
>
> "Mathieu CHATEAU" wrote:
>
>> Hello,
>>
>> mapped drive are user based...how to get it if you are not the user who
>> logs
>> on ?
>>
>> I guess it's for a software installed on it ?
>> Can't it uses UNC path ?
>>
>> --
>> Cordialement,
>> Mathieu CHATEAU
>> http://lordoftheping.blogspot.com
>>
>>
>> "gscanga" <gscanga@discussions.microsoft.com> wrote in message
>> news:E94CA756-9AC1-45B2-A75B-8AC1C6E7ADB3@microsoft.com...
>> > Does anyone know if this is relatively easy to accomplish?
>> >
>> > I'm trying to figure out if I can install a service on Windows 2003
>> > that
>> > will execute a net use command? So, this will allow a network drive to
>> > be
>> > mapped without requiring a user to logon.
>> >
>> > Thanks!
>> >

>>
>>
 
Re: Install mapped drive as a service?

Thanks for the insight Pegasus but for the sake of accuracy your analogy is
incorrect. Take, for instance, a windows service that uses a domain service
account to connect to remote sql server. An actual 'user' does not have to be
logged on since the service runs under the domain user service account.


"Pegasus (MVP)" wrote:

> If you do not have a user logged on, what access rights
> should apply? Your question is equivalent to asking "How
> do we open the bank's safe automatically in the morning
> without an authorised person being present?" You don't!
>
>
> "gscanga" <gscanga@discussions.microsoft.com> wrote in message
> news:56E0485E-6EB0-43E6-830D-DC74FCB5965A@microsoft.com...
> > Well, the issue arose as a result of NFS (Network File Sharing) to a Unix
> > system. A DTS package taht's to run on the Windows system needs to see a
> > remote directory on the Unix system but simply typing "dir \\(unix
> > system)\directory" responds with 'Unknown username or bad password'.
> > However,
> > once the command "net use z: \\(unix system)\directory" is given, it
> > cmplets
> > successfully (obviously using the logged on users account) and THEN, the
> > "dir..." command works and displays the directory contents on the Unix
> > system.
> >
> > So, my thinking led me to installing the 'net use' command as service to
> > avoid having to have a user logged on to the Windows system.
> >
> >
> > "Mathieu CHATEAU" wrote:
> >
> >> Hello,
> >>
> >> mapped drive are user based...how to get it if you are not the user who
> >> logs
> >> on ?
> >>
> >> I guess it's for a software installed on it ?
> >> Can't it uses UNC path ?
> >>
> >> --
> >> Cordialement,
> >> Mathieu CHATEAU
> >> http://lordoftheping.blogspot.com
> >>
> >>
> >> "gscanga" <gscanga@discussions.microsoft.com> wrote in message
> >> news:E94CA756-9AC1-45B2-A75B-8AC1C6E7ADB3@microsoft.com...
> >> > Does anyone know if this is relatively easy to accomplish?
> >> >
> >> > I'm trying to figure out if I can install a service on Windows 2003
> >> > that
> >> > will execute a net use command? So, this will allow a network drive to
> >> > be
> >> > mapped without requiring a user to logon.
> >> >
> >> > Thanks!
> >> >
> >>
> >>

>
>
>
 
Re: Install mapped drive as a service?

I am nearly sure windows service won't load all the users properties, and
may not load the network mapped drive.
I didn't test it myself yet anyway..

Create a windows account, log into, set the network mapped drive, log off,
log on to be sure it's still there.
Then try the windows service with this account.

Bu that's not safe for a production server even if it's works. Network drive
tends to stop working sometimes

--
Cordialement,
Mathieu CHATEAU
http://lordoftheping.blogspot.com


"gscanga" <gscanga@discussions.microsoft.com> wrote in message
news:9C808DAD-F8E4-4AF6-AE27-6E2610C7FC2B@microsoft.com...
> Thanks for the insight Pegasus but for the sake of accuracy your analogy
> is
> incorrect. Take, for instance, a windows service that uses a domain
> service
> account to connect to remote sql server. An actual 'user' does not have to
> be
> logged on since the service runs under the domain user service account.
>
>
> "Pegasus (MVP)" wrote:
>
>> If you do not have a user logged on, what access rights
>> should apply? Your question is equivalent to asking "How
>> do we open the bank's safe automatically in the morning
>> without an authorised person being present?" You don't!
>>
>>
>> "gscanga" <gscanga@discussions.microsoft.com> wrote in message
>> news:56E0485E-6EB0-43E6-830D-DC74FCB5965A@microsoft.com...
>> > Well, the issue arose as a result of NFS (Network File Sharing) to a
>> > Unix
>> > system. A DTS package taht's to run on the Windows system needs to see
>> > a
>> > remote directory on the Unix system but simply typing "dir \\(unix
>> > system)\directory" responds with 'Unknown username or bad password'.
>> > However,
>> > once the command "net use z: \\(unix system)\directory" is given, it
>> > cmplets
>> > successfully (obviously using the logged on users account) and THEN,
>> > the
>> > "dir..." command works and displays the directory contents on the Unix
>> > system.
>> >
>> > So, my thinking led me to installing the 'net use' command as service
>> > to
>> > avoid having to have a user logged on to the Windows system.
>> >
>> >
>> > "Mathieu CHATEAU" wrote:
>> >
>> >> Hello,
>> >>
>> >> mapped drive are user based...how to get it if you are not the user
>> >> who
>> >> logs
>> >> on ?
>> >>
>> >> I guess it's for a software installed on it ?
>> >> Can't it uses UNC path ?
>> >>
>> >> --
>> >> Cordialement,
>> >> Mathieu CHATEAU
>> >> http://lordoftheping.blogspot.com
>> >>
>> >>
>> >> "gscanga" <gscanga@discussions.microsoft.com> wrote in message
>> >> news:E94CA756-9AC1-45B2-A75B-8AC1C6E7ADB3@microsoft.com...
>> >> > Does anyone know if this is relatively easy to accomplish?
>> >> >
>> >> > I'm trying to figure out if I can install a service on Windows 2003
>> >> > that
>> >> > will execute a net use command? So, this will allow a network drive
>> >> > to
>> >> > be
>> >> > mapped without requiring a user to logon.
>> >> >
>> >> > Thanks!
>> >> >
>> >>
>> >>

>>
>>
>>
 
Re: Install mapped drive as a service?

"gscanga" <gscanga@discussions.microsoft.com> wrote in message
news:9C808DAD-F8E4-4AF6-AE27-6E2610C7FC2B@microsoft.com...
> Thanks for the insight Pegasus but for the sake of accuracy your analogy
> is
> incorrect. Take, for instance, a windows service that uses a domain
> service
> account to connect to remote sql server. An actual 'user' does not have to
> be
> logged on since the service runs under the domain user service account.
>



Possibly you could setup the Unix share as an iSCSI target for one Windows
server then share that from the Windows server. This might allow you to use
UNC paths.

--
Kerry Brown
Microsoft MVP - Shell/User
http://www.vistahelp.ca
 
Back
Top