Monday, August 10, 2009

How to "forget" network share credentials so you can authenticate as another user

UPDATE (10/26/09): I recently stumbled across a case where I was getting the "multiple connections" error and the steps below did not resolve the issue. There is one more place to look (especially if you checked the box to "Remember my password" when connecting to the network share) to remove stored credentials. Go to Control Panel -> User Accounts. Then go to the Advanced tab and under "Passwords and .NET Passports" click on "Manage Passwords". If the server you're trying to connect to is listed there, you're in luck. Simply remove the entry, and log off and then back in again. You should then be prompted for your new credentials.

This is something that has saved me a lot of time by removing the need to log out from my current Windows session. Have you ever connected to a network share and then wanted to authenticate as another user and received the following error:
"Multiple connections to a server or shared resource by the same user, using more than one user name, are not allowed."?

For the longest time, I thought the solution was to log out and then back in again to authenticate as the other user. It turns out there is a much easier way to get your computer to "forget" your current credentials so that you can use alternative ones. Simply bring up a command prompt and type:
net use * /d /y
This will effectively disconnect all remote connections as well as their associated credentials.
If you have more than one network connection open and you'd rather just delete a specific connection, type in:
net use
in a command prompt window. This will list all of your current remote connections. To delete a specific connection (let's say to \\server\share), type in the following in the command prompt:
net use \\server\share /d /y

If you're more of a GUI fan, you can go to My Computer and then select:
Tools -> Disconnect Network Drive
Then just select the specific connection that you'd like to disconnect and click the OK button.

I hope that this saves you some time!


Sam said...

Thanks Matt...I hate when that happens!

Matt Augustine said...

Hey Sam! Thanks for stopping by :)
I know what you're saying! This has always bugged me when I needed it -- so hopefully it'll help someone!

Anonymous said...

Thanks, Matt. You just helped me tremendously! I have a colleague who can benefit from this tip as well. Thanks!

Matt Augustine said...

Hi! I'm glad that it will save you both some time, and thanks for stopping by! Have a great weekend!

Anonymous said...

Thanks alot Matt

Alex Lovasas said...

Thanks a lot. That helped me too!!

Anonymous said...

I had accidentally clicked the "remember password" icon on my laptop when logging into my desktop over the network, and used your command line suggestion to forget the remembered password. It forgot it, but now I can no longer connect to the desktop from the laptop at all, using any username/password.

Anonymous said...

Thank you!

Julie K. said...

Thanks Matt! Just the help I was looking for.