Wang Mang, an ambitious court official, seized power from the Western Han in 9 AD and took over the capital city of Chang'an. The House of Han was briefly deposed as Wang Mang ruled the Xin dynasty, but in 220 AD the Han dynasty overthrew Wang Mang and restored the Han. This new dynasty reigned from the cities of Chang'an and Luoyang, and the empire stretched from the Gobi Desert to the north, North Korea and the East China Sea to the east, Vietnam to the south, and Sichuan to the west. Ruled by the descendants of Liu Bang, the Later Han dynasty was one of military power. They crushed Trung Trac and Trung Ni's revolt in Vietnam, which prevented northern Vietnam from becoming independent, and they also fought several punitive campaigns against the Xiongnu and Xianbei to the north. Barbarians remained a persistent threat, but the real threat came from within.In 184 AD, the Yellow Turban Rebellion broke out in northern China as peasants rallied around the "Way of Peace" movement of Zhang Jiao. The warlords of the land rallied around the noble Cao Cao and crushed the rebellion, but the land devolved into chaos as the Ten Eunuchs and Dong Zhuo seized power in the late 180s. Cao Cao, an ambitious ruler, combatted these ambitious warlords, winning his greatest victory at the Battle of Guandu in 200 AD. He was appointed as the regent of the Han, but he still faced opposition from Sun Quan of Yang Province and Liu Bei of Jing Province to the south. His army of 800,000 troops was defeated by the two warlords at the Battle of Chibi in 208, preventing them from being subdued. These three warlords vied for control of China at the head of their own lands, but it was not until 220 that the Later Han fell when Cao Cao's son Cao Pi forced Liu Xie to abdicate and founded Cao Wei.