Repository navigation
Description
Describe the bug
A clear and concise description of what the bug is.
After deploying, i see the invalid credentials error in the log
HTTP access denied: user 'default_user_HrdLmjryMbnYQFcLIur' - invalid credentials
The operator then cannot authenticate against the management API, resulting in Quorum Status: unavailable and repeated log warnings.
To Reproduce
Steps to reproduce the behavior:
-
Deploy a RabbitmqCluster with load_definitions pointing to a definitions JSON that defines its own users (without the operator's generated default user).
-
Observe logs:
HTTP access denied: user 'default_user_HrdLmjryMbnYQFcLIur' - invalid credentials -
kubectl describe rabbitmqcluster shows Quorum Status: unavailable.
Include any YAML or manifest necessary to reproduce the problem.
manifests:
- apiVersion: rabbitmq.com/v1beta1
kind: RabbitmqCluster
metadata:
name: rabbitmq
namespace: rabbitmq-system
spec:
replicas: 1
resources:
requests:
cpu: 600m
memory: 800Mi
limits:
cpu: 600m
memory: 800Mi
persistence:
storageClassName: standard
storage: 10Gi
rabbitmq:
additionalPlugins:
- rabbitmq_mqtt
- rabbitmq_prometheus
additionalConfig: |
vm_memory_high_watermark.absolute = 550MiB
mqtt.listeners.tcp.default = 1883
mqtt.allow_anonymous = false
collect_statistics_interval = 10000
load_definitions = /etc/rabbitmq/definitions
override:
statefulSet:
spec:
template:
spec:
containers:
- name: rabbitmq
volumeMounts:
- mountPath: /etc/rabbitmq/definitions/definitions.json
subPath: definitions.json
name: definitions
ports:
- containerPort: 1883
name: mqtt
protocol: TCP
volumes:
- name: definitions
secret:
secretName: rabbitmq-definitions
service:
spec:
ports:
- name: mqtt
port: 1883
targetPort: 1883
protocol: TCP
- apiVersion: policy/v1
kind: PodDisruptionBudget
metadata:
name: rabbitmq
namespace: rabbitmq-system
spec:
maxUnavailable: 1
selector:
matchLabels:
app.kubernetes.io/name: rabbitmq
- apiVersion: secrets.hashicorp.com/v1beta1
kind: VaultStaticSecret
metadata:
name: rabbitmq-user-definitions
namespace: rabbitmq-system
spec:
vaultAuthRef: rabbitmq-system/rabbitmq-system
mount: k8s/mount
type: kv-v2
path: rabbitmq-system/rabbitmq-server
refreshAfter: 5m
destination:
create: true
name: rabbitmq-definitions
overwrite: true
transformation:
excludeRaw: true
excludes:
- .*
templates:
definitions.json:
text: |
{
"vhosts": [
{
"name": "/"
}
],
"users": [
{
"name": "admin",
"password": "{{ "{{" }} .Secrets.admin {{ "}}" }}",
"tags": "administrator"
}
],
"permissions": [
{
"vhost": "/",
"user": "admin",
"read": ".*",
"write": ".*",
"configure": ".*"
}
],
}
rolloutRestartTargets:
- kind: StatefulSet
name: rabbitmq-server
- apiVersion: monitoring.coreos.com/v1
kind: ServiceMonitor
metadata:
name: rabbitmq
spec:
endpoints:
- port: prometheus
scheme: http
interval: 15s
scrapeTimeout: 14s
tlsConfig:
insecureSkipVerify: true
- port: prometheus
scheme: http
path: /metrics/detailed
params:
family:
- queue_coarse_metrics
- queue_metrics
interval: 15s
scrapeTimeout: 14s
selector:
matchLabels:
app.kubernetes.io/component: rabbitmq
namespaceSelector:
any: true
Expected behavior
A clear and concise description of what you expected to happen.
Quorum Status: ok
Screenshots
If applicable, add screenshots to help explain your problem.
Version and environment information
- RabbitMQ: RabbitMQ: 4.1.3 (Erlang 27.3.4.2)
- RabbitMQ Cluster Operator: [e.g. 1.1.0 or commit if building from source]
- Kubernetes: [e.g. 1.18.0] v1.33.8-gke.1026000 - Cloud provider or hardware configuration: GKE
Additional context
Add any other context about the problem here.
Activity
SachinMaharana commentedon Apr 10, 2026
even with the
addtionalConfig, i see the same issue.MirahImage commentedon Apr 10, 2026
Yes, the default user created by the operator will not work if you import definitions, it will be overwritten by the definitions, which means the checks will not function. This is documented in the example https://github.com/rabbitmq/cluster-operator/tree/main/docs/examples/import-definitions
MirahImage commentedon Apr 10, 2026
One option to work around this issue is to create your own default user both in the imported configuration as well as in a provided secret, following the example https://github.com/rabbitmq/cluster-operator/tree/main/docs/examples/external-admin-secret-credentials