-
Notifications
You must be signed in to change notification settings - Fork 107
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
SPSearchManagedProperty: Can't define Searchable #1288
Comments
I later noticed that I was missing TokenNormalization = $true from the configuration, which is required for a property to be searchable. However, adding that didn't change the issue. |
Hi @rurikon, just checked this issue and noticed that you specified "IncludeAllCrawledProperties = $false" in your config, but did not specify the CrawledProperties parameter. That is probably why the Test resource always returns false. Can you please share the full verbose logging for this resource? That will give me more information on what goes wrong at which point. |
I have left the CrawledProperties parameter out because of this issue: #1289 But I have also tried defining CrawledProperties and having IncludeAllCrawledProperties = $true, neither of those affect the error. If Searchable is defined, the Test-DscConfiguration doesn't even execute, it just dies with the error "Item has already been added. Key in dictionary: 'Searchable' Key being added: 'Searchable'". I included the full error in the "verbose logs" section above. If you want more, could you specify which ones you want? |
Here is a screenshot for further clarification. Do you want me to look at the Event Viewer for details? Now that I tested this again, I did notice that all properties don't give this error. The configurations are the same, though, except some are set as refinable or sortable and some are not, and it doesn't look like those settings play a role in this. And no, Searchable is not set twice, I was checking again and again when I first came across this. |
The "all properties don't give this error" in the last comment bothered me, so I investigated more. I went through every property we have in the configuration and changed the Searchable value individually for each. It looks like every time I try to set Searchable = $true, it gives that error, and Searchable = $false goes through just fine without error. |
Can you do another Test-DscConfiguration, but this time with the -Verbose parameter and share the outcome? Based on the verbose logging, I can see where the issue is thrown, which makes troubleshooting much easier ;-) |
Oh sorry, stupid me :) It doesn't give much more info, but here it is:
We had to work on the actual property to get our project forward, so I went to Central Administration and manually checked the "Searchable" checkbox for the TargetAudience I created before. It might be relevant that after I manually checked it, the error disappeared for that property, even though it still has Searchable = $true. Here are the verbose logs for that one:
|
Details of the scenario you tried and the problem that is occurring
I tried to add a search managed property. I wanted it to be searchable. This is the configuration I tried:
Running this goes smoothly, but trying Test-DscConfiguration will give an error (see below).
Without Searchable = $true there is no error in Test-DcsConfiguration, but still reports as "not in desired state". If I check Central Administration, the property has been created, but is not searchable.
Information from the node itself:
Verbose logs showing the problem
When running Test-DscConfiguration with Searchable = $true:
Suggested solution to the issue
N/A
The DSC configuration that is used to reproduce the issue (as detailed as possible)
See beginning.
The operating system the target node is running
N/A
Version and build of PowerShell the target node is running
PSVersion 5.1.14393.3866
BuildVersion 10.0.14393.3866
Version of the DSC module that was used
SharePointDSC 4.3.0
The text was updated successfully, but these errors were encountered: