  We derive an explicit form of the quadratic in fermions Dirac action on the
M5 brane for an arbitrary on-shell background of 11D supergravity with
non-vanishing fluxes and in presence of a chiral 2-form on M5. This action may
be used to generalize the conditions for which the non-perturbative
superpotential can be generated in M/string theory. We also derive the Dirac
action with bulk fluxes on the M2 brane.
