1.测试CMQ topic的时候报错如下
1.1 测试报错
{"code":6000,"message":"(10050)server internal error","requestId":"2077840488935586962","clientRequestId":1231231231}
Traceback (most recent call last):
File "cmq_sample_topic.py", line 47, in <module>
publish_message()
File "cmq_sample_topic.py", line 35, in publish_message
my_topic.publish_message(msg)
File "/root/test/cmq_sdk/sdk/simple_demo/../cmq/topic.py", line 103, in publish_message
msgId = self.cmq_client.publish_message(params)
File "/root/test/cmq_sdk/sdk/simple_demo/../cmq/cmq_client.py", line 339, in publish_message
self.check_status(resp_inter)
File "/root/test/cmq_sdk/sdk/simple_demo/../cmq/cmq_client.py", line 116, in check_status
raise CMQServerException(message=message, request_id=requestId, code=code, data=resp)
cmq.cmq_exception.CMQServerException: CMQServerException Code:6000, Message:(10050)server internal error, Data:{u'clientRequestId': 1231231231, u'message': u'(10050)server internal error', u'code': 6000, u'requestId': u'2077840488935586962'}
1.2查看routeProxy(nameServer)日志发现如下:
2021/01/22 12:38:38 qps : %v 0
2021/01/22 12:38:39 qps : %v 0
2021/01/22 12:38:40 qps : %v 0
2021/01/22 12:38:41 qps : %v 1
2021/01/22 12:38:42 qps : %v 0
2021/01/22 12:38:43 qps : %v 0
2021/01/22 12:38:44 qps : %v 0
1.3 查看access的日志发现如下
[2021-01-22 12:38:40] receive http client request (reqid:2077840488935586959, client reqid:1231231231, cmd:1011) now:1611290320601
[2021-01-22 12:38:40] publisher.cpp:133:Dispatch buname:topic-runvwn1b(tid:300001) don't have mq servers servecie for it!
[2021-01-22 12:38:40] Task(cmd:1011 reqid:2077840488935586959 status:2 in_time:1611290320601225 now:1611290320601225 time used:0) err_code:102 err_msg:access don't have mq server to serivice qcloud qid(topic-runvwn1b))
[2021-01-22 12:38:40] http client task (reqid:2077840488935586959, client reqid:1231231231, cmd:1011) total time used:0 us with [errCode:10050]
1.4 解释: 错误码为 内部错误 https://cloud.tencent.com/document/api/406/42641
故推断为access的问题.
2. 解决办法
登录控制台 : http://IP/cmq-manager/access
移除topic的access, 并重新添加即可