You move both gears into place at the very beginning. You then break the platform on the left, right at the end of the stairs that is blocking the waters path. You then use your magnetic boots to activate two pads right behind you were you broke the platform.
Jump up on the ledge were the three movable pegs are at. Use your fist to break the debris that is blocking the gear on the right side. Then from left to right, move the pegs one by one until all three are locked into place.
Lastly, you jump down right in the middle were there are small channels for the water to flow. You then use your jet boots to ignite the water. Kill the enemies that spawn, then exit the level