Various bug fixes mostly related to Sage servers.