Why should Egypt or Iran take them in? Their homeland is in Palestine and territory claimed by Israel. This is like saying after the US conquered the homelands of native tribes that Mexico and Canada should have felt obligated to accept the displaced people. The premise you offer is absurd.
Gaza is a microcosm of the old adage that if trade cannot cross borders, armies will. Let Gaza be truly independent. Let them have ports and trade. When people can build real prosperity, the appeal of mindless violence diminishes. Half the population is under 18, so we could be only a generation away from peaceful coexistence if people are no longer given reasons for hate and fear.
RE: How big is Israel's military really? Hint: Wikipedia is WRONG!