Ibn Haldun spent his last 20 years at Egypt. The times he was in Egypt corresponds to the times of Sultan Berkuk and his son Ferec. These times contain the most tempestuous time of the Egyptian history. Sultan Berkuk started the reign of Circassian Sultans by putting an end to the reign of Turkish Mamluk Sultans at 1382. His son was only 11 years old when he was ascended to the throne so his son was not able to rule the country. At this reign Mamluk State was in a turmoil situation because of important cases such as economical depressions, struggles between commanders and also Timurid invasion on Syria. In this turmoil Ibn Haldun was living in Egypt and he found himself in these cases. Ibn Haldun raised and shined in a short time due to his intelligence and scientific level in a country where he was a foreigner and he particularly spent his time with sultans, commanders and scientists. He got high ranking positions such as müderris (formerly professor) and Maliki governor. He had conversations with Timur who was a great Turkish sovereign at the time. It is seen that there are people who like Ibn Haldun at Egypt as well as there are people who envy him. His often dismissals is a proof for that. Mamluk historians of the time admired him and gave information about his life at Egypt.
Ibn Haldun, Egypt, Mamluk State, Berkûk, Ferec, Timur