Choose the Drive Letter?

31 views
Skip to first unread message

Brian Collins

unread,
Nov 17, 2024, 5:10:17 PM11/17/24
to mTCP
Hello,

I'd love to be able to tell NETDRIVE.SYS what drive letter to use, or at least what drive letter to start from, as I have lots of code that references my P: drive (P for projects), so I can use the same consistent drive letter across all my DOS machines and the code that runs on them can be hard-coded for P:

Is there a flag for this on NETDRIVE.SYS? I only see -d option for setting number of drives.

Michael Brutman

unread,
Nov 17, 2024, 6:51:24 PM11/17/24
to mTCP
(Reply all this time for posterity ...)

It's not possible to reserve a drive letter.  NetDrive gets loaded while DOS is booting, and it gets assigned a starting drive letter depending on what the BIOS finds and the other device drivers in the CONFIG.SYS file.  It literally has no ability/control to ask or change its assigned letter.

(Programs that do that are always TSR utilities that load after DOS, and they have to alter the DOS internal data structures to do so.  Which makes them incompatible across the different versions of DOS unless they detect the version in use and run special case code for each version.  Which makes for a much larger and complicated program.)

Tim Sedlmeyer

unread,
Nov 17, 2024, 8:34:13 PM11/17/24
to mTCP
You can use the "subst" command as a work around. "subst" maps a drive letter to a directory path. For example if netdrive mounts as D:, the command "subst p: d:\" will allow you to access your netdrive as P:. You can remove the mapping using "subst p: /d". I did a quick test to verify that netdrive and subst do work together ok. 

Brian Collins

unread,
Nov 17, 2024, 8:39:08 PM11/17/24
to Tim Sedlmeyer, mTCP
Thanks Tim, I actually replied earlier that I'd just use subst, but I replied directly to Michael so it didn't get cc'd to the group. It does indeed work well, thanks.

--
You received this message because you are subscribed to a topic in the Google Groups "mTCP" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/mtcp/y5VM0wL1ci4/unsubscribe.
To unsubscribe from this group and all its topics, send an email to mtcp+uns...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/mtcp/9cbc2782-5954-4f10-b189-3569e739800en%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages