The operating system is loaded into RAM when. Booting the operating system

The computer boot process is briefly described in the article “Turning on the PC” in the BIOS section. Let's look at this process in more detail.

Initializing the system using BIOS

  1. Pressing the power button. When turned on Power buttons to elements motherboard supply voltages are supplied; the Power Good signal starts the clock generator; A reset signal is sent to the processor, which resets it to its original state. System BIOS programs start running.
  2. BIOS check. Check sum system programs, located in the ROM, is located in one of the cells. After startup, the checksum is recalculated and compared with the reference value.
  3. Processor identification. The motherboard provides the ability to install various models processor. The BIOS submits a request to identify the processor and, based on the response received, determines the processor type, frequency, voltage, etc.
  4. Setting up basic elements. The basic components of the motherboard are initialized and tested: direct memory access unit, timer, hardware interrupt unit.
  5. RAM testing. The type of memory modules, their volume, and organization are determined; The first 64 KB of RAM are tested.
  6. Organization of working RAM structures. An area for the BIOS is allocated and interrupts are configured.
  7. Checking CMOS memory and battery. If the CMOS battery is faulty, all BIOS settings data stored in memory are lost. Loading the latest configuration becomes impossible, as indicated on the monitor screen. It is possible to load standard factory BIOS values.
  8. Initializing motherboard devices. Boot devices are searched and configured ( HDD, CD drive, FDD), boot process controls (keyboard, mouse), input/output devices (COM, LPT). Devices are allocated appropriate interrupt lines.
  9. PnP. Devices connected via system connectors are identified. Devices are allocated resources and interrupts.
  10. Turn on the video system. The Video BIOS starts, which configures the video controller to VGA or EGA mode, which is supported by all video controllers. After this, the video controller is ready for use.
  11. Displaying a message on the monitor screen. The first message appears on the monitor screen: BIOS manufacturer, processor type and frequency, RAM type and amount.
  12. RAM testing. A random check of unused RAM is performed.
  13. Initializing the disk drive controller.
  14. Initializing the hard drive controller.
  15. Initializing the keyboard. The keyboard controller is turned on, the contact matrix is ​​tested, the temporary parameters for polling keys and the NumLock mode are set. The keyboard is ready to use. A message appears on the screen about the possibility of using the program BIOS Setup(usually the Del key is used for this).
  16. Search for devices with their own BIOS. If such devices are found, then control is transferred to the BIOS programs of these devices and they are initialized.
  17. Transferring control to the OS bootloader. By software interrupt Int 19h, the OS loader (Boot Record) is searched on disk drives. It must be located on one of the devices (HDD, CD, FDD, SCSI). The bootloader location is the same everywhere. Once the OS loader is found, control is transferred to it.

Loading the operating system

The operating system (OS) kernel is loaded into RAM, after which the main part of the OS is stored in system memory.


The BIOS performs a “rough” setup of the computer system. Its main task is to “breathe” life into computer hardware, regardless of its specific modification. New models of processors, motherboards, chipsets and other devices are released almost quarterly. It is impossible to immediately include the identification of all this diversity in the BIOS. Yes, this is not necessary. The main task of the BIOS is to initialize the hardware and start the operating system, which itself fine-tunes the computer components.


At the dawn of the development of personal computers, system configuration required users to have appropriate qualifications. Surely, experienced users still remember files such as config.exe And autoexec.bat, which had to be adjusted correctly in order for the “cart” to move normally.


What to do - this was the other side of the coin of IBM's open architecture. For the convenience of getting a computer with the desired configuration, you had to pay for the knowledge of how to configure it correctly. Such inconveniences scared off unprepared users, therefore, PC manufacturing companies could not put up with this state of affairs for long. Manufacturers computer equipment and software developers have tried to remove as much as possible from the consumer the need to configure their computer. For the first time, the new system setup procedure was applied to the OS Windows- the operating system itself “queried” the connected devices and configured them correctly:

  • a list of devices requiring software configuration was determined;
  • appropriate programs were sought for the correct operation of such devices;
  • The procedure for software initialization of devices and setting them up for operating modes was carried out.

The task, in general, is quite difficult. To facilitate its implementation, chipset manufacturers and software developers have agreed and established certain rules for the bootstrap mechanism. Now the components of the computer system that require initialization and configuration were equipped with the appropriate software(initializing programs, drivers, INF files):

  • Initialization programs enter control codes at specific addresses (one-time procedure);
  • Drivers- these are programs that control the operation of the controller of the corresponding device;
  • INF file- a command file that helps the OS organize the procedure for setting up a specific computer unit.

Initial Windows boot is managed batch file, which contains a list of programs and drivers executed during the OS boot process. This is the so-called “blank” batch file, which should be converted into working version, according to the installed equipment on this computer.


Windows has a certain set of universal drivers (which is constantly updated with the release of new version OS), allowing you to configure all system components. To be fair, it should be said that universal drivers Windows is not always able to produce optimal setting of one or another device, which reduces the performance and stability of the entire computer system. Therefore, all devices are supplied with their own installation software (usually on CD). When installing a new one for the first time Windows devices may ask you to install a disk with the appropriate drivers for correct settings new device. It is also recommended to monitor the release of new versions of drivers (in which errors are fixed, performance optimizations are made, etc.) for the chipset of your motherboard and update them regularly.

It will not be possible to run from one operating system to another for a long time if there are two of them installed on the computer. After carefully studying both, sooner or later you will have to choose only one of them - main, with which the work will be carried out primarily. If for the most part only one Windows system is used, its other versions or editions located on other disk partitions, does not have to be deleted. Of course, provided that the space hard drive not limited in size.

The ability to work in the future with other computer systems can be left, but for convenience, it is possible to simplify the entrance to the main one by removing temporarily unused ones from the boot. In this case, starting the computer will be simplified automatic download only the required operating system. Another option to make it easier to get started with your computer is not to remove the window for selecting to boot all systems, but to assign the required version Windows as the default boot and reduce the time it takes to select other options in the bootloader window.

How to edit the boot process for multiple operating systems Windows systems installed on one computer - more on this below.

So, in our case we have a computer with installed versions Windows 7 and 8.1. When you turn on the computer, you see a bootloader window with a list of systems to select.

Every time you boot your computer, you get into the right system possible by making the appropriate choice. IN otherwise after a certain time - and by default this is 30 seconds– Windows will automatically load, first on the list. In our case it is Windows 7, since it is the last one installed on the computer, and it is its bootloader, as we see, that greets us after the computer starts.

Well, let's change that. Let's set up automatic loading of the main system - Windows 8.1. To do this, of course, you need to enter it.

We need a settings section, and in Windows 8.1 you can get to it using the context menu on the button.

In the system window select Extra options.

You can also get to the settings section in Windows 7 using the context menu, but called up on the icon "Computer" in Explorer. Among the commands you must select .

In Windows 7 we also select Extra options.

The further steps in both systems are identical.

In the system properties window that appears, in the tab "Additionally" Click the parameters button in the last section.

Now you can start editing the boot of multiple systems. Changing the boot software Windows default from the options in the drop-down list. In our case, we change the pre-installed Windows 7 to Windows 8.1.

As mentioned, by default Windows boot loader waiting half a minute so that the user can select the operating system.

If work is primarily carried out in only one system, there is no point in leaving half a minute waiting for it to automatically load. Another operating system may not be prevented from starting, but the preset time for selecting boot options may be reduced. In displaying the list of bootable systems, in our case we will install 5 second Waiting before Windows 8.1 main system boots automatically. This time will be more than enough to make a choice if you ever need to log into Windows 7.

To completely remove another system from the boot list, you need to uncheck the option display system list. In this case, only the system selected for booting by default will boot without any time delay.

If a second operating system is ever needed, you can enter it by making this option active again.

After making changes, click "OK" at the bottom of this window, as well as at the bottom of the system properties window.

Everything - download list operating systems edited.

Above we looked at editing the boot of existing operating systems. But often, when starting a computer, we can see a list of operating systems that are already on the computer No. This is a natural development of events after the second operating system was removed by simply formatting the disk partition or destroying it. system files manually, but at the same time The entry about the possibility of loading it in the system configuration was not removed. The boot loader may also display the option to start a non-existent main Windows after the system has been reinstalled. This, by the way, is not the main one, but one of the reasons why system specialists advise implementing the so-called clean Windows installation– without saving files from the previous system and formatting the disk partition.

It is better to completely remove the existing operating system from the boot options so that it does not delay the process of starting the main Windows.

In the main system we call the command. In Windows 8.1, quick access to it is implemented in context menu on the button.

We need system configuration section. Enter the value in the command field:

Click "OK".

In Windows 7, you can launch the system configuration window more easily by entering a key query in the menu search field.

The system configuration window will appear, go to the tab. Select the entry about loading a non-existent system and delete it.

In our case, the download list contained different versions Windows, and decide on the one to be deleted "Seven" It obviously wasn't difficult for us. But if the download list contains entries for two identical versions of Windows, the system descriptions will help you orient yourself with the one you want to remove. The Windows we are actually in will be designated as current.

Save the changes made with the button. After clicking "OK" the system will offer reboot.

After restarting the computer, we can observe immediate startup of the main system.

login , which registers users in the system, is launched only when the system itself is already fully operational and operating in normal mode. This does not happen immediately after turning on the computer: Linux is a rather complex system, the objects of which end up in the operating system - a stepwise process: the behavior of the computer at various boot stages is determined by different people - from hardware developers to system administrator. The requirements for flexibility, the ability to change its settings depending on the hardware component, the need to solve different tasks using the same computer also make the loading process stepwise: first it is determined profile future system and then this profile being implemented.

The initial stage does not depend at all on what operating system installed on a computer, for some stages in each operating system They offer their own solutions - mostly interchangeable. Let's call this stage (initial) pre-system boot. Starting from a certain stage, the computer boot is already controlled by Linux itself, utilities, scripts, etc. are used. Let's call this (final) stage system boot .

Bootloader to ROM

Immediately after switching on, the RAM of a classical architecture computer is pristine. In order to start working, the processor needs at least some kind of program. This program is automatically loaded into memory from permanent storage device, ROM (or ROM, read-only memory), into which it is written once and for all in an unchanged form 1 Modern computers use programmable ROMs, the contents of which can be changed, but such a change is always considered an abnormal situation: for example, writing a new version of the ROM contents, in which errors are corrected (upgrade).. IN specialized computers (for example, in cheap game consoles) everything that the user needs is recorded exactly on

Usually on computers general purpose the program from the ROM is of no use to the user: it is small, and it always does the same thing. You can slightly change the behavior of a program from ROM by operating with data recorded in non-volatile memory(sometimes called CMOS, sometimes called NVRAM). Volume non-volatile memory is very small, and the data from it is saved after the computer is turned off due to an autonomous power supply (usually from a battery like a clock battery).

What should this starter program be able to do? Recognize the main devices on which another program needed by the user can be written, be able to load this program into memory and transfer execution to it, and also support an interface that allows you to change settings in NVRAM. Actually, this is not even one program, but many subroutines, engaged in interaction with a variety of input-output devices - both with those on which programs can be stored (hard and floppy disks, magnetic tapes and even network cards), and those through which you can communicate with the user (serial data ports - if it is possible to connect a console terminal, a system keyboard and a video card - for simple personal workstations). This set of routines in ROM is usually called BIOS(basic input-output system).

BIOS. Abbreviation for "Basic Input-Output System", a set of routines in ROM designed for simple low-level access to external devices computer. In modern operating systems it is used only during the initial boot process.

This stage of system boot can be called zero, since it does not depend on any system. Its task is to determine (possibly with the help of the user) from which device the download will take place, download a special bootloader program from there and run it. For example, to find out that the boot device is a hard drive, consider the most first sector of this disk and transfer control to a program that is located in a few areas.

Boot sector and primary bootloader

Most often, the size of the primary disk loader - the program to which control is transferred after stage zero - is quite small. This is due to the requirements versatility this kind of programs. You can read data from the disk sectors, the size of which varies for different types disk devices (from half a kilobyte to eight or even more). In addition, if you can always read one, first, sector of a disk in the same way, then the commands for reading several sectors on different devices may look different. That's why primary loader usually occupies no more than one sector at the very beginning of the disk, in its boot sector.

If primary loader was bigger, he probably could have figured out where the core was operating system, and could independently read it, place it in memory, configure it and transfer control to it. However, the core operating system has a rather complex structure - and therefore a difficult loading method; it can be quite large, and, most unpleasant of all, it can be located in an unknown location on the disk, obeying the laws file system(for example, consist of several parts scattered across the disk). Take it all into account primary loader I can't. Its task is more modest: to determine where on the disk the “big one” is located. secondary loader, download and run it. Secondary loader is simple, and can be put in a predetermined place on the disk, or, at worst, put in a predetermined place accommodation map, describing exactly where to look for its parts (size secondary bootloader limited, so it is possible to construct such a map).

Location map. Representation of the area with the necessary data (for example, secondary loader or the system kernel) in the form of a list of disk sectors that it occupies.

For an IBM-compatible computer, the size boot sector is only 512 bytes, of which not all are found in software region. Boot sector IBM PC, called MBR(master boot record), also contains disk partition table, the structure of which is described in Lecture 11. It is clear that a program of this size cannot boast of a variety of functions. Standard on many systems boot sector can only count disk partition table, define the so-called boot partition(active partition) and load the program located at the beginning of this partition. Each type of disk can have its own MBR software part, which allows you to read data from anywhere on the disk, depending on its type and geometry. However, you can still read no more than one sector: it is unknown what the installed on this partition is used for. operating system second and subsequent sectors. It turns out that the standard software part of the MBR is a certain preloader, which reads and runs the real primary loader from the first sector boot partition.

There are versions of the preloader that provide the user with the ability to independently choose, from which partition to boot 2 For example, BOOTACTV from the pfdisk package or the standard FreeBSD preloader boot0 , which, due to their pre-system, can be used anywhere.. This allows for each of the installed operating systems keep own primary loader at the beginning of the section and freely choose among them. The standard Linux boot scheme takes a different approach: simple primary loader is written directly to the MBR and the select function is passed to the secondary bootloader.

Primary loader. The first stage of booting a computer: a program whose size and capabilities depend on hardware requirements and BIOS functions. The main task is to load secondary loader .

Kernel loader

To task operating system. Typically, the system kernel is written to a file with a specific name. But how to the secondary bootloader read the file with the kernel, if this operation exists in Linux function kernels? This problem can be solved in three ways.

First, the kernel may not be a file on disk. If the download occurs over the network, it is enough to ask the server for “a file with such and such a name”, and in response will come a solid sequence of data containing the requested kernel. All file operations will be performed by the server on which the system is already loaded and running. In other cases, the kernel is “driven” into a section specially allocated for this purpose, where it no longer lies in the form of a file, but in the same continuous piece, the size and location of which are known. However, in Linux it is not customary to do this, since there may not be space for a special partition on the disk of, say, an IBM-compatible computer.

Secondly, you can use the above location map: imagine the kernel as a set of sectors on the disk, write this set to a predetermined location, and force the bootloader to assemble the kernel from pieces on the map. Usage location maps has two significant drawbacks: its Creation only possible under control already loaded systems, and change kernels must necessarily be accompanied by a change in the map. If for some reason the system does not boot in any of the pre-planned configurations, the only way to improve the situation is to boot from external media (for example, from a laser disk). And the system may not boot precisely because the administrator forgot after changing the kernel, rebuild the map: the map contains a list of sectors that correspond old file with the kernel, and after deleting the old file, these sectors may contain any kind of “garbage”.

Thirdly, you can teach secondary loader recognize structure file systems and find files there by name. This will noticeably increase its size and require “doubling functions” - after all, exactly the same, even more powerful, recognition will be in the

Have you ever wondered what happens to the operating system at the moment when it draws its logo and says “Starting Windows”? And in general, why does it take so long to load? After all, when the system starts, no problems that are complex from a computational point of view are solved!

What then does loading the operating system mean? For the most part, this involves mapping executable modules into memory and initializing service data structures. Data structures live in memory, so operations with them should, in theory, be fast. Everything suggests that time is consumed precisely by the process of loading executable modules into memory.

For fun, let’s figure out which modules, in what quantity and in what order are loaded when the OS starts. To find out, you can, for example, get the system boot log. The test OS in my case is Windows 7 Enterprise x64. We will log the boot process using the kernel debugger. There are several options for kernel debuggers, personally I prefer WinDbg. We'll also need some tools to magically transform the log into something more pleasing to the eye.

Mining and crafting

Setting up debugging is easy to Google, so I won’t describe this process in detail. Since we are interested in everything that happens from the moment the system starts, we need to check the “Cycle Initial Break” item, with the help of which the debugger will stop as soon as the kernel debugging subsystem is loaded in the system being debugged. Duplicating the output to a file can be done using the ".logopen" and ".logclose" commands, it's simple. Another useful command is ".cls". It clears the command screen, and yes, only the command screen.

The function we are interested in is “MiCreateImageFileMap”. This is an internal function of the memory manager that maps the executable file into memory. Memory projection occurs when a section is created, for example, at startup executable file. However, please note that just because an executable file is mapped into memory does not guarantee that its code will be executed! This function simply creates a projection, most often “in reserve,” so that if someone decides to run the module for execution, it can save loading time. Let's set a logging breakpoint on this function.

If you have enough mana, enter the following command:
bu nt!MiCreateImageFileMap "dt nt!_EPROCESS -d ImageFileName @$proc; dt nt!_FILE_OBJECT -d FileName @rcx; g"
The magic line literally means the following:

  • bu (Set Unresolved Breakpoint) - set an unresolved breakpoint. It’s not that someone or something doesn’t allow it, it’s just that to install it you need to decide at what address to put it. The fact is that it is not known in advance at what address it should be located. When loading any module, the presence of the required function is checked, and if such a function is found, a breakpoint is set automatically. This installation method is indispensable when ASLR is enabled - address space randomization, since modules will be loaded at different addresses each time, and a breakpoint set at a fixed address will most likely be out of work.
  • nt!MiCreateImageFileMap is the symbol to stop at. WinDbg accepts an entry in the form "module_name!function_name". In this case, nt is a predefined alias for ntoskrnl.exe.
  • What follows is part of the WinDbg script, which will be executed every time this function is stopped. “dt nt!_EPROCESS -d ImageFileName @$proc” in Russian means “display the ImageFileName field of the _EPROCESS structure from the nt module, provided that it is displayed at the address defined in the “current process” pseudo-register.” Next after the separator ";" the command means approximately the same thing, only the address of the structure is taken from the rcx register, in which the first parameter of the function is passed to the Microsoft x64 ABI. "g" means "go", i.e. continue execution.

A quick tip for using logging breakpoints: try not to use debugger extensions (commands starting with "!"), as this will make logging an order of magnitude slower.

Go! Release the breakpoint brake and wait. I waited until the desktop loaded, i.e. I'm logged in. The resulting “harvest” is slightly edited, all unnecessary is cut off for the convenience of further processing and fed to the python. Let's not focus on parsing the log. Let us only note that the graph fit into the shape of an Archimedes spiral with further manual correction, since the nodes overlapped each other. The resulting graph takes into account the order in which the libraries are loaded. Unfortunately, we had to sacrifice taking into account the loading order of executable files relative to libraries for the sake of readability of the graph.

Star map


Let's tentatively select several loading groups.

The OS starts working in the ntoskrnl.exe module, which is the core of the OS. And to be even more specific - from the KiSystemStartup() function. Along with downloadable system components it forms the foundation of the OS: separation of operating modes, basic services for user applications, etc. This group also includes drivers marked for loading during system startup. In a nutshell, Windows OS is born in this shell.

The next node is the session manager. He is introduced by the first one after system process, starting in Windows - smss.exe. The process is notable for being native. Windows process, that is, it does not use the Win32 subsystem, which is generally not loaded yet. This process uses only native operating system services through ntdll.dll, which is the user mode interface to OS services. This process is also a trusted component of the operating system and has exclusive rights, for example, it can create security tokens. But its main purpose is to create sessions and initialize subsystems, both graphical and various executable ones (Windows, POSIX). This shell meets everyone's needs.

A logon group consists of several processes. In general, they are responsible for initializing sessions. This includes displaying the welcome screen, creating desktops, starting startup processes and initializing the security subsystem, etc. This broom sweeps away all strangers.

The group of services turned out to be the most massive. It owes much of its volume to the SuperFetch service. This is the one about which they say that she loads in advance on weekends office suite, and at the beginning of the work week - Steam with toys. Superfetch loads a huge number of modules when the system starts, so that later “everything works faster.” And besides it, the system has enough service applications and auto-starting drivers. I think everyone has seen the Services and Applications snap-in. This star of life brings into the system everything that is needed and not so much.

The last one I’ll mention is everyone’s favorite explorer.exe. It is noteworthy that by the time it starts, all the modules it uses are already loaded into memory. The screenshot also included a certain vcredist_x64.exe - the poor fellow was lying on the desktop of the experimental virtual machine and was loaded into memory by the conductor.

In general, there are many ways for a module to be loaded into memory. For example, it is enough to request information from the resources of the executable file, including its icon. Specifically in in this example Explorer checked whether this program requires elevated privileges, i.e. Is it worth adding a corresponding picture with a yellow-blue shield to the icon? Let me note once again that loading a module into memory does not mean executing its code!

Personally, I keep the resulting picture close by. It clearly shows dependencies, for example, of drivers. Also, paired with the Sysinternals Autoruns utility, you can see at what stage of loading certain modules are pulled up.

The load graph was built for Windows 7 Enterprise x64 OS installed on a virtual VMware machine. Below are vector image graph and directly a file in gml format, which you can play with in any graph editor.

For normal operation of a computer, it is necessary that the main modules of the operating system be in RAM. Therefore, after turning on the computer, the operating system is automatically rewritten (loaded) from the disk into RAM.

Software works best when it is divided into layers, with each layer performing a specific function and relieving other, higher layers of worrying about the details within its layer. Based on this philosophy, the MS-DOS operating system is built on a modular principle and consists of the following components:

    Operating system loader;

    System files IO.SYS and MSDOS.SYS;

    Device drivers.

    MS DOS command processor (COMMAND.COM file);

    External MS DOS commands.

Additionally, MS-DOS, like all other operating systems for the IBM PC, uses the computer's built-in software called Basic Input/Output System (BIOS).

Let's consider the specified software modules in the order in which they are loaded into RAM after turning on the PC.

Basic I/O system- This is the lowest level of control, a kind of interface between computer hardware and programs. The BIOS controls the computer's hardware directly and saves other programs from knowing the details of how it's done. BIOS programs are written into the computer ROM by the manufacturer and carry out:

    self-testing of the computer when it is turned on (POST program);

    initialization, i.e. setting up computer equipment (the computer configuration is determined, the necessary values ​​of some registers are set);

    performing maintenance functions and processing hardware interrupts;

    loading the operating system recorded on a magnetic disk (BOOT program).

Immediately after turning on the computer, the POST program starts running, checking the functionality of the RAM and other components of the computer. The BIOS then initializes and tries to read from the disk in drive A: the operating system loader program in order to transfer control to it and continue the DOS boot process. If the necessary files or the floppy disk itself are missing, the search continues on hard drives C:, D:, E: etc. If the boot (or, in other words, system) disk is not found, a message about this is displayed on the monitor.

Note that after the boot is complete, BIOS service functions (for example, outputting individual bytes to the disk or display screen, reading a character from the keyboard, reading the real-time clock, etc.) are called using interrupts. Interrupt is a hardware mechanism that causes the processor to interrupt the current task and begin processing an external event. Such an event could be a signal from external I/O devices, a request from a program, or an error event (division by zero, integer too large, etc.).

Operating system loader is a very short program located in the first sector of each floppy disk and hard drive (hard drive) with the MS DOS operating system. The function of this program is to read from boot disk V RAM DOS system files.

System file IO.SYS is a BIOS extension. This module configures the operating system for a specific configuration of the computing system and allows you to connect new drivers to non-standard input/output devices,

System fileMSDOS.SYS- interrupt processing module. It mainly maintains the file system and manages the allocation of RAM.

After reading by the boot loader, system files are permanently located in the computer’s RAM, i.e. they are resident programs.

Upon successful loading of system files, the IO.SYS software module installs the required configuration of the computer system. For this purpose, it places external device drivers into the computer's RAM.

Drivers external devices are separate program files that provide operations for interacting with external devices. The list of connected drivers is contained in the CONFIG.SYS configuration file. .

Command processor completes the operating system boot process. After control of the computer is transferred to the command processor, the latter automatically begins executing a special command file - AUTOEXEC.BAT (if such a file is present in the root directory of the boot disk). The AUTOEXEC.BAT file specifies the commands and programs that are executed each time the computer starts. Using this file, you can configure the operating environment parameters. For example, create virtual disk, ensure changing printing modes, download auxiliary programs, etc.

Files with the .BAT extension play a special role when working in a system environment. They contain a set of operating system commands or executable file names. After running a file with the .BAT extension, all commands written in it are executed automatically one after another.

If the AUTOEXEC.BAT file is not found in the root directory of the disk from which the operating system is loaded, then MS DOS prompts the user for the current date and time.

After executing the AUTOEXEC.BAT file, the operating system boot process ends. The command processor issues a prompt indicating that MS-DOS is ready to accept commands. The invitation usually looks like A:\> or, for example, C:\>, if the boot was done from a hard drive.

Internet