In general, God has allowed suffering to remind us that we need to adhere to His laws. The other reason for suffering is as a punishment for those who have violated Gods laws. Ultimately, suffering is a test of our faith in God and we must endure it with patience and appreciation for those who are suffering even greater trials.