 By 24 June 1659 Vyhovsky and his allies approached the area and defeated a small reconnaissance detachment of the invader's army near the village of Shapovalivka, several kilometers south-west of Konotop.According to the plan made that evening, the 30,000 Tatars were left in an ambush south-east of the river Sosnivka, and Vyhovsky's forces with Poles and mercenaries were positioned at the village of Sosnivka, south of the river with the same name.Meanwhile, Vyhovsky left the command of his forces to the brother of Hryhoriy Hulyanytsky, Stepan Hulyanytsky, and at the head of a small Cossack detachment left for Konotop.