And now, brothers, you must pay attention and listen carefullly to what I am going to lay out before you. Teach it to children and women so that any questions of belief they may have will be answered, so that the truth will become so firmly lodged in their souls that they cannot budge from it. And you, brothers, be strong and courageous, and be supported by these true verses.The Chofetz Chaim elaborates on this point:
Let not the strength of the enemy's hand and our own nations' weakness frighten you. For this entire situation is no more than a trial and a test so that you can demonstrate your belief and your chosenness to the world.
Before the coming of Moshiach, Hashem will act in a hurried manner so wondrous that even all who are wise of heart will be unable to fathom it. The troubles and persecutions [of the Jewish people] will follow each other so closely that there will be no space between them. Just as for an expectant woman who is about to give birth, the closer she comes to the moment of birth, the more intense her contractions and her pain, and this is her most reliable indication that the birth is nearing, so too, the wheels of the era will turn fast at the time of the birth pangs of Moshiach.Toward the end of the sixth millenium, the heavenly tribunal will wish to settle all accounts opened since the world's creation. Hashem will want to prepare His world for its new state, the state of redemption.
Rabbi Elchanan Wasserman states:
Since the world will be in a perfected, flawless state during the time of Moshiach, it is necessary for all old accounts to be settled in the period that precedes it. For piles of accounts have accumulated in heaven from the time of Creation to the present [ that is, sins that man has not yet rectified], and they must be put in order before Moshiach comes. IT is therefore the duty of every individual to pay what he still owes to heaven -- Ikvesa di Meshicha 18.
The Chessed l'Avaraham expounds:
All those who are stubborn and do not repent will perish. But anyone who bears the yoke of repentance and accepts the troubles without complaint, putting his shoulder to the task, will be purified and become worthy. HKBH, is an honest and perfectly just Judge, and there is no injustice. Therefore, He will refine the person time and time again until he is pure and clean silver. This process will be carried out by the strictest standards of judgment. In those days, one nation will pulverize another. Israel will be among them in great suffering. Each nation will want to shear this sheep and eat its meat. But HKBH will have mercy on His people through the merit of the three Avos and they will become purified and cleansed as a result of these troubles and this judgment.
Source: The Ishmaelite Exile