Meanwhile, the Egyptian amirs elected Jumanbay to the sultanate. According to Ibn lyas’s account Jurnanbay cuts a truly impressive figure. Already as al-Ghawri’s deputy during the fated Syrian campaign, he showed all the qualities of an ideal ruler. He is described as just, young (he was in his forties), energetic, brave, modest, and pious. As soon as he assumed the responsibility of government he did his utmost to maintain security in the capital and the countryside and to abolish the unjust and oppressive ways by which al-Ghawri had enriched himself. When it became confirmed that al-Ghawri had been killed, the grandees compelled the reluctant Tumanbay to accept the sultanate. He understood the seriousness of the situation: the Ottoman attack was imminent, the treasury was nearly empty, and the amirs’ loyalty was dubious. Tumanbay made his officers swear allegiance to him, and the ceremony was administered by the $ufi shaykh Abu’l-Su'ud al-Jarihi. The emirs pledged to restore the just regime of Qaytbay.
Tumanbay was installed as sultan under the regal name al-Malik al-Ashraf (like al-Ghawri, but also like Qaytbay, whose just rule Tumanbay tried to emulate). The ceremony was modest, since part of the regalia had been lost with Qansuh al-Ghawri. It was Ya'qub, Caliph al-Mutawakkil Ill’s father, a former caliph himself, who formally invested Tumanbay with the office and accepted his vow of allegiance {bay'a), in the name of his son, who was in captivity in Salim’s camp. The people of Cairo accepted their new sultan with jubilation. In a symbolic gesture, Tumanbay sat to dispense justice on the same couch used by Qaytbay and not on the mastaba where Qansuh al-Ghawri had sat. The sultan named new chief qadts, but unlike former sultans, did not take any money from them for the appointment; instead, he warned them against taking bribes. He ordered the flogging of advisors who suggested imposing unjust taxes on the markets and grain after he had abolished them.
Tumanbay reviewed his army and made appointments and promotions of officers and bureaucrats. He named al-Ghazali governor of the province of Damascus. He also reinstated the powerful Arab Bedouin shaykhs of the Banu Baqar clan as governors of the important province of al-Sharqiyya. He was compelled to do so, in spite of the family’s notorious turbulence, owing to the region’s economic and strategic importance as the gateway to Egypt from the north.
Tumanbay was desperate for additional manpower for the army, and had to look for it even in questionable places. He called up a great number of Bedouin, traditionally considered unreliable and undisciplined. Young city roughs (zu'ar) were encouraged to join, and even criminals in hiding were promised amnesty if they joined the army. Tumanbay wanted to enlist a thousand men from Cairo’s north African (MaghribI) community, but they refused, claiming that they were not accustomed to go with the army, and besides, they were ready to fight Franks, not Muslims.
The Mamluk high command belatedly realized the importance of firearms. In the short time available to him, Tumanbay focused his energy on providing his army with cannons and handguns. Following the example of Sultan al-Nasir Muhammad ibn Qaytbay (901-03/1496-98), a frivolous young man who nevertheless did the right thing, Tumanbay created a unit of black arquebusiers ("abid mftiyya). Some Maghribis and Turkomans were also included. As already indicated, it was inconceivable that mamluks should become infantrymen who carried handguns.
Like the young sultan, Tumanbay marched through Cairo followed by his new military unit. He also introduced wooden carriages pulled by oxen to carry the soldiers and their handguns, adopting an Ottoman technique observed by Ibn Tulun in Damascus. Ibn lyas saw a procession of too carriages, each carrying a copper cannon (mukhula) followed by 200 camels laden with gunpowder, lead, iron and other war materials. Turnanbay prepared for a long siege, and relied on artillery for defense. He ordered a long trench to be dug from Sabll 'Allan to al-Jabal al-Ahmar (the Red Mountain) and the Matariyya gardens to protect the heavy guns. He barricaded the positions with a fence; the sultan and his amirs themselves carried stones to finish it.
Meanwhile, Salim was pondering his options. Since the possibility of a Mamluk-Safavid alliance was temoved and his hold over Anatolia was firm, he had been in no hurry to carry his campaign into Egypt. Some advisors were apprehensive about the hardships of advancing the army through the Sinai desert with its hostile nomad population. Salim proposed to Tumanbay that he govern Egypt as his viceroy. In his letter, which he sent with a small delegation, Salim emphasized his own royal pedigree as opposed to Tuman-bay’s unknown origin, as a former imported slave. The proposal was rejected, and Salim’s emissary was ill-treated (according to Ottoman sources, he was put to death). It was then that the above-mentioned expedition to retake Gaza, which was defeated on December 22, was sent.
Salim therefore decided to proceed with his campaign. The Ottomans realized that Egypt was necessary to control Syria; there is also little doubt that Khayrbak’s advice contributed to Salim’s determination to conquet Egypt. The people of Egypt panicked and many of the inhabitants of Sharqiyya province fled to the capital. In Cairo itself the rich concealed their valuable fabrics and there was also talk of escaping to Upper Egypt. The fallahin refused to pay their taxes before it became clear who would be their ruler, to avoid paying twice.
After visiting the holy places in Jerusalem and Hebron, Salim led his army through Sinai. A few soldiers were murdered by Bedouin, but the main body of the army arrived without difficulty in Egypt, and on 28 Dhu ’l-Hijja/ January 22 the Ottoman vanguard reached Birkat al-Hajj, a few miles north of Cairo. Tumanbay wished to meet the Ottomans at al-Salihiyya, where the desert route entered the confines of the Delta, before they could provision and rest, but his amirs insisted on making a stand at the fortifications of al-Raydaniyya, immediately outside Cairo.
The battle of Raydaniyya, which sealed the fate of the Mamluk sultanate.
Was fought on 29 Dhu’l-Hijja 922/January 23, 1517. The Egyptian army, 20,000-strong by contemporary estimates, was defeated within twenty minutes. The heavy guns, on which Tumanbay invested so much effort, were utterly useless; an Ottoman force coming from the rear, from the direction of the Red Mountain, attacked his gunners (many of whom were European Christians - Franks - if the Ottoman sources are correct) and seized the cannons, which could not be rotated to fire in the opposite direction. Again, the handguns and light artillery of the Ottomans inflicted heavy casualties in the Egyptians’ ranks. The mamluks fought bravely, and Sinan Pasha himself was killed. Tumanbay with a handful of his mamluks and arquebusiers fought for a full eighty minutes until he too had to flee. On the next day, the last of the Muslim year, the khutba was recited for the Friday prayer in the name of Sultan Salim. He was called “the Breaker of the Two Armies and the Servitor of the Two Holy Sanctuaries” (khadim al-haramayn al-shari-fayn).
The Ottoman soldiers looted homes of amirs and other wealthy persons, and pillaged the granaries of old Cairo and Bulaq. They also abducted the mamluks’ male servants and black slaves. The looting continued for three days until an official proclamation promised security and peace, and Janissaries were stationed at the gates to enforce it. Yet a systematic manhunt for the Circassians (i. e. mamluks) started, and those captured were immediately put to death. Many Bedouin and HijazI Arab residents of Cairo were also executed and their severed heads were suspended from specially erected poles. Anyone of the mamluks’ sons, awlad al-nas, wearing the typical Mamluk headgear, the takhfifa or the red zamt, was put to death; so that they used the turban {‘imama) typical of ‘ulamd
In the days following the occupation many acts of killing (mainly mamluks, zu'ar, and Bedouins) took place, as well as the pillage and desecration of holy places. Like any other military occupation, the Ottoman conquest of Cairo was traumatic for its inhabitants. Ibn lyas compares it to the conquest of Egypt by Nebuchadnezzar in antiquity, who supposedly laid waste the whole country, and to the destruction of Baghdad by the Mongols in 1258, which symbolized a disaster of immense magnitude. While such comparisons are gross exaggerations, they reveal the chronicler’s attitude toward the Ottomans.
Sultan Salim preferred to camp at Bulaq on the bank of the river rather than stay in the Citadel. Tumanbay, who had gathered a force of mamluks and Bedouin, strengthened by the city toughs, made a sudden night attack (5 Muharram/January 28). The bloody streetfighting went on for four days and nights (on Friday, the khutba was even called in the name of Tumanbay), until Tumanbay was forced to flee again. Hundreds of captured mamluks and Bedouin were beheaded. The executioner, who allegedly was a European Christian or a Jew, separated the heads and threw the bodies into the Nile. In their pursuit of the mamluks and their allies, the Ottoman soldiers desecrated some of the holiest shrines and mosques of Cairo, such as the mosques of al-Azhar, al-Hakim and Ibn Tulun and the sepulchers of Sayyida Nafisa, al-Imam al-Shafi'i and al-Layth ibn Sa‘d. When the fighting was over, it was proclaimed that the mamluks would be given amnesty if they surrendered; some four hundred did so, and were instantly imprisoned. However, JanbirdI al-Ghazali was pardoned, on the assumption that he would henceforth cooperate. The Ottomans also put to death in the Alexandria prison the former sultan al-Zahir Qansuh (1498-99) fearing that the Mamluks might proclaim him their sultan.
Tumanbay gathered a force of mamluks and Bedouin at al-Bahnasa in Middle Egypt and sent a message to Salim offering to act as his deputy in Egypt. Salim dispatched a delegation consisting of the chief Egyptian qddls with a proposal of a treaty. Again, Tumanbay failed to control some of his hotheaded amirs, and one of them killed a qddl, a member of the delegation. Tumanbay’s third battle against the Ottomans took place at a place called Wardan or al-Munawat in the Giza desert on 10 Rabi' 1 9Z3/April 2, 1517. He was again defeated. The Ottomans executed 800 mamluks who had surrendered after obtaining a promise of quarter. At least 700 mamluks were chained, brought to Alexandria, and sent to Istanbul. After his defeat, Tumanbay escaped westward to Buhayra province, where he took refuge in the house of a Bedouin shaykh who was indebted to him. The Arab swore seven times on the Qur’an that he would not hand Tumanbay over to the Ottomans, but immediately broke his oath. The Mamluk sultan was hanged like a common criminal at Cairo’s Zuwayla Gate. The scene of Tumanbay’s execution, during which he proved his courage and piety, is touching. Salim had achieved his purpose; he scotched the rumors that Tumanbay was still at large.
Soon afterwards Salim declared his intention to return to his capital. Meanwhile, he spent his time visiting parts of Cairo and relaxing at the Nilometer (twityyiis),where he ordered a pavilion erected at the palace that had been built by al-GhawrI. Later, he left Cairo for fifteen days to visit Alexandria. Before departing, he prayed at al-Azhar and donated presents to mosques and Sufi centers. He also displayed his interest in the kiswa, the brocaded carpet covering of the Ka'ba, and the coverings of the Prophet’s tomb and Abraham’s tomb in Hebron.