亚马逊MSK未能将1秘密与集群相关联。提供的秘密有无效的模式
我们要设置。
- 我们在MSK中创建了一个群集,
- 也创建了一个秘密
Amazonmsk_testmsk2
,并用键为password
and值为{“ username”:“ alice”:“ alice”,“密码”,“密码” “:“ alice-secret”}
仍然是我们将秘密与MSK关联时,我们会得到错误 Amazon MSK无法将1与群集相关联。提供的秘密具有无效的模式
故障排除也没有太多帮助
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(5)
当未遵循创建密钥的一个或多个先决条件时,可能会发生此错误。创建秘密时有一些先决条件。 AWS 文档供参考。下面列出它们以便快速访问。
AmazonMSK_
Plaintext
选项输入键值对。This error can occur when one or more pre-requisites for creating the secret has not been followed. There are a few pre-requisites when creating the secret. AWS document for reference. Listing them below for quick access.
AmazonMSK_
Plaintext
option.事实证明您需要使用纯文本形式。

Turns out you need to use Plaintext form.

除了@Sourabh 的回答之外,
使用默认 AWS KMS 密钥创建的密钥无法与 Amazon MSK 集群一起使用,
因此您需要执行以下操作:
打开 Secrets Manager 控制台。
在秘密名称中,选择您的秘密。
选择操作,然后选择下拉列表,选择 AWS KMS 密钥,选中使用新加密密钥创建新版本的密钥复选框,然后选择保存。
这应该可以解决这个错误
In addition to @Sourabh 's answer,
a secret created with the default AWS KMS key cannot be used with an Amazon MSK cluster,
so what you need to do is:
Open the Secrets Manager console.
In Secret name, choose your secret.
Choose Actions, and then choose dropdown list, select the AWS KMS key, select the check box for Create new version of secret with new encryption key, and then choose Save.
that should solve this error
发生这种情况是因为在创建密钥时您选择了默认的 aws kms 选项。
首先您必须创建新的 KMS
那么你必须在秘密管理器创建时更新它。
完成所有操作后,您将不会收到此错误。
This is happening because at the time of secret creation you had selected the default aws kms option.
Frist you have to create the new KMS
then you have to update it in secret manager creation time.
After following all you will not get this error.
您不能在密码中使用后斜线:
将给出此错误:
您可以保存它,但是您不能将其与群集关联。
You can't use a backslash in the password:
will give this error:
You can save it, but you cannot associate it with a cluster.