The optically detected magnetic resonance (ODMR) technique has been employed to examine the nature and formation mechanism of non-radiative defects in GaNAs and InGaAsN. In both alloys, two defects were observed and were shown to be deep-level, non-radiative recombination centers. One of the defects has been identified as a complex involving an AsGa antisite. These two defects gain more importance with increasing N composition up to 3%, presumably due to an increase in their concentration. With a further higher N composition, the defects start to lose importance in carrier recombination that is attributed to an increasingly important role of other new non-radiative channels introduced with a high N composition. On the other hand, effect of In composition up to 3% seems to be only marginal. Both defects were shown to be preferably introduced in the alloys during low-temperature growth by molecular beam epitaxy (MBE), but can be rather efficiently removed by post-growth rapid thermal annealing.