• $SNAPSHOT_CONFIGS
    • 描述
    • 标示
      • 字段信息
    • 快照参数
    • 示例

    $SNAPSHOT_CONFIGS

    描述

    配置快照 $SNAPSHOT_CONFIGS 列出数据库中指定节点的配置信息。

    每一个节点上的配置信息为一条记录。

    标示

    $SNAPSHOT_CONFIGS

    字段信息

    字段信息详见数据库配置一节。

    快照参数

    可以使用 use_option 进行指定。

    参数名参数类型描述是否必填
    ModeString指定返回配置的模式。在 run 模式下,显示当前运行时配置信息,在 local 模式下,显示配置文件中配置信息。如 { "Mode": "local" }。默认为 run。
    ExpandBool/String是否扩展显示用户未配置的配置项。如 { "Expand": false }。默认为 true。

    示例

    查看数据组 db1 中数据节点 20000 上的配置信息

    1. > db.exec( "select * from $SNAPSHOT_CONFIGS where GroupName = 'db1' and SvcName = '20000'" )
    2. {
    3. "NodeName": "hostname:20000",
    4. "confpath": "/opt/trunk/conf/local/20000/",
    5. "dbpath": "/opt/test/20000/",
    6. "indexpath": "/opt/test/20000/",
    7. "diagpath": "/opt/test/20000/diaglog/",
    8. "auditpath": "/opt/test/20000/diaglog/",
    9. "logpath": "/opt/test/20000/replicalog/",
    10. "bkuppath": "/opt/test/20000/bakfile/",
    11. "wwwpath": "/opt/trunk/web/",
    12. "lobpath": "/opt/test/20000/",
    13. "lobmetapath": "/opt/test/20000/",
    14. "maxpool": 50,
    15. "diagnum": 20,
    16. "auditnum": 20,
    17. "auditmask": "SYSTEM|DDL|DCL",
    18. "svcname": "20000",
    19. "replname": "20001",
    20. "catalogname": "20003",
    21. "shardname": "20002",
    22. "httpname": "20004",
    23. "omname": "20005",
    24. "diaglevel": 3,
    25. "role": "data",
    26. "logfilesz": 64,
    27. "logfilenum": 20,
    28. "logbuffsize": 1024,
    29. "numpreload": 0,
    30. "maxprefpool": 0,
    31. "maxsubquery": 0,
    32. "maxreplsync": 10,
    33. "replbucketsize": 32,
    34. "syncstrategy": "KeepNormal",
    35. "preferedinstance": "M",
    36. "preferedinstancemode": "random",
    37. "preferedstrict": "FALSE",
    38. "instanceid": 0,
    39. "dataerrorop": 1,
    40. "memdebug": "FALSE",
    41. "memdebugsize": 0,
    42. "indexscanstep": 100,
    43. "dpslocal": "FALSE",
    44. "traceon": "FALSE",
    45. "tracebufsz": 256,
    46. "transactionon": "TRUE",
    47. "transactiontimeout": 60,
    48. "transisolation": 0,
    49. "translockwait": "FALSE",
    50. "transautocommit": "FALSE",
    51. "transautorollback": "TRUE",
    52. "transuserbs": "TRUE",
    53. "translrbinit": 524288,
    54. "sharingbreak": 7000,
    55. "startshifttime": 600,
    56. "catalogaddr": "hostname:30003,hostname:30013,hostname:30023",
    57. "tmppath": "/opt/test/20000/tmp/",
    58. "sortbuf": 256,
    59. "hjbuf": 128,
    60. "directioinlob": "FALSE",
    61. "sparsefile": "FALSE",
    62. "weight": 10,
    63. "auth": "TRUE",
    64. "planbuckets": 500,
    65. "optimeout": 300000,
    66. "overflowratio": 12,
    67. "extendthreshold": 32,
    68. "signalinterval": 0,
    69. "maxcachesize": 0,
    70. "maxcachejob": 10,
    71. "maxsyncjob": 10,
    72. "syncinterval": 10000,
    73. "syncrecordnum": 0,
    74. "syncdeep": "FALSE",
    75. "archiveon": "FALSE",
    76. "archivecompresson": "TRUE",
    77. "archivepath": "/opt/test/20000/archivelog/",
    78. "archivetimeout": 600,
    79. "archiveexpired": 240,
    80. "archivequota": 10,
    81. "omaddr": "",
    82. "dmschkinterval": 0,
    83. "cachemergesz": 0,
    84. "pagealloctimeout": 0,
    85. "perfstat": "FALSE",
    86. "optcostthreshold": 20,
    87. "enablemixcmp": "FALSE",
    88. "plancachelevel": 3,
    89. "maxconn": 0,
    90. "svcscheduler": 0,
    91. "svcmaxconcurrency": 0,
    92. "logwritemod": "increment",
    93. "logtimeon": "FALSE",
    94. "enablesleep": "FALSE",
    95. "recyclerecord": "FALSE",
    96. "maxsocketpernode": 1,
    97. "maxsocketperthread": 0,
    98. "maxsocketthread": 1,
    99. "businessname": "yyy",
    100. "clustername": "xxx"
    101. }

    查看数据组 db1 中数据节点 20000 上的用户指定的配置信息

    1. > db.exec('select * from $SNAPSHOT_CONFIGS where GroupName = "db1" and SvcName = "20000" /*+use_option(Mode, local)use_option(Expand, false)*/')
    2. {
    3. "NodeName": "hostname:20000",
    4. "dbpath": "/opt/test/20000/",
    5. "svcname": "20000",
    6. "diaglevel": 3,
    7. "role": "data",
    8. "catalogaddr": "hostname:30003,hostname:30013,hostname:30023",
    9. "sparsefile": "TRUE",
    10. "plancachelevel": 3,
    11. "businessname": "yyy",
    12. "clustername": "xxx"
    13. }