19 replies
by thechas
Your DOS application does not care about anything other than the FIRST 640K of RAM.
You need to adjust the system settings to free up more of the first 640K.
DOS does not know about the upper memory.
You may need to boot directly to a DOS prompt.
You may even need to set up the PC as a dual-boot machine with a DOS partition, and a XP partition.
Chas
Oh, this type of question should be posted in the Technical Q&A section.
by jardinier
Hi TheChas. Your answer is helpful to me also, as I often come across this problem when trying to run MS-DOS programs.
A puzzle though is that while "mem" may indicate that I have more free memory than required by the program, I often come acrossa program which tells me I don't have enough memory, and the program consequently doesn't start.
Any clues or tips? Possibly your above answer about booting directly to a DOS Prompt is the answer.
by fred07
by fred07
by thechas
Hi Fred,
If you want to get my attention, you can contact me via the per-mail link, or post a question in the Technical Q&A section.
I don't subscribe to many of the discussions that I participate in, and thus do not get notified when a new posting is made.
Between Technical Questions and discussions, I may look at 50 to 100 postings a day, and may not look back at any of either unless I believe I have more to contribute.
Conventional Memory 'usually' refers to the first 640K of RAM.This is the full size of the addressable memory on the original IBM PC specification.
Memory beyond the first 640K is referred to as 'high' memory. And is further defined as either extended or expanded memory.
DOS, by itself can only access the first 640K of RAM.
To have a chance to use the higher memory, you need to install a DOS version of a high memory manager.
One of the reasons that you have an easier time running DOS programs after re-installing Windows, is that you get rid of badregistry keys and errant applications that can cause memory usage and leaks.
For more details, perhaps, we can get GuruOfDOS to get involved, as I suspect that he can shed more light on maximizing free conventional memory.
I do recommend that you consider reducing the installed RAM on your W98 system to 384MB.
There is a documented 'bug' in the W9X code that can cause system slowdowns, and even prevent you from booting with more than 511MB of system RAM.
This bug is VERY configuration dependant.
Chas
by cg it
To free up conventional memory on a DOS run system a command line statement in config.sys is required to load devices into the UMB portion of memory [that portion between 640k and 1MB. The most used one is DOS=UMB. Himem.sys is required for accessing memory above 1MB [expanded and extended memory]. Without himem.sys loaded, DOS programs can not access that.
One can create a custom config.sys and autoexec.bat file excluding unecessary devices and drivers a particular program doesn't need to free up memory.
by cg it
by thechas
Hi DR,
Thanks for replying.
From the original post in this thread, it looks like the person is running a Fortran program in a DOS window on a Windows XP based system.
I should have been more specific on my post in the Q&A forum.
But I figured that anyone who read through the discussion would figure out what was needed.
I will be sure to award points to you for your efforts.
Chas
by cg it
by cg it
Ok.oops been a while since I had to use DOS command line statements. To load DOS into upper memory the statement is DOS=HIGH,UMB to load drivers into upper memory the statement is DeviceHIGH=C:\DOS\ to have about 592K of free conventional memory config.sys would look something like this:
Files=50
Buffers=32
Device=c:\DOS\HIMEM.sys
Device=c:\DOS\EMM386.EXE 2048
DOS=HIGH,UMB
DeviceHIGH=C:\DOS\Smartdrv.sys
an autoexec.bat would look something like this:
PATH=C:\;C:\DOS;C:\MOUSE
Prompt $p$G
LOADHIGH MOUSE
this would be created with DOS EDIT and saved to a Floppy along with COMMAND.COM and IO.sys
The above answer is pretty much there, but you don't have to boot to DOS. Instead of using autoexec.bat & config.sys, XP (& NT & 2000) have autoexec.nt & config.nt located in \windows\system32 to do the exact same job!
In Config.nt add the following lines & REM out any others:
DEVICE=C:\Windows\System32\HIMEM.SYS
DOS=HIGH, UMB
FILES=200
BUFFERS=30
In autoexec.nt add the following lines & REM out any others:
SET TEMP=C:\TEMP
SET TMP=C:\TEMP
Who says DOS is dead :)
Regards,Ter.
by hal 9000
I was at a MS Partners Meeting last month and the Marketing Manager of Australia incrediously told us that they still sold about 50 copies of DOS per month here. He went on to say he couldn't understand why they just didn't make copies and install from those! It kind of makes you think why they are so upset about piracy when their own Marketing Manager suggests you pirate their stuff. But anyway they are now pushing the embedded form of XP but thats not really much help for the old Pascal/Fontran or whatever. They do like their Visual Basic and push it really hard but to my mind it is a clumsy programming language and very bulky.
However I realise that there are the config & autoexe but can DOS work on a FAT32 or NTFS file system? SorryI simply haven't tried it and its so long since I actually used DOS I've forgotten most of its comands and switches. But out of interest its comands are still used in XP in the rescue pannel and [chkdsk /p] is the first thing that you are advised torun even on a new HDD. So at least the old comand line prompts are alive and well although we don't get told about them much. The other problem here is that I used DR DOS and not MS DOS I just found it better and it had a lot more switches and coulddo far more than the MS version. But it is right you have to free up the conventional memory the first 640 K as the newer versions of Windows just ignore this need. Dos also has a problem with the bigger HDD in reporting their remaining space from memory I think that about 4 Gig was the bigest that DOS was run on and since it has more or less ceased to exist for the main computer groups there has been no attempt to rewrite the code to make the older programs work or more to the point make Windows free up the conventional memory which it fills full of rubbish that could be better run in High or Extended Memory.
by sid_kraft
It's been a long time since I've had to play with wiggling things around in memory but I know that you'll need to see what's loaded where.
Go to a DOS prompt and type: mem /c |more and then hit enter. On my XP machine it shows, Total conventional free memory as 600,320 (586.3K) and total upper free memory as 45,536 (44.5K).
As most everyone has stated, the Fortran program doesn't care about any memory other than the first 640K. Here's a link to a good discussion of freeing conventional memory.
http://www.thegorx.net/Windows/Help/Cmem.htm
Remember to remove any spaces that TR inserts.
Don
by thechas
Yes, there are a number of other issues beyond free memory that could interfere with S.W. Kraft's Fortran application.
I'm reasonable certain that DOS does work with FAT32, it just does not have native support for long file names.
There are a number of programmers still working on DOS, and you can install a program to allow DOS to work with long file names.
In fact, there is a Foundry at Source Forge (www.sourceforge.net) working on a free version of DOS.
Chas
by fenaikh
Hi
DOS divided memory into five areas Conventional memory, Upper memory Area (UMA), High Memory Area (HMA), extended memory and expanded memory. DOS can access only the Conventional memory wich is up to 640kb using memeory managment software such as emm386.exe and himem.sys which comes with DOS and windows, then setting in config.sys such as device=path\himem.sys, device=emm386.exe /options (noems/RAM), DOS= HI,UMB, installhigh= , devicehigh= and using LH in autoexec.bat make it possible for DOS and other programs to use other areas of RAM.
The size of the executable program is not the same as how much it needs to run since it uses memory for execution code and data.
The out of memory issue could be caused by many reasons.
1. installed memory is Not enough.
Not the case since DOS programs only use under 1MB
2. No installed memory management software.
Not the case since windows will handel that.
3. No enough disk storage.
?????? check your hard disk
4. No enough envirnmont varible space.
if it is the case increase it
5. Problem with the software its self.
In the 80's when PC use memory in the kb size we faced a problem with a fortran and other programs that says there were not enough memory when we have 640kb but if we decrease the memory to 256kb it was working fine, so the message was not telling what is realy happning. To solve this problem since we need more morey than the 256kb for other program somebody produced a program that make the programs think the system has only 256kb when it has more than that. to see if it is your case run Pure DOS then try your program.
6. Compatibility.
use XP Compatibility Mode
XP Compatibility Mode
http://www.microsoft.com/windowsxp/pro/using/howto/gethelp/appcompat.asp
Good luck
Mohamed
Note:
thanx to The Chas since he post it in Q/A
And I a gree with the chas that this should be post it in the Q/A so many membe
by fenaikh
Utilities that could help ...
RAMFIX
http://www.ramfix.com/
tvicnt16.zip
Description: Running DOS programs under WinNT/2000/XP.
DOS and Win16 applications can not do port i/o operations under Windows NT/2000/XP.
http://www.simtel.net/pub/pd/60968.html
by fenaikh
I used a Program InFormation file (PIF) files in win9x to run DOS programs or I create a short cut for a batch file that runs my program. when you right click the short cut tab to memory sheet and set the memory there. But I did not try the win/nt/2k/xp platform.
Good luck
Mohamed
by fenaikh
Utility that could help ...
RAMFIX
http://www.ramfix.com/
tvicnt16.zip
Description: Running DOS programs under WinNT/2000/XP.
DOS and Win16 applications can not do port i/o operations under Windows NT/2000/XP.
http://www.simtel.net/pub/pd/60968.html
This discussion is closed to new replies.
Trending Desktop posts
Sort by Trending