399 Star 1.3K Fork 1.5K

GVPopenGauss / openGauss-server

 / 详情

【测试类型:功能】【测试版本:3.0.0】release版本编译安装数据库,且dblink模块编译安装后,create extension dblink导致数据库core

已验收
缺陷
创建于  
2022-01-27 17:55

【标题描述】:
【测试类型:SQL功能】【测试版本:3.0.0】release版本编译安装数据库,且dblink模块编译安装后,create extension dblink导致数据库core

【操作系统和硬件信息】(查询命令: cat /etc/system-release, uname -a):
CentOS Linux release 7.6.1810 (Core)
Linux kwemhisprc01300 3.10.0-957.el7.x86_64 #1 SMP Thu Nov 8 23:39:32 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux
【测试环境】(单机/1主x备x级联备):单机

【被测功能】:编译安装方式,追加dblink扩展

【测试类型】:功能测试

【数据库版本】(查询命令: gaussdb –V):
gaussdb (GaussDB Kernel V500R002C00 build ) compiled at 2022-01-26 14:29:35 commit 0 last mr

【预置条件】:
新建用户、下载源码包、三方包
openGauss-server-master.zip
openGauss-third_party_binarylibs.tar.gz

【操作步骤】(请填写详细的操作步骤):
--step1:编译安装数据库

  • unzip openGauss-server-master.zip
  • tar -zxvf openGauss-third_party_binarylibs.tar.gz
  • 配置环境变量,并source
  • cd /.../openGauss-server-master
  • ./configure --gcc-version=7.3.0 CC=g++ CFLAGS="-O2 -g3" --prefix=$GAUSSHOME --3rd=$BINARYLIBS --enable-thread-safety --without-readline --without-zlib
  • make
  • make install
  • gs_initdb -D /.../dest/dn1 -U user -E UTF-8 --nodename='dn1'
  • gs_guc set -D /.../dest/dn1 -c "port = 35001"

--step2:编译安装dblink

  • cd /..../contrib/dblink/
  • make
  • make install

--step3:启动、连接数据库,进行加载dblink扩展

  • gs_ctl start -D /.../dest/dn1 -Z single_node
  • gsql -r postgres -p 35001
  • create extension dblink;

【预期输出】:
--step1:成功
--step2:成功
--step3:成功

【实际输出】:
--step1:成功
--step2:成功
--step3:报错:The connection to the server was lost. Attempting reset: Failed.

【原因分析】:

  1. 这个问题的根因
  2. 问题推断过程
  3. 还有哪些原因可能造成类似现象
  4. 该问题是否有临时规避措施
  5. 问题解决方案
  6. 预计修复问题时间

【日志信息】(请附上日志文件、截图、coredump信息):
输入图片说明
输入图片说明
#0 BBOX_CreateCoredump (file_name=file_name@entry=0x0) at bbox_create.cpp:404
#1 0x0000562c628f8fdf in bbox_handler (sig=, si=0x7fa9efccb0b0, uc=0x7fa9efccaf80) at gs_bbox.cpp:123
#2
#3 repallocDebug (pointer=0x0, size=size@entry=16, file=file@entry=0x562c674c05c7 "extension.cpp", line=line@entry=2911) at mcxt.cpp:1282
#4 0x0000562c62a812bb in RepallocSessionVarsArrayIfNecessary () at extension.cpp:2910
#5 0x00007fa9ea3f829e in init_session_vars () at dblink.cpp:229
#6 0x0000562c626bfd9a in internal_load_library (libname=libname@entry=0x7fa9edc0a730 "/data/lixin/20220125/pkg/openGauss-server-master/src/dest/lib/postgresql/dblink.so")
at dfmgr.cpp:326
#7 0x0000562c626c0cf2 in load_external_function (filename=, funcname=funcname@entry=0x7fa9edc096c0 "dblink_connect", signalNotFound=signalNotFound@entry=true,
isValidate=isValidate@entry=true) at dfmgr.cpp:109
#8 0x0000562c622e3d7a in fmgr_c_validator (fcinfo=) at pg_proc.cpp:1764
#9 0x0000562c626c6290 in OidFunctionCall3Coll (functionId=functionId@entry=2247, collation=collation@entry=0, arg1=arg1@entry=49157, arg2=arg2@entry=0, arg3=arg3@entry=0)
at fmgr.cpp:1857
#10 0x0000562c622e78d2 in ProcedureCreate (procedureName=0x7fa9ee971a50 "dblink_connect", procNamespace=procNamespace@entry=2200, propackageid=propackageid@entry=0,
isOraStyle=, replace=false, returnsSet=returnsSet@entry=false, returnType=25, proowner=10, languageObjectId=13, languageValidator=2247,
prosrc=0x7fa9edbee910 "dblink_connect", probin=, isAgg=false, isWindowFunc=false, security_definer=false, isLeakProof=false, isStrict=true, volatility=118 'v',
parameterTypes=0x7fa9edc09200, allParameterTypes=0, parameterModes=0, parameterNames=0, parameterDefaults=0x0, proconfig=0, procost=procost@entry=1, prorows=prorows@entry=0,
prodefaultargpos=0x0, fenced=false, shippable=false, package=, proIsProcedure=false, proargsrc=0x0, isPrivate=false) at pg_proc.cpp:1665
#11 0x0000562c62a8a9ff in CreateFunction (stmt=stmt@entry=0x7fa9ee971bd8, queryString=queryString@entry=0x562c64e5182b " ", pkg_oid=pkg_oid@entry=0) at functioncmds.cpp:1125
#12 0x0000562c62c3f8fe in standard_ProcessUtility (parse_tree=parse_tree@entry=0x7fa9ee971bd8, query_string=query_string@entry=0x562c64e5182b " ", params=params@entry=0x0,
is_top_level=, dest=dest@entry=0x7fa9ee10a1f0, sent_to_remote=, completion_tag=0x0, isCTAS=false) at utility.cpp:4653
#13 0x00007faa54358f11 in gsaudit_ProcessUtility_hook (parsetree=0x7fa9ee971bd8, queryString=0x562c64e5182b " ", params=0x0, isTopLevel=, dest=0x7fa9ee10a1f0,
sentToRemote=, completionTag=0x0, isCTAS=false) at gs_policy_plugin.cpp:1062
#14 0x0000562c62c4d9ec in pgaudit_ProcessUtility (parsetree=0x7fa9ee971bd8, queryString=0x562c64e5182b " ", params=, isTopLevel=, dest=,
sentToRemote=, completionTag=0x0, isCTAS=false) at auditfuncs.cpp:1198
#15 0x0000562c62a7ad58 in execute_sql_string (filename=, sql=) at extension.cpp:758
#16 execute_extension_script (extensionOid=extensionOid@entry=49156, control=control@entry=0x7fa9ee971b88, from_version=from_version@entry=0x0,
version=version@entry=0x7fa9ee971cb8 "1.0", requiredSchemas=requiredSchemas@entry=0x0, schemaName=schemaName@entry=0x7fa9ee971b70 "public", schemaOid=2200) at extension.cpp:903
#17 0x0000562c62a7c931 in CreateExtension (stmt=stmt@entry=0x7fa9edb28ab0) at extension.cpp:1438
#18 0x0000562c62c4297e in standard_ProcessUtility (parse_tree=parse_tree@entry=0x7fa9edb28ab0, query_string=query_string@entry=0x7fa9edb28040 "create extension dblink;",
params=params@entry=0x0, is_top_level=, dest=dest@entry=0x7fa9edb28b30, sent_to_remote=, completion_tag=0x7fa9efcd1ac0 "", isCTAS=false)
at utility.cpp:2976
#19 0x00007faa54358f11 in gsaudit_ProcessUtility_hook (parsetree=0x7fa9edb28ab0, queryString=0x7fa9edb28040 "create extension dblink;", params=0x0, isTopLevel=,
dest=0x7fa9edb28b30, sentToRemote=, completionTag=0x7fa9efcd1ac0 "", isCTAS=false) at gs_policy_plugin.cpp:1062
#20 0x0000562c62c4d9ec in pgaudit_ProcessUtility (parsetree=0x7fa9edb28ab0, queryString=0x7fa9edb28040 "create extension dblink;", params=, isTopLevel=,
dest=, sentToRemote=, completionTag=0x7fa9efcd1ac0 "", isCTAS=false) at auditfuncs.cpp:1198
#21 0x0000562c62c31d35 in PortalRunUtility (portal=portal@entry=0x7fa9edbf8040, utilityStmt=utilityStmt@entry=0x7fa9edb28ab0, isTopLevel=isTopLevel@entry=true,
dest=dest@entry=0x7fa9edb28b30, completionTag=completionTag@entry=0x7fa9efcd1ac0 "") at pquery.cpp:1758
#22 0x0000562c62c32c0c in PortalRunMulti (portal=portal@entry=0x7fa9edbf8040, isTopLevel=isTopLevel@entry=true, dest=dest@entry=0x7fa9edb28b30, altdest=altdest@entry=0x7fa9edb28b30,
completionTag=completionTag@entry=0x7fa9efcd1ac0 "") at pquery.cpp:1937
#23 0x0000562c62c356c8 in PortalRun (portal=portal@entry=0x7fa9edbf8040, count=count@entry=9223372036854775807, isTopLevel=isTopLevel@entry=true, dest=dest@entry=0x7fa9edb28b30,
altdest=altdest@entry=0x7fa9edb28b30, completionTag=completionTag@entry=0x7fa9efcd1ac0 "") at pquery.cpp:1183
#24 0x0000562c62c2a034 in exec_simple_query (query_string=, query_string@entry=0x7fa9edb28040 "create extension dblink;", msg=msg@entry=0x7fa9efcd1c50,
messageType=QUERY_MESSAGE) at postgres.cpp:2702
#25 0x0000562c62c2dd33 in PostgresMain (argc=, argv=argv@entry=0x7fa9ee281918, dbname=, username=) at postgres.cpp:8325
#26 0x0000562c62ba3175 in BackendRun (port=port@entry=0x7fa9efcd21f0) at postmaster.cpp:7732
#27 0x0000562c62bc0498 in GaussDbThreadMain<(knl_thread_role)1> (arg=0x7faa35172d28) at postmaster.cpp:11599
#28 0x0000562c62ba31d5 in InternalThreadFunc (args=) at postmaster.cpp:12156
#29 0x00007faa5e8ceea5 in start_thread () from /lib64/libpthread.so.0
#30 0x00007faa5e5f7b0d in clone () from /lib64/libc.so.6

【测试代码】:

评论 (6)

lixin 创建了缺陷

Hey @lixin, Welcome to openGauss Community.
All of the projects in openGauss Community are maintained by @opengauss-bot.
That means the developers can comment below every pull request or issue to trigger Bot Commands.
Please follow instructions at Here to find the details.

lixin 修改了描述
lixin 修改了标题
lixin 修改了描述
lixin 负责人设置为zhangxubo
lixin 关联分支设置为master
lixin 优先级设置为严重
zhangxubo 添加了
 
sig/storageengine
标签

12-23号的PR,移动了初始化扩展插件变量的位置 InitExtensionVariable,导致产生了core

输入图片说明

输入图片说明

zhangxubo 任务状态待办的 修改为已完成
lixin 任务状态已完成 修改为测试中
lixin 任务状态测试中 修改为已验收

登录 后才可以发表评论

状态
负责人
项目
里程碑
Pull Requests
关联的 Pull Requests 被合并后可能会关闭此 issue
分支
开始日期   -   截止日期
-
置顶选项
优先级
预计工期 (小时)
参与者(4)
5622128 opengauss bot 1581905080
C++
1
https://gitee.com/opengauss/openGauss-server.git
git@gitee.com:opengauss/openGauss-server.git
opengauss
openGauss-server
openGauss-server

搜索帮助