Bobcares

How to Change Pool Master in XenServer?

by | Oct 30, 2024

How to change the pool master in XenServer? To find out more about the steps, see this article. Bobcares, as a part of our Server Management Service offers solutions to every query that comes our way.

Overview
  1. How to Change the Pool Master in XenServer?
  2. Why Change the Pool Master?
  3. Preparing for the Pool Master Change
  4. How to Change the Pool Master?
  5. Changing the Pool Master When the Current Master Is Down
  6. Changing the Pool Master via XenServer Console
  7. Best Practices
  8. Conclusion

How to Change the Pool Master in XenServer?

In XenServer and XCP-ng environments, a pool consists of multiple servers (or hosts) with one designated as the pool master. This master server manages essential tasks like resource allocation, networking, and storage for the entire pool. Occasionally, situations arise where we may need to reassign the pool master. This article will guide us through understanding why, when, and how to change the pool master in a simple, actionable way.

xenserver change pool master

Why Change the Pool Master?

There are several common reasons to change the pool master:

1. Planned Maintenance: When performing updates or replacing hardware on the current master, it’s often necessary to reassign the pool master role temporarily.

2. Master Failure: If the pool master fails or becomes unresponsive, reassigning the master to another host ensures continuous pool operation.

3. Resource Optimization: Shifting the pool master role to a less busy server can help balance resources within the pool.

4. Pool Reconfiguration: Adding or removing hosts may require a master reassignment to keep the pool organized and efficient.

Preparing for the Pool Master Change

Before we begin, keep these important considerations in mind:

1. Pool Master Responsibilities: The pool master is the central server managing all other hosts (often called slaves). Ensure the new pool master has enough resources and is stable to handle these responsibilities.

2. Host and Version Compatibility: All hosts should run the same version of XenServer or XCP-ng with identical patch levels to avoid compatibility issues.

3. Backup Configurations: Backing up the pool’s configuration ensures that we can restore settings in case of errors during the pool master transition.

4. Verify Network and Storage Access: Make sure the new pool master has access to all necessary shared resources, such as storage repositories (SRs) and virtual networks.

How to Change the Pool Master?

If the current pool master is operational, follow these steps for a smooth transition:

1. Log in to the Current Pool Master by using XenCenter (for Citrix XenServer) or Xen Orchestra (for XCP-ng) to access the current pool master, or SSH directly from a terminal.

2. Run the following command to list hosts in the pool and find the UUID (Universally Unique Identifier) of the host we want to assign as the new master:

xe host-list

3. Now, promote the selected host by running this command on the current pool master:

xe pool-designate-new-master host-uuid=<new-master-uuid>

Replace <new-master-uuid> with the UUID of the chosen host.

4. After the change, confirm it by running:

xe pool-list

The new master’s UUID should now be displayed as the master.

5. Run this command to check that all hosts in the pool are functioning correctly:

xe host-list

Changing the Pool Master When the Current Master Is Down

If the pool master is down or unresponsive, follow these steps to restore operations:

1. Use SSH or the console to log in to one of the slave hosts in the pool.

2. On the slave host, use this command to list all hosts and their UUIDs:

xe host-list

3. Run the following command on the slave host to promote it as the new pool master:

xe pool-emergency-transition-to-master

4. On each slave, use this command to reattach it to the new pool master:

xe pool-recover-slaves

5. Confirm the pool master change and check that all hosts are reattached correctly:

xe pool-list
xe host-list

Changing the Pool Master via XenServer Console

If we’re using the XenServer console, follow these simple steps:

1. Log in to any server in the pool.

2. Open the console by typing xsconsole.

3. Go to Resource Pool Configuration.

4. Select Designate a New Pool Master.

5. Choose the host to make the master and press Enter.

6. Confirm the choice by pressing F8.

Reconnect to the pool with the new pool master, and the transition should be complete.

Best Practices

  • With high-availability (HA) enabled, the pool can automatically elect a new pool master in case of failure. HA can be configured using XenCenter or by setting up heartbeat storage and fencing policies.
  • Track the pool master’s resource usage with tools like XenCenter or Xen Orchestra to ensure it has enough resources to handle management tasks.
  • Keep all hosts updated to the same XenServer or XCP-ng version and patch level. Mismatches can cause operational issues, especially during master migration.

Troubleshooting Pool Master Change Issues

If problems arise during the pool master change, try these troubleshooting steps:

  • Make sure all hosts can communicate and check firewall settings or network interfaces for misconfigurations.
  • Confirm that all hosts are running compatible versions of XenServer/XCP-ng with the same patch level.
  • If a slave remains disconnected, try rebooting it or check its logs for issues. Key logs include:
XAPI logs: /var/log/xensource.log




Pool logs: /var/log/xe-pool.log

[Searching solution for a different question? We’re happy to help.]

Conclusion

By following these steps from our Experts and keeping the XenServer environment in sync, we can ensure smooth and reliable pool master transitions. With regular monitoring and best practices in place, managing a XenServer pool can become a hassle-free task, allowing us to focus on optimizing and expanding the virtual environment effectively.

0 Comments

Submit a Comment

Your email address will not be published. Required fields are marked *

Never again lose customers to poor
server speed! Let us help you.

Privacy Preference Center

Necessary

Necessary cookies help make a website usable by enabling basic functions like page navigation and access to secure areas of the website. The website cannot function properly without these cookies.

PHPSESSID - Preserves user session state across page requests.

gdpr[consent_types] - Used to store user consents.

gdpr[allowed_cookies] - Used to store user allowed cookies.

PHPSESSID, gdpr[consent_types], gdpr[allowed_cookies]
PHPSESSID
WHMCSpKDlPzh2chML

Statistics

Statistic cookies help website owners to understand how visitors interact with websites by collecting and reporting information anonymously.

_ga - Preserves user session state across page requests.

_gat - Used by Google Analytics to throttle request rate

_gid - Registers a unique ID that is used to generate statistical data on how you use the website.

smartlookCookie - Used to collect user device and location information of the site visitors to improve the websites User Experience.

_ga, _gat, _gid
_ga, _gat, _gid
smartlookCookie
_clck, _clsk, CLID, ANONCHK, MR, MUID, SM

Marketing

Marketing cookies are used to track visitors across websites. The intention is to display ads that are relevant and engaging for the individual user and thereby more valuable for publishers and third party advertisers.

IDE - Used by Google DoubleClick to register and report the website user's actions after viewing or clicking one of the advertiser's ads with the purpose of measuring the efficacy of an ad and to present targeted ads to the user.

test_cookie - Used to check if the user's browser supports cookies.

1P_JAR - Google cookie. These cookies are used to collect website statistics and track conversion rates.

NID - Registers a unique ID that identifies a returning user's device. The ID is used for serving ads that are most relevant to the user.

DV - Google ad personalisation

_reb2bgeo - The visitor's geographical location

_reb2bloaded - Whether or not the script loaded for the visitor

_reb2bref - The referring URL for the visit

_reb2bsessionID - The visitor's RB2B session ID

_reb2buid - The visitor's RB2B user ID

IDE, test_cookie, 1P_JAR, NID, DV, NID
IDE, test_cookie
1P_JAR, NID, DV
NID
hblid
_reb2bgeo, _reb2bloaded, _reb2bref, _reb2bsessionID, _reb2buid

Security

These are essential site cookies, used by the google reCAPTCHA. These cookies use an unique identifier to verify if a visitor is human or a bot.

SID, APISID, HSID, NID, PREF
SID, APISID, HSID, NID, PREF