Jump to content

Triple fault: Difference between revisions

From Wikipedia, the free encyclopedia
Content deleted Content added
Scientus (talk | contribs)
Virtual machines: put image back up
Line 10: Line 10:
<!--could be worked in here if find specific information: http://www.intel.com/cd/ids/developer/asmo-na/eng/197666.htm or pacifica-->
<!--could be worked in here if find specific information: http://www.intel.com/cd/ids/developer/asmo-na/eng/197666.htm or pacifica-->
In [[QEMU]], a triple fault produces a dump of the virtual machine in the console, with EIP (or whatever PC may be called for the selected architecture) set to the instruction that triggered the first exception.
In [[QEMU]], a triple fault produces a dump of the virtual machine in the console, with EIP (or whatever PC may be called for the selected architecture) set to the instruction that triggered the first exception.

[[Image:Virtual_PC_Triple_Fault_Window.png|thumb|[[Microsoft Virtual PC]] displaying a triple fault message.]]


==Other uses==
==Other uses==

Revision as of 04:58, 16 April 2009

A triple fault is a special kind of exception generated by the CPU when an exception occurs while the CPU is trying to invoke the double fault exception handler, which itself handles exceptions occurring while trying to invoke a regular exception handler.

x86 processors beginning with the 80286 will cause a SHUTDOWN cycle to occur when a triple fault is encountered. This typically causes the motherboard hardware to initiate a CPU reset which in turn causes the whole computer to reboot.

Possible causes of triple faults

Triple faults indicate a problem with the operating system kernel or device drivers. In modern operating systems, a triple fault is typically caused by a buffer overflow or underflow in a device driver which writes over the interrupt descriptor table. When the next interrupt happens, the processor cannot call either the needed interrupt handler or the double fault handler because the descriptors in the IDT are corrupted.

Virtual machines

In QEMU, a triple fault produces a dump of the virtual machine in the console, with EIP (or whatever PC may be called for the selected architecture) set to the instruction that triggered the first exception.

File:Virtual PC Triple Fault Window.png
Microsoft Virtual PC displaying a triple fault message.

Other uses

  • Some operating system kernels, such as Linux, use triple faults as a last effort in their rebooting process. This is done by setting the IDTR register to 0 and then issuing an interrupt. Since the table now has length 0, all attempts to access it fail and the processor generates a triple fault. Note that this is not the preferred method of restarting the computer. In Linux, using the ACPI is tried first.
  • The Intel 80286 processor was the first to introduce the now-ubiquitous protected mode. However, the 286 could not revert to the basic 8086-compatible "real mode" without resetting the processor. The documented method of doing this was to use a special function on the Intel 8042 keyboard controller. However, intentionally triple-faulting the CPU was found to cause the transition to occur much faster and more cleanly, permitting multitasking operating systems to switch back and forth at high speed. [1]

See also