iterator for hosts