Definition

# parity

Contributor(s): Ed Hannan

In computers, parity (from the Latin paritas, meaning equal or equivalent) is a technique that checks whether data has been lost or written over when it is moved from one place in storage to another or when it is transmitted between computers.

### How parity works

Because data transmission is not an entirely error-free process, data is not always received in the same way as it was transmitted. A parity bit adds checksums into data that enable the target device to determine whether the data was received correctly.

An additional binary digit, the parity bit, is added to a group of bits that are moved together. This bit, sometimes referred to as a check bit, is used only to identify whether the moved bits arrived successfully.

### Even parity bit vs. odd parity bit

There are two kinds of parity bits:

• In even parity, the number of bits with a value of one are counted. If that number is odd, the parity bit value is set to one to make the total number of ones in the set (including the parity bit) an even number. If the number of bits with a value of one is even, the parity bit value is set to zero, so that the total number of ones in the set (including the parity bit) remains an even number.
• In odd parity, if the number of bits with a value of one is an even number, the parity bit value is set to one to make the total number of ones in the set (including the parity bit) an odd number. If the number of bits with a value of one is odd, the parity bit value is set to zero, so that the total number of ones in the set (including the parity bit) remains an odd number.

At the receiving end, each group of incoming bits is checked to see if the group totals to an even or odd number. If a transmission error occurs, the transmission is retried or the system halts and an error message is sent to the user.

### Parity error detection

The above description explains how parity checking works within a computer. Specifically, the Peripheral Component Interconnect bus and the I/O bus controller use the odd parity method of error checking. Parity bit checking is not an infallible error-checking method since it's possible that two bits could be in error in a transmission, offsetting each other. For transmissions within a personal computer, this possibility is considered extremely remote. In some large computer systems where data integrity is seen as extremely important, three bits are allocated for parity checking.

This video by Eddie Woo explains
the concept of parity checking.

Parity checking is also used in communication between modems. Here, parity checking can be selected to be even (a successful transmission forms an even number) or odd. Users may also select no parity, meaning the modems will not transmit or check a parity bit. When no parity is selected (or defaulted), it's assumed there are other forms of checking that will detect any errors in transmission. No parity also usually means the parity bit can be used for data, speeding up transmission. In modem-to-modem communication, the type of parity is coordinated by the sending and receiving modems before the transmission takes place.

### Parity checking vs. error-correction code

At the 64-bit word level, parity checking and error-correction code (ECC) require the same number of extra bits. While parity checking just detects an error -- it does not have correction capabilities -- ECC technology allows errors to not only be detected, but corrected. This means a system can continue to work without data being corrupted. In general, ECC offers greater reliability to any computing or telecommunications system without adding much cost.

### Parity and RAID

The concept of parity is also used in redundant array of independent disks (RAID) protection. RAID devices use enhanced forms of parity checking such as vertical and horizontal parity. Some RAID groups -- such as RAID 4 or RAID 5 -- have one or more disk drives that contain parity information that allows them to rebuild data if a drive failure occurs. For example, double-parity RAID (also known as RAID 6), stripes data across a set of at least four drives at a block level, like RAID 5, but then writes a second set of parity data across all the drives.

This approach guards against data loss in up to two failed drives. Drawbacks to double-parity RAID include the use of a complex controller, the cost of two extra drives for implementation and slower write transactions due to the extra parity set.

When data is written to a RAID group, it will always have the correct parity, as it will have gone through various error-checking algorithms. That way, if a drive in the RAID group fails, the system uses the information on the remaining disks along with the parity information to rebuild the data on the failed drive to a spare drive.

How does this happen? If the RAID group is using even parity, it can figure out what was on the failed drive by adding up the bits on the remaining drives. If the data on the remaining drives adds up to an odd number, the information on the failed drive must have been a one to maintain even parity. If the data on the remaining drives adds up to an even number, the data on the failed drive must have been a zero.

This was last updated in August 2016

## Content

Find more PRO+ content and other member only offers, here.

#### Join the conversation

Send me notifications when other members comment.
The definition of parity is incorrect: not the number of bits is counted, but the number of 1's is counted!
Cancel
How have parity bits and parity checking helped your organization guard against data loss?
Cancel
Why is parity distributed in RAID 5? Why can't we have parity on a single drive?
Cancel

## SearchSolidStateStorage

• ### Will the eMMC controller market keep up with flash innovation?

EMMC host controllers may have a hard time handling advances in flash memory technology, like 3D NAND and newer connection ...

• ### Small but mighty eMMC flash storage grows its enterprise role

Many common devices, like your cell phone and tablet, use eMMC flash for storage. But the internet of things will soon make eMMC ...

• ### How eMMC 5.0 can improve your organization's small storage needs

The latest eMMC specification puts the tiny flash storage devices on a level playing field with many SSDs when it comes to speed ...

## SearchConvergedInfrastructure

• ### Holy COW! New Hampshire med center turns to Pivot3 vSTAC for VDI

Southern New Hampshire Medical Center put its traditional server-storage architecture out to pasture when it added ...

• ### Examining the state of the hyper-converged infrastructure market

HCI market leaders have emerged, but some question how long they'll retain their hold over the rapidly evolving segment.

• ### Nutanix networking management includes microsegmentation, APIs

Nutanix adds 'one-click networks' to its hyper-convergence as part of its plans to become an on-premises version of Amazon Web ...

## SearchCloudStorage

• ### Hitachi Content Intelligence searches, analyzes data

Hitachi Content Intelligence, built into Hitachi Content Portfolio object storage, extracts data and metadata from repositories ...

• ### OpenStack Newton storage features include data encryption

Storage updates in OpenStack's Newton release include at-rest data encryption in Swift, a message API for async tasks in Cinder ...

Google Cloud Platform expands Zadara Storage VPSA and ZIOS hyperscale cloud SaaS options, which already support Amazon Web ...

## SearchDisasterRecovery

• ### Case closed: Law firm selects iland DRaaS for faster, easier DR

Minutes count in legal work, and Graubard Miller needed a simpler platform for disaster recovery. The verdict: The law firm chose...

• ### Disaster recovery and business continuity plans require updating

Updating business continuity and disaster recovery plans can seem daunting, but it becomes easier when you delegate tasks and ...

• ### Enhance cloud resiliency with proper data management

Explore factors that can influence your level of cloud resilience, such as outages in different geographic locations, and the ...

## SearchDataBackup

• ### Mobile data backup helped by encryption, data policies

More and more corporate data is being created and living on mobile devices such as tablets and smartphones. That dynamic requires...

• ### Veeam backup software protects mental health facility's Hyper-V

A mental health and addiction facility had an ongoing problem with its virtual machine backup and recovery until it was solved ...

• ### Commvault backup software builds in cloud capability, virtualization

By embracing new technology, like the cloud and virtualization, Commvault Systems provides businesses with a complete backup ...

Close