When the king had settled into his palace and the Lord had given him rest on every side from all his enemies,