Page 1 of 1

Strange DOS 6.22 Issue

Posted: Mon Feb 10, 2014 5:59 pm
by Rodimus80
When I create a directory called "C:\DRIVERS\CDROM", I am unable to access it. Shoots me an error "invalid directory" Any folder called "CDROM" shoots back that error. I'm stumped.

Posted: Mon Feb 10, 2014 8:27 pm
by dosraider
Choose another dir name.....

falls under "yep shit happens"

Posted: Mon Feb 10, 2014 10:06 pm
by Rodimus80
It's very weird. I'm blaming it on the CPU. I have other DOS machines and I have never seen this.

Posted: Mon Feb 10, 2014 10:38 pm
by dosraider
Sure there isn't a /drivers/cdrom/ installed by some external prog?
Flagged read only-sys-hidden?

Whatever, if you ever find out why let us know. :laugh:

Posted: Mon Feb 10, 2014 10:42 pm
by Rodimus80
I don't see how. My process of building a DOS 6.22 PC is "format c: /s" Then I make 4 directories. MOUSE, CDROM, SBBASIC, and CTCM. Copy over drivers from a self-made Driver CD. Nothing is different this time. Not too mention that on the Driver CD is a folder called CDROM too and it gives me the same error. I've used a IDE HDD with a 500MB partition and a CF Card 256MB. Both have the same problem and both were in different machines at one time. Frustratingly odd.

Posted: Mon Feb 10, 2014 10:47 pm
by dosraider
Weird? Yes.
Strange? Yes.

And yet I won't let my sleep for it.

As said before: shit happens.

Catched an old dos virus?

Posted: Mon Feb 10, 2014 10:48 pm
by Rodimus80
Caught an old virus? lol Wouldn't that be something.

Posted: Mon Feb 10, 2014 11:32 pm
by Rodimus80
I wasn't able to resolve this but I think I have narrowed it down. It seems when the CDROM driver is loaded in config.sys, it makes all folders named CDROM unreadable. Very weird.

Posted: Tue Feb 11, 2014 12:42 am
by Quadko
:) Makes sense, actually. DOS checks device names before directory names, and both devices and directories use the same "file" access APIs. Reading/writing data from a device is the same as from a file, since the disk is really just another device...

Ergo, if your cdrom device driver is loaded, it will mask any directory of that same name. There are a few other similar names that are blocked for that reason, not 100% sure what they are, but things like CON and PRN.

I'm not certain, but it's possible you can rename the actual CD device driver in-memory name as a commandline arg to the config sys or autoexec driver. If you really want a "cdrom" directory, it might be worth a try or some research. Then name it cdrom1 or banana or asdfqwer, and *that* name will be blocked instead. As I recall, you specify that in the driver and in the mscdex commandlines, but it's been a loooong time, so ymmv.

I think I recall a generic cdrom driver boot disk that tried to load a bunch of common drivers and named them all banana; that covered access for like 80% of the drives out there but it took me too long to figure the banana thing out - just a silly unlikely name.

Actually, I think the problem still exists in Windows. I was getting a weird bug testing some software, and we tracked it down to this bizarre and obscure (but documented) behavior; that's how I know about it. That's what I get for trying to name the print-to-file output directory PRN. :rolleyes: During our research, we found out it went back to Dos 1.0, and may be true in CP/M and Unix as well.

Hope that helps, sorry for the tl;dr history lesson. :D

Posted: Tue Feb 11, 2014 5:27 am
by dosraider
Makes sense Quadko.

For those interested:
CDRom drivers need config.sys and autoexec.bat comm lines.

Basic CD driver +'device name' config.sys:
example:
DEVICEHIGH=C:\DOS\cdrom.sys /D:name001
/d: defines driver name

Must match with autoexec.bat mscdex
LH C:\DOS\MSCDEX.EXE /D:name001 /l:D
/d: must match config.sys name.
If more than one CD drive should be : name001 - name002 - etcetera....
/l: drive letter

Pour moi, never had a CD driver who was named as 'CDROM', still a weird idea, 'bananas' on the other hand, plenty of them........
Also lots of 'MSCD001' -002-003 ........, when used in multi CD-DVD drive systems, keeps things a bit sorted out.

Rodimus80, if you wanna keep that 'cdrom' device name simply add a number, something as 'cdrom01' ... whatever suits you.

Posted: Tue Feb 11, 2014 8:04 pm
by Quadko
Thanks, dosraider! I'm glad you've got the details, that should help a lot.

And it brings back memories. "mscd001" - I sure remember that in particular. And Oak cdrom drivers. :)