God is not harsh; He is holy. He is not selfish; He is sovereign. He is not unfeeling; He is all-knowing. Like David, we need to come to know Him, and respect Him; and, like David, we will love Him more.
Peace comes in situations completely surrendered to the sovereign authority of Christ.
We must settle in our hearts that no matter what, God is sovereign.