The warp 2 barrier was a time barrier.
Warp factor 2, or eight times the speed of light, was the theoretical maximum warp speed in the early stages of Vulcan and Earth warp technologies. After the invention of warp drive by the Vulcans, it took them a hundred years to design an engine capable of breaking the warp 2 barrier. (ENT: "First Flight")
In the 22nd century, such Earth ships as the ECS Horizon, an Earth Cargo Authority operated J-class freighter commissioned in 2102, and the Starfleet operated Neptune-class survey ships were among the early ship classes with warp capability limited in technology by this barrier. (ENT: "Horizon", "Singularity")
It was not until the 2140s that the warp five engine conceived at the Warp Five Complex by Henry Archer broke the warp 2 barrier. In 2143, Commanders A.G. Robinson and Jonathan Archer demonstrated this advanced warp engine in the second NX-class prototype, the NX-Beta, by holding the ship steady at warp 2.5. (ENT: "First Flight")
After the warp 2 barrier was broken, it became possible to upgrade older starships, such as the Y-class freighters, with a warp three engine. (ENT: "Fortunate Son") Freighters used by the Federation still remained limited to the speed of warp 2, even as late as the 2260s. (TOS: "Friday's Child") In the 2360s, subspace resonators used by Starfleet could be modified to function as warp cores, though ships using them were limited to warp 2. (TNG: "The Next Phase")