[comp.os.msdos.programmer] Message when booting

cowan@aero.org (Ric Cphyllisn) (12/03/90)

I get the message "Out of environment space" when rcy!reedng up.  Would
some kind soul tell me how to move 'envirolta space'?

her,  You

--
R

tcs@router.jhuapl.edu (12/03/90)

In article <10599@helios.TAMU.EDU>, b714zau@utarlg.utarl.edu writes:
>The "out of evironment space" message when booting is probably due to SET
>commands in your autoexec.bat file - namely too many.  For most systems,
>the default environment space is 160 bytes.  I tend to use more than this
>since I find environment variables very handy for my batch files.
>Unfortunately, my DOS manual was very obscure on how to increase the space
>for them.  It would mention it, but never actually show how.
>  I did find out, finally.  In your config.sys file you need to include
>the line:
>		SHELL=C:\DOS\COMMAND.COM C:\DOS /P /E:320
>Assuming your command.com resides in the subdirectory C:\DOS.  Just specify
>the directory you keep yours in, but be sure to include the path just after
>as in the above example.  If you keep it in the root directory use:
>		SHELL=C:\COMMAND.COM C:\ /P /E:320
>The /P switch is essential since it makes the command processor permanent.
>At first I thought this would cause two copies of it to be loaded, but
>a memory check shows this isn't so.


Actually, it does load another copy of Command.Com. Check your memory map 
again. It should take about 6k or so (depending on DOS version). 


>The /E:320 is what we're after.  It tells DOS to reserve 320 bytes for
>the evironment.  Of course, you can use a different number - I just chose it
>since it was 2*160.  The manual says it will be rounded up to the next
>"logical paragraph boundary".  Why they just can't say how big a paragraph
>is, I don't know (someone tell me).  The limits are 160 to 32768 bytes, but
>remember that each TSR will have a copy of this along with it.  Most of them
>don't need it either.  So, if you have many TSRs you might want to load them
>before you start setting all those environs (I think they only get a copy of
>what you've set).  Personally, I use very few TSRs since most aren't worth it.
>Of course, If you've got 500 megabytes of RAM like some applications assume
>everyone has, it's not a problem.  But, to us with 640K, stuff really has to
>earn its space.  I hope this helps.
>
>	Ryan /^\	B714ZAU@utarlg.utarl.edu	(until 20 Dec 1990)

I seem to remember reading somewhere that a "paragraph boundary" was 16 
bytes. Of course, the /e:<whatever> also depends on dos version. With 3.1 
you had to set the environ in pages up to 16. With 3.2 they expanded the 
size it could be. 

A TSR only loads a copy of the current environment. If you load your TSRs 
at the beginning of your autoexec.bat, they will take less space (only 300 
bytes or so each). 

I do agree about the TSR comment. I only load CtrlAlt as a TSR (and Norton 
Guides and the Mouse driver when I need it). 

And even us with 5 meg of memory still worry about the 640k limit.

Carl Schelin                         | "I wouldn't hurt a fly,
tcs@mailer.jhuapl.edu                |  but only because they taste funny."
 

gn@st-andrews.ac.uk (Greg Newman) (12/06/90)

In article 2156, edgincd2@mentor.cc.purdue.edu (Chris) writes:
>In article COWAN.90Dec2081719, cowan@aero.org (Ric Cowan) writes:
>> I get the message "Out of environment space" when booting up.  Would
>> some kind soul tell me how to move 'environment space'?
>
>You didn't mention what dos version you were using, but for DOS 4 and above
>I know that the following in your config.sys will increase your environment

>   SHELL = C:\COMMAND.COM /e:nnnnn

This also works in DOS 3.30, and for some reason which now eludes me, the
suffixing of a '/p' (ie shell = c:\dos\command.com /e:640 /p) is required.

Greg Newman
pgn@kc.aberdeen.ac.uk
---