One of the big mysteries in life is why 'innocent' people suffer as a result of disasters including terrorist action. Even with the story of Job, many Christians believe that godly people will not get anything like cancer or face accidents, and whenever something like that happens, they begin to accuse victims that they must have some unconfessed sin in their lives, just as Job's friends thought! Job was the godliest man on earth at that time, and yet God allowed him to lose all his children and wealth on the same day, and immediately afterwards he came down with a terrible sickness! In his case the reason was that God was testing him, and he actually came out of the experience as a much humbler, purer person. In other cases it may be just that we are living on this earth which was cursed when our forefather Adam disobeyed God.
One mistake many Christians make is to think only of a comfortable life on earth and not so much of the eternal life that is to follow which will have no sorrow, sickness, pain or evil (Re.21:4). Because of this, they also attribute every evil that happens to us as related to some past sin. Even though God has forgiven our sins and accepted us as His children by grace through our faith (Ep.2:8,9), some people still think in terms of law and punishment. Sometimes they feel condemned when some calamity hits them thinking that God must be punishing them, and at other times they feel indignant against God for letting some evil come to them 'even though they have been such good people'!
When some people asked Jesus about why something evil had happened to some people in Lk.13:1-5 what He told them can be quite confusing if we don't have a proper perspective about our life on earth and the life to come afterwards. He said that those people who had 'perished' in those incidents were not greater sinners than the others. But then He warned the disciples that they would 'perish' if they did not repent. The first 'perish' referred to what happens on earth, but the second 'perish' referred to what would happen in eternity. For God, it is clear that eternal perishing is far more serious than what happens on earth.
Because of the presence of sin here on earth, many unpleasant, unrighteous, unfair, painful and ugly things happen here. Even though God is aware of what we are going through here (He.4:15), and He knows how frail we are (Ps.103:13,14), and even though He will step in whenever things tend to go beyond what He has permitted (1Co.10:13), His plan is not to eliminate all the difficulties and pain on the earth. Jesus said that in this world we would have much trouble (Jn.16:33). But as we have seen earlier, His plan is to provide us with an eternity full of pleasure (Ps.16:11).
When we have this perspective, it gives us meaning when we go through painful times here. When we go through trouble ourselves or see innocent people suffer, what comforts us is that there is an eternity coming (1Th.4:17,18).