Why was Abraham so grieved about casting out Ishmael?
Abraham grieved because Ishmael was his son, whom he loved, yet Sarah demanded that the bondwoman and her son be cast out so Ishmael would not be heir with Isaac, the son of promise. God then told Abraham not to be grieved but to hearken to Sarah's voice.
The teaching explains that Isaac and Ishmael had to be separated. Sarah saw the son of Hagar the Egyptian mocking and told Abraham to cast out the bondwoman and her son, because the son of the bondwoman would not be heir with Isaac, the son of promise. Ishmael was of the flesh. Abraham loved Ishmael, but he still did not have the long-range concept of the Abrahamic covenant of a Messiah coming through his loins. God told Abraham not to be grieved because of the lad and the bondwoman, but to hearken to Sarah's voice.
And the thing was very grievous in Abraham’s sight because of his son.