Raise your memory limit up higher. Also, 18 minutes it should have been completed within that timeframe