 He made himself virtually independent ruler of Azerbaijan by 1146.His marriage with the widow of Sultan Toghrul II (1132–1133; Masud's brother and predecessor) afforded him to intervene in the dynastic strife which erupted upon Mas'ud's death in 1152.He succeeded, in 1160, in deposing Suleiman-Shah and installing his stepson Arslan-Shah (1160–1175) as a Sultan.