Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ClusterQuorum : not compatible with french OS #196

Open
OPT-ksarr opened this issue Dec 11, 2018 · 3 comments
Open

ClusterQuorum : not compatible with french OS #196

OPT-ksarr opened this issue Dec 11, 2018 · 3 comments
Labels
bug The issue is a bug. help wanted The issue is up for grabs for anyone in the community.

Comments

@OPT-ksarr
Copy link

OPT-ksarr commented Dec 11, 2018

Details of the scenario you tried and the problem that is occurring

Preparing 2 target nodes for installation of SQL server with AlwaysOn HA

Code executed:

           xClusterQuorum TemoinCluster 
           { 
                IsSingleInstance = 'Yes'
                Type = 'NodeAndFileShareMajority' 
                Resource = "\\server\myshare" 
                PsDscRunAsCredential = $DomainAdminCredential                
           }

Verbose logs showing the problem

La ressource DSC PowerShell MSFT_xClusterQuorum n'a pas pu exécuter la fonctionnalité Test-TargetResource. Message
d'erreur: Unknown quorum resource: Témoin de partage de fichiers
+ CategoryInfo : InvalidOperation : (:) [], CimException
+ FullyQualifiedErrorId : ProviderOperationExecutionFailure
+ PSComputerName : srv-sql1

Suggested solution to the issue

When I check the quorum resource type on target nodes, displayname show a value set in french language. But "Name" value is set in English

image

Solution:

  1. Just replace $getClusterQuorumResult.QuorumResource.ResourceType.DisplayName by $getClusterQuorumResult.QuorumResource.ResourceType.Name in the powershel block above
  2. Replace compared value by english value(Ex: 'File Share Quorum Witness' By 'File Share Witness')

I don't know if it is the solution for all OS language but I suppose its corrects numerous (German. SPain,Deutch,etc...)

This solution works in french OS (line with NodeAndFileShareMajority):

MSFT_xClusterQuorum.psm1:

        'Majority'
        {
            if ($null -eq $getClusterQuorumResult.QuorumResource)
            {
                $clusterQuorumType = 'NodeMajority'
            }
            elseif ($getClusterQuorumResult.QuorumResource.ResourceType.Name -eq 'Physical Disk')
            {
                $clusterQuorumType = 'NodeAndDiskMajority'
            }
            elseif ($getClusterQuorumResult.QuorumResource.ResourceType.Name -eq 'File Share Witness')
            {
                $clusterQuorumType = 'NodeAndFileShareMajority'
            }
            elseif ($getClusterQuorumResult.QuorumResource.ResourceType.Name -eq 'Cloud Witness')
            {
                $clusterQuorumType = 'NodeAndCloudMajority'
            }
            else
            {
                throw "Unknown quorum resource: $($getClusterQuorumResult.QuorumResource)"
            }
        }

The DSC configuration that is used to reproduce the issue (as detailed as possible)

Use default resource:

        'Majority'
        {
            if ($null -eq $getClusterQuorumResult.QuorumResource)
            {
                $clusterQuorumType = 'NodeMajority'
            }
            elseif ($getClusterQuorumResult.QuorumResource.ResourceType.DisplayName -eq 'Physical Disk')
            {
                $clusterQuorumType = 'NodeAndDiskMajority'
            }
            elseif ($getClusterQuorumResult.QuorumResource.ResourceType.DisplayName -eq 'File Share Quorum Witness')
            {
                $clusterQuorumType = 'NodeAndFileShareMajority'
            }
            elseif ($getClusterQuorumResult.QuorumResource.ResourceType.DisplayName -eq 'Cloud Witness')
            {
                $clusterQuorumType = 'NodeAndCloudMajority'
            }
            else
            {
                throw "Unknown quorum resource: $($getClusterQuorumResult.QuorumResource)"
            }
        }

The operating system the target node is running

OsName : Microsoft Windows Server 2016 Datacenter
OsOperatingSystemSKU : DatacenterServerEdition
OsArchitecture : 64 bits
WindowsBuildLabEx : 14393.2551.amd64fre.rs1_release.181004-1309
OsLanguage : fr-FR
OsMuiLanguages : {fr-FR}

Version and build of PowerShell the target node is running :

WMF 5.1

Version of the DSC module that was used ('dev' if using current dev branch) :

xFailOverCluster '1.11.0.0'

@stale
Copy link

stale bot commented Jan 10, 2019

This issue has been automatically marked as stale because it has not had activity from the community in the last 30 days. It will be closed if no further activity occurs within 10 days. If the issue is labelled with any of the work labels (e.g bug, enhancement, documentation, or tests) then the issue will not auto-close.

@stale stale bot added the stale The issue or pull request was marked as stale because there hasn't been activity from the community. label Jan 10, 2019
@reidav
Copy link

reidav commented Jan 23, 2019

Hi ksarr,

Thanks for your feedback, interesting one !
We need to reproduce this issue and have a PR with this update.

@johlju
Copy link
Member

johlju commented Jan 24, 2019

Labelling this as a bug.

@johlju johlju added bug The issue is a bug. help wanted The issue is up for grabs for anyone in the community. and removed stale The issue or pull request was marked as stale because there hasn't been activity from the community. labels Jan 24, 2019
@SteveL-MSFT SteveL-MSFT added this to Help Wanted in powershell/dscresources May 14, 2019
@SteveL-MSFT SteveL-MSFT removed this from Help Wanted in powershell/dscresources Nov 27, 2019
@johlju johlju changed the title xClusterQuorum : not compatible with french OS ClusterQuorum : not compatible with french OS Jun 11, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug The issue is a bug. help wanted The issue is up for grabs for anyone in the community.
Projects
None yet
Development

No branches or pull requests

3 participants