We study the Einstein-Yang-Mills theory which has a classical solution of instanton-monopole configuration on an internalCPN space and leads to a four-dimensional effective gauge theory with an isometry groupSUN+1. We derive the generalized Dirac quantization condition in the presence of instanton monopole, so that the fermion is well accommodated in the isotropy group with a nontrivial representation associated with an instanton monopole. After harmonic expansions, we look for a chirally isolated fermion representation and derive a theorem to obtain a massless fermion. Several examples which satisfy the anomaly-free condition are studied. It is shown thatSO14 andSO18 gauge theories give spectra of generation numbers, 1, 3, 7, … and 1, 5, … of16L inSO10, respectively. We also study examples fromE8⊗E8 superstring theory.