Disconnect from a network share
How do I really disconnect from a network share in Windows 8.1?
I'm familiar with using net use to disconnect from a network share, even if it isn't mapped to a network drive letter:
net use \\server\share /delHowever, even after doing so, the folder may remain connected: if I quickly open Windows Explorer and go to \server\share, it connects immediately, without prompting me for a password, and I can do whatever file operations I want in that folder without it ever showing up again in net use's output.
If I use net use /del then leave things alone for 10-15 seconds, then the share appears to really disconnect, so that Windows Explorer prompts for password and takes time to reconnect and so on.
I'm not sure that this is a duplicate of this question; that makes it sound like net use sometimes fails, while my issue is that it appears to work but leaves connections open that it can't see.
Is there a way to really, truly close network share connections, besides net use? Is there a way to see what connections are open that net use isn't telling me about?
(This is using a Windows 8.1 Active Directory domain member as a client and a non-domain member Samba server.)
12 Answers
Run net use * /delete instead. This will remove all share connections, and force you to use a new username/password, unless you're on a domain joined computer
It sounds like what you're running into is Kerberos credential caching, which refreshes on a timed interval.
Try this, which will disconnect the map, and then purge the Kerberos list:
net use \\server\share /del
klist purgeklist by itself should show you currently active Kerberos 'tickets', that may be used.