Since version 3.2, Microsoft included the file RAMDRIVE.SYS in MS-DOS (released in 1986)
Did you ever wonder why Microsoft invested effort and resources into providing a tool for creating RAM drives during a time when memory was a pricey commodity? Back in the mid-80s, your typical personal computer boasted a mere 1 or 2 MBs of system memory. Perhaps Microsoft felt compelled to compete with IBM’s PC DOS (version 3.0, released in 1984), which included RAM drive capabilities via VDISK.SYS. While it’s uncertain if this was the sole motive behind Microsoft’s addition of this feature to MS-DOS, it’s certainly something worth exploring. After all, it gives us an intriguing avenue for experimentation.
Setting up a RAM drive in MS-DOS is fairly easy. We just need to add a reference to our CONFIG.SYS file like so:
DEVICE=C:\DOS\HIMEM.SYS /TESTMEM:OFF
DEVICE=C:\DOS\RAMDRIVE.SYS 25600 512 1024 /E
…
The commands above will create a 25 MB RAM drive configured with a sector size of 512 KB and a maximum of 1024 root entries. By specifying the /E
parameter, the space required for the RAM drive is allocated in extended memory. However, to utilize extended memory, it is essential to place HIMEM.SYS before RAMDRIVE.SYS. The RAM drive is assigned to the next free drive letter and allows you to access it from the command prompt:
With a few more tools and configuration lines in CONFIG.SYS and AUTOEXEC.BAT, you can boot MS-DOS and Windows 3.1 from the RAM drive. But be aware that memory is volatile – meaning: You will lose all data when restarting or powering down your system.
Here is a YouTube video where you will be able to see a lot more: