21
Thu, Nov
1 New Articles

Understanding the Windows 95 Boot Cycle

Typography
  • Smaller Small Medium Big Bigger
  • Default Helvetica Segoe Georgia Times

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 let’s face it, if you’re not moving towards Windows 95, you’re pretty much sitting still. It’s been quite some time since we’ve seen any new software written specifically for Windows
3.1. In fact, most new software won’t even work on Windows 3.1, because it’s written to use 32-bit drivers and 32-bit file access. Therefore, it’s 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.

Let’s 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. I’ll 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 wasn’t truly an operating system. Prior to Windows 95, when you loaded a new software program on your PC and it wouldn’t 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. I’ll get into this in a bit more detail soon, but for now, let’s 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 device’s 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. It’s 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. I’ll 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 doesn’t 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.

That’s 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. I’m 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 won’t 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 you’re 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, you’ll 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 you’ll 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 you’ve 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 car—there is no comparison. Although you push the power button on your computer to start both programs—just as turning a key starts every car from a Pacer to a Maserati—from 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
;xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx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xxxxxxxxxxxxxxxxxxxxxr

;xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxs

Network=1

Figure 1: This basic MSDOS.SYS 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 O’Donnell

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 doesn’t help you much if you don’t 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.


SHANNON ODONNELL
Shannon O'Donnell has held a variety of positions, most of them as a consultant, in dozens of industries. This breadth of experience gives him insight into multiple aspects of how the AS/400 is used in the real world. Shannon continues to work as a consultant. He is an IBM Certified Professional--AS/400 RPG Programmer and the author of an industry-leading certification test for RPG IV programmers available from ReviewNet.net.
 
BLOG COMMENTS POWERED BY DISQUS

LATEST COMMENTS

Support MC Press Online

$

Book Reviews

Resource Center

  • SB Profound WC 5536 Have you been wondering about Node.js? Our free Node.js Webinar Series takes you from total beginner to creating a fully-functional IBM i Node.js business application. You can find Part 1 here. In Part 2 of our free Node.js Webinar Series, Brian May teaches you the different tooling options available for writing code, debugging, and using Git for version control. Brian will briefly discuss the different tools available, and demonstrate his preferred setup for Node development on IBM i or any platform. Attend this webinar to learn:

  • SB Profound WP 5539More than ever, there is a demand for IT to deliver innovation. Your IBM i has been an essential part of your business operations for years. However, your organization may struggle to maintain the current system and implement new projects. The thousands of customers we've worked with and surveyed state that expectations regarding the digital footprint and vision of the company are not aligned with the current IT environment.

  • SB HelpSystems ROBOT Generic IBM announced the E1080 servers using the latest Power10 processor in September 2021. The most powerful processor from IBM to date, Power10 is designed to handle the demands of doing business in today’s high-tech atmosphere, including running cloud applications, supporting big data, and managing AI workloads. But what does Power10 mean for your data center? In this recorded webinar, IBMers Dan Sundt and Dylan Boday join IBM Power Champion Tom Huntington for a discussion on why Power10 technology is the right strategic investment if you run IBM i, AIX, or Linux. In this action-packed hour, Tom will share trends from the IBM i and AIX user communities while Dan and Dylan dive into the tech specs for key hardware, including:

  • Magic MarkTRY the one package that solves all your document design and printing challenges on all your platforms. Produce bar code labels, electronic forms, ad hoc reports, and RFID tags – without programming! MarkMagic is the only document design and print solution that combines report writing, WYSIWYG label and forms design, and conditional printing in one integrated product. Make sure your data survives when catastrophe hits. Request your trial now!  Request Now.

  • SB HelpSystems ROBOT GenericForms of ransomware has been around for over 30 years, and with more and more organizations suffering attacks each year, it continues to endure. What has made ransomware such a durable threat and what is the best way to combat it? In order to prevent ransomware, organizations must first understand how it works.

  • SB HelpSystems ROBOT GenericIT security is a top priority for businesses around the world, but most IBM i pros don’t know where to begin—and most cybersecurity experts don’t know IBM i. In this session, Robin Tatam explores the business impact of lax IBM i security, the top vulnerabilities putting IBM i at risk, and the steps you can take to protect your organization. If you’re looking to avoid unexpected downtime or corrupted data, you don’t want to miss this session.

  • SB HelpSystems ROBOT GenericCan you trust all of your users all of the time? A typical end user receives 16 malicious emails each month, but only 17 percent of these phishing campaigns are reported to IT. Once an attack is underway, most organizations won’t discover the breach until six months later. A staggering amount of damage can occur in that time. Despite these risks, 93 percent of organizations are leaving their IBM i systems vulnerable to cybercrime. In this on-demand webinar, IBM i security experts Robin Tatam and Sandi Moore will reveal:

  • FORTRA Disaster protection is vital to every business. Yet, it often consists of patched together procedures that are prone to error. From automatic backups to data encryption to media management, Robot automates the routine (yet often complex) tasks of iSeries backup and recovery, saving you time and money and making the process safer and more reliable. Automate your backups with the Robot Backup and Recovery Solution. Key features include:

  • FORTRAManaging messages on your IBM i can be more than a full-time job if you have to do it manually. Messages need a response and resources must be monitored—often over multiple systems and across platforms. How can you be sure you won’t miss important system events? Automate your message center with the Robot Message Management Solution. Key features include:

  • FORTRAThe thought of printing, distributing, and storing iSeries reports manually may reduce you to tears. Paper and labor costs associated with report generation can spiral out of control. Mountains of paper threaten to swamp your files. Robot automates report bursting, distribution, bundling, and archiving, and offers secure, selective online report viewing. Manage your reports with the Robot Report Management Solution. Key features include:

  • FORTRAFor over 30 years, Robot has been a leader in systems management for IBM i. With batch job creation and scheduling at its core, the Robot Job Scheduling Solution reduces the opportunity for human error and helps you maintain service levels, automating even the biggest, most complex runbooks. Manage your job schedule with the Robot Job Scheduling Solution. Key features include:

  • LANSA Business users want new applications now. Market and regulatory pressures require faster application updates and delivery into production. Your IBM i developers may be approaching retirement, and you see no sure way to fill their positions with experienced developers. In addition, you may be caught between maintaining your existing applications and the uncertainty of moving to something new.

  • LANSAWhen it comes to creating your business applications, there are hundreds of coding platforms and programming languages to choose from. These options range from very complex traditional programming languages to Low-Code platforms where sometimes no traditional coding experience is needed. Download our whitepaper, The Power of Writing Code in a Low-Code Solution, and:

  • LANSASupply Chain is becoming increasingly complex and unpredictable. From raw materials for manufacturing to food supply chains, the journey from source to production to delivery to consumers is marred with inefficiencies, manual processes, shortages, recalls, counterfeits, and scandals. In this webinar, we discuss how:

  • The MC Resource Centers bring you the widest selection of white papers, trial software, and on-demand webcasts for you to choose from. >> Review the list of White Papers, Trial Software or On-Demand Webcast at the MC Press Resource Center. >> Add the items to yru Cart and complet he checkout process and submit

  • Profound Logic Have you been wondering about Node.js? Our free Node.js Webinar Series takes you from total beginner to creating a fully-functional IBM i Node.js business application.

  • SB Profound WC 5536Join us for this hour-long webcast that will explore:

  • Fortra IT managers hoping to find new IBM i talent are discovering that the pool of experienced RPG programmers and operators or administrators with intimate knowledge of the operating system and the applications that run on it is small. This begs the question: How will you manage the platform that supports such a big part of your business? This guide offers strategies and software suggestions to help you plan IT staffing and resources and smooth the transition after your AS/400 talent retires. Read on to learn: