For them the Lord loveth he chasteneth, and scourgeth every son whom he re-ceiveth. (Hebrews 12:6)
The word "chasten" is a bit misunderstood because it is interpreted as meaning punishment. Actually it is not that at all. It belongs in an altogether different category. It literally means child training. Our word today for it would be discipline. In other words, God does not have undisciplined children. He disciplines His own, and there are certain lessons He gets through to us by suffering.
Therefore we have this matter of discipline. The Judge punishes; the Father chastens. Punishment is for breaking the rules of the Father. God deals that way with His children. But when he chastises, or child trains, He is doing that in love. It does not have the same background as does punishment. However, this does not mean it is not severe and that it does not hurt.
It's rather like the old chestnut about the father who took his son out to the woodshed for a little discipline. But before the father whipped the boy, he sat down and wept. As he looked up at the child, he said, "Son, this hurts me more than it does you." And the son said, "Yes, Dad, but not in the same place.”"
Our heavenly Father, I'm confident, is not severe because He takes delight in disciplining us, but He does it for our benefit. Therefore, the writers of Scripture did not show us, as God's children, how to escape suffering but how to endure suffering. That is the most important thing. There is a worthy purpose and a productive goal to be gained in the chastening or the discipline of the Lord.
—From J. Vernon McGee's booklet "Why Do God's Children Suffer?"