mirror of
https://github.com/xcp-ng/xenadmin.git
synced 2024-11-23 20:36:33 +01:00
CA-338830: Pool join checks should not allow slave with enabled clustering to join.
Signed-off-by: Konstantina Chremmou <konstantina.chremmou@citrix.com>
This commit is contained in:
parent
8a478011d9
commit
fc9d617f27
9
XenModel/Messages.Designer.cs
generated
9
XenModel/Messages.Designer.cs
generated
@ -25411,6 +25411,15 @@ namespace XenAdmin {
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Looks up a localized string similar to Clustering is enabled on this server..
|
||||
/// </summary>
|
||||
public static string NEW_POOL_CLUSTERING_ENABLED {
|
||||
get {
|
||||
return ResourceManager.GetString("NEW_POOL_CLUSTERING_ENABLED", resourceCulture);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Looks up a localized string similar to You are attempting to add the server '{0}' to a pool with a master that is using an older CPU.
|
||||
///
|
||||
|
@ -8793,6 +8793,9 @@ You should only proceed if you have verified that these settings are correct.</v
|
||||
<data name="NEWNETWORK_VNAME" xml:space="preserve">
|
||||
<value>New Private Network</value>
|
||||
</data>
|
||||
<data name="NEW_POOL_CLUSTERING_ENABLED" xml:space="preserve">
|
||||
<value>Clustering is enabled on this server.</value>
|
||||
</data>
|
||||
<data name="NEWPOOL_DIFFERENT_HOMOGENEOUS_UPDATES_FROM_MASTER" xml:space="preserve">
|
||||
<value>This server has different updates from the master</value>
|
||||
</data>
|
||||
|
@ -71,6 +71,7 @@ namespace XenAdmin.Core
|
||||
NonCompatibleManagementInterface,
|
||||
WrongRoleOnMaster,
|
||||
WrongRoleOnSlave,
|
||||
HasClusteringEnabled,
|
||||
WrongNumberOfIpsCluster,
|
||||
WrongNumberOfIpsBond,
|
||||
NotConnected,
|
||||
@ -168,11 +169,11 @@ namespace XenAdmin.Core
|
||||
if (!Helpers.FeatureForbidden(slaveConnection, Host.RestrictManagementOnVLAN) && !HasCompatibleManagementInterface(slaveConnection))
|
||||
return Reason.NonCompatibleManagementInterface;
|
||||
|
||||
bool clusterHostInBond;
|
||||
if (!HasIpForClusterNetwork(masterConnection, slaveHost, out clusterHostInBond))
|
||||
{
|
||||
return clusterHostInBond ? Reason.WrongNumberOfIpsBond : Reason.WrongNumberOfIpsCluster;
|
||||
}
|
||||
if (slaveHost?.Connection?.Cache.Clusters.FirstOrDefault() != null)
|
||||
return Reason.HasClusteringEnabled;
|
||||
|
||||
if (!HasIpForClusterNetwork(masterConnection, slaveHost, out var clusterHostInBond))
|
||||
return clusterHostInBond ? Reason.WrongNumberOfIpsBond : Reason.WrongNumberOfIpsCluster;
|
||||
|
||||
return Reason.Allowed;
|
||||
}
|
||||
@ -235,6 +236,8 @@ namespace XenAdmin.Core
|
||||
return Messages.NEWPOOL_MASTER_ROLE;
|
||||
case Reason.WrongRoleOnSlave:
|
||||
return Messages.NEWPOOL_SLAVE_ROLE;
|
||||
case Reason.HasClusteringEnabled:
|
||||
return Messages.NEW_POOL_CLUSTERING_ENABLED;
|
||||
case Reason.WrongNumberOfIpsCluster:
|
||||
return Messages.NEWPOOL_IP_COUNT_CLUSTER;
|
||||
case Reason.WrongNumberOfIpsBond:
|
||||
|
Loading…
Reference in New Issue
Block a user