Set muc_restore_timeout to 0 = request the maximum available lines
muc_restore_timeout entry in the ACE
Screenshots attached (Gajim vs. MCabber)
Setting up muc_restore_timeout to 0 will make Gajim to request all the availanle lines that the server has kept
But, on the other hand, I'm not so sure, because if the server has kept 1,000,000 lines then it would be a problem, to say the least.