Logon Credentials set via logon script?

G

Guest

Question pertains to setting logon credentials in a logon script. We are
setting up a remote client with access to a mapped network drive. The problem
is everytime the pc is rebooted the settings for the drive are not saved.
Drive is there @ every reboot, but credientials are not saved. Is there a way
to write a logon script that maps the drive as well as sets the logon
credentials!

All help is appreciated! Thank you
 
R

Richard G. Harper

Use the following logon script:

net use d: /d
net use d: \\servername\sharename <password> /user:<username>

Of course, change the d: drive letter to the correct drive letter and make
the obvious substitutions above.

By disconnecting the drive first, then reconnecting with the correct
username and password you can avoid the problem of non-cached credentials.

--
Richard G. Harper [MVP Shell/User] (e-mail address removed)
* PLEASE post all messages and replies in the newsgroups
* for the benefit of all. Private mail is usually not replied to.
* My website, such as it is ... http://rgharper.mvps.org/
* HELP us help YOU ... http://www.dts-l.org/goodpost.htm
 
G

Guest

Where in XP would I be able to put this script. For some reason I am not
finding the Script folder where this would go.?

Richard G. Harper said:
Use the following logon script:

net use d: /d
net use d: \\servername\sharename <password> /user:<username>

Of course, change the d: drive letter to the correct drive letter and make
the obvious substitutions above.

By disconnecting the drive first, then reconnecting with the correct
username and password you can avoid the problem of non-cached credentials.

--
Richard G. Harper [MVP Shell/User] (e-mail address removed)
* PLEASE post all messages and replies in the newsgroups
* for the benefit of all. Private mail is usually not replied to.
* My website, such as it is ... http://rgharper.mvps.org/
* HELP us help YOU ... http://www.dts-l.org/goodpost.htm


iQtony said:
Question pertains to setting logon credentials in a logon script. We are
setting up a remote client with access to a mapped network drive. The
problem
is everytime the pc is rebooted the settings for the drive are not saved.
Drive is there @ every reboot, but credientials are not saved. Is there a
way
to write a logon script that maps the drive as well as sets the logon
credentials!

All help is appreciated! Thank you
 
R

Richard G. Harper

You can put it in the domain script folder on the AD domain controller
(C:\WINNT\SYSVOL\sysvol) and assign it to users via AD, or you could copy it
to each PC in the C:\Documents and Settings\All Users\Start Menu\Startup
folder.

--
Richard G. Harper [MVP Shell/User] (e-mail address removed)
* PLEASE post all messages and replies in the newsgroups
* for the benefit of all. Private mail is usually not replied to.
* My website, such as it is ... http://rgharper.mvps.org/
* HELP us help YOU ... http://www.dts-l.org/goodpost.htm


iQtony said:
Where in XP would I be able to put this script. For some reason I am not
finding the Script folder where this would go.?

Richard G. Harper said:
Use the following logon script:

net use d: /d
net use d: \\servername\sharename <password> /user:<username>

Of course, change the d: drive letter to the correct drive letter and
make
the obvious substitutions above.

By disconnecting the drive first, then reconnecting with the correct
username and password you can avoid the problem of non-cached
credentials.

--
Richard G. Harper [MVP Shell/User] (e-mail address removed)
* PLEASE post all messages and replies in the newsgroups
* for the benefit of all. Private mail is usually not replied to.
* My website, such as it is ... http://rgharper.mvps.org/
* HELP us help YOU ... http://www.dts-l.org/goodpost.htm


iQtony said:
Question pertains to setting logon credentials in a logon script. We
are
setting up a remote client with access to a mapped network drive. The
problem
is everytime the pc is rebooted the settings for the drive are not
saved.
Drive is there @ every reboot, but credientials are not saved. Is there
a
way
to write a logon script that maps the drive as well as sets the logon
credentials!

All help is appreciated! Thank you
 
G

Guest

That much is done. One issue pertains to that script not working when placed
in the startup. Is there a setting that needs to be changed so that it will
work. Another issue is if we store this in a script folder, then call this
when initializing an application (in the target section of properties for a
certain application) so that whenever the application is started the drive is
mapped, how can we set it so that it is mapped once when the app is started,
and you close out and go back in, that it won't try to map it again and give
you error msg sayin name already exists.

Richard G. Harper said:
You can put it in the domain script folder on the AD domain controller
(C:\WINNT\SYSVOL\sysvol) and assign it to users via AD, or you could copy it
to each PC in the C:\Documents and Settings\All Users\Start Menu\Startup
folder.

--
Richard G. Harper [MVP Shell/User] (e-mail address removed)
* PLEASE post all messages and replies in the newsgroups
* for the benefit of all. Private mail is usually not replied to.
* My website, such as it is ... http://rgharper.mvps.org/
* HELP us help YOU ... http://www.dts-l.org/goodpost.htm


iQtony said:
Where in XP would I be able to put this script. For some reason I am not
finding the Script folder where this would go.?

Richard G. Harper said:
Use the following logon script:

net use d: /d
net use d: \\servername\sharename <password> /user:<username>

Of course, change the d: drive letter to the correct drive letter and
make
the obvious substitutions above.

By disconnecting the drive first, then reconnecting with the correct
username and password you can avoid the problem of non-cached
credentials.

--
Richard G. Harper [MVP Shell/User] (e-mail address removed)
* PLEASE post all messages and replies in the newsgroups
* for the benefit of all. Private mail is usually not replied to.
* My website, such as it is ... http://rgharper.mvps.org/
* HELP us help YOU ... http://www.dts-l.org/goodpost.htm


Question pertains to setting logon credentials in a logon script. We
are
setting up a remote client with access to a mapped network drive. The
problem
is everytime the pc is rebooted the settings for the drive are not
saved.
Drive is there @ every reboot, but credientials are not saved. Is there
a
way
to write a logon script that maps the drive as well as sets the logon
credentials!

All help is appreciated! Thank you
 
R

Richard G. Harper

If a script file is placed in the All Users' Startup folder it should always
execute when a user logs on. As for re-running the script there should be
no problem if you design it as I suggested since the network drive will be
disconnected before it's re-connected.

--
Richard G. Harper [MVP Shell/User] (e-mail address removed)
* PLEASE post all messages and replies in the newsgroups
* for the benefit of all. Private mail is usually not replied to.
* My website, such as it is ... http://rgharper.mvps.org/
* HELP us help YOU ... http://www.dts-l.org/goodpost.htm
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top