The core services within an operating system. The term “kernel” is most often used in a UNIX environment and is contrasted with the term shell, which describes the outer portion of the operating system that is exposed to the user and provides a user interface for entering commands and receiving output. (In Microsoft Windows operating systems, the shell is the desktop.)
The kernel generally interfaces with other components of the operating system through system calls, which provide a standard interface to kernel functions. In many operating systems, the kernel is primarily responsible for scheduling processes and threads and for handling interrupts from devices. The kernel also typically manages input/output (I/O) operations and memory management.
In Windows NT and Windows 2000, the kernel (called ntoskernl.exe and commonly referred to as the microkernel) is located in the \Winnt\System32 directory and runs in nonpageable memory (which means that it is always resident in memory). The kernel is responsible for thread scheduling and dispatching threads to processors on a symmetric multiprocessing (SMP) platform. The kernel code itself is not preemptive - that is, no other thread or process can preempt the kernel’s operations. Each thread is assigned a priority level from 0 to 31, as follows:
The kernel adjusts priority levels for threads to ensure that no thread is starved and that each receives proper attention, with threads having a higher priority level getting the greater share of processor resources.
The kernel does its job by managing two classes of objects:
The Windows NT kernel communicates with the hardware abstraction layer (HAL) to interact with hardware and communicates with the Windows NT executive and its components for higher-level operating system functions. The kernel loads when the screen turns blue during the boot process.
In Windows 95 and Windows 98, the kernel file is kernel32.dll, and it is located in the \Windows\System directory. If the kernel is corrupt or missing, you can expand the file from the distribution CD and replace the damaged or missing file on your hard drive (as long as you can access that drive in a way that doesn’t involve this file, such as through MS-DOS).