Crash (computing)
Encyclopedia
A crash in computing
Computing
Computing is usually defined as the activity of using and improving computer hardware and software. It is the computer-specific part of information technology...

 is a condition where a computer or a program, either an application
Application software
Application software, also known as an application or an "app", is computer software designed to help the user to perform specific tasks. Examples include enterprise software, accounting software, office suites, graphics software and media players. Many application programs deal principally with...

 or part of the operating system
Operating system
An operating system is a set of programs that manage computer hardware resources and provide common services for application software. The operating system is the most important type of system software in a computer system...

, ceases to function properly, often exiting after encountering errors. Often the offending program may appear to freeze or hang
Hang (computing)
In computing, a hang or freeze occurs when either a single computer program, or the whole system ceases to respond to inputs. In the most commonly encountered scenario, a workstation with a graphical user interface, all windows belonging to the frozen program become static, and though the mouse...

 until a crash reporting service
Crash reporter
A crash reporter is an application whose function is to report crash data to a third party, usually to the party responsible for the crashed program. Crash reports often include data such as stack traces, type of crash, and version of software...

 documents details of the crash. If the program is a critical part of the operating system kernel, the entire computer may crash. This is different from a hang or freeze where the application or OS continues to run without obvious response to input.

Many crashes are the result of the execution of a single machine instruction, but the causes of this are many fold. Typical causes are when the program counter
Program counter
The program counter , commonly called the instruction pointer in Intel x86 microprocessors, and sometimes called the instruction address register, or just part of the instruction sequencer in some computers, is a processor register that indicates where the computer is in its instruction sequence...

 is set to an incorrect address or a buffer overflow
Buffer overflow
In computer security and programming, a buffer overflow, or buffer overrun, is an anomaly where a program, while writing data to a buffer, overruns the buffer's boundary and overwrites adjacent memory. This is a special case of violation of memory safety....

 overwrites a portion of program code due to an earlier bug. In either case, it is quite common for the processor
Central processing unit
The central processing unit is the portion of a computer system that carries out the instructions of a computer program, to perform the basic arithmetical, logical, and input/output operations of the system. The CPU plays a role somewhat analogous to the brain in the computer. The term has been in...

 to attempt to execute data or random memory values. Since all data values are possible but only some values are valid instructions, this often results in an illegal instruction exception. By chance such data or random values could be valid (though unplanned) instructions. One might say that the original bug that upset the program counter "caused" the crash, but the actual fault was an illegal instruction some time later. The art of debugging
Debugging
Debugging is a methodical process of finding and reducing the number of bugs, or defects, in a computer program or a piece of electronic hardware, thus making it behave as expected. Debugging tends to be harder when various subsystems are tightly coupled, as changes in one may cause bugs to emerge...

 such crashes is connecting the actual cause of the crash (easily determined) with the code that set off the chain of events. This is often very far from obvious—the original bug is usually perfectly valid code from the processor's perspective.

On earlier personal computers, it was actually possible to cause hardware damage through trying to write to hardware addresses outside of the system's main memory. Occasionally, execution of arbitrary data on a system will result in a breakup of screen display. This is widely considered a severe system crash.

Etymology

The term "crash" may originate from the phrase "head crash
Head crash
A head crash is a hard-disk failure that occurs when a read–write head of a hard disk drive comes in contact with its rotating platter, resulting in permanent and usually irreparable damage to the magnetic media on the platter surface....

", which occurs when the read/write heads
Disk read-and-write head
Disk read/write heads are the small parts of a disk drive, that move above the disk platter and transform platter's magnetic field into electrical current or vice versa – transform electrical current into magnetic field...

 inside a hard disk
Hard disk
A hard disk drive is a non-volatile, random access digital magnetic data storage device. It features rotating rigid platters on a motor-driven spindle within a protective enclosure. Data is magnetically read from and written to the platter by read/write heads that float on a film of air above the...

 physically come into contact with--"crash" into—the platter
Hard disk platter
A hard-disk platter is a component of a hard-disk drive: it is the circular disk on which the magnetic data is stored. The rigid nature of the platters in a hard drive is what gives them their name . Hard drives typically have several platters which are mounted on the same spindle...

, the magnetic data storage surface of a hard disk. A head crash is catastrophic to the drive operation, roughly analogous to the severity of a computer crash to computer software.

Application crashes

An application
Application software
Application software, also known as an application or an "app", is computer software designed to help the user to perform specific tasks. Examples include enterprise software, accounting software, office suites, graphics software and media players. Many application programs deal principally with...

 typically crashes when it performs an operation which is not allowed by the operating system. The operating system then triggers an exception
Exception handling
Exception handling is a programming language construct or computer hardware mechanism designed to handle the occurrence of exceptions, special conditions that change the normal flow of program execution....

 or signal
Signal (computing)
A signal is a limited form of inter-process communication used in Unix, Unix-like, and other POSIX-compliant operating systems. Essentially it is an asynchronous notification sent to a process in order to notify it of an event that occurred. When a signal is sent to a process, the operating system...

 in the application. Unix applications traditionally responded to the signal by dumping core
Core dump
In computing, a core dump consists of the recorded state of the working memory of a computer program at a specific time, generally when the program has terminated abnormally...

. Most Windows and Unix GUI
Gui
Gui or guee is a generic term to refer to grilled dishes in Korean cuisine. These most commonly have meat or fish as their primary ingredient, but may in some cases also comprise grilled vegetables or other vegetarian ingredients. The term derives from the verb, "gupda" in Korean, which literally...

 applications respond by displaying a dialog box (such as the one shown to the right) with the option to attach a debugger
Debugger
A debugger or debugging tool is a computer program that is used to test and debug other programs . The code to be examined might alternatively be running on an instruction set simulator , a technique that allows great power in its ability to halt when specific conditions are encountered but which...

 if one is installed. This behavior is called "crashing". Some applications attempt to recover from the error and continue execution instead of crashing.

Typical errors that result in application crashes include:
  • attempting to read or write memory that is not allocated for reading or writing by that application (segmentation fault
    Segmentation fault
    A segmentation fault , bus error or access violation is generally an attempt to access memory that the CPU cannot physically address. It occurs when the hardware notifies an operating system about a memory access violation. The OS kernel then sends a signal to the process which caused the exception...

    )
    or x86 specific (general protection fault
    General protection fault
    A general protection fault in the Intel x86 and AMD x86-64 architectures, and other unrelated architectures, is a fault that can encompass several cases in which protection mechanisms within the processor architecture are violated by any of the programs that are running, either the kernel or a...

    )
  • attempting to execute privileged or invalid instructions
  • attempting to perform I/O operations on hardware
    Hardware
    Hardware is a general term for equipment such as keys, locks, hinges, latches, handles, wire, chains, plumbing supplies, tools, utensils, cutlery and machine parts. Household hardware is typically sold in hardware stores....

     devices to which it does not have permission to access
  • passing invalid arguments to system calls
  • attempting to access other system resources to which the application does not have permission to access (bus error)
  • attempting to execute machine instructions with bad arguments (depending on CPU architecture): divide by zero
    Divide By Zero
    Divide By Zero was a British video game developer. It was disestablished sometime in 1996.Divide By Zero is a BBS originally started in 1996 in Columbia SC by Keven and Eric Coots...

    , operations on denorms
    Denormal number
    In computer science, denormal numbers or denormalized numbers fill the underflow gap around zero in floating point arithmetic: any non-zero number which is smaller than the smallest normal number is 'sub-normal'.For example, if the smallest positive 'normal' number is 1×β−n In computer...

     or NaN
    NaN
    In computing, NaN is a value of the numeric data type representing an undefined or unrepresentable value, especially in floating-point calculations...

     values, memory access to unaligned addresses, etc.

Website server crashes

The software running the server
Web server
Web server can refer to either the hardware or the software that helps to deliver content that can be accessed through the Internet....

 behind a website
Website
A website, also written as Web site, web site, or simply site, is a collection of related web pages containing images, videos or other digital assets. A website is hosted on at least one web server, accessible via a network such as the Internet or a private local area network through an Internet...

 may crash, rendering it inaccessible entirely or providing only an error message instead of normal content.

For example: If a site was using a SQL database (such as MySQL) for a script (such as php) and that SQL server crashed, then php would display a connection error.

Operating system crashes

An operating system crash commonly occurs when a hardware exception occurs that cannot be handled. Operating system crashes can also occur when internal sanity-checking logic within the operating system detects that the operating system has lost its internal self-consistency.

Modern multi-tasking operating systems, such as Windows NT, Linux, or Mac OS X usually remain unharmed when an application program crashes.

See also

  • Blue Screen of Death
    Blue Screen of Death
    To forse a BSOD Open regedit.exe,Then search: HKLM\SYSTEM\CurrentControlSet\services\i8042prt\ParametersThen make a new DWORD called "CrashOnCtrlScroll" And set the value to 1....

  • Crash to Desktop
    Crash to Desktop
    A crash to desktop is a computer program crash which is said to occur when a program unexpectedly quits, abruptly taking the user back to the desktop. Usually, the term is applied only to crashes where no error is displayed, hence all the user sees as a result of the crash is the desktop. Many...

  • Segmentation fault
    Segmentation fault
    A segmentation fault , bus error or access violation is generally an attempt to access memory that the CPU cannot physically address. It occurs when the hardware notifies an operating system about a memory access violation. The OS kernel then sends a signal to the process which caused the exception...

  • Safe Mode
    Safe Mode
    Safe mode is a diagnostic mode of a computer operating system . It can also refer to a mode of operation by application software. Safe mode is intended to fix most, if not all problems within an operating system...

  • Debugging
    Debugging
    Debugging is a methodical process of finding and reducing the number of bugs, or defects, in a computer program or a piece of electronic hardware, thus making it behave as expected. Debugging tends to be harder when various subsystems are tightly coupled, as changes in one may cause bugs to emerge...

  • Kernel panic
    Kernel panic
    A kernel panic is an action taken by an operating system upon detecting an internal fatal error from which it cannot safely recover. The term is largely specific to Unix and Unix-like systems; for Microsoft Windows operating systems the equivalent term is "Bug check" .The kernel routines that...

  • Reboot
  • Crash reporter
    Crash reporter
    A crash reporter is an application whose function is to report crash data to a third party, usually to the party responsible for the crashed program. Crash reports often include data such as stack traces, type of crash, and version of software...

  • Data loss
    Data loss
    Data loss is an error condition in information systems in which information is destroyed by failures or neglect in storage, transmission, or processing. Information systems implement backup and disaster recovery equipment and processes to prevent data loss or restore lost data.Data loss is...

  • SystemRescueCD
    SystemRescueCD
    SystemRescueCd is an operating system for the x86 computer platform, though the primary purpose of SystemRescueCD is to repair unbootable or otherwise damaged computer systems after a system crash. SystemRescueCD is not intended to be used as a permanent operating system. It runs from a Live CD or...

The source of this article is wikipedia, the free encyclopedia.  The text of this article is licensed under the GFDL.
 
x
OK