华为openGauss gs_install

网友投稿 831 2022-10-25

本站部分文章、图片属于网络上可搜索到的公开信息,均用于学习和交流用途,不能代表睿象云的观点、立场或意见。我们接受网民的监督,如发现任何违法内容或侵犯了您的权益,请第一时间联系小编邮箱jiasou666@gmail.com 处理。

华为openGauss gs_install

背景信息

数据库的部署是一个复杂的过程。openGauss提供了gs_install工具来帮助完成openGauss的安装和部署。

openGauss安装部署,要求用户指定配置文件,配置文件中会指定程序安装路径、实例数据目录、主备关系、实例数、各实例的业务IP端口等信息。

前提条件

已成功执行前置脚本gs_preinstall。用户需确保各个节点上的locale保持一致。需要使用前置时设置的openGauss用户进行安装操作。

语法

参数说明

-XopenGauss配置文件的路径。取值范围:xml文件的存储路径。-l指定安装日志文件及日志文件存放的路径。当既不明确指定-l,又不在XML文件中配置gaussdbLogPath时,默认值为“$GAUSSLOG/om/gs_install-YYYY-MM-DD_hhmmss.log”;当不明确指定-l,但在XML文件中配置了gaussdbLogPath时,默认值为“gaussdbLogPath的值、用户名和om/gs_install-YYYY-MM-DD_hhmmss.log”的组合。--gsinit-parameter=PARAM数据实例参数指定。取值范围请参见zh-cn_topic_0242223705.md的参数说明,其中对-A、-D、-U、-C、-X参数的设置不生效。--dn-guc=PARAM配置参数。取值范围请参见gs_guc的参数说明。--time-out=SECS启动超时等待时间。单位:s。若--time-out取值过小,有可能会因为需要启动的实例数过多而引起超时。若在超时时间内启动不成功,则会报错启动超时,但是openGauss会在后台继续启动。可以等待一段时间后,查询openGauss状态,检查openGauss是否启动成功。取值范围:正整数,若无特殊需求,不需要配置该参数,系统会自动调整超时时间。--alarm-component=alarm_component指定告警上报组件的绝对路径。--autostart=yes|no用来指定openGauss配置完成后是否启动。yes:启动openGauss。no:不启动openGauss。-?, --help显示帮助信息。-V, --version显示版本号信息。

示例

使用gs_install脚本进行openGauss安装。

gs_install -X /opt/software/openGauss/clusterconfig.xmlParsing the configuration file.Creating the backup directory.Successfully created the backup directory.Installing the cluster.Checking the installation environment on all nodes.Installing applications on all nodes.Cluster installation is completed.Configuring.Deleting instances from all nodes.Checking node configuration on all nodes.Initializing instances on all nodes.Updating instance configuration on all nodes.Configuring pg_hba on all nodes.Configuration is completed.Starting.=====================================================================Starting cluster.======================================================================Successfully started primary instance. Wait for standby instance.======================================================================.Successfully started cluster.======================================================================cluster_state : Normalredistributing : Nonode_count : 3Coordinator State normal : 2 abnormal : 0GTM State primary : 1 standby : 1 abnormal : 0 down : 0Datanode State primary : 3 standby : 3 secondary : 3 building : 0 abnormal : 0 down : 0

相关命令

gs_postuninstall,gs_preinstall,gs_uninstall

上一篇:2020 kubernetes讲座(上)-CKA考试指南(二)kubernetes基础知识
下一篇:达梦DM7使用mybatis示例
相关文章

 发表评论

暂时没有评论,来抢沙发吧~