Ujjain, also known historically as "Ujjaiyini" and "Avanti", emerged as the first major centre in the Malwa region during India's second wave of urbanisation in the 7th century BC (the first wave was the Indus Valley Civilization). Around 600 BC an earthen rampart was built around Ujjain, enclosing a city of considerable size. Ujjain was the capital city of the Avanti kingdom, one of the prominent mahajanapadas of ancient India. In the post-Mahabharata period—around 500 BC—Avanti was an important kingdom in western India; it was ruled by the Haihayas, a people who were responsible for the destruction of Naga power in western India.