How does hydrogen gas build up in hot water lines? Recently I was reading through the owner's manual of a washing machine; notably, the warnings in the front of the booklet. One warning stood out to me; it said that if the hot water in your house has not been run in a few weeks $\ce{H2}$ can build up in your lines. The warning of course stated that this can only occur under certain circumstances so I'm assuming it is quite rare.

Okay, so my question is, under what conditions does hydrogen gas build up in a hot water line?
I think that it is probably due to a reaction between an acid and a metal. These reactions can lead to the formation of hydrogen following this generic forumula:
$$\ce{M + 2H+ -&gt; M^{2+} + H2}$$

For example iron could be a source of electrons. If you look at the corrosion of iron: $$\ce{Fe-&gt;Fe^{2+} + 2e^{-}}$$ 

At low pH (notice that there is a correlation between pH and temperature) hydrogen gas is formed:
$$\ce{2H^{+} +2e- -&gt; 2H2}$$