Login script executes from which server?

I have a W2k server and a Windows Server 2003 in the same domain and am running AD.  I am not having very reliable results running the script to simply map some drives.  I have been making the adjustments to the scriptacct.bat file that looks like this:
:rem script for accounting group
net use M:  \\ccs3\acct$ /persistent:no
net use P:  \\ccs3\public /persistent:no
:rem net use H:  /delete
:rem if exist H: net use H: /delete /y
:net use H:  \\ccs3\%Username%$ /persistent:no
:rem net use M:  \\ccs3\acct$ /persistent:no
:rem if exist p: net use p: /delete /y
----------------------------------------------------------------

This file is located in this directory \\servername\sysvol\sysvol\domainname\scripts\  on the 2003 server, but seems to replicate to the W2k server in the like directory.  

I am only trying to get it to execute a simple mapping command on XP desktops.  I have the profile tab for the test users to read:  scriptacct.bat

I have been also including a home directory in the profile tab and sometimes in the script.

The drive mappings do not work from a cold boot.  If I then do a logoff/logon, the mappings work very consistently.  Is there something strange about where I am putting this script?  I would like to think that I have migrated all of the important services to the 2003 server, except for some printing services.  When I browse the network from a WIN98 desktop I can only see the "logon" share on the original W2K server.

The bat file works very well if I execute it manually after bootup.  

I have spent hours trying to find a pattern.  The best that I can figure is that the script does not execute from a cold boot, or a restart. A subsequent logon/logoff seems to do the trick.

What is wrong with my process?

winventionsAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

NJComputerNetworksCommented:
"This file is located in this directory \\servername\sysvol\sysvol\domainname\scripts\  on the 2003 server, but seems to replicate to the W2k server in the like directory.  "    Scripts are replicated to every DC by default.  \\serverdc\netlogon directory is how the clients get to this infomration....


0
NJComputerNetworksCommented:
So, if I understand you right, you have a logon script that basically does this:

net use M:  \\ccs3\acct$ /persistent:no
net use P:  \\ccs3\public /persistent:no

The script name is scriptacct.bat

You have copied the scriptacct.bat file to the \\serverdc\netlogon directory.


-------------------------------

I would recommend adding this to your script (This will make sure that the clients doesn't have these drive letters already in use)
Net use M: /delete
net use M:  \\ccs3\acct$ /persistent:no
Net use P: /delete
net use P:  \\ccs3\public /persistent:no

"The drive mappings do not work from a cold boot.  If I then do a logoff/logon, the mappings work very consistently."  I wonder if there are any event viewer errors on the client after reboot.  Can you check this..

Make sure that your clients TCP/IP properties is setup to point DNS to your internal Windows 200X DNS servers.  The clients should only point to internal Windows 200x DNS servers....not to ISP DNS servers.

For example:

Server NAme:  DC1Server
IP: 10.10.10.5
Subnet: 255.255.255.0
Gateway: 10.10.10.1
DNS: 127.0.0.1 or 10.10.10.5   <-- internal Windows DNS must be pointed locally not to ISP DNS servers

Client NAme:  Desktop1
IP: 10.10.10.50
Subnet: 255.255.255.0
Gateway: 10.10.10.1
DNS: 10.10.10.5   <-- internal Windows DNS must be pointed to internal Windows 200x server not to ISP DNS servers.









0
NJComputerNetworksCommented:
what OS's are you client machines?
0
Cloud Class® Course: Microsoft Azure 2017

Azure has a changed a lot since it was originally introduce by adding new services and features. Do you know everything you need to about Azure? This course will teach you about the Azure App Service, monitoring and application insights, DevOps, and Team Services.

winventionsAuthor Commented:
So, if I understand you right, you have a logon script that basically does this:

net use M:  \\ccs3\acct$ /persistent:no
net use P:  \\ccs3\public /persistent:no

The script name is scriptacct.bat

You have copied the scriptacct.bat file to the \\serverdc\netlogon directory.


This is correct.   I did have some other lines that were disconnecting from the drive letter, but remarked them to simplify the script.  I was getting some errors about files already being open on those drive and had added the /y parameter to force the disconnect.

You asked about event errors on the cold reboot.  I do see that there are some errors that say they cannot find the domain controller for your computer network.  The specified domain either does not exist or could not be contacted.  Group policy process aborted.

I do have my DNS pointed to my internal server, but also to the ISP DNS.  I have been adding my server DNS, because it was not be pushed by the DHCP server.  Is this the root problem?


0
winventionsAuthor Commented:
My client machines are Win98, 2K and Xp.  I was planning on adapting the script to each OS.  I may be able to get rid of the 98 machines before I implement this script.

Thanks.
0
NJComputerNetworksCommented:
"I do have my DNS pointed to my internal server, but also to the ISP DNS.  I have been adding my server DNS, because it was not be pushed by the DHCP server.  Is this the root problem?"  This could very well be the problem.

You need to point all clients and server of a Windows 200x domain to internal DNS servers only.  The members of the domain need DNS to "Talk" to active directory.

So, please make sure that you have this setup:

Make sure that your clients TCP/IP properties is setup to point DNS to your internal Windows 200X DNS servers.  The clients should only point to internal Windows 200x DNS servers....not to ISP DNS servers.

For example:

Server NAme:  DC1Server
IP: 10.10.10.5
Subnet: 255.255.255.0
Gateway: 10.10.10.1
DNS: 127.0.0.1 or 10.10.10.5   <-- internal Windows DNS must be pointed locally not to ISP DNS servers

Client NAme:  Desktop1
IP: 10.10.10.50
Subnet: 255.255.255.0
Gateway: 10.10.10.1
DNS: 10.10.10.5   <-- internal Windows DNS must be pointed to internal Windows 200x server not to ISP DNS servers.

Then to get Internet DNS resolution working, you can enable DNS forwarding on each Internal Windows 200x DNS server.  To do this go into the DNS console.  Right click your DNS server name in the left hand pane...and choose PROPERTIES from the drop down box.  Then click the FORWARDERS tab.  Enter the IP address of your Internet Router or enter the IP addresses of the ISP DNS servers.  Do this on each Internal Windows DNS server...

Then test to make sure you can get out to the internet.,,,using IE.

You must get those errors to go away on the client computers before going too crazy with your logon script.  It sounds to me like the client machines are not "talking" to active directory correctly.  This would prevent the logon script from running.  You may have to remove the computer from the domain and re-add it to the domain.


0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
winventionsAuthor Commented:
I see your post and am testing your comments.  Thanks.
0
NJComputerNetworksCommented:
ok
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Windows Server 2003

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.