[Webinar] Streamline your web hosting managementRegister Today

x
?
Solved

RAM Drive on Win98???

Posted on 2000-01-14
10
Medium Priority
?
1,107 Views
Last Modified: 2013-12-28
I had used a RAM drive quite some time ago (Win 3.1) and have recently come to a situation where I would like to use one again.

Can you do this in Win98? How?

I saw a note in the Win95 forum where the answer was supposedly yes for Win95 and that you needed to create an entry in the config.sys of (for example):

device=C:\windows\randrive.sys 8192 512 256

This is roughly what I remember from Win 3.1, but when I tried it on Win98 I didn't get a drive, so the question is "Can it be done and how?".  If so, what are the parameters needed and allowed?
0
Comment
Question by:Gene Klamerus
  • 5
  • 4
10 Comments
 
LVL 25

Expert Comment

by:dew_associates
ID: 2354485
Here ya go klamerus!

In your config.sys file

device=himem.sys
files=10 (whatever setting you choose)
buffers=10 (whatever setting you choose)
dos=high,umb
stacks=9,256
devicehigh=ramdrive.sys /E 2048

You'll find the current version of Ramdrive.sys on your Windows 98 Boot Disk.

Dennis


0
 
LVL 6

Expert Comment

by:1cell
ID: 2354499
here's a program that will do it for you, let you assign the drive letter and how much RAM to use

http://thetechzone.com/downloads/ram_drive.zip

over course, you'll need winzip
www.winzip.com
0
 
LVL 1

Author Comment

by:Gene Klamerus
ID: 2354790
Well, that's half the answer (or perhaps more), but it raises some more questions.

1 - I don't have a config.sys.  I can create one, but since I don't have one, my thought would be that nothing is going to read it.

2 - What good will the other items in your config.sys do on my Win98 (which doesn't have DOS, I'm think).  For instance, files=10 refers to allowed open filehandles, etc.  Do I need to have all these for the ramdrive to work, or is this simply your config.sys which happens to have them?

3 (and last) - what are the allowed parameters for ramdrive.sys now?  I would expect /E = extended memory like before and /A = expanded memory.  What about the arguments for # of allowed files in RAM drive root directory, etc?

If you can answer these, I'll even boost the points
0
Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

 
LVL 25

Accepted Solution

by:
dew_associates earned 400 total points
ID: 2354853
Klamerus, I can answer your questions, which I have done below, but really using a ramdrive within the Win98 user interface somewhat defeats the way Win98 runs normally. Actually you would be causing a massive drain on Windows resources for very little, if any, benefit.

First, ramdrive doesn't support long files names, as it is a MS-DOS utility, not a 16bit or 32bit Windows utility.

Second, by incorporating ramdrive, you are blocking physical memory that Windows would rely upon and would then run into out of memory errors. Win 3.X ran fine this was as it was predominantly MS-DOS based, Win9X is entirely different.

Ramdrive, like I mentioned above, is a DOS utility, which is why I mentioned the config.sys file, as this is normally where it is called (or invoked). You can still call it from your config.sys, however I suppose I could show you how to call it from either your registry or an INI file as long as you thoroughly understand that doing so could result in a Win98 crash.

The file handle issue, again, goes back to the fact that Ramdrive.sys is a dos utility, which is why I included it. Are they needed in Windows, no, but in DOS they are, as are the stacks and buffer calls and loading dos high.

The /E and /A parameters date back to DOS versions 5.0 and earlier when Ramdrive was a convenient way to speed up taskswapping, which isn't necessary in Win9X. Windows 95 relies on, in part, MS-DOS 7.X and I believe that Win98 is at 8.X. Neither of these are required.

Unlike any version of Win9X, Windows 3.X could use Ramdrive.sys, but it also relied upon an ini statement of swapdisk= in order to swap files between extended memory and workspace memory. This is not supported in any Win9X versions.

The maximum value for RAMDRIVE.SYS is 32 MB minus 1K, which comes out to 32,767 kilobytes. However, when HIMEM.SYS is being used as an XMS provider, RAMDRIVE.SYS can be no
larger than 16 MB. This is due to a limitation in HIMEM.SYS. This leads to my earlier comment as to why would you want to do this as Win9X has virtually no such limits.

The values for files, or "NumEntries" is a minimum of 2, a maximum of 1024 and a default of 64.

Here's an article you may find interesting:
-----------------------------
PSS ID Number: Q142546
Article last modified on 05-18-1999
95
WINDOWS
======================================================================
The information in this article applies to: - Microsoft Windows 95
-------------------------------------------------------------------------------
SUMMARY
=======
Windows 95 uses memory differently than earlier versions of Windows. If you
encounter unusual random problems in Windows 95 that you did not experience in
an earlier version of Windows, your computer may have faulty memory. This
article describes how to use a RAM drive to test the memory in your computer and
what to do if this does not solve the problems you are experiencing.
 
MORE INFORMATION
================
Microsoft RAMDrive is a memory-resident program that lets you use part of your
computer's RAM as if it were a disk drive. By creating a RAM drive that uses
most of your computer's physical RAM, you may be able to isolate the memory
problem to a particular memory chip. To create a RAM drive using Windows 95,
perform the following steps:
 
1. Restart your computer. When you see the "Starting Windows 95" message, press
   the F8 key, and then choose Command Prompt Only from the Startup menu.
 
2. Use any text editor, such as Edit.com, to add the following line to the
   Config.sys file
 
   device=<path>\ramdrive.sys <x> /E
 
   where <path> specifies the location for Ramdrive.sys and <x> is
   equal to the total amount of RAM (converted from megabytes to kilobytes)
   minus 4096 (4 megabytes are required for Windows 95 to start). For example,
   if you installed Windows 95 on drive C in a folder called Windows and your
   computer has 16 megabytes (MB) of RAM, add the following line:
 
   device=c:\windows\ramdrive.sys 12288 /E
 
   The value 12288 is derived from the following formula using the example
   above:
 
   (16 * 1024) - 4096 = 12288 bytes
 
   NOTE: The Ramdrive.sys line must follow the Himem.sys line, or the RAM drive
   may not function.
 
   NOTE: Windows 95 is limited to a 16-MB RAM drive. For additional information,
   please see the following article in the Microsoft Knowledge Base:
 
   Q126448 Err Msg: Not Enough Extended Memory Available to Start...
 
3. Save the Config.sys file and then restart your computer normally.
 
4. If the problems no longer occur, halve the value for <x> in the
   Config.sys file and restart your computer. Repeat these steps until the
   problem returns. Once it returns, the faulty RAM is in the area that you most
   recently removed from the RAM drive. Contact your hardware manufacturer about
   replacing this memory.
 
5. If the problems persist, there may be a problem in the memory above the high
   memory area (HMA) that Ramdrive.sys is not using. To test the memory above
   the HMA (starting at 1088K), remove Ramdrive.sys from the Config.sys file and
   add the following line to the Config.sys file
 
   device=<path>\himem.sys /int15=<x>
 
   where <path> specifies the location for Himem.sys and <x> is equal
   to the total amount of RAM you want to exclude from Windows 95's use. For
   example, the line "device=c:\windows\himem.sys /int15=4096" prevents Windows
   95 from using the section of memory from 1088K to 5184K (or roughly the first
   4 MB of RAM above conventional memory + the UMA + the HMA). If the problems
   no longer occur, this memory needs to be replaced.
 
If you continue to have problems, one of the following situations may exist:
 
 - The problems may be caused by memory within the 1088K of RAM that the
   RAMdrive and HIMEM statements cannot reserve for Windows 95. To test this,
   try new memory modules or switch the order of the RAM modules in your
   computer. If you are unfamiliar with this process, Microsoft recommends that
   you contact your hardware manufacturer for assistance.
 
 - The problems may be caused by CPU cache RAM. Many new processors implement a
   method of optimization that uses motherboard and internal CPU cache RAM to
   increase performance and optimize data and code execution. This cache is used
   to offset the number of direct reads that are performed against main memory
   for frequently used data and code.
 
   To test this, disable the internal and external CPU cache. For information on
   how to do this, please read your hardware documentation or contact your
   hardware manufacturer.
 




0
 
LVL 1

Author Comment

by:Gene Klamerus
ID: 2356442
Well that's enough information.

I've experimented a bit with this and may just have to toss in the towel.  Although the various notes I've read indicate that you "should" be able to create a drive of up to ~32 MB, as soon as I go past ~5,000 MB Win98 fails to fully come up, so apparently, RAM drives are not only poorly supported, they're now pretty much broken.  I have 288 MB of RAM in my laptop, and I would like to "donate" 20-30 MB of it to working storage when I'm in Win98.  When I'm booted into NT I need all I can get for DBs, etc., so I wouldn't use it there.  I will be checking out the pointer from 1cell however.

There are good reasons to use RAM Drives, despite the fact that the the O/S caches.  For one thing, they make a very good workarea.  For instance, if you have a MSVC project with 20-30 files (sources, includes, etc.) and are in a mode where you need to recompile frequently, RAM drives are very handy, especially if you use the same drive for your TEMP directories.  When I go through re-compiles in such a scenario, my speeds are a fraction of what they are when the files are on a hard drive.

Another reason is drives on laptops are notoriously slow.  In fact, at one point, we found it was actually faster to use DriveSpace because it was faster to read less bytes from the drive and do the decompression, than it was to read uncompressed data.  This was a while ago.

I might play with a RAM drive as a service, or in one of the *.INI files. I'll have to experiment to see if that helps with the lock-ups during startup.  The timing or when the drive is created may be the issue.

Anyway, this has been an interesting weekend experiment, but nothing I really need, it was just an idea.
0
 
LVL 25

Expert Comment

by:dew_associates
ID: 2356455
You may want to try and push it as high in the upper memory area as possible and stay away from the first 64Mb of memory and see what happens.
0
 
LVL 1

Author Comment

by:Gene Klamerus
ID: 2378134
The program XMKDSK.EXE mentioned above works great!

It creates drives very fast, can create huge drives (I'm using 50 MB, but I tried 100 MB just for grins), I can specify the drive letter and it will create from the top of memory if desired.

As to the value of using a RAM Drive, a relatively new book from Oreilly has come out on optimizing Windows that describes some of the reasons for having a RAM Drive.  The books actual name claims its for optimizing Windows for games, graphics, & multimedia, but it really doesn't hit those areas specifically at all.  It's very good and covers most of the tricks I know, but a few I didn't know of.
0
 
LVL 25

Expert Comment

by:dew_associates
ID: 2378156
Thanks for the info, its appreciated!
0
 
LVL 1

Author Comment

by:Gene Klamerus
ID: 2378397
That was a typo:

The program is XMSDSK.EXE - it's a bit hard to get, but worth having.
0
 
LVL 25

Expert Comment

by:dew_associates
ID: 2378410
Thanks!
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Each password manager has its own problems in dealing with certain websites and their login methods. In Part 1, I review the Top 5 Password Managers that I've found to be the best. In Part 2 we'll look at which ones co-exist together and why it'…
In a question here at Experts Exchange, a member was looking for "a little app that would allow sound to be turned OFF and ON by simply clicking on an icon in the system tray". This article shows how to achieve that, as well as providing the same OF…
This Micro Tutorial will give you a basic overview of Windows DVD Burner through its features and interface. This will be demonstrated using Windows 7 operating system.
The viewer will learn how to successfully create a multiboot device using the SARDU utility on Windows 7. Start the SARDU utility: Change the image directory to wherever you store your ISOs, this will prevent you from having 2 copies of an ISO wit…

640 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question