How can a good God ordain evil? John Frame has an interesting way to look at the problem:
I borrowed the Shakespeare/Macbeth illustration from Wayne Grudem’s excellent Systematic Theology. But I do disagree with Grudem on one point. He says that we could say that either Macbeth or Shakespeare “killed King Duncan.” I agree, of course, that both Macbeth and Shakespeare are responsible, at different levels of reality, for the death of Duncan. But as I analyze the language we typically use in such contexts, it seems clear to me that we would not normally say that Shakespeare killed Duncan. Shakespeare wrote the murder into his play. But the murder took place in the world of the play, not the real world of the author. Macbeth did it, not Shakespeare. We sense the rightness of the poetic justice brought against Macbeth for his crime. But we would certainly consider it very unjust if Shakespeare were tried and put to death for killing Duncan. And no one suggests that there is any problem in reconciling Shakespeare’s benevolence with his omnipotence over the world of the drama. Indeed, there is reason for us to praise Shakespeare for raising up this character, Macbeth, to show us the consequences of sin.
The difference between levels, then, may have moral significance as well as metaphysical. It may illumine why the biblical writers, who do not hesitate to say that God brings about sin and evil, are not tempted to accuse him of wrongdoing. The relation between God and ourselves, of course, is different in some respects from that between an author and his characters. Most significantly: we are real; Macbeth is not. But between God and ourselves there is a vast difference in the kind of reality and in relative status. God is the absolute controller and authority, the most present fact of nature and history. He is the lawgiver, we the law receivers. He is the head of the covenant; we are the servants. He has devised the creation for his own glory; we seek his glory, rather than our own. He makes us as the potter makes pots, for his own purposes. Do these differences not put God in a different moral category as well?
The very transcendence of God plays a significant role in biblical responses to the problem of evil. Because God is who he is, the covenant Lord, he is not required to defend himself against charges of injustice. He is the judge, not we. Very often in Scripture, when something happens that calls God’s goodness in question, God pointedly refrains from explaining. Indeed, he often rebukes those human beings who question him. Job demanded an interview with God, so that he could ask God the reasons for his sufferings (23:1-7, 31:35-37). But when he met God, God asked the questions: “Brace yourself like a man; I will question you, and you shall answer me” (38:3). The questions mostly revealed Job’s ignorance about God’s creation: if Job doesn’t understand the ways of the animals, how can he presume to call God’s motives in question? He doesn’t even understand earthly things; how can he presume to debate heavenly things? God is not subject to the ignorant evaluations of his creatures.
(via)
Go read the rest and make sure to read the earlier posts as well.