pysx0503
作者pysx0503联盟成员·2020-04-20 23:24
系统工程师·第十区。散人

GBase 8a MPP Cluster 日志参考手册

字数 17836阅读 4016评论 0赞 4

GBase 8a MPP Cluster (集群)
日志参考手册 V8.6.2.X
GBase 8a MPP Cluster 日志参考手册

  • II - 南大通用数据技术股份有限公司
    GBase 8a MPP Cluster 日志 参考 手册 , 南大通用数据技术股份有限公司
    GBase 版权所有 2004-2018,保留所有权利。
    版权声明
    本文档所涉及的软件著作权、版权和知识产权已依法进行了相关注册、登记,由南大通用数据
    技术股份有限公司合法拥有,受《中华人民共和国著作权法》、《计算机软件保护条例》、《知识
    产权保护条例》和相关国际版权条约、法律、法规以及其它知识产权法律和条约的保护。未经
    授权许可,不得非法使用。
    免责声明
    本文档包含的南大通用公司的版权信息由南大通用公司合法拥有,受法律的保护,南大通用公
    司对本文档可能涉及到的非南大通用公司的信息不承担任何责任。在法律允许的范围内,您可
    以查阅,并仅能够在《中华人民共和国著作权法》规定的合法范围内复制和打印本文档。任何
    单位和个人未经南大通用公司书面授权许可,不得使用、修改、再发布本文档的任何部分和内
    容,否则将视为侵权,南大通用公司具有依法追究其责任的权利。
    本文档中包含的信息如有更新,恕不另行通知。您对本文档的任何问题,可直接向南大通用数
    据技术股份有限公司告知或查询。
    未经本公司明确授予的任何权利均予保留。
    通讯方式
    南大通用数据技术股份有限公司
    天津华苑产业区海泰发展六道 6 号海泰绿色产业基地 J 座(300384)
    电话:400-013-9696 邮箱:info@gbase.cn
    商标声明
    是南大通用数据技术股份有限公司向中华人民共和国国家商标局申请注册的注册
    商标,注册商标专用权由南大通用公司合法拥有,受法律保护。未经南大通用公司书面许可,
    任何单位及个人不得以任何方式或理由对该商标的任何部分进行使用、复制、修改、传播、抄
    录或与其它产品捆绑使用销售。凡侵犯南大通用公司商标权的,南大通用公司将依法追究其法
    律责任。
    GBase 8a MPP Cluster 日志参考手册
    南大通用数据技术股份有限公司 - I -
    目 录
    前言 ............................................................. 1
    手册简介 ..................................................... 1
    公约 ......................................................... 2
  • 日志说明 ..................................................... 3
    1.1 trc 日志 (查询计划) ................................... 3
    1.1.1 日志内容 ......................................... 4
    1.1.2 日志项目 ......................................... 7
    1.2 express.log (执行日志) ............................... 15
    1.2.1 Got error 28 from storage engine ................. 15
    1.2.2 端口号 6002 被占用 ................................ 15
    1.2.3 create temporary table fail ...................... 16
    1.2.4 其他 gnode 返回的错误 ............................. 17
    1.3 system.log .......................................... 19
    1.4 日志按期归档 ........................................ 22
    GBase 8a MPP Cluster 日志参考手册
    南大通用数据技术股份有限公司 - 1 -
    前言
    手册简介
    GBase 8a MPP Cluster 日志参考手册主要用于介绍集群日志的相关信息。
    本手册主要介绍 trc 日志、express.log 日志以及 system.log 日志这三类
    日志的功能以及日志的相关信息,为用户提供参考依据。
    GBase 8a MPP Cluster 日志参考手册
  • 2 - 南大通用数据技术股份有限公司
    公约
    下面的文本约定用于本文档:
    约 定 说 明
    加粗字体 表示文档标题
    大写英文(SELECT) 表示 GBase 8a MPP Cluster 关键字
    等宽字体 表示代码示例
    … 省略号指明被省略的内容。
    GBase 8a MPP Cluster 日志参考手册
    南大通用数据技术股份有限公司 - 3 -
  • 1 日志说明
    gcluster 日志分为三类:trc 日志记录查询计划;express.log 记录 SQL
    执行过程以及执行过程中的警告和错误;system.log 主要记录 gcluster 的启
    停以及 crash 信息,日志存放路径为:/opt/gcluster/log/gcluster。
    当需要分析 SQL 的查询计划时请查看 trc 日志,trc 日志详细记录了 SQL
    的查询和执行计划,通过分析这些计划来确定 SQL 的计划是否是最优的。
    当需要分析 SQL 执行过程中的时间消耗以及执行过程中出现的警告和错误
    时请查看 express.log 日志,express.log 日志详细记录了 SQL 执行过程中各
    个步骤的时间以及警告和错误,但缺省只记录 SQL 执行过程中的警告和错误,
    通过分析这些警告和错误来定位问题的原因。
    当 gcluster 正常启停和启动失败以及运行过程中出现 crash 时,信息都
    会记录到 system.log 中,通过分析这些日志来定位启动失败以及运行过程中出
    现 crash 的原因。当运行过程中出现 crash 时,system.log 中记录了宕机的堆
    栈信息,core 文件中记录了宕机的详细的堆栈信息,core 文件的存放路径在
    /opt/gcluster/userdata/gcluster/下,可通过gdb的方式来查看详细的crash
    信息(发版的 gcluster 是带有符号的 release 版本),命令如下:
    gdb /opt/gcluster/server/bin/gclusterd
    /opt/gcluster/userdata/gcluster/corefile
    thread apply all bt
    1.1 c trc 日志 ( ( 查询计划) )
    在 gcluster 配置文件中设置
    gbase_sql_trace = 1
    gbase_sql_trace_level = 3
    GBase 8a MPP Cluster 日志参考手册
  • 4 - 南大通用数据技术股份有限公司
    后,查询计划可输出到.trc 文件中。
    1.1.1 日志 内容
    gbase> SELECT b, SUM (a) FROM t1 GROUP BY b HAVING( ( SUM (a) >100);

    //按照 b 进行动态 hash 的查询计划如下。

    QueryPlan:
    ++++++++++++++++++++++++++++++++++++++++++++++
    Step: 0
    Leaf type: REGULAR STEP
    Need combiner: false
    Is Broadcast: false
    Target temp table:
    _tmp_rht_n1_t12_1_356508_0x45a00ad0_0x12eebd68
    Temp table definition: CREATE TABLE
    gctmpdb._tmp_rht_n1_t12_1_356508_0x45a00ad0_0x12eebd68(_col_1
    VARCHAR(100), _col_2 DECIMAL(18,0)) ENGINE = express nolock
    Optimization: {hash redist}
    Hash Redist Indexes: 1
    Query String: SELECT zsy1.t1.b AS _col_1,
    SUM(zsy1.t1.a) AS _col_2 FROM zsy1.t1 AS zsy1.t1 GROUP BY
    _col_1
    GBase 8a MPP Cluster 日志参考手册
    南大通用数据技术股份有限公司 - 5 -
    ++++++++++++++++++++++++++++++++++++++++++++++
    Step: 1
    Leaf type: REGULAR STEP
    Need combiner: false
    Is Broadcast: false
    Target temp table: _tmp_n1_t12_2_356618_0x45a00b90_0x12eebd68
    Temp table definition: CREATE TABLE
    gctmpdb._tmp_n1_t12_2_356618_0x45a00b90_0x12eebd68(b
    VARCHAR(100), sum(a) DECIMAL(18,0)) ENGINE = express nolock
    Optimization:
    Query String: SELECT _col_1 AS b, SUM(_col_2) AS sum(a)
    FROM gctmpdb._tmp_rht_n1_t12_1_356508_0x45a00ad0_0x12eebd68 GROUP

    BY b HAVING (SUM(_col_2) > 100)

    2012-07-18 19:06:09.356 [M: 0B, 0B,D: 0B] [DC: 0,
    0]
    GBase 8a MPP Cluster 日志参考手册

  • 6 - 南大通用数据技术股份有限公司

    CExecStep

    isFinalStep = 0
    m_nRequestId = 0
    StepNo = 0
    DestType = 1

    aStepDetail

    isProducer = 1
    isConsumer = 1
    isGroupHashRedist = 0
    isAllTableAreHashTmpDist = 0
    queryString = SELECT zsy1.t1.b AS _col_1, SUM(zsy1.t1.a)
    AS _col_2 FROM zsy1.t1 AS zsy1.t1 GROUP BY _col_1
    targetTable =
    gctmpdb._tmp_rht_n1_t12_1_356508_0x45a00ad0_0x12eebd68
    targetSchema = CREATE TABLE
    gctmpdb._tmp_rht_n1_t12_1_356508_0x45a00ad0_0x12eebd68(_col_1
    VARCHAR(100), _col_2 DECIMAL(18,0)) ENGINE = express nolock
    DropList =
    CExecStep
    GBase 8a MPP Cluster 日志参考手册

    南大通用数据技术股份有限公司 - 7 -

    isFinalStep = 0
    m_nRequestId = 0
    StepNo = 1
    DestType = 0

    aStepDetail

    isProducer = 1
    isConsumer = 0
    isGroupHashRedist = 0
    isAllTableAreHashTmpDist = 1
    queryString = SELECT _col_1 AS b, SUM(_col_2) AS sum(a) FROM
    gctmpdb._tmp_rht_n1_t12_1_356508_0x45a00ad0_0x12eebd68 GROUP BY b
    HAVING (SUM(_col_2) > 100)
    DropList =
    2012-07-18 19:06:09.419 [M: 0B, 0B,D: 0B] [DC: 0, 0]
    Executor success.
    1.1.2 日志项目
    (一)中间表的命名方式:
    _tmp_n1_t11_1_405747_0x45a002a0_0x12eebd68
    GBase 8a MPP Cluster 日志参考手册

  • 8 - 南大通用数据技术股份有限公司
    _tmp_rht_n1_t12_1_356508_0x45a00ad0_0x12eebd68
    对于一个集群临时表名,_tmp_rht 前缀表示这是一个动态重分布临时表,
    仅有_tmp 前缀时,表示这是一个普通临时表(复制表)。其余部分,动态重分
    布临时表和普通临时表一样,因此这里以动态重分布产生的临时表名
    _tmp_rht_n1_t12_1_356508_0x45a00ad0_0x12eebd68 来统一说明。
    _tmp_rht:动态重分布临时表
    n1:发起这条查询的节点后缀,这里表示此查询是从 n1 节点发起的
    t12: 查询计数,gcluster server 启动后,执行的第n 条查询,n 从 1 开
    始。
    1:该查询产生的第 m 个临时表名,m 从 1 开始(因为查询会分解为多步执
    行,因此可能会产生多个临时表)
    356508: 产生临时表名时,系统时间的微秒部分
    0x45a00ad0:产生临时表名时,时间结构的内存地址
    0x12eebd68:产生临时表名的 thd 对象的内存地址
    (二) Optimization
    A.{single hash node}
    Select * from t where hash_col = '123';
    B.{hash group by}
    Select * from t1 group by a, hash_col, c;
    GBase 8a MPP Cluster 日志参考手册
    南大通用数据技术股份有限公司 - 9 -
    C.{distinct group hash}
    select count(distinct hash_col) from x1;
    select sum(distinct hash_col) from x1 group by id3;
    D.{distinct hash}
    select distinct a, hash_col, c from x1;
    select distinct id2, hash_col, id3 from x1 group by id3
    E.{one step hash join complex}
    在多步计划中,其中一步可以使用 hash join complex 优化(主查询与相
    关子查询,
    或非相关子查询存在 hash 关系)
    测试用例如下:(id4 是 hash 列)
    gbase> SELECT x3.* FROM x1, x3 WHERE x1.id3 = x3.id3 AND x1.id4 IN ( ( SELECT id4

    FROM x2);

    2012-07-19 18:31:14.243
    JOIN ----test.x3
    |
    test.x1
    GBase 8a MPP Cluster 日志参考手册

  • 10 - 南大通用数据技术股份有限公司

    2012-07-19 18:31:14.243

    2012-07-19 18:31:14.244
    JOIN {(test.x1.id3 =
    test.x3.id3)}---------------------------------------------------
    --test.x3{}
    |
    test.x1{test.x1.id4 IN ( SELECT test.x2.id4 as id4 From
    test.x2 as test.x2)}
    2012-07-19 18:31:14.244 >>>>> using one step hash join complex
    optimization

    2012-07-19 18:31:14.244

    ==============================================
    QueryPlan:
    ++++++++++++++++++++++++++++++++++++++++++++++
    Step: 0
    GBase 8a MPP Cluster 日志参考手册
    南大通用数据技术股份有限公司 - 11 -
    Leaf type: REGULAR STEP
    Need combiner: false
    Is Broadcast: false
    Target temp table: _tmp_n1_t15_1_244477_0x45cfca40_0x13c53788
    Temp table definition: CREATE TABLE
    gctmpdb._tmp_n1_t15_1_244477_0x45cfca40_0x13c53788(id3 INT)
    ENGINE = express nolock
    Optimization: {one step hash join complex}
    Query String: SELECT test.x1.id3 AS id3 FROM
    test.x1 AS test.x1 WHERE test.x1.id4 IN ( SELECT test.x2.id4
    as id4 From test.x2 as test.x2)
    ++++++++++++++++++++++++++++++++++++++++++++++
    Step: 1
    Leaf type: REGULAR STEP
    Need combiner: false
    Is Broadcast: false
    Target temp table: _tmp_n1_t15_2_244595_0x45cfcaf0_0x13c53788
    Temp table definition: CREATE TABLE
    gctmpdb._tmp_n1_t15_2_244595_0x45cfcaf0_0x13c53788(entry_id INT,
    id2 INT, id3 INT, id4 INT) ENGINE = express nolock
    Optimization:
    GBase 8a MPP Cluster 日志参考手册

  • 12 - 南大通用数据技术股份有限公司
    Query String: SELECT test.x3.entry_id AS entry_id,
    test.x3.id2 AS id2, test.x3.id3 AS id3, test.x3.id4 AS
    id4 FROM gctmpdb._tmp_n1_t15_1_244477_0x45cfca40_0x13c53788 INNER
    JOIN test.x3 AS test.x3 ON
    (_tmp_n1_t15_1_244477_0x45cfca40_0x13c53788.id3 =

    test.x3.id3)

    2012-07-19 18:31:14.244

    CExecStep

    isFinalStep = 0
    m_nRequestId = 0
    StepNo = 0
    DestType = 1

    aStepDetail

    isProducer = 1
    isConsumer = 1
    isGroupHashRedist = 0
    isAllTableAreHashTmpDist = 0
    GBase 8a MPP Cluster 日志参考手册
    南大通用数据技术股份有限公司 - 13 -
    queryString = SELECT test.x1.id3 AS id3 FROM test.x1 AS
    test.x1 WHERE test.x1.id4 IN ( SELECT test.x2.id4 as id4
    From test.x2 as test.x2)
    targetTable =
    gctmpdb._tmp_n1_t15_1_244477_0x45cfca40_0x13c53788
    targetSchema = CREATE TABLE
    gctmpdb._tmp_n1_t15_1_244477_0x45cfca40_0x13c53788(id3 INT)
    ENGINE = express nolock
    DropList =

    CExecStep

    isFinalStep = 0
    m_nRequestId = 0
    StepNo = 1
    DestType = 0

    aStepDetail

    isProducer = 1
    isConsumer = 0
    isGroupHashRedist = 0
    isAllTableAreHashTmpDist = 0
    GBase 8a MPP Cluster 日志参考手册

  • 14 - 南大通用数据技术股份有限公司
    queryString = SELECT test.x3.entry_id AS entry_id,
    test.x3.id2 AS id2, test.x3.id3 AS id3, test.x3.id4 AS
    id4 FROM gctmpdb._tmp_n1_t15_1_244477_0x45cfca40_0x13c53788 INNER
    JOIN test.x3 AS test.x3 ON
    (_tmp_n1_t15_1_244477_0x45cfca40_0x13c53788.id3 =
    test.x3.id3)
    DropList =
    2012-07-19 18:31:15.171 Executor success.
    F.{hash redist}
    Hash Redist Indexes: 1
    hash 重分布步骤,Hash Redist Indexes 表示按 projection 的第 n 列进行
    hash 重分布(n 从 1 开始)
    例如:select 执行结果按照 projection 的第 1 列(zsy1.t1.b AS
    _col_1)进行动态 hash 后,把结果发送到各个节点,日志如下:
    Optimization: {hash redist}
    Hash Redist Indexes: 1
    Query String: SELECT zsy1.t1.b AS _col_1,
    SUM(zsy1.t1.a) AS _col_2
    FROM zsy1.t1 AS zsy1.t1 GROUP BY _col_1
    (三) DestType(中间结果的汇聚方式)
    DEST_TYPE_NOSET = 0, ///< not set
    GBase 8a MPP Cluster 日志参考手册
    南大通用数据技术股份有限公司 - 15 -
    DEST_TYPE_BROADCAST = 1,///< 广播到所有的 Node : 8a -> 8a 或
    者是 Cluster -> 8a
    DEST_TYPE_COORD = 2, ///< 发送结果到 Cluster
    DEST_TYPE_ONE = 3, ///< 发送结果到一个 Node 目前为当前
    Cluster 所在的 8a
    (四) isProducer
    生产者
    (五)isConsumer
    消费者
    (六)JOIN 树
    Inner join 评估把较小的表放在左面,较大的表放到右面,如果要拉复制
    表,则把左面的表拉成复制表, 如果是 left join 则不能改变顺序,只能把右
    边的表拉成复制表。
    1.2 express.log ( 执行日志) )
    在 gcluster 配置文件中设置 gcluster_dml_log_level =15 后,完整的执
    行计划可输出到 express.log 文件中, 缺省情况下只有执行过程中出现的警告
    和错误才会输出到 express.log 文件中, 以下介绍几个常见的错误。
    1.2.1 Got error 28 from storage engine
    临时空间满了,请配置临时空间的参数(缺省是/tmp 目录下)。
    [gbased]
    tmpdir = /opt/tmp
    1.2.2 端口号 2 6002 被占用
    GBase 8a MPP Cluster 日志参考手册
  • 16 - 南大通用数据技术股份有限公司
    2012-03-23 00:18:13.746 [WARN ] <Pool_Init|48>: Thread pool is
    created successfully. Max thread number is 600.
    2012-03-23 00:18:15.755 Bind to address ip: 192.168.11.121 port:
  • fail cause by Address already in use
    2012-03-23 00:18:24.825 Start gcluster message listener fail and
    exit
    1.2.3 create temporary table fail
    简单用例如下:
    CREATE TABLE ta(a date);
    CREATE TABLE tb(a date);
    SELECT a FROM ta WHERE a IN (SELECT date '2011-12-04' + interval '$i'
    day FROM tb);
    2012-07-19 02:57:30.355 [ERROR] <CreateTempTable|14825>: Create
    table fail with SQL: CREATE TABLE
    gctmpdb._tmp_n1_t23_1_513743_0x40e542a0_0x446e9b8(`date
    '2011-12-04' + interval '$i' day ` VARCHAR(29)) ENGINE = express
    nolock
    CAUSE: Incorrect column name 'date '2011-12-04' + interval '$i' day
    '
    2012-07-19 02:57:30.355 [ERROR]
    <GbaseTempTableUnionWithDistributeTable|1556 [THD=0x446e9b8]>: Create
    temporary table gctmpdb._tmp_n1_t23_1_513743_0x40e542a0_0x446e9b8
    fail
    GBase 8a MPP Cluster 日志参考手册
    南大通用数据技术股份有限公司 - 17 -
    推荐:projection 中使用表达式时请使用别名;projection 中出现相同列
    名时也使用别名。
    1.2.4 其他 e gnode 返回的错误
    发送 SQL 到 gnode 执行过程中的错误举例如下:
    2012-05-25 02:17:23.319 [WARN ] <HAEventHandler::PutEventToCache>:
    Receive event: Raiser - 10.10.10.18 event - node left
    2012-05-25 02:19:11.560 [WARN ] <HAEventHandler::PutEventToCache>:
    Receive event: Raiser - 10.10.10.20 event - node joined
    2012-05-25 05:26:47.138 [ERROR] <QueryRedistributeTable|10910
    [THD=0x2aab0c0ab870] [Initiator 10.10.10.13:5050 Target
    10.10.10.17:5050]>: Query fail with SQL: SELECT TB.mer_amt AS
    MER_AMT, TB.disc_amt AS DISC_AMT, TC.MSISDN AS MSISDN
    FROM cmcc.tb_svc_subs_hist_n5 AS TC INNER JOIN cmcc.dtl_bill_n5
    AS TB ON (TB.subs_id = TC.subs_id) target into server (host
    '10.10.10.13,10.10.10.14,10.10.10.15,10.10.10.16,10.10.10.17,10.10.1
    0.18,10.10.10.19,10.10.10.20' , port 5050 , user 'root' , password
    'gbase20110531' , database 'gctmpdb' , table
    '_tmp_rht_n1_t90_1_256189_0x40ef93c0_0x2aab0c0ab870' , comment
    'group 3' )
    CAUSE: SELECT INTO SERVER error: Can't connect to GBase server on
    '10.10.10.20' (110)
    2012-05-25 05:26:51.004 [WARN ] <WaitForAllWorkerFinish|9719
    [THD=0x2aaaf802ff20]>: One worker haven't finished normally, now need
    to stop other workers.
    GBase 8a MPP Cluster 日志参考手册
  • 18 - 南大通用数据技术股份有限公司
    2012-05-25 05:26:51.029 [WARN ] <WaitForAllWorkerFinish|9719
    [THD=0x2aab0c0ab870]>: One worker haven't finished normally, now need
    to stop other workers.
    2012-05-25 05:26:54.117 [WARN ] <WaitForAllWorkerFinish|9719
    [THD=0x2aab100b8910]>: One worker haven't finished normally, now need
    to stop other workers.
    2012-05-25 05:27:14.186 [ERROR] <QueryRedistributeTable|10882
    [THD=0x2aab100b8910] [Initiator 10.10.10.13:5050 Target
    10.10.10.15:5050]>: Query fail with SQL: SELECT TB.mer_amt AS
    MER_AMT, TB.disc_amt AS DISC_AMT, TC.MSISDN AS MSISDN
    FROM cmcc.tb_svc_subs_hist_n3 AS TC INNER JOIN cmcc.dtl_bill_n3
    AS TB ON (TB.subs_id = TC.subs_id) target into server (host
    '10.10.10.13,10.10.10.14,10.10.10.15,10.10.10.16,10.10.10.17,10.10.1
    0.18,10.10.10.19,10.10.10.20' , port 5050 , user 'root' , password
    'gbase20110531' , database 'gctmpdb' , table
    '_tmp_rht_n1_t91_1_256217_0x7facf3c0_0x2aab100b8910' , comment
    'group 3' )
    CAUSE: Stopped by user.
    2012-05-25 05:27:15.504 [ERROR] <QueryRedistributeTable|10882
    [THD=0x2aaaf802ff20] [Initiator 10.10.10.13:5050 Target
    10.10.10.15:5050]>: Query fail with SQL: SELECT TB.mer_amt AS
    MER_AMT, TB.disc_amt AS DISC_AMT, TC.MSISDN AS MSISDN
    FROM cmcc.tb_svc_subs_hist_n3 AS TC INNER JOIN cmcc.dtl_bill_n3
    AS TB ON (TB.subs_id = TC.subs_id) target into server (host
    '10.10.10.13,10.10.10.14,10.10.10.15,10.10.10.16,10.10.10.17,10.10.1
    0.18,10.10.10.19,10.10.10.20' , port 5050 , user 'root' , password
    'gbase20110531' , database 'gctmpdb' , table
    GBase 8a MPP Cluster 日志参考手册
    南大通用数据技术股份有限公司 - 19 -
    '_tmp_rht_n1_t85_1_495075_0x5b0be3c0_0x2aaaf802ff20' , comment
    'group 3' )
    CAUSE: Stopped by user.
    1.3 system.log
    在运行过程中出现 crash 时,system.log 中记录了宕机的堆栈信息,core
    文件中记录了宕机的详细的堆栈信息,如果用户希望看到详细的堆栈信息,则
    需要在集群以及集群节点的配置文件中,开启该功能,具体如下:
    集群层面:在每台集群节点机器的/opt/gcluster/config 路径下,找到配
    置文件 gbase_8a_gcluster.cnf,将文件中的 core-file 参数去掉参数前的注
    释符号“#”。
    集群节点:在每台集群节点机器的/opt/gnode/config 路径下,找到配置
    文件 gbase_8a_gbase.cnf,将文件中的 core-file 参数去掉参数前的注释符号
    “#”。
    进行完上述设置后,每台节点机器切换到 root 用户,运行 service gcware
    restart 命令,重新启动集群服务,使上述配置文件的设置生效。
    下面举例为用户展示 system.log 文件中的 crash 信息。
    system.log 中包含有 crash 信息,如下:
  • 0:18:09 [Note] Event Scheduler: Purging the queue. 6 events
  • 0:18:09 - gbased got signal 11 ;
    This could be because you hit a bug. It is also possible that this
    binary
    or one of the libraries it was linked against is corrupt, improperly
    built,
    GBase 8a MPP Cluster 日志参考手册
  • 20 - 南大通用数据技术股份有限公司
    or misconfigured. This error can also be caused by malfunctioning
    hardware.
    We will try our best to scrape up some info that will hopefully help
    diagnose
    the problem, but since we have already crashed, something is
    definitely wrong
    and this may fail.
    key_buffer_size=8384512
    read_buffer_size=131072
    max_used_connections=6
    max_threads=5000
    threads_connected=0
    It is possible that gbased could use up to
    key_buffer_size + (read_buffer_size +
    sort_buffer_size)*max_threads = 10950336 K
    bytes of memory
    Hope that's ok; if not, decrease some variables in the equation.
    thd: 0x675a560
    Attempting backtrace. You can use the following information to find
    out
    where gbased died. If you see no messages after this, something went
    terribly wrong...
    GBase 8a MPP Cluster 日志参考手册
    南大通用数据技术股份有限公司 - 21 -
    stack_bottom = (nil) thread_stack 0x40000
    gclusterd(my_print_stacktrace+0x2e) [0xea49fd]
    gclusterd(handle_segfault+0x32e) [0x6e6b36]
    /lib64/libpthread.so.0 [0x361300eb70]
    gclusterd(ExpressChannel::lock(unsigned int)+0x130) [0xb68746]
    gclusterd(DMLLog(int, std::string, char const*)+0xbf) [0x9308ff]
    gclusterd(GCQueryExecutorStatement::UnionTableHandler::Execute()
    +0x14d0) [0x8f5ec0]
    gclusterd(GCQueryExecutorStatement::TaskThread::ExecuteUnionTabl
    eTask(char*, unsigned int)+0x93) [0x8dd23f]
    gclusterd(GCQueryExecutorStatement::TaskThread::execute()+0x100)
    [0x8df976]
    gclusterd(CGCThreadPool::GCThreadDispatchFunc(void*)+0x17)
    [0x92b5b1]
    gclusterd(wrapper_fn(void*)+0x28) [0x92cafe]
    /lib64/libpthread.so.0 [0x361300673d]
    /lib64/libc.so.6(clone+0x6d) [0x36124d44bd]
    Trying to get some variables.
    Some pointers may be invalid and cause the dump to abort...
    thd->query at (nil) is an invalid pointer
    thd->thread_id=0
    thd->killed=NOT_KILLED
    Writing a core file
    GBase 8a MPP Cluster 日志参考手册
  • 22 - 南大通用数据技术股份有限公司
    1.4 日志按期归档
    集群在线时,corosync.log、express.log、syncserver.log、
    gc_recover.log、system.log 等日志过大,查看日志耗时,并且不方便归档。
    集群在线时,使用logrotate 工具,可以实现日志文件按日期生成,利于查看,
    方便归档。
    logrotate 在 linux 系统中默认安装,logrotate 默认放置在
    /etc/cron.daily 目录下,默认让 cron 每天执行 logrotate 一次,从而实现按
    天转储日志。同时,将转储后的日志存放于集群日志相同的目录下,用户可以
    通过查看集群日志的方式查看转储日志。
    用户通过将配置文件中的 daily 改为 weekly 或 monthly,实现按周或月转
    储日志。(集群日志的相关配置文件放置在/etc/logrotate.d 目录下)
    Example:
    /var/log/corosync.log{
    missingok
    compress
    copytruncate
    weekly // or monthly
    rotate 31
    size 10M
    minisize 1M
    notifempty
    }
    其中,daily,weekly,monthly 都是系统自带的(/etc/cron.weekly,
    /etc/cron.monthly),如果想要自己手动设置时间来转储日志,如每分钟、每
    GBase 8a MPP Cluster 日志参考手册
    南大通用数据技术股份有限公司 - 23 -
    小时、某一天转储一次日志,则通过单独写 crontab 表达式来让 logrotate 指
    定配置文件和指定时间执行,如下:
    Example:
    cat /etc/crontab
    SHELL=/bin/bash
    PATH=/sbin:/bin:/usr/sbin:/usr/bin
    MAILTO=root
    HOME=/

    For details see man 4 crontabs

    Example of job definition:

    .---------------- minute (0 - 59)

    | .------------- hour (0 - 23)

    | | .---------- day of month (1 - 31)

    | | | .------- month (1 - 12) OR jan,feb,mar,apr ...

    | | | | .---- day of week (0 - 6) (Sunday=0 or 7) OR

    sun,mon,tue,wed,thu,fri,sat

    | | | | |

    * user-name command to be executed

  • 号从左至右,依次表示 minute ,hour ,day of month,month,day of
    week
    0-59 root run-parts /etc/cron.daily
    表示每分钟转出一次
  • /1 root run-parts /etc/cron.daily
    表示每小时转储一次
    GBase 8a MPP Cluster 日志参考手册
  • 24 - 南大通用数据技术股份有限公司
        • 6 root run-parts /etc/cron.daily
          表示每周六转储一次
    • 12 root run-parts /etc/cron.daily
      表示每月 12 日转储一次
      GBase 8a MPP Cluster 日志参考手册
      南大通用数据技术股份有限公司 - 2 -

如果觉得我的文章对您有用,请点赞。您的支持将鼓励我继续创作!

4

添加新评论0 条评论

Ctrl+Enter 发表

作者其他文章

相关文章

相关问题

相关资料

X社区推广