Networking Forums

Networking Forums > Network Hardware > Home Networking > NET USE logon script

Reply
Thread Tools Display Modes

NET USE logon script

 
 
Tx2
Guest
Posts: n/a

 
      03-11-2007, 08:45 PM

I'm trying to set up a logon script using GPEDIT.MSC on a Windows XP Pro
(media centre edition) but i'm not on a domain, just a workgroup.

I need to map a drive on my other PC which is acting as a file server,
and UI want this to run in a script at logon.

thus far, I have created a .bat file which has been placed in C:\WINDOWS
\System32\GroupPolicy\User\Scripts\Logon and contains the following

net use n: \\OtherPC\MyFiles\

.....but I can't get it to run!

It shows up in the script logon properties of GPEDIT, so it's definitely
there.

The other PC has an account on it with the credential for this PC (I
also have network shares on the other PC which are restricted to just me
accessing them from this machine) so do I need to set up a password?

Maybe I'm going about it all the wrong way... help?



--
My reply address is invalid.
Please post replies to the group.
Messages sent via Google Groups are 'auto-ignored'
XPS M1710 / 2.16 GHz dual core / 2Gb DDR2 / nVidia GeForce 7950GTX
 
Reply With Quote
 
 
 
 
Simon Dobson
Guest
Posts: n/a

 
      03-11-2007, 08:51 PM
Tx2 wrote:
> I'm trying to set up a logon script using GPEDIT.MSC on a Windows XP Pro
> (media centre edition) but i'm not on a domain, just a workgroup.
>
> I need to map a drive on my other PC which is acting as a file server,
> and UI want this to run in a script at logon.
>
> thus far, I have created a .bat file which has been placed in C:\WINDOWS
> \System32\GroupPolicy\User\Scripts\Logon and contains the following
>
> net use n: \\OtherPC\MyFiles\


There should be no trailing \
 
Reply With Quote
 
Tx2
Guest
Posts: n/a

 
      03-11-2007, 09:09 PM
In article <(E-Mail Removed)>, Simon Dobson
of (E-Mail Removed)lid, felt we'd be interested in the
following...


> Tx2 wrote:
> > I'm trying to set up a logon script using GPEDIT.MSC on a Windows XP Pro
> > (media centre edition) but i'm not on a domain, just a workgroup.
> >
> > I need to map a drive on my other PC which is acting as a file server,
> > and UI want this to run in a script at logon.
> >
> > thus far, I have created a .bat file which has been placed in C:\WINDOWS
> > \System32\GroupPolicy\User\Scripts\Logon and contains the following
> >
> > net use n: \\OtherPC\MyFiles\

>
> There should be no trailing \


Tried with, and without - no success :-(

--
My reply address is invalid.
Please post replies to the group.
Messages sent via Google Groups are 'auto-ignored'
XPS M1710 / 2.16 GHz dual core / 2Gb DDR2 / nVidia GeForce 7950GTX
 
Reply With Quote
 
Martin Underwood
Guest
Posts: n/a

 
      03-11-2007, 09:17 PM
"Tx2" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed) T...
> In article <(E-Mail Removed)>, Simon Dobson
> of (E-Mail Removed)lid, felt we'd be interested in the
> following...
>
>
>> Tx2 wrote:
>> > I'm trying to set up a logon script using GPEDIT.MSC on a Windows XP
>> > Pro
>> > (media centre edition) but i'm not on a domain, just a workgroup.
>> >
>> > I need to map a drive on my other PC which is acting as a file server,
>> > and UI want this to run in a script at logon.
>> >
>> > thus far, I have created a .bat file which has been placed in
>> > C:\WINDOWS
>> > \System32\GroupPolicy\User\Scripts\Logon and contains the following
>> >
>> > net use n: \\OtherPC\MyFiles\

>>
>> There should be no trailing \

>
> Tried with, and without - no success :-(


What happens if you type this command in a DOS prompt after Windows has
started - does it work OK or does it give an error message.

Why do you need to connect using logon script rather than configuring it in
Windows Explorer "Map Network Drive"?


 
Reply With Quote
 
Tx2
Guest
Posts: n/a

 
      03-11-2007, 09:34 PM
In article <45f47ffb$0$8723$(E-Mail Removed)>, Martin
Underwood
of (E-Mail Removed), felt we'd be interested in the following...


> What happens if you type this command in a DOS prompt after Windows has
> started - does it work OK or does it give an error message.


"Logon failure: unknown user name or bad password."

So it is going to require my account username and password?
Not too happy about this being in a .bat file...

I know I can wildcard the password for a prompt, but that defeats the
object.

> Why do you need to connect using logon script rather than configuring it in
> Windows Explorer "Map Network Drive"?


I don't. I'm just trying an alternate method, mainly in part because I
am embarking on installing Server 2000 soon in preparation for an even
bigger project I'm undertaking in the near future

:-)

I will be 'mucking' about with domains, active directory and so on. I
want to get a few scripts running first.

--
My reply address is invalid.
Please post replies to the group.
Messages sent via Google Groups are 'auto-ignored'
XPS M1710 / 2.16 GHz dual core / 2Gb DDR2 / nVidia GeForce 7950GTX
 
Reply With Quote
 
Martin Underwood
Guest
Posts: n/a

 
      03-11-2007, 09:51 PM

"Tx2" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed) T...
> In article <45f47ffb$0$8723$(E-Mail Removed)>, Martin
> Underwood
> of (E-Mail Removed), felt we'd be interested in the following...
>
>
>> What happens if you type this command in a DOS prompt after Windows has
>> started - does it work OK or does it give an error message.

>
> "Logon failure: unknown user name or bad password."
>
> So it is going to require my account username and password?
> Not too happy about this being in a .bat file...
>
> I know I can wildcard the password for a prompt, but that defeats the
> object.
>
>> Why do you need to connect using logon script rather than configuring it
>> in
>> Windows Explorer "Map Network Drive"?

>
> I don't. I'm just trying an alternate method, mainly in part because I
> am embarking on installing Server 2000 soon in preparation for an even
> bigger project I'm undertaking in the near future
>
> :-)
>
> I will be 'mucking' about with domains, active directory and so on. I
> want to get a few scripts running first.


create an account on each PC with the same username (and maybe same
password)


 
Reply With Quote
 
David Wade
Guest
Posts: n/a

 
      03-11-2007, 10:25 PM

"Tx2" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed) T...
>
> I'm trying to set up a logon script using GPEDIT.MSC on a Windows XP Pro
> (media centre edition) but i'm not on a domain, just a workgroup.
>
> I need to map a drive on my other PC which is acting as a file server,
> and UI want this to run in a script at logon.
>
> thus far, I have created a .bat file which has been placed in C:\WINDOWS
> \System32\GroupPolicy\User\Scripts\Logon and contains the following
>
> net use n: \\OtherPC\MyFiles\
>
> ....but I can't get it to run!
>
> It shows up in the script logon properties of GPEDIT, so it's definitely
> there.
>


You may need to put it in the user section....

> The other PC has an account on it with the credential for this PC (I
> also have network shares on the other PC which are restricted to just me
> accessing them from this machine) so do I need to set up a password?
>
> Maybe I'm going about it all the wrong way... help?
>
>
>
> --
> My reply address is invalid.
> Please post replies to the group.
> Messages sent via Google Groups are 'auto-ignored'
> XPS M1710 / 2.16 GHz dual core / 2Gb DDR2 / nVidia GeForce 7950GTX



 
Reply With Quote
 
Mike Sun
Guest
Posts: n/a

 
      03-11-2007, 11:30 PM

"Martin Underwood" <(E-Mail Removed)> wrote in message
news:45f487dc$0$8752$(E-Mail Removed)...
> create an account on each PC with the same username (and maybe same
> password)


or try the syntax:-

net use s: \\servername\sharename /u:username password

Cheers from Mike


 
Reply With Quote
 
Tx2
Guest
Posts: n/a

 
      03-12-2007, 05:30 PM
In article <45f487dc$0$8752$(E-Mail Removed)>, Martin
Underwood
of (E-Mail Removed), felt we'd be interested in the following...


>
> "Tx2" <(E-Mail Removed)> wrote in message
> news:(E-Mail Removed) T...
> > In article <45f47ffb$0$8723$(E-Mail Removed)>, Martin
> > Underwood
> > of (E-Mail Removed), felt we'd be interested in the following...
> >
> >
> >> What happens if you type this command in a DOS prompt after Windows has
> >> started - does it work OK or does it give an error message.

> >
> > "Logon failure: unknown user name or bad password."
> >
> > So it is going to require my account username and password?
> > Not too happy about this being in a .bat file...
> >
> > I know I can wildcard the password for a prompt, but that defeats the
> > object.
> >
> >> Why do you need to connect using logon script rather than configuring it
> >> in
> >> Windows Explorer "Map Network Drive"?

> >
> > I don't. I'm just trying an alternate method, mainly in part because I
> > am embarking on installing Server 2000 soon in preparation for an even
> > bigger project I'm undertaking in the near future
> >
> > :-)
> >
> > I will be 'mucking' about with domains, active directory and so on. I
> > want to get a few scripts running first.

>
> create an account on each PC with the same username (and maybe same
> password)


That has been done as a matter of course anyway due to some shares
already in place.


--
My reply address is invalid.
Please post replies to the group.
Messages sent via Google Groups are 'auto-ignored'
XPS M1710 / 2.16 GHz dual core / 2Gb DDR2 / nVidia GeForce 7950GTX
 
Reply With Quote
 
Simon Dobson
Guest
Posts: n/a

 
      03-12-2007, 05:34 PM
Tx2 wrote:
>
>> Tx2 wrote:
>>> I'm trying to set up a logon script using GPEDIT.MSC on a Windows XP Pro
>>> (media centre edition) but i'm not on a domain, just a workgroup.
>>>
>>> I need to map a drive on my other PC which is acting as a file server,
>>> and UI want this to run in a script at logon.
>>>
>>> thus far, I have created a .bat file which has been placed in C:\WINDOWS
>>> \System32\GroupPolicy\User\Scripts\Logon and contains the following
>>>
>>> net use n: \\OtherPC\MyFiles\

>> There should be no trailing \

>
> Tried with, and without - no success :-(


There wouldn't be with a trailing \ :-)

As other posters have pointed out (and as the error message shows you
missed from your first post!), this is permissions related. Check you've
identical accounts set up on both PC's, and that share/file permissions
are as they should be.
 
Reply With Quote
 
 
 
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
No logon script over wan Martin Schweizer Windows Networking 2 06-15-2007 03:25 PM
GP logon script Stuart Jeffrey Windows Networking 1 09-12-2004 08:31 PM
Logon script =?Utf-8?B?RGF2ZQ==?= Windows Networking 4 04-22-2004 11:56 PM
Logon Script Eddy Melsbach Windows Networking 2 02-18-2004 02:18 PM
Logon script Alan Crawford Windows Networking 0 12-26-2003 10:45 PM



1 2 3 4 5 6 7 8 9 10 11