Operating System Debugging
Failure Analysis is the activity of discovering what caused a program to fail.
Two approaches could be used by the operating system to record the failure-related data:
- The OS could write any errors that occur during the execution of the program to a log file, which can later be reviewed by the computer administrator or the user who ran the program. This data could hint at what causes the program to fail.
- The OS could copy data in memory that the program used to a file at the moment when the program crashes. This process is called a core dump. Since a core dump represents the state at which the program failed, a programmer could later use this data to discover what caused the failure.
However, when operating system code needs to undergo debugging, the methods above might be inappropriate for the next reasons.