TArchaeological findings suggest that settlers in the Red River Delta may have been among the first peoples in East and Southeast Asia to practice agriculture. By the end of the 2nd millennium bc, Vietnamese civilization had begun to enter the Bronze Age. The ancestors of the modern Vietnamese were one of many scattered communities that lived in what are now South China and northern Vietnam during the 1st millennium BC. According to local tradition, a line of hereditary kings governed over the ancient kingdom of Van Lang in the Red River Delta for thousands of years. Van Lang was conquered by Thuc Phan, who founded a small Vietnamese kingdom called Au Lac.
In the succeeding centuries a series of unsuccessful uprisings against Chinese rule followed. Finally in ad 939 Ngo Quyen took advantage of chaotic conditions in China and led a successful Vietnamese rebellion against the local occupation forces. In the early 11th century Ly Thai To founded the first of the great Vietnamese dynasties. Under the astute leadership of several dynamic rulers, the Ly dynasty governed Vietnam from 1010 to 1225.The rise of the new state, known as Dai Viet,reflected the emergence of a strong sense of Vietnamese national identity. The Ly rulers, found Chinese techniques useful in controlling and mobilizing their subjects; therefore they retained many of the political and social institutions that had been introduced during the long centuries of Chinese rule. For example, they adopted the Confucian civil service examination system, formalized in China during the 8th and 9th centuries, as a means of selecting government officials. This method of selection allowed talented individuals to rise to positions of power based on their abilities, not their political connections. At first, only members of the ruling aristocracy were authorized to compete in the examinations, but eventually the right was extended to most males. The Ly used the educational system to spread moral principles valued in China. Young Vietnamese who prepared for the examinations learned the Confucian classics and grew up conversant with the great figures and ideas that had shaped Chinese history.