In 1447, Mäxmüd sent an army against Muscovy but was repelled. Another of Ulugh Muhammad's sons, Qasim Khan, fled to Moscow, where Vasily II granted him land that became the Qasim Khanate Both the khans Küchük Muhammad and Sayid Ahmad attempted to reassert authority over Moscow. Küchük Muhammad attacked Ryazan and suffered a major defeat against the forces of Vasily II. Sayid Ahmad continued to raid Muscovy and in 1449 made a direct attack on Moscow. However he was defeated by Muscovy's ally Qasim Khan. In 1450, Küchük Muhammad attacked Ryazan but was turned back by a combined Russo-Tatar army. In 1451, Sayid Ahmad tried to take Moscow again and failed.