 In Ming China, the royal palace acquired eunuchs from both domestic and foreign sources.On the one hand, the eunuchs in Ming China come from the foreign supplies, the enemies of Ming China are castrated as a mean of punishment when they are captured by Ming army as prisoners.For example, the population of Mongol eunuchs in Nanjing increased significantly during Yongle's reign when there was a war between Ming China and the Mongols.