Transaction-protect setInstanceUnavailable, log counter updates.