Egypt. On 25 August 1798, General Desaix embarked at the head of his division on a flotilla and sailed up the Nile. On 31 August, Desaix arrived at Beni Suef where he began to encounter supply problems, then he went up the Nile to Behneseh and progressed towards Minya. The Mamluks did not fight, and the flotilla returned on September 12 at the entrance of Bahr Yussef. Desaix learned that the Mamluks were in the plain of Faiyum by 24 September. The first contact between the two sides occurred on 3 October and a second minor fight took place, which began to deplete food and ammunition of the French forces. On 7 October, Mourad Bey's troops came out of Sédiman's entrenchments and attacked the French, who formed themselves into three squares, one large and two small at its angles. The Mamluks as previous encounters attacked furiously but were repulsed. The Mamluks attempted to use their four cannons, but a vigorous attack led by Captain Jean Rapp managed to capture them. After several hours of fighting, the French went on the offensive and the Mamluks fled southwards. Revolt of Cairo In 1798, Napoleon led the French army into Egypt, swiftly conquering Alexandria and Cairo. However, in October of that year, discontent against the French led to an uprising by the people of Cairo. While Bonaparte was in Old Cairo, the city's population began spreading weapons around to one another and fortifying strongpoints, especially at the Al-Azhar Mosque. A French commander, Dominique Dupuy, was killed by the revolting Cairenes, as well as Bonaparte's Aide-de-camp, Joseph Sulkowski. Excited by the sheikhs and imams, the local citizens swore by the Prophet to exterminate all and any Frenchman they met, and all Frenchmen they encountered – at home or in the streets – were mercilessly slaughtered. Crowds rallied at the city gates to keep out Bonaparte, who was repulsed and forced to take a detour to get in via the Boulaq gate. The French army's situation was critical – the British were threatening French control of Egypt after their victory at the Battle of the Nile, Murad Bey and his army were still in the field in Upper Egypt, and the generals Menou and Dugua were only just able to maintain control of Lower Egypt. The Ottoman peasants had common cause with those rising against the French in Cairo – the whole region was in