Israel closed a major crossing into Gaza for humanitarian aid after Hamas fired rockets towards the border, causing a setback for relief efforts as famine spreads in Gaza.