Derivation of 2nd law of Thermodynamics from ergodicity assumption In Wikipedia it is claimed that:

Assumption of the ergodic hypothesis allows proof that certain types of perpetual motion machines of the second kind are impossible.

Since perpetual motion machines are machines which would violate the 2nd law, shouldn't it then from this be possible to derive the 2nd law from the ergodic hypothesis?
 A: Ergodicity is also compatible with violations of the second law of thermodynamics, because of the simple reason that if $T_t$ is an ergodic time-evolution which is invertible, then also $T_{-t}$ is ergodic. But obviously, if one of them leads to an increase in entropy, the other one violates the second law. Therefore, as said correctly in a comment above, an assumption about (typical) initial values is also necessary.
By the way, the second law of thermodynamics cannot be proven strictly since it holds only effectively, and not as necessarily as other physical laws. 
Ergodicity is usually used as a reason for the applicability of equilibrium thermodynamics, this is its main application (although it is not necessary for it and probably does not hold for real physics in a strict sense).
A: Ergodicity is a property used to allow the use of ensemble averages in place of time averages. As such, it is only indirectly related to the second law. 
In order to provide a statement equivalent to 2nd law, statistical mechanics has to show that the relevant fundamental equation (entropy, Helmholtz free energy, grand potential,..) has got the correct convexity properties. For instance, entropy per particle  must be a concave function of its natural variables (energy per particle , volume per particle). Assuming the  ergodic hypothesis, statistical mechanics can prove existence and the right convexity of the entropy per particle, under a few general conditions on the interactions and under the condition of dealing with an infinite system (the so called thermodynamic limit). These last conditions are necessary to ensure that the statistical behavior of a mechanical system would reproduce the macroscopic thermodynamics, including the second law..
There is no observable (no function of the microstate) which can be used to define the entropy of a single configuration. Whatever approach can be used, it turns out that entropy depends on all the microstates. So, neither the reversibility of dynamics nor the initial condition is really an issue. 
