After the janissaries had been defeated on the Rumelian front, they marched on Istanbul in 1687 to depose Mehmed IV.
[1] The latter appointed Yeğen Osman Aga, a self-made sekban commander, to hold the janissaries in check.
[1] His successor, Suleyman II, continued the policy of his predecessor, making Yeğen Osman governor-general of Rumelia.
When this happened, the incumbent grand vizier outlawed the sekban corps, threatening soldiers who proved unwilling to disperse with execution, and a civil war ensued.
[1] The sekban gained the upper hand, but a further volte-face of the Ottoman central administration saw Yeğen Osman captured and executed.