From the outset, it was considered an important safety feature that ships were guided though the lock chambers by electric locomotives, known as mulas (mules, named after the animals traditionally used to pull barges), on the lock walls. These mules are used for side-to-side and braking control in the rather narrow locks (narrow relative to modern-day ships). Forward motion into and through the locks is actually provided by the ship's engines and not the mules'. A ship approaching the locks first pulls up to the guide wall, which is an extension of the centre wall of the locks, where she is taken under control by the mules on the wall before proceeding into the lock. As she moves forward, additional lines are taken to mules on the other wall. With large ships, there are two mules on each side at the bow, and two each side at the stern — eight in total, allowing for precise control of the ship.
The mules themselves run on rack tracks, to which they are geared. Each mule has a powerful winch, operated by the driver; these are used to take two cables in or pay them out, to keep the ship centred in the lock while moving it from chamber to chamber. With as little as 2 ft (60 cm) of space on each side of a ship, considerable skill is required on the part of the operators.
Smaller vessels, such as small tour boats and private yachts, are taken as handline transits, where mooring lines to the lock walls are handled manually by line handlers on the ship.
Read more about this topic: Panama Canal Locks