SUBST – Windows CMD Command
Substitute a drive letter for a network or local path.
SUBST drive_letter: path
SUBST drive_letter: /D
SUBST with no parameters will display current SUBST drives
/D : Delete the drive_letter substitution.
The SUBST command can be used to map a drive letter to a LOCAL folder on the same machine. In early versions of Windows SUBST also provided some drive mapping options that are now covered by NET USE.
If the network resource is unavailable (ie the server is down) SUBST will continually retry – unlike NET USE which will try to connect once and fail – a subst’d drive that is not available will badly impact performance of the computer.
When SUBST is used against a local shared folder, it will create a RECYCLER for that drive. The RECYCLER is not removed when the drive substitution is removed, but can be deleted manually.
If you map a drive with the NET command, use the NET command to remove it, similarly if you substitute a drive letter with SUBST then use the SUBST command to remove it.
Undocumented behaviour: if a drive is substed using characters other than A-Z ($,#, :, !, 0-9) it will not appear in Windows Explorer or in the drives reported by SUBST.