# Mapped drives lose connectivity upon reboot



## asuh (Jan 18, 2009)

Our network consists of the following:

1x Windows Server 2003
5x Windows XP Home
1x Windows Vista Home x64

I have mapped drives from each of the desktops to a folder on the server. Everytime a PC is shut off then booted again, upon booting into Windows the mapped connection is lost. I have to go to each PC and manually reconnect to the server using the username and password.

I'm not sure why these connections are breaking when someone reboots the computer.

I checked the event log on the server and I'm getting an error that might be related:


> Error 1054
> Windows cannot obtain the domain controller name for your computer network. (An unexpected network error occurred. ). Group Policy processing aborted.


Help me!


----------



## Squashman (Apr 4, 2003)

I guess I will ask the obvious.
How did you map the drives?
If you did it thru the Windows Explorer GUI did you check the box to Reconnect at login?
If a batch file did you use the persistent and save credentials switches?


----------



## asuh (Jan 18, 2009)

I mapped the drives using the Windows Explorer GUI as you guessed. I am not sure I remember seeing any Reconnect at Login checkbox when I originally mapped these drives.

Knowing that I missed this, must I break and remap these drives and enabling this Reconnect at Login checkbox?

If I go back to find out that there is no Reconnect at login checkbox, what should I do?


----------



## Squashman (Apr 4, 2003)

asuh said:


> If I go back to find out that there is no Reconnect at login checkbox, what should I do?


Trust me. It is there on XP and Vista.


----------



## JohnWill (Oct 19, 2002)

Squashman said:


> Trust me. It is there on XP and Vista.


And even with Windows 7.


----------



## asuh (Jan 18, 2009)

Okay, I have an update.

When mapping drives in XP, the reconnect at login checkbox is already enabled by default. So, all of the mapped drives that I have created and will create all have this box checked by default.

So, having double checked this problem and confirmed that I am indeed doing it correctly, what other solutions can you provide?


----------



## JohnWill (Oct 19, 2002)

Did you try it with the NET USE command?


----------



## asuh (Jan 18, 2009)

JohnWill, I did not use the net use command. What's the full command I should use?


----------



## JohnWill (Oct 19, 2002)

NET USE d: \\_<network_path>_ /USER:_<user_name>_ _<password>_ /PERSIST:YES

_d: - Local drive letter for mapping.
<network_path> - The full network path to the shared resource.
<user_name> - The user name on the remote server.
<password> - The user password on the remote server._


----------



## asuh (Jan 18, 2009)

Is this command doing anything different than the Windows Explorer GUI or is it just the line command version?


----------



## JohnWill (Oct 19, 2002)

The GUI should work, it's always worked for me.

I just figure if something odd is going on, we could see if this works properly.


----------



## Squashman (Apr 4, 2003)

You should only have to use credentials if the username and password are different from the workstation to the server. You may want to add the /savecred switch as well.


----------



## asuh (Jan 18, 2009)

Alright, thanks. I'll give it a shot and report back.

FYI, I should have included this in the beginning, even if it might be obvious, that these computers are not in a domain, only connected to the wired network. The Windows Home desktops are in the same workgroup and the server is in it's own domain.


----------



## Squashman (Apr 4, 2003)

asuh said:


> FYI, I should have included this in the beginning, even if it might be obvious, that these computers are not in a domain, only connected to the wired network. The Windows Home desktops are in the same workgroup and the server is in it's own domain.


That was plain obvious from your first post. XP Home and Vista Home cannot be joined to a domain.


----------



## asuh (Jan 18, 2009)

Squashman said:


> That was plain obvious from your first post. XP Home and Vista Home cannot be joined to a domain.


haha, okay. You never know who would quickly overlook this fact so I thought plainly stating it would be good.


----------



## JohnWill (Oct 19, 2002)

More information is always good.


----------



## asuh (Jan 18, 2009)

Okay, I finally have an update! I couldn't do anything until end of business day and I'm on the left coast so people are finally leaving here.

We are still having the issue of losing connection upon reboot. I tried the net use command with and without the /savecred switch and it still breaks the connection. Using /savecred switch seems to conflict with /persist switch so that wasn't successful.

Either way, I can't seem to have these desktops keep the connection alive after a reboot.


----------



## JohnWill (Oct 19, 2002)

Well, you could always put the NET USE command in the startup folder so they're remapped each boot.


----------



## Squashman (Apr 4, 2003)

JohnWill said:


> Well, you could always put the NET USE command in the startup folder so they're remapped each boot.


Agreed. There doesn't seem to be any definitive reason as to why this happens or a definitive fix for it. But making a batch file to execute at startup should work.

Are these computers wired to the network or are they wireless? If they are wireless tt may be they are trying to map the drives before a network connection is present.


----------



## asuh (Jan 18, 2009)

Man, I sure hope that startup folder suggestion isn't the main answer because that seems so janky!

All the computers are wired. We now have no wireless connections available.


----------



## JohnWill (Oct 19, 2002)

I know that drive mapping works fine for me with wired systems, don't know what's going on there. I have to agree with the previous opinion, for some reason the mapping may be failing because it takes too long to get a connection.

Did you look in the Event Log of one of these systems to see if there's an error related to attempting to map the drive?


----------



## asuh (Jan 18, 2009)

JohnWill said:


> Did you look in the Event Log of one of these systems to see if there's an error related to attempting to map the drive?


See my first post for the error I'm getting. This problem could certainly be related to a DNS error that I'm having but I don't know.

If I write a batch file that includes the net use, will this basically be recreating the mapped drive every time? All I need to happen on reboot is to log into the existing mapped drives, not create new ones.


----------



## Squashman (Apr 4, 2003)

Have your batch file delete any existing mappings first and then recreate them.
I know it is kind of hokey but you gotta do what you gotta do to get things done sometimes. Back in the days of Win 9x the only way to get things to launch at startup was to put it in the startup folder. You should thank Bill for at least having that option in your time of need.


----------



## asuh (Jan 18, 2009)

Squashman said:


> Have your batch file delete any existing mappings first and then recreate them.
> I know it is kind of hokey but you gotta do what you gotta do to get things done sometimes. Back in the days of Win 9x the only way to get things to launch at startup was to put it in the startup folder. You should thank Bill for at least having that option in your time of need.


Oh no, don't get me wrong, I'll definitely thank Bill if/once I get this working correctly! It's the best solution yet!!

Let's talk hypothetical first: If I write this batch file to delete Q drive, recreate Q drive, and enter credentials, I shouldn't have to do this to every single mapped file on the same server, right? I'm assuming that once I recreate the one mapped drive, the other mapped drives will then be able to log in based on the fact that I logged into the one. Right?

Assuming so, how would I write this net use command? I'm not sure how to do it. Thanks for all your help so far!! You guys are amazing.


----------



## JohnWill (Oct 19, 2002)

Actually, if the mappings are getting lost, you'll probably have to have a NET USE for each mapping.

I had overlooked the error you're getting, that appears to be what *Squashman* mentioned, for some reason the workstation isn't connected when the drive mappings are being attempted.


----------



## asuh (Jan 18, 2009)

JohnWill said:


> Actually, if the mappings are getting lost, you'll probably have to have a NET USE for each mapping.


Upon reboot, all the mapped drives are there and do exist. In fact, I think any mapped drive to another Windows XP Home stays connected (although, I'm not at work and looking at this but I've only had a problem with the server). It's just that the mapped drives to the server need to be logged in after each reboot. Once I log into one, all of them are accessible.

Hmm... I think maybe I was a little unclear about what's going on. It's not that I'm completely losing all sign of a mapped drive after I log into the desktop after a reboot. Every original mapped drive appears but needs to be logged into again after every reboot. That's what causing the most problems since Quickbooks multiuser files are being shared centrally.


----------



## JohnWill (Oct 19, 2002)

So, you have a user permissions issue, not a drive mapping issue, right?

Try running this on the server.

Create a file in notepad named FIXANON.REG with the following contents:

You should have 3 boxes on the bottom in NOTEPAD.
1)Filename : FIXANON.REG
2)Save as type: all files
3)Encoding: ANSI
If you do not change it from txt type to All files type, then the file will actually be FIXANON.REG.txt, this won't accomplish the desired result.

------------------- Use text after this line -------------------
Windows Registry Editor Version 5.00
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Lsa]
"restrictanonymous"=dword:00000000
------------------- Use text before this line -----------------

Double click on the file and say Yes to the merge into registry question.

Reboot the computer.


----------



## Squashman (Apr 4, 2003)

Do your users have the same username and password on server and their PC?


----------



## asuh (Jan 18, 2009)

I'm sorry for my delayed response to this. It has been a hectic week and time was running short.

I have done as JohnWill suggested by patching the registry. I saw no change, however. It's possible that the reason is because I didn't reboot the server, but I'm going out of town for a few weeks and won't be able to revisit this problem until I'm back.

To answer Squashman's question, the local user accounts have different usernames and passwords, each unique to its own computer. There are no shared usernames and passwords on the server since it's running in its own domain and I'm not sure there would be any benefit to recreating these usernames and passwords in the domain that we're not using. Is there something I don't know?

Thanks for all your suggestions, guys! I'll report back as soon as I have something to say.


----------



## Squashman (Apr 4, 2003)

If you map a drive to another computer and the user has the same credentials (ie: username and password) on both computers there shouldn't ever be a problem mapping the drive as long as they have permissions to access the share.


----------



## asuh (Jan 18, 2009)

Squashman, does that work for a desktop workstation and server in a domain? Theoretically, it sounds correct as long as the local UNs and PWs are the same, but that isn't how we log into the server. There's an actual domain which is active but only on the server, which is where we log in using a UN and PW created from active directory.


----------

