A mapped drive is useful when you want to transfer files between multiple computers over a network. However, sometimes mapped Drive gets disconnected while copying large files. It usually happens because Windows automatically kills the session after a certain period. Luckily, fixing the issue is not complicated, and below you will find all the methods to deal with the error:
Why Does Mapped Drive Get Disconnected?
There can be various reasons why your mapped drive gets disconnected. According to Microsoft, a mapped drive can get disconnected if sitting idle for too long to prevent wasting server resources on unused sessions. Usually, it will get disconnected if your mapped drive is not in use for about 15 minutes or so.
However, there can be other reasons behind this. For instance, the mapped drive source computer might be offline, the disk drive is faulty, or there are some issues with the network.
Fix: Mapped Drive Gets Disconnected While Copying Large Files in Windows
While the issue can appear for many reasons, fixing it is fairly straightforward. To get rid of the error, here are some methods that you can try out:
- Command Line method
- Using Registry
You will need admin permission to execute these steps. Also, create a system restore before making changes in the registry.
1] Turn off the Auto-disconnect Feature Using the Command Line
As mentioned earlier, Windows automatically disconnects the mapped drives after a certain period. To prevent that, you can turn off the feature. For this, you have to follow the below steps:
- Right-click on the Start Menu.
- Click on Windows Terminal (Admin) > Yes.
- In Windows Terminal, copy and run the following command, and press the Enter key.
net config server /autodisconnect:-1
2] Turn off the Auto-disconnect Using the Registry
You can also modify the auto-disconnect feature using Registry. However, Regedit cannot turn off the auto-disconnect feature on the server side. But it allows you to change the default time-out period of the auto-disconnect feature. And to do so, follow these steps:
- Press Windows Key + R to launch Run.
- Type Regedit and press Enter.
- Go to the following location:
- In the right pane, you will find an autodisconnect value, right-click on it and select Modify.
- If you don’t see the autodisconnect value, right-click on a blank surface, New > REG_DWORD > Name it autodisconnect, and press enter.
- From the Modify Window, select Hexadecimal value.
- Finally, in the value data box, type ffffffff, and then click OK.
Besides the server side, the client-side session gets disconnected when the connection sits idle for too long. However, you can extend the period of your client-side machine by creating a KeepConn value. To do so, follow these steps:
- Press Windows Key + R to launch the Run prompt
- Type Regedit and press Enter to open the Registry Editor
- Go to the following location:
- Now right-click and select New > REG_DWORD Value and name it KeepConn.
- Finally, double-click on the value and enter a value between 1 to 65535 seconds. The default value is set to 600 seconds or 10 mins. However, to prevent any unwanted server disconnection set the value to its highest number.
So those were a few quick methods to fix the mapped drive getting disconnected while copying large files in Windows. I recommend disabling the auto-disconnect feature of Windows to prevent any issues in the future. But feel free to choose the right setting as per your usage.
How Do I Unmap a Disconnected Network Drive?
You can unmap a network drive by accessing File Explorer > This PC. Then under the Network locations, right-click on the drive you want to unmap and select disconnect, and the drive will no longer be available on your computer.
How Do I Permanently Map a Network Drive in Windows?
To map a network drive, first, you need to turn on Network discovery by going to Control Panel > Network and Internet > Network and Sharing Center > Change advanced sharing settings.
Over here, turn on every other feature, and for password protection sharing, make sure to disable it. Once done, go to File Explorer > This PC, click on the three-dotted icon, and select Map network drive. Next, click on Browse and select a folder that you want to share over your network, and you are good to go.