Devarim / Deuteronomy 3:11 · Drash
כִּי רַק־עוֹג מֶלֶךְ הַבָּשָׁן נִשְׁאַר מִיֶּתֶר הָרְפָאִים הִנֵּה עַרְשׂוֹ עֶרֶשׂ בַּרְזֶל הֲלֹה הִוא בְּרַבַּת בְּנֵי עַמּוֹן תֵּשַׁע אַמּוֹת אָרְכָּהּ וְאַרְבַּע אַמּוֹת רָחְבָּהּ בְּאַמַּת־אִישׁ׃
For only Og king of the Bashan was left of the remnant of the Refaim. Behold, his bed was a bed of iron. Is it not in Rabbah of the children of Ammon? Nine cubits was its length and four cubits its breadth, by the cubit of a man.
Drash דְּרָשׁ
Survivor of the flood
Legends are told about giants. The midrash explains where Og came from if the flood wiped out all life, and why he is called "the fugitive".
Pirkei DeRabbi Eliezer: in the flood Og sat on a rung of the ark and swore to Noach (Noah) to be his slave forever. Noach made a hole and passed him food every day, and so Og "remained". Midrash Aggadah: "only" (רַק) diminishes: Og was lower and worse than all the Rephaim of his time. He was called "the fugitive" because he was not counted as their equal.
How Pirkei DeRabbi Eliezer and Midrash Aggadah explain it
Pirkei DeRabbi Eliezer "For only Og king of Bashan remained" (Devarim / Deuteronomy 3:11)
And all that existed on the earth was wiped out, as it is said: "And He wiped out all that existed on the face of the ground", except Noach and all who were with him in the ark, as it is said: "And only Noach remained, and those with him in the ark" (Bereshit / Genesis 7:23). And except Og king of Bashan, who sat on one of the rungs of the ark and swore to Noach and his sons that he would be their slave forever. What did Noach do? He made a hole in the ark and passed him his food every day. And he too remained, as it is said: "For only Og king of Bashan" and so on. And except the Land of Israel, on which no rain fell, as it is said: "Son of man, say to her: you are a land not cleansed, not rained upon in the day of wrath" (Yechezkel / Ezekiel 22:24). And the waters rolled down from all the lands and came into it.
Midrash Aggadah For only Og king of Bashan
Wherever "only" (רַק) is said, it diminishes. Because Og was lower and worse than all the Rephaim of his days. And he remained of the remnant of the Rephaim, of those whom Amraphel and his allies killed, as it is said: "And they struck the Rephaim in Ashterot-Karnaim" (Bereshit / Genesis 14:5). And of him it is said: "And the fugitive came and told Avram the Hebrew" (Bereshit / Genesis 14:13), and this was Og. And why was he called "the fugitive" (פָּלִיט)? Because he was not counted like the other Rephaim. As in the baraita we learned: "fugitive (פְּלִיטֵי) olives", those not fully cooked.
Takeaway
The Rephaim were an ancient people of giants who lived in Canaan and east of the Jordan (Devarim / Deuteronomy 2:11, 2:20).
Amraphel and three other kings made war on five kings by the Dead Sea. The fugitive came to tell Avram that Lot had been taken captive (Bereshit / Genesis 14:1–13).
A baraita is a teaching of the sages of the Mishnah that was not included in the Mishnah itself.