【DWS跨region集群级容灾】创建容灾任务界面备集群信息不显示

举报
居居小太阳 发表于 2025/10/22 14:54:55 2025/10/22
【摘要】 1、问题现象【现象1】在创建容灾任务界面,已经选择跨region容灾、备集群区域,但没有显示备集群项目ID和集群名称。【现象2】备集群项目ID可以正常显示,选择其中一个ID,集群名称仍没有显示。2、解决方案【现象1】定位步骤及解决方案   步骤1     在管控面创建容灾任务无法显示备集群信息界面按F12。   步骤2     点击项目ID下拉框,获取返回接口及返回状态。   步骤3    ...

1、问题现象

现象1】在创建容灾任务界面,已经选择跨region容灾、备集群区域,但没有显示备集群项目ID和集群名称。

现象2】备集群项目ID可以正常显示,选择其中一个ID,集群名称仍没有显示。

2、解决方案

【现象1】定位步骤及解决方案

   步骤1     在管控面创建容灾任务无法显示备集群信息界面按F12

   步骤2     点击项目ID下拉框,获取返回接口及返回状态。

   步骤3     header中获取对应的tranceid

   步骤4     进入dwscontroller容器,cd log/ 查看ossres-dws.log中带有tranceid的报错信息。

   步骤5     根据报错信息分析。

                  报错原因:主集群数据库rds_intance表中记录备集群信息与实际的备集群信息不一致,导致无法获取到备集群信息。

   步骤6     查看原刷新数据库rds_intance表的sql,发现是有备集群信息收集的不对。重新收集正确的备集群信息

   步骤7     更新sql语句重新执行,刷新到rds_intance表中。

                 主region数据库插入:

                insert into region_information (id, region_id, geo_category, display_name, endpoint, enabled, namespace, available_region)
                values(uuid(), '主regionid', 'xx
主region', 'xx中心主Region', '主endpoint',1, 'dws', '{"snapshot":[],"disaster_recovery":["备regionid"]}');
                insert into region_information (id, region_id, geo_category, display_name, endpoint, enabled, namespace, available_region)
                values(uuid(), '备regionid', 'xx
备region', 'xx中心备Region', '备endpoint',1, 'dws', '{"snapshot":[],"disaster_recovery":["主regionid"]}');

                 备region数据库插入:
                insert into region_information (id, region_id, geo_category, display_name, endpoint, enabled, namespace, available_region)
                values(uuid(), '备regionid', 'xx
备region', 'xx中心备Region', 'endpoint',1, 'dws', '{"snapshot":[],"disaster_recovery":["主regionid"]}');
                insert into region_information (id, region_id, geo_category, display_name, endpoint, enabled, namespace, available_region)
                values(uuid(), '主regionid', 'xx
主region', 'xx中心主Region', '主endpoint',1, 'dws', '{"snapshot":[],"disaster_recovery":["备regionid"]}');

    步骤8   查看管控面上容灾信息,项目ID及备集群信息是否正常显示。

【现象2】定位步骤及解决方案

     步骤1   打开F12。主region页面查询,触发接口,选择项目ID

                    观察接口返回

                    看接口:xxx//disaster-recovery-clusters?primaryClusterId=xxx&standbyAZCode=&standbyRegion=shpj-sc-01&drType=region&standbyProjectId=80e43c0c01ae4df4827c8246e792963e1&isFineGrainedDr=0

                    在header中获取对应的tranceid

     步骤2   region管控面pod容器内,根据traceId找对应的pod容器,进入logs目录

                    grep "xxx" ossres-dws.log
                    关键日志:注意时间点
                    Enter query standby clusters by primary cluster id:
                    Enter get cluster cross region dr service
                    get disaster cluster from other region url is:
                    get cluster from other region response is

      步骤3     region管控面pod容器内,由于没有traceId,只能两个pod都去查找日志

                   grep "disaster-recovery-clusters" ossres-dws.log
                   关键日志:注意时间点匹配
                   Enter query standby clusters by primary cluster id:
                   Start to filter the region standby cluster
                   sql is {}, projectId is {}, dataType is {}, dataVersion is {}, vpcId is {}
                   dnNum of primary is:
                   dnNumTotal of primary is:
                   dnNumOfStandby of standby is:


      步骤4    分析日志信息后发现是主集群没有在备集群中获取到规格信息。无法匹配。去查看rds_resspecattr中是否存在主集群规格信息。

                  SELECT * FROM `rds_resspecattr` WHERE `specId` IN (SELECT `instance_spec_id` FROM `rds_cluster_instance_resspec` WHERE `cluster_spec_id` IN (SELECT `id` FROM `rds_cluster_spec` WHERE `code` in ('dwsk.xlarg')));

      步骤5    查询信息显示备集群中没有记录主集群相关规格信息。备集群rds_resspecattr中插入一条主集群规格信息。

      步骤6    查看管控面上备集群信息是否显示正常。

【声明】本内容来自华为云开发者社区博主,不代表华为云及华为云开发者社区的观点和立场。转载时必须标注文章的来源(华为云社区)、文章链接、文章作者等基本信息,否则作者和本社区有权追究责任。如果您发现本社区中有涉嫌抄袭的内容,欢迎发送邮件进行举报,并提供相关证据,一经查实,本社区将立刻删除涉嫌侵权内容,举报邮箱: cloudbbs@huaweicloud.com
  • 点赞
  • 收藏
  • 关注作者

评论(0

0/1000
抱歉,系统识别当前为高风险访问,暂不支持该操作

全部回复

上滑加载中

设置昵称

在此一键设置昵称,即可参与社区互动!

*长度不超过10个汉字或20个英文字符,设置后3个月内不可修改。

*长度不超过10个汉字或20个英文字符,设置后3个月内不可修改。