But Abbasgulu Bakikhanov states that he wished to rule Shirvan as vassal of Safavids therefore sent his son Burhan Ali Mirza to court of shah, but failed to be successful in his rebellion.
In 1709, when the Hotaki dynasty rose to power in Kandahar and defeated the Persian Safavids, Bamyan was under the Mughal Empire until Ahmad Shah Durrani made it become part of his new Durrani Empire, which became to what is now the modern state of Afghanistan.
Although in 1555 the Ottomans and Safavids signed the Treaty of Zuhab (or Qasr’i Shirin) in 1639, a peace accord based on accepting the legitimacy of each other's empires, in 1732 Nadir Shah launched a new initiative to reconquer Iraq, leading to four separate invasions between 1732 and 1743.
Both Hasan and Ahmad rendered a valuable service to the Ottoman Porte by curbing the unruly tribes and securing a steady inflow of taxes to the treasury in Constantinople as well as by defending Iraq against yet another military threat from the Safavids of Iran.