Smolensk is a port on the Dnieper River, an important rail junction, commercial, cultural and educational center. The name of the city most probably originates from the resin («smola» in Russian) that was extracted from the thick pine woods surrounding the town. By the end of the 9th century, Smolensk had turned into a large fortified settlement and became the capital of the Krivichi tribe. In the 13th century, Smolensk fell out of Kievan rule as it had been sacked by the Mongols. The westward expansion of the grand duchy of Moscow made Smolensk a target of a prolonged struggle between Moscow and Poland-Lithuania. More than once it passed from hand to hand. At last, it was given over to Russia by the Treaty of Andrusov (1667). This city, due to its important strategic location on the road to Moscow, played a considerable part in Patriotic War against Napoleon and World War II.