In 1815 he attended the Congress of Vienna, and was afterwards made adjutant-general to the emperor, with whom, as also with his successor Nicholas, he had great influence. By Nicholas he was created baron, and later count. In 1820 he had become chief of the general staff, and in 1825 he assisted in suppressing the Decembrist revolt.