Magnetisation of a degenerate electron gas in a weak field?

So I am looking at Landau's and Lifshitz's "Statistical Physics, Part I" chapter on degenerate fermi gases and specifically at chapter on Pauli's Mangetism or magnetism of degenerate electron gases, §59. And I don't quite understand the first step. They claim: $$\mathbf M = - \frac{\partial \Omega}{\partial \mathbf H}$$

Where $\Omega$ is grand thermodynamic potential and $M$ is magnetic moment. In fact I know I have seen this before, I saw expression $$\mathbf M = - \frac{\partial F}{\partial \mathbf H}$$ Where $F$ is free energy. So I imagine the two expressions kinda mean the same thing but the first one is for a grand canonical ensemble the other is for canonical ensemble. So the idea is that you can obtain magnetisation from thermodynamical potentials. But why? Where do this expressions come from? How are they still valid for a degenerate electron gas? How do I derive them?