Military history of the Three Kingdoms
By the time of the Three Kingdoms period the Xiongnu had already ceased to be a major power. Their last stand as a steppe empire was in 89 when Dou Xian led an army of 45,000 and decisively defeated them at the Battle of the Altai Mountains. The Xiongnu Empire was replaced by a loose confederation of disorganized Xianbei tribes, who were nonetheless highly aggressive and proved problematic to their southern neighbors. A southern branch of the Xiongnu split off from their northern neighbors in 50 AD and continued to exist as a Han puppet state in Bing Province. However, in 188 the Xiuchuge clan rebelled against their Chanyu, Qiangqu, for sending troops to aid the Han against the rebels Zhang Ju and Zhang Chun. They replaced Qiangqu with his son Yufuluo, who's hold on power was tenuous, and he was ousted over a marquis of the Xubu clan. When the marquis of Xubu died the next year an elderly king became the nominal head of state without the title of Chanyu and the Southern Xiongnu ceased to exist as a coherent entity. In 216 the Xiongnu of the Ordos were settled but the region remained outside the jurisdiction of Cao Wei's administration.
History of Mongolia
During the next century, as Chinese strength waned, border warfare between the Chinese and the Xiongnu was almost incessant. Gradually the nomads forced their way back into Gansu and the northern part of what is now China's Xinjiang. In about the middle of the 1st century AD, a revitalized Eastern Han dynasty (AD 25-220) slowly recovered these territories, driving the Xiongnu back into the Altai Mountains and the steppes north of the Gobi. During the late 1st century AD, having reestablished the administrative control over southern China and northern Vietnam that had been lost briefly at beginning of this same century, the Eastern Han made a concerted effort to reassert dominance over Inner Asia.
The concept of Mongolia as an independent power north of China is seen in the letter sent by Emperor Wen of Han to Laoshang Chanyu in 162 BC (recorded in the Hanshu):
The identity of the ethnic core of Xiongnu has been a subject of varied hypotheses and some scholars, including A.Luvsandendev, , Henry Howorth, Rashpuntsag, Alexey Okladnikov, Peter Pallas, Isaak Schmidt, Nikita Bichurin and Byambyn Rinchen, insisted on a Mongolic origin.