Crash-only software
Encyclopedia
Crash-only software refers to computer program
Computer program
A computer program is a sequence of instructions written to perform a specified task with a computer. A computer requires programs to function, typically executing the program's instructions in a central processor. The program has an executable form that the computer can use directly to execute...

s that handle failures by simply restarting, without attempting any sophisticated recovery. Correctly written components of crash-only software can microreboot
Microreboot
Microrebooting is a technique used to recover from failures in crash-only software systems. Instead of rebooting the whole system, only subsets of fine-grain components are restarted...

 to a known-good state without the help of a user. Since failure-handling and normal startup use the same methods, this can increase the chance that bugs in failure-handling code will be noticed, except when there are leftover artifacts, such as data corruption
Data corruption
Data corruption refers to errors in computer data that occur during writing, reading, storage, transmission, or processing, which introduce unintended changes to the original data...

 from a severe failure, that don't occur during normal startup.

An example of a crash-only implementation is unplugging a computer and plugging it back in. Any data being written at the time may be corrupted, and unsaved data and settings in RAM
Random-access memory
Random access memory is a form of computer data storage. Today, it takes the form of integrated circuits that allow stored data to be accessed in any order with a worst case performance of constant time. Strictly speaking, modern types of DRAM are therefore not random access, as data is read in...

 will be lost. However, if one waits for the computer to be idle (no data being written), saves all the data they need, and hasn't changed any operating system settings they want to keep, then unplugging the computer is faster than shutting down.

Crash-only software also has benefits for end-users. All too often, applications do not save their data and settings while running, only at the end of their use. For example, word processor
Word processor
A word processor is a computer application used for the production of any sort of printable material....

s usually save settings when they are closed. A crash-only application is designed to save all changed user settings soon after they are changed, so that the persistent state matches that of the running machine. No matter how an application terminates (be it a clean close or the sudden failure of a laptop battery), the state will persist.

Erlang

Erlang
Erlang
Erlang may refer to:* Agner Krarup Erlang , a mathematician and engineer after whom several concepts are named** Erlang , a unit to measure traffic in telecommunications or other domains...

 is a computer language originally built by Ericsson
Ericsson
Ericsson , one of Sweden's largest companies, is a provider of telecommunication and data communication systems, and related services, covering a range of technologies, including especially mobile networks...

 for fault-tolerant telephone switches. Programs are structured as modules that can be replaced (hot swapped
Hot swapping
Hot swapping and hot plugging are terms used to describe the functions of replacing computer system components without shutting down the system...

) without having to restart the entire program. If a module crashes or needs to be updated it can be restarted or replaced without affecting any other part of the program. Within the Open Telecom Platform, which often is used together with Erlang, there exist frameworks to simplify and automate this task.

External links

  • http://web.archive.org/web/20060426230247/http://crash.stanford.edu/
  • http://dslab.epfl.ch/pubs/crashonly/ - Original paper
The source of this article is wikipedia, the free encyclopedia.  The text of this article is licensed under the GFDL.
 
x
OK