1、启动openGauss
• 以操作系统用户omm登录数据库主节点。
• 使用以下命令启动openGauss。
[omm@opengauss ~]$ gs_om -t start
Starting cluster.
=========================================
[SUCCESS] opengauss
2023-11-13 17:38:10.189 [unknown] [unknown] localhost 47781153439104 0[0:0#0] 0 [BACKEND] WARNING: could not create any HA TCP/IP sockets
2023-11-13 17:38:10.189 [unknown] [unknown] localhost 47781153439104 0[0:0#0] 0 [BACKEND] WARNING: could not create any HA TCP/IP sockets
2023-11-13 17:38:10.192 [unknown] [unknown] localhost 47781153439104 0[0:0#0] 0 [BACKEND] WARNING: Failed to initialize the memory protect for g_instance.attr.attr_storage.cstore_buffers (16 Mbytes) or shared memory (3489 Mbytes) is larger.
=========================================
Successfully started.
2、停止openGauss
• 以操作系统用户omm登录数据库主节点。
• 使用以下命令停止openGauss。
[omm@opengauss ~]$ gs_om -t stop
Stopping cluster.
=========================================
Successfully stopped cluster.
=========================================
End stop cluster.
3、查看openGauss
• 以操作系统用户omm登录数据库主节点。
• 使用以下命令查看openGauss。
[omm@opengauss ~]$ gs_om -t status
-----------------------------------------------------------------------
cluster_name : yonath
cluster_state : Normal
redistributing : No
-----------------------------------------------------------------------
[omm@opengauss ~]$ gs_om -t status
-----------------------------------------------------------------------
cluster_name : yonath
cluster_state : Normal
redistributing : No
-----------------------------------------------------------------------
[omm@opengauss ~]$ gs_om -t status --detail
[ Cluster State ]
cluster_state : Normal
redistributing : No
current_az : AZ_ALL
[ Datanode State ]
node node_ip port instance state
--------------------------------------------------------------------------------
1 opengauss 192.168.203.139 26000 6001 /mogdb/data P Primary Normal
[omm@opengauss ~]$ gs_om -t status -h opengauss
-----------------------------------------------------------------------
cluster_state : Normal
redistributing : No
-----------------------------------------------------------------------
node : 1
node_name : opengauss
instance_id : 6001
node_ip : 192.168.203.139
data_path : /mogdb/data
instance_port : 26000
type : Datanode
instance_state : Normal
az_name : AZ1
instance_role : Normal
-----------------------------------------------------------------------