  We develop a thermodynamical model of fermionic dark matter halos at finite
temperature. Statistical equilibrium states may be justified by a process of
violent collisionless relaxation in the sense of Lynden-Bell or from a
collisional relaxation of nongravitational origin if the fermions are
self-interacting. The most probable state (maximum entropy state) generically
has a "core-halo" structure with a quantum core (fermion ball) surrounded by an
isothermal atmosphere. The quantum core is equivalent to a polytrope of index
$n=3/2$. The Pauli exclusion principle creates a quantum pressure that prevents
gravitational collapse and solves the core-cusp problem of the cold dark matter
model. The isothermal atmosphere (which is similar to the NFW profile of cold
dark matter) accounts for the flat rotation curves of the galaxies at large
distances. We numerically solve the equation of hydrostatic equilibrium with
the Fermi-Dirac equation of state and determine the density profiles and
rotation curves of fermionic dark matter halos.
