Monitoring Console: Reference to LM in other NS breaks MC

Open
#1,886 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
3/5
Estimated time
1-2 days
Newbie friendliness
55/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Active
Tech stack
go, kubernetes
Domain
backend

Research direction

Start by tracing how MonitoringConsole handles licenseManagerRef and adds the LicenseManager as a monitored resource, then inspect the cross-namespace reference validation and credential setup. Reproduce with the two instances in separate namespaces and different passwords; done means the MonitoringConsole starts successfully or the reference is rejected with a clear validation error.

Written by the indexing model from the issue text.

Description

monitoring console
Please select the type of request

Bug

Tell us more

Describe the request
Although documentation and CRDs differ in specification, apparently the monitoringConsoleRef is not supposed to link resources from other namespaces.
However, when a MonitoringConsole receives a licenseManagerRef, it adds the LicenseManager as monitored resource. When both instances are deployed within different namespaces and do not share a password, the MonitoringConsole will no longer be able to start, as it tries to authenticate to the LicenseManager with it's local, non-matching password.

FAILED - RETRYING: [localhost]: Set search peers (44 retries left).Result was: {                                                                                                                                                                                                                  
    "attempts": 17,                                                                                                                                                                                                                                                                               
    "changed": false,                                                                                                                                                                                                                                                                             
    "cmd": [                                                                                                                                                                                                                                                                                      
        "/opt/splunk/bin/splunk",                                                                                                                                                                                                                                                                 
        "add",                                                                                                                                                                                                                                                                                    
        "search-server",                                                                                                                                                                                                                                                                          
        "https://splunk-shared-license-manager-service.splunk-shared.svc.cluster.local:8089",                                                                                                                                                                                                     
        "-auth",                                                                                                                                                                                                                                                                                  
        "admin:<MC Password>",                                                                                                                                                                                                                                                         
        "-remoteUsername",                                                                                                                                                                                                                                                                        
        "admin",                                                                                                                                                                                                                                                                                  
        "-remotePassword",                                                                                                                                                                                                                                                                        
        "<MC Password>"                                                                                                                                                                                                                                                                
    [],                                                                                                                                                                                                                                                                                           
    "delta": "0:00:01.093771",                                                                                                                                                                                                                                                                    
    "end": "2026-10-27 22:37:22.047758",                                                                                                                                                                                                                                                          
    "failed_when_result": true,                                                                                                                                                                                                                                                                   
    "invocation": {                                                                                                                                                                                                                                                                               
        "module_args": {                                                                                                                                                                                                                                                                          
            "_raw_params": "/opt/splunk/bin/splunk add search-server https://splunk-shared-license-manager-service.splunk-shared.svc.cluster.local:8089 -auth admin:<MC Password> -remoteUsername admin -remotePassword <MC Password>",                                     
            "_uses_shell": false,                                                                                                                                                                                                                                                                 
            "argv": null,                                                                                                                                                                                                                                                                         
            "chdir": null,                                                                                                                                                                                                                                                                        
            "creates": null,                                                                                                                                                                                                                                                                      
            "executable": null,                                                                                                                                                                                                                                                                   
            "expand_argument_vars": true,                                                                                                                                                                                                                                                         
            "removes": null,                                                                                                                                                                                                                                                                      
            "stdin": null,                                                                                                                                                                                                                                                                        
            "stdin_add_newline": true,                                                                                                                                                                                                                                                            
            "strip_empty_ends": true                                                                                                                                                                                                                                                              
        }                                                                                                                                                                                                                                                                                         
    },                                                                                                                                                                                                                                                                                            
    "rc": 24,                                                                                                                                                                                                                                                                                     
    "retries": 61,                                                                                                                                                                                                                                                                                
    "start": "2026-10-27 22:37:20.953987"                                                                                                                                                                                                                                                         
}                                                              

STDERR:                                                                                                                                                                                                                                                                                           
                                                                                                                                                                                                                                                                                                  
WARNING: Server Certificate Hostname Validation is disabled. Please see server.conf/[sslConfig]/cliVerifyServerName for details.                                                                                                                                                                  
                                                                                                                                                                                                                                                                                                  
An error occurred:                                                                                                                                                                                                                                                                                
Status 401 while sending public key to search peer https://splunk-shared-license-manager-service.splunk-shared.svc.cluster.local:8089: Unauthorized                                                                                                                                               
                                                                                                                                                                                                                                                                                                  
                                                                                                                                                                                                                                                                                                  
MSG:                                                                                                                                                                                                                                                                                              
                                                                                                                                                                                                                                                                                                  
non-zero return code                        

Expected behavior
The value for remotePassword should be the password of the namespace that holds the LicenseManager, not the local password of the namespace with the MonitoringConsole.

Splunk setup on K8S
See reproduction steps.

Reproduction/Testing steps

  • Create two namespaces and setup a shared pass4SymmKey (to enable licenseManagerRef to other namespace)
  • Namespace secrets must not specify a shared password
  • Deploy LicenseManager in one namespace, no monitoringConsoleRef required
  • Deploy MonitoringConsole in other namespace with licenseManagerRef to LicenseManager in first namespace

K8s environment
SOK 3.2.0
k8s v1.36.5

Proposed changes(optional)
Either use the correct password or don't automatically setup monitoring of the referenced LM.

Dominant language
Go
Stars
260
Forks
134
PR merge metrics
No merged PRs in 30d

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from splunk/splunk-operator

All issues in splunk/splunk-operator

Similar issues

More Go issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.