By this time, many of your users are already running Windows 95. Oh sure, there are still plenty of Windows 3.1 and Windows for Workgroups users out there, but lets face it, if youre not moving towards Windows 95, youre pretty much sitting still. Its been quite some time since weve seen any new software written specifically for Windows
3.1. In fact, most new software wont even work on Windows 3.1, because its written to use 32-bit drivers and 32-bit file access. Therefore, its to your benefit to learn as much as you can about this pervasive new operating system. This article will give you an in-depth background on the Windows 95 boot cycle.
Lets Review
When I first started programming, PCs were text-based DOS machines. There was very little commercial software written for PCs at that time, and what was available only ran in DOS. When you had a problem, you generally only needed to look in a few places to diagnose and fix the problem. DOS was great for its time, but a better user interface was needed. Microsoft responded with the Windows operating system. Ill call it an operating system rather than an environment, since it performed many tasks at the machine level. However, it still used DOS for most operations, so it wasnt truly an operating system. Prior to Windows 95, when you loaded a new software program on your PC and it wouldnt run, you would find and modify one or more of a limited number of files: CONFIG.SYS, AUTOEXEC.BAT, and perhaps the WIN.INI or SYSTEM.INI files. These were the files used by the 16-bit versions of Windows to control the startup of both the PC and Windows. CONFIG.SYS was used to set device drivers for such things as CD-ROM drives, emulation boards, and printers, while AUTOEXEC.BAT was used for starting Terminate Stay Resident (TSR) programs, setting paths, and starting Windows.
Once Windows was initiated, the *.INI files told it what settings and configurations to use. For example, SYSTEM.INI was commonly used, among other things, to tell Windows where to find the specific drivers needed by various Windows applications. WIN.INI was used to define parameters such as fonts, and PROTOCOL.INI was used for defining communications protocols. When you had problems with Windows, you generally made changes to one of these files. If you have 16-bit applications that need to use those files, Windows 95 will still let you. For the most part however, the need for these files has been done away with in Windows 95.
Things Are Different Now
Windows 95 does things differently. It is a true operating system in the sense that it handles all operations itself. Unless you specifically tell it to, it will not pass any processing directly to DOS, although it may indirectly do so through 32-bit API calls. While it will still allow you to use the previously discussed files, it no longer requires them. Ill get into this in a bit more detail soon, but for now, lets step through the Windows 95 boot cycle. Surprisingly, there are only three major steps involved in this cycle. They are
as follows:
BIOS
IO.SYS
Windows 95 When you first power up your personal computer, the initial operating system needs to know certain things about the basic hardware of your PC. It gets this information from the Basic Input/Output System (BIOS) stored in the boot sector of your boot device (usually the hard drive). This information is stored in memory block F000 of the boot devices ROM, and is in the same memory location on every PC. BIOS provides instructions that run such low-level functions as writing to disk drives and providing drivers for video cards, ports, and the like. When you first see information on your display after powering on the PC, it is information being echoed from the BIOS instructions. The final instruction from BIOS is to start IO.SYS.
What is IO.SYS? It is the familiar MS-DOS that you are acquainted with from previous Windows versions; it resides in the root drive of your boot disk as a hidden file. IO.SYS performs such functions as starting the PC processor in real mode, setting up the DOS data structures in conventional memory, and initializing some low-level DOS functions. Finally, it runs the boot cycle to start Windows 95.
If your PC still has information in the CONFIG.SYS file, IO.SYS will attempt to use that information. It then loads the command interpreter (COMMAND. COM), which is used to read the AUTOEXEC.BAT file. The file is read, and the commands in it, if there are any, are executed. However, before it reads CONFIG.SYS and AUTOEXEC.BAT, IO.SYS reads a hidden file called MSDOS.SYS. This is a text file that determines the Windows 95 startup configuration. Its entirely possible that MSDOS.SYS will tell IO.SYS to skip reading the CONFIG.SYS and AUTOEXEC.BAT files and instead go directly to Windows 95. You can also manually prevent IO.SYS from reading CONFIG.SYS and AUTOEXEC.BAT by holding down the Shift key during startup. Ill take a more in-depth look at this file later. The last instruction from IO.SYS is to call WIN.COM, which starts Windows 95.
Windows 95
BIOS
IO.SYS
Windows 95 uses the settings defined in the MSDOS.SYS file to decide what to load during startup. However, once the GUI initiates, the applications defined in the designated startup folder determine what will run first. Incidentally, the startup folder doesnt have to be named Startup. Windows 95 gets the location and folder name to use as the startup folder from the Windows 95 Registry under the key HKEY_CURRENT_USERSoftware MicrosoftWindowsCurrentVersion Explorershellfolders. You can change this folder name by changing the default value in this key.
Once all applications in the startup folder have been run, Windows 95 returns control to the user. Previous versions of Windows used the *.INI files to tell the Windows operating system how to load, what to load, and how to configure certain initial settings. Windows 95 will still use the information in these files if they exist, but most of that information is now stored in the Registry. This Registry is analogous to a relational database such as DB2/400, in that the Registry uses keys, sub-keys, and values within those keys in much the same way as a relational database uses related files.
Thats pretty much the entire boot cycle. In most cases, you can leave things as they are. However, if you like to tinker or need to change these settings for a specific reason, Windows 95 allows you to do so by editing the MSDOS.SYS file. You can also edit the Registry with the command REGEDIT, but you should do so only if absolutely necessary and only after backing it up first. Im not going to review the REGEDIT command here, but for more information check out The Windows 95 Registry and the REGEDIT Command in the September/October 1997 issue of Client Access/400 Expert.
MSDOS.SYS Settings
As I stated, MSDOS.SYS is called from IO.SYS and is used to control the way Windows 95 starts. Despite the SYS extension, this is really just a batch file that you can edit with any text editor. However, you wont find it by using the DOS DIR command or by looking in Explorer unless you first change its properties. MSDOS.SYS is a hidden, read-only system file. You have to change its attributes before you can edit it. This is easy enough to do.
1. Open an Explorer session.
2. From the Explorer Menu, click on View, click Options, and check the Show All Files button.
3. Now click on the C: drive (or whichever drive is your boot drive).
4. You should now be able to see MSDOS.SYS in this root drive.
5. Right-click on MSDOS.SYS and open the Properties panel.
6. Change the file attributes by removing the check marks next to the read-only and hidden attributes. Now you can edit this file with a text editor. Before you do though, make sure you make a backup copy just in case you have any problems later. Figure 1 is an example of the MSDOS.SYS file. When youre done editing this file, make sure you reset the attributes back to their original values. As you can see, this copy of MSDOS.SYS only has two options: BootMulti=0 and BootGUI=1. The first option means that there is only one version of Windows (in this case Windows 95) to boot from. The second option, BootGUI, tells your system to start Windows 95. Each of these options has other combinations, and you can add many more options. The table in Figure 2 lists the various MSDOS.SYS options along with their values. I will provide you with a brief explanation of what each option controls.
BootMulti
This option lets you boot to a previous version of Windows (if one is available on your system). A value of 1 tells the PC to boot to the previous version, while the default value of 0 says to start Windows 95. Incidentally, when you up- graded to Windows 95, you may have installed it over Windows 3.1. In that scenario, Windows 95 loaded into the default directory, and you will not be able to boot to the previous version of Windows, because both versions reside in the same space on your hard drive. You would have had to load Windows 95 in a different directory when you installed it to take advantage of this option. In Windows NT, the Boot Loader determines whether your system is capable of a dual boot.
This option is very much like BootMulti in that it lets you determine which version of Windows to boot to. The default value of 1 tells the system to boot to Windows 95. A value of 0 means to boot to a previous version of Windows. In addition, the BootWin setting determines the effect of the F4 key during startup. BootWin=1 means that if you press F4 at the message Windows 95 is starting, youll get a new message saying that MSDOS is starting, and DOS will be started instead of Windows 95. On the other hand, if BootWin=0, the first message youll see is that MS-DOS is starting. Pressing F4 before this message appears will allow you to start Windows 95 instead.
This option determines whether the Windows 95 GUI interface will be started. A value of 1, which is the default, tells the PC to start the GUI, while a value of 0 drops the system back to a DOS prompt.
This option tells your system whether to display the startup menu. If youve ever had to start Windows 95 in Safe Mode, you are familiar with the startup menu. It allows you to, among other things, start Windows 95 normally, start Windows 95 in Safe Mode, or drop out to a command prompt. The default value of 1 tells the PC to start the Windows 95 GUI; a value 0 means to display the startup menu. You can also display the startup menu by pressing F8 when you see the message Starting Windows 95.
BootMenuDefault
This option gives the status of the last exit from Windows 95. The default is 1 for a normal exit, 3 for an abnormal exit, and 4 for an abnormal exit with a network connection. This option controls whether certain options, such as Start Windows In Safe Mode With Network Support, appear in the startup menu.
BootMenuDelay
This option controls the number of seconds allowed before the default action is taken when the startup menu is displayed.
This option enables function keys F4, F5, F6, F8, Shift+F5, Ctrl+F5, and Shift+F8 during the boot process. These keys are used to control how Windows 95 starts. For more information on how these keys work, see the sidebar titled What are the Windows 95 Startup Keys? The default value is 1; a value of 0 disables these function keys.
This option specifies the number of seconds your system waits for you to press a function key after the message Starting Windows 95 is displayed.
BootWin
BootGUI
BootMenu
BootKeys
BootDelay
Logo
This option controls whether or not the Windows 95 logo is displayed when starting Windows 95. The default value of 1 tells your system it should use the logo, while 0 says to use text mode.
This option controls whether or not you use Drvspace. The value of 0 indicates the PC should load Drvspace.bin if it exists. A value of 1 tells your system not to load Drvspace.bin.
This option works the same as Drvspace, but controls DoubleSpace.
DoubleBuffer
This option is used if you have a SCSI drive that requires double buffering. The default value of 1 tells the PC to use double buffering; a value of 0 means double buffering should not be used.
This value enables the startup menu option Safe Mode with Network Support if specified as 1; a value of 0 disables this option.
BootFailSafe
A value of 1 in this option forces Windows to boot to Safe Mode. The default value of 0 lets the system boot in normal mode.
Use this option to display a warning message that you are booting in Safe Mode by specifying a value of 1. Use a value of 0, the default, to skip the warning message.
This option is used to allow Command. Com and Drvspace.Bin to be loaded at the top of conventional memory by using a value of 1. A value of 0 prevents these programs from loading at the top of conventional memory.
As you can see, there is a lot you can do to control the way Windows 95 boots by editing the MSDOS.SYS batch file. There are many other combinations and ramifications of using these options that are outside the scope of this article. If you want more information, I highly recommend the book Windows 95 Secrets 4th Edition by Brian Livingston and David Straub, from which some of this information was obtained. In my opinion, it is the definitive work on Windows 95.
Purrs Like A Porsche
Windows 95 has changed the way we think about desktop computing. Comparing it to Windows 3.1 is like comparing a Porsche to a Dodge K carthere is no comparison. Although you push the power button on your computer to start both programsjust as turning a key starts every car from a Pacer to a Maseratifrom that point on, the turbocharged Windows 95 leaves Windows 3.1 in the dust. Now that you know more about the Windows 95 boot cycle and the options you can use to control it, you are ready to give up putt-putting around in that old Dodge K Car, and start racing your Porsche 911 down the information autobahn.
[Paths]
WinDir=C:WINDOWS
WinBootDir=C:WINDOWS
HostWinBootDrv=C
Drvspace
Dblspace
Network
BootWarn
LoadTop
[Options]
BootMulti=0
BootGUI=1
;
;The following lines are required for compatibility with other programs.
;Do not remove them (MSDOS.SYS needs to be >1024 bytes).
;xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxa
;xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxb
;xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxc
;xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxd
;xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxe
;xxxx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YS file has only two options: BootMulti=0 and BootGUI=1.
Option Value
BootMulti 0 or 1 BootWin 1 or 0 BootGUI 1 or 0 BootMenu 0 or 1 BootMenuDefault (default is either 1 or 3) BootMenuDelay (default is 30 seconds) BootKeys 1 or 0
BootDelay (default is 2 seconds) Logo 1 or 0
DrvSpace 1 or 0
DblSpace 1 or 0
DoubleBuffer 1 or 0
Network 1 or 0
BootFailSafe 0 or 1
BootWarn 1 or 0
LoadTop 1 or 0
Figure 2: The MSDOS.SYS file options will let you tweak your system so that it boots just how you want it to.
What Are the Windows 95 Startup Keys?
by Shannon ODonnell
If you use the BootKey option in the MSDOS.SYS file, you can control whether the Startup Keys are functional when booting Windows 95. This information doesnt help you much if you dont know what the Startup Keys are used for in the first place. With that in mind, the following table will define the various Startup Keys available to you.
Key Function When Pressed
F4 When BootWin=1, this key will start the previous version of DOS, If Windows 95 was loaded in its own directory when it was installed. When BootWin=0, this key will start Windows 95. This only works if BootMulti=1, otherwise BootWin=0 has no effect.
F5 Pressing this key causes Windows 95 to start in Safe Mode.
Shift+F5 This causes Windows 95 to start in Command Line Prompt Mode. This also automatically bypasses your Config.Sys and Autoexec.bat files.
F6 This key works the same as F5 in that it boots Windows 95 in Safe Mode. In addition, it starts
Network Support if you are attached to a network.
F8 Pressing this key displays the Windows 95 Startup Menu.
Shift+F8 Pressing this key lets you step through your startup files one line at a time to let you decide whether or not to process that instruction. This key is especially interesting as it lets you see what is happening in your IO.SYS file before Config.Sys is even run.
LATEST COMMENTS
MC Press Online