motor feedback system for linear motion
"Best" covers a lot of ground: accuracy, resolution and cost. High resolution was discussed before in terms of LVDTs. If you are willing to trade off resolution for accuracy, then a simple way of doing this is to have a few opto-interrupter sensors spaced at accurately known locations, and attach a flag to the linear motor that blocks the sensors as it moves.

At slightly higher cost, and roughly equal accuracy, but higher resolution is to use an off the shelf rotary encoder with a mechanism that converts linear to rotary motion. The simplest way is by wrapping a string around the shaft of the encoder and fixing the two ends of the string to the ends of the object that moves. Another method is to press a gear onto the encoder shaft and attach a "gear rack" of some type to the linear motion shaft. The gear rack can be an actual rack that mates with the rotary gear or a section of timing belt that is glued flat to act as a rack. This arrangement is generally known as 
rack and pinion