I've been digging web a bit and trying to figure out how data is stored on a HDD in a lowest level...

So far I managed to figure out that HDD plate surface is divided into domains (consisting of tiny particles able to be polarised) which are magnetized as N-S or S-N. Now what is bothering me - what is a single bit?

After reading one site I was under impression that N-S->N-S->N-S->S-N->S-N is equal to 0010 (2) as first three domains have the same polarity and while it does not change they are treated as zeros (bits '0'), but the third arrow joins two opposite domains hence it (the arrow) is treated as one (bit '1'). This would make sense, but this also means that once I change a single bit in a file - the whole file must be rewritten (well at least the bits after what was modified) to preserve data.

On another source I was explained that the direction of the domain polarity (not delta between two domains as above) is treated as a single bit, i.e. NS is '1' and 'SN is 0' (or vice versa -- do not remember...).

So which model is it after all? Or neither?

1 Answer 1


Very old hard drives used MFM encoding on the physical disk surface (just like floppies), then they used RLL encoding. Then PRML/EPRML encoding was used (and may still be used now for all I know - though new methods have probably been developed by now).

A common thing in all of these is that the hard drive head is not expected to read the magnetic state of a domain directly beneath it, but rather it is the time between flux reversals (NS to SN to NS, etc.) is what determines the data. So the pattern written to the medium won't match 1:1 with the data it "stands for."

Reliable communication schemes depend on a "clock" of some sort to know when the "data" line means new data. However, in this situation, you don't have a "clock", so the data itself must be the "clock." Thus, you can't have too much time between flux reversals otherwise the firmware loses sync, so the above encoding schemes are all about making sure there's enough flux reversals so that the head has something to sense.

  • I am sorry I'm not completely following you... Doesn't that 'data-based-clock' distort actual data? Or is it like DNA chain - only some parts are effective and code genes (data), while others are meta-parts (not storing effective data) that on HDD act like 'ticks'?
    – netikras
    Apr 18, 2015 at 11:26
  • What happens basically is that a given number of bits on the wire (encoded by flux reversals) stand for a fewer number bits of data. A good example is Eight-to-Fourteen Modulation used on optical discs (en.wikipedia.org/wiki/Eight-to-fourteen_modulation).
    – LawrenceC
    Apr 18, 2015 at 14:53
  • Thinking about it, your DNA analogy makes sense.
    – LawrenceC
    Apr 18, 2015 at 15:03

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .