PDA

View Full Version : Win 95B won't accept any autoexec.bat!



Robin S_
17-08-2003, 12:08 AM
Let's see if someone can crack this one.
I have 'revived' a DX4-100 (16MB RAM) which used to happily run Win 95 or 95A. I replaced the drive in it with a 540MB one which had been working flawlessly in another computer. I reformatted the drive and installed Win95B (OEM version). The system now freezes at an early stage of loading Windows if there is an autoexec.bat file present. If I delete a/e.bat Windows loads normally. The config.sys file is minimal and unremarkable. The autoexec.bat is essentially or exactly the same as the one that was used previously with Win95; it comprises only 3 lines (loading share.exe and mouse.com and running the date command) but even with all 3 remmed out (ie no functioning commands) Windows still locks up. If I select the 'Command prompt only' option during Windows bootup it executes the unremmed a/e.bat and boots to the command prompt without problems. If I select the 'Step by Step' boot option and bypass only the a/e.bat step it boots to Windows perfectly. I installed a copy of the same version of 95B, together with the same autoexec.bat and config.sys, on another DX4-100 with a different HDD and it runs OK.
I have reformatted and reinstalled Win95B several times but exactly the same thing happens every time. Win bootup chokes even if the a/e.bat file is completely empty ie 0 bytes. It will only start if no a/e.bat is present.
Other info which should be irrelevant - the drive is partitioned into a DOS primary (C:, 200MB)and a DOS extended (D:) partion; the extended partition is compressed with Drivespace and Windows (and little else) is installed on C:.
The problem is apparently some sort of conflict between this version of Win95B and the presence of even an empty a/e.bat yet the same Windows setup runs happily on a very similar computer.
One possibility that has occurred to me is that it might be due to a memory conflict. I presume that a/e.bat is loaded into memory before executing and if there is a conflict there (eg a flushing problem) then that could produce this effect.

Can anyone explain or solve this?

Chilling_Silently
18-08-2003, 01:17 PM
IIRC, when in DOS if you type:
win
it will load up doze, what happens if you make an Autoexec.bat file that only contains that, will it still boot?

If it does, try adding a command to make a folder on your c:\ drive and then to "win" after that on the next line.

Get back with the results :-)

Cheers


Chill.

Terry Porritt
18-08-2003, 01:25 PM
Very odd, but in actual fact you dont need and shouldnt have share.exe, or mouse.com in autoexec.bat. These are hangovers from an earlier win3 period. Share.exe function is incorporated into Vmm32.exe, and Windows will load its own mouse driver. There could be conflicts.

If you really need an autoexec.bat in Windows 9x then it is much better to to have a multi configuration menu for starting up so that you either start DOS or start Windows and the config.sys and autoexec.bat files load those bits specifically for either DOS or Windows.

Havent actually come across Windows not liking the presence of an autoexec.bat before.
Could possibly be a faulty IO.sys, but the work around at the moment is just to do away with the autoexec file

Graham L
18-08-2003, 05:59 PM
It's an interesting one.

Batch files aren't actually read into memory as such ... one line at a time is read into a buffer and executed immediately.

But as Terry says, like the old medical joke: If it hurts when you do "that", don't do that. :D

Robin S_
19-08-2003, 02:54 PM
Thanks for the replies, people.
Chill, one of the many things I have tried is setting BootGui=0 in Msdos.sys with a view to doing as you suggested, because the a/e.bat file is accepted and processed correctly if booting to the DOS prompt via F8. BootGui=0 is supposed to direct the system to boot to DOS instead of Windows, but for some reason that system didn't work - IIRC it still tried to boot to Win. I might revisit that avenue sometime.
I am aware that it is not necessary to have an a/E.bat for W95 but I want to be able to run one for several reasons.
(a) This cptr has a BIOS written by a klutz committee who only allowed the decade digit range of 94 - 99. The decimals of 0 - 93 aren't accepted by the BIOS even though the designers at least allowed 20 as century digits. As a result, when the cptr starts up it always sets the year as 2094. When it was running a pre-B version of Windows this was easily corrected for each session by including the Date command in a/e.bat and that worked OK. This cannot now be done.
(b) I wanted to include mouse.com in a/e.bat so that the mouse function is available in DOS sessions.
(c) I had included the share.exe line (even though I had remmed it out) because I have read that some DOS-based programmes need to find it before they will run; it could simply be un-remmed if it was ever needed.
(d) Some programmes, during installation, add a line to a/e.bat (creating one if necessary). Such an installation in the present situation would cause Win to freeze during any subsequent startup attempts.
(e) It may become necessary sometime to add something to the default Path command. In any case, I find it handy to include Pkzip so that Pkunzip can be run from anywhere.

I currently have a workaround but it is a bit clumsy and I have not checked it out properly to see how effective it is. I have created a file called start.bat (containing the mouse, pkzip and date lines) and run it from the Startup menu. However, I wish to pass the cptr on to someone who would probably not understand the limitations and may well end up having Windows crash problems. It would be nice to get back to the simple way it used to be.
I was hoping that someone would know how to fix this problem or that it is definitely caused by Win 95B. Digging up some discs for an earlier version of Win and installing that may be a solution but would involve some time and effort possibly without gain.

Any more offers? TIA.

Terry Porritt
19-08-2003, 06:19 PM
Very strange indeed.
One, perhaps unrelated thing, in msdos.sys, bootmulti=0 instead of bootmulti=1, should be set, as any attempt to boot to a previous dos (eg. dos6.22) will cause windows to hang if there isnt a previous dos version there.
This was a bug of Win95B OEM CDs.

I suppose with a 540MB HDD you will be using FAT16.

Robin S_
20-08-2003, 01:01 AM
Thanks Terry.
BootMulti is still set to the default 0 as there was no previous OS to boot to. What was the actual Win95B bug that you referred to - that it would just hang instead of giving an error message or something if B/M was set to 1 and there was no previous OS?
Yes, I am using FAT 16.

Robin

parry
20-08-2003, 01:29 AM
Have you looked at the Bootlog.txt file to see if anything strange is happening? I would try step by step confirmation boot to check each line as well and see what happens when it gets to autoexec.bat.

You could also try starting win with the /wx switch and this restores config.sys and autoexec.bat files from config.wos and autoexec.wos files respectively. Type Win /? to see a list of switches.

Terry Porritt
20-08-2003, 09:28 AM
Hello Robin, the unrelated bug I found when I installed win95B from an OEM CD was that the Start Menu (from F8 key) gave the option to boot to previous dos, even though there was no previous dos, especially with an OEM disk. The bootmulti as loaded in msdos.sys had the value 1 instead of 0.
Then if previous dos was chosen it threw a serious wobbly and hung.

Robin S_
21-08-2003, 05:38 PM
Here's some more grist for the mill.
Last night I revisited msdos.sys and set BootGUI=0 (with no a/e.bat present) which should have caused the system to boot to the DOS prompt. It got as far as the first bit of splash screen then the screen turned black and bootup hung. The change to the black screen I think coincided with the point where bootup switches to a DOS screen and displays the a/e.bat lines as they are executed if Echo isn't off.
Does this ring any bells?

Terry Porritt
21-08-2003, 07:11 PM
No bells are rung :( I wonder if it would be worthwhile re-installing the system files from a win95 boot disk, ie a:\>sys c: , so that there is a new IO.sys and msdos.sys, just in case there is something funny with them.

Graham L
22-08-2003, 03:02 PM
Yes. I can't think of any "proper" way the software should behave like this. So it must be improper. :D

Robin S_
23-08-2003, 10:55 PM
Thanks for the system files idea, Terry. That gives me a few other ideas too so I'll do some more trials as soon as I get a chance and report back.

Robin S_
28-08-2003, 01:02 AM
Je l'ai trouve! By chance! Terry, I tried redoing the system files as you suggested but to no avail (I thought it might work as it was possible I had originally run the sys command from a DOS 6.22 or 6.20 boot disc). But on my list of other things to try was suppressing the startup splash screen in case it was hiding any startup messages. And lo! with the logo off a/e.bat worked. I have now installed the a/e commands that I wanted (I decided to leave out share.exe) and everything goes. It doesn't explain why there was no problem with an earlier version of Win 95 and I might try the logo.sys file from an earlier version sometime. It would appear that there was a conflict somewhere in the BIOS/Win 95B or something combination as the problem did not occur when the same version of Win 95B was tried on 2 other computers.

Thanks to all who offered suggestions. Any thoughts now on how/why this came about?

Robin

mark.p
28-08-2003, 06:17 AM
IRQ or I/O address conflict maybe.

Terry Porritt
28-08-2003, 09:14 AM
Well, that is probably going to remain one the great mysteries of life, the universe and everything, Robin.

Logo.sys is just a bitmap file, it's a nuisance anyway as it obscures the text screen 'underneath' and you cant see what is happening.

IO.sys reads msdos.sys before reading config.sys and autoexec.bat, and msdos.sys determines the win start configuration. Difficult to know why msdos.sys was saying ignore the autoexec.bat.

It isnt an IRQ problem Mark, as at that stage of the boot, there are only the preset IRQs from the BIOS, and logo.sys is not a device anyway.

The answer must be 42 :)

Graham L
28-08-2003, 03:55 PM
Or, in an alternative numeric base, "MS".

mark.p
29-08-2003, 07:09 PM
Isn't it trying to load mouse.com?
69 is a great number........................;)

Terry Porritt
29-08-2003, 07:21 PM
Well, it would load mouse.com if only it accepted an autoexec.bat in the first place. I must say it is all very strange.
Generally it is not a good idea to load real mode drivers like mouse or cdrom that windows itself will try to load later in protected mode. That can certainly cause conflicts in some cases.

Robin S_
30-08-2003, 12:48 AM
Thanks Terry, I thought logo.sys was a bitmap file, but it's mighty big for a bitmap. It might have something to do with the animation of the bottom banner strip. Incidentally, I have read somewhere that that banner can be used as an indicator of the version of Win 95, according to the direction and speed in which the colour patches run. I also have a reference that states that some 3rd party memory managers conflict with the Windows startup logo. I don't have any but in my case I suspect the problem lies in the Win 95B version of the logo file or the way it is handled.

parry
30-08-2003, 01:25 PM
Just my 2 cents. Logo.sys has to be 320x400 bitmap image - not sure what happens if its not this size :-). I presume you havent customised it. Seems strange that a 3rd party mem mgr would baulk at logo.sys - himem.sys or emm386.sys I could understand.

Robin S_
01-09-2003, 02:03 AM
Win 95B must be at least part of the problem. Have just had the opportunity to borrow an HDD with Win 95C installed and it gunned up without problems in the same cptr as the troublesome Win 95B installation. Good old M$!
Parry, I haven't touched the logo.sys file, but IIRC its file size is exactly the same as in at least some earlier versions. It could, however, have been modified radically yet still finished up with an identical file size. Given that the bottom colour banner has apparently been changed in different versions the unaltered size may not be significant.