A cation is a positively charged atom. The number of protons and electrons in an atom are equal keeping it electrically neutral. But when an atom loses one or more electrons, the atom will have more positively charged particles called protons than the negatively charged particles called electrons, and this atom is then called a cation.
An anion is similarly a negatively charged atom with more electrons than protons.
Trenchlesspedia Explains Cation
When a pipeline begins to corrode, the metallic atoms at the anode oxidize to cations and leave the metal surface to the surrounding environment. These cations form oxides, hydroxides and carbonates in the form of a film or corrosion product. As the cation leaves the metal surface, it leaves behind electrons which are consumed by the reduction reaction at cathode.
This transfer of electrons can be used for electrochemical monitoring methods in which the anode and cathode are physically separated and sensitive instruments are used to measure the flow of current between them.