【标题】(请简要描述下实现的内容)
fix bug about verify parameter of gs_initdb
【实现内容】:
修改gs_initdb的参数校验,校验参数-I和--dms_url不为空
【根因分析】:
由于当-I和--dms_url同时为空的时候,gs_initdb会继续走下去,这里逻辑应该不是不能继续走下去。
【实现方案】:
修改参数-I或--dms_url不为空时,则报错退出gs_initdb
【关联需求或issue】:
#I6Z5GK:【资源池化】gs_initdb --enable-dss 实例化过程,产生core dump
【开发自验报告】:

  1. 请附上自验结果(内容或者截图) 自研结果
    /opt/zx_workroom//source_code/openGauss-server/mppdb_temp_install//bin/gs_initdb -D /home/zx/ss_hatest/dn0 --nodename=single_node -w Gauss_234 --vgname="+data,+log0" --enable-dss --dms_url="0:127.0.0.1:6611,1:127.0.0.1:6711" -I 0 --socketpath="UDS:/home/zx/ss_hatest/dss_home0/.dss_unix_d_socket"
    The files belonging to this database system will be owned by user "zx".
    This user must also own the server process.

The database cluster will be initialized with locale "zh_CN.UTF-8".
The default database encoding has accordingly been set to "UTF8".
gs_initdb: could not find suitable text search configuration for locale "zh_CN.UTF-8"
The default text search configuration will be set to "simple".

creating directory /home/zx/ss_hatest/dn0 ... ok
creating subdirectories ... in shared storage mode ... ok
creating configuration files ... adding dms parameters to configuration files ... ok
selecting default max_connections ... 100
selecting default shared_buffers ... 1024MB
Begin init undo subsystem meta.
[INIT UNDO] Init undo subsystem meta successfully.
creating template1 database in /home/zx/ss_hatest/dn0/base/1 ... The core dump path is an invalid directory
2023-05-25 15:42:42.003 [unknown] [unknown] localhost 140212397903872 0[0:0#0] [BACKEND] WARNING: macAddr is 40049/984840912, sysidentifier is 2624666291/2060485376, randomNum is 4111958784
[SS] Current node:0 initdb first, will become PRIMARY for first-time SS cluster startup.
ok
initializing pg_authid ... ok
setting password ... ok
initializing dependencies ... ok
loading PL/pgSQL server-side language ... ok
creating system views ... ok
creating performance views ... ok
loading system objects' descriptions ... ok
creating collations ... ok
creating conversions ... ok
creating dictionaries ... ok
setting privileges on built-in objects ... ok
initialize global configure for bucketmap length ... ok
creating information schema ... ok
loading foreign-data wrapper for distfs access ... ok
loading foreign-data wrapper for log access ... ok
loading hstore extension ... ok
loading foreign-data wrapper for MOT access ... ok
loading security plugin ... ok
update system tables ... ok
creating snapshots catalog ... ok
vacuuming database template1 ... ok
copying template1 to template0 ... ok
copying template1 to postgres ... ok
freezing database template0 ... ok
freezing database template1 ... ok
freezing database postgres ... ok

WARNING: enabling "trust" authentication for local connections
You can change this by editing pg_hba.conf or using the option -A, or
--auth-local and --auth-host, the next time you run gs_initdb.

Success. You can now start the database server of single node using:

/opt/zx_workroom//source_code/openGauss-server/mppdb_temp_install//bin/gaussdb -D /home/zx/ss_hatest/dn0 --single_node

or
/opt/zx_workroom//source_code/openGauss-server/mppdb_temp_install//bin/gs_ctl start -D /home/zx/ss_hatest/dn0 -Z single_node -l logfile

  1. 是否可以添加fastcheck测试用例,如是,请补充fastcheck用例 否
  2. 是否涉及资料修改,如是,在docs仓库补充资料 否
  3. 是否考虑升级场景(系统表修改、日志持久化以及修改执行态数据格式) 否
  4. 是否考虑在线扩容等扩展场景 否
  5. 是否考虑异常场景/并发场景/前向兼容/性能场景 否
  6. 是否对其他模块产生影响 否

【其他说明】: