首页 > 其他分享 >gs-probackup在集群中的备份与恢复

gs-probackup在集群中的备份与恢复

时间:2024-04-17 11:47:55浏览次数:26  
标签:10 01 gs LOG unknown 备份 12 2021 probackup

gs-probackup 在集群中的备份与恢复
集群状态(一主一备):

[omm@ecs-268e-0004 ~]$ gs_om -t status --detail
[ Cluster State ]
cluster_state : Normal
redistributing : No
current_az : AZ_ALL
[ Datanode State ]
node node_ip instance state | node node_ip instance state

1 ecs-268e-0004 ... 6001 /opt/data/dn1 P Primary Normal | 2 ecs-268e-0005 ...76 6002 /opt/data/dn1 S Standby Normal
Standby Normal 备份列表:

[omm@ecs-268e-0004 ~]$ gs_probackup show -B /opt/probackupdir/

BACKUP INSTANCE 'opengauss0111'

Instance Version ID Recovery Time Mode WAL Mode TLI Time Data WAL Zratio Start LSN Stop LSN Status

opengauss0111 9.2 QMRYNK 2021-01-11 22:52:33+08 FULL STREAM 1/0 13s 587MB 16MB 0.97 0/8000028 0/80001E0 OK
opengauss0111 9.2 QMRY1K 2021-01-11 22:39:22+08 FULL STREAM 1/0 14s 587MB 16MB 0.97 0/6000028 0/60001E0 OK
主库恢复成其他集群单主库
[omm@ecs-268e-0004 ~]$ cd /opt/data/
[omm@ecs-268e-0004 data]$ gs_probackup restore -B /opt/probackupdir/ --instance opengauss0111 -D /opt/data/db1 -i QMRYNK
LOG: Restore begin.
LOG: there is no file tablespace_map
LOG: check tablespace directories of backup QMRYNK
LOG: check external directories of backup QMRYNK
WARNING: Process 535458 which used backup QMRYNK no longer exists
INFO: Validating backup QMRYNK
INFO: Backup QMRYNK data files are valid
LOG: Thread [1]: Opening WAL segment "/opt/probackupdir/backups/opengauss0111/QMRYNK/database/pg_xlog/000000010000000000000008"
INFO: Backup QMRYNK WAL segments are valid
INFO: Backup QMRYNK is valid.
INFO: Restoring the database from backup at 2021-01-11 22:52:32+08
LOG: there is no file tablespace_map
LOG: Restore directories and symlinks...
INFO: Start restoring backup files. PGDATA size: 587MB
LOG: Start thread 1
INFO: Backup files are restored. Transfered bytes: 603MB, time elapsed: 0
INFO: Restore incremental ratio (less is better): 103% (603MB/587MB)
INFO: Syncing restored files to disk
INFO: Restored backup files are synced, time elapsed: 9s
INFO: Restore of backup QMRYNK completed.
修改端口和 replinfo:

修改为与当前集群不同的端口号:

[omm@ecs-268e-0004 ~]$ cd /opt/data/db1
[omm@ecs-268e-0004 db1]$ cat postgresql.conf | grep 'port '
port = 25000 # (change requires restart)
作为单主启动,注释 replconninfo1 这一行:

[omm@ecs-268e-0004 db1]$ cat postgresql.conf | grep 'replconninfo1'

replconninfo1 = 'localhost=... localport=26001 localheartbeatport=26005 localservice=26004 remotehost=...76 remoteport=26001 remoteheartbeatport=26005 remoteservice=26004' # replication connection information used to connect primary on standby, or standby on primary,

[omm@ecs-268e-0004 data]$ gs_ctl -D /opt/data/db1/ start
[2021-01-12 10:14:46.150][553923][][gs_ctl]: gs_ctl started,datadir is /opt/data/db1
[2021-01-12 10:14:46.193][553923][][gs_ctl]: waiting for server to start...
.0 LOG: [Alarm Module]can not read GAUSS_WARNING_TYPE env.

0 LOG: [Alarm Module]Host Name: ecs-268e-0004

0 LOG: [Alarm Module]Host IP: ...

0 LOG: [Alarm Module]Cluster Name: gauss_omm

0 LOG: [Alarm Module]Invalid data in AlarmItem file! Read alarm English name failed! line: 52

0 WARNING: failed to open feature control file, please check whether it exists: FileName=gaussdb.version, Errno=2, Errmessage=No such file or directory.
0 WARNING: failed to parse feature control file: gaussdb.version.
0 WARNING: Failed to load the product control file, so gaussdb cannot distinguish product version.
0 LOG: Failed to initialze environment for codegen.
0 WARNING: bbox_dump_path is set to /opt/data/corefile/

2021-01-12 10:14:46.282 5ffd0616.1 [unknown] 281457534107664 [unknown] 0 dn_6001_6002 DB010 0 [REDO] LOG: Recovery parallelism, cpu count = 4, max = 4, actual = 4
2021-01-12 10:14:46.282 5ffd0616.1 [unknown] 281457534107664 [unknown] 0 dn_6001_6002 DB010 0 [REDO] LOG: ConfigRecoveryParallelism, true_max_recovery_parallelism:4, max_recovery_parallelism:4
2021-01-12 10:14:46.282 5ffd0616.1 [unknown] 281457534107664 [unknown] 0 dn_6001_6002 00000 0 [BACKEND] LOG: [Alarm Module]can not read GAUSS_WARNING_TYPE env.

2021-01-12 10:14:46.282 5ffd0616.1 [unknown] 281457534107664 [unknown] 0 dn_6001_6002 00000 0 [BACKEND] LOG: [Alarm Module]Host Name: ecs-268e-0004

2021-01-12 10:14:46.282 5ffd0616.1 [unknown] 281457534107664 [unknown] 0 dn_6001_6002 00000 0 [BACKEND] LOG: [Alarm Module]Host IP: ...

2021-01-12 10:14:46.282 5ffd0616.1 [unknown] 281457534107664 [unknown] 0 dn_6001_6002 00000 0 [BACKEND] LOG: [Alarm Module]Cluster Name: gauss_omm

2021-01-12 10:14:46.282 5ffd0616.1 [unknown] 281457534107664 [unknown] 0 dn_6001_6002 00000 0 [BACKEND] LOG: [Alarm Module]Invalid data in AlarmItem file! Read alarm English name failed! line: 52

2021-01-12 10:14:46.282 5ffd0616.1 [unknown] 281457534107664 [unknown] 0 dn_6001_6002 00000 0 [BACKEND] LOG: Transparent encryption disabled.

2021-01-12 10:14:46.287 5ffd0616.1 [unknown] 281457534107664 [unknown] 0 dn_6001_6002 00000 0 [BACKEND] LOG: loaded library "security_plugin"
2021-01-12 10:14:46.289 5ffd0616.1 [unknown] 281457534107664 [unknown] 0 dn_6001_6002 01000 0 [BACKEND] WARNING: could not create any HA TCP/IP sockets
2021-01-12 10:14:46.294 5ffd0616.1 [unknown] 281457534107664 [unknown] 0 dn_6001_6002 00000 0 [BACKEND] LOG: InitNuma numaNodeNum: 1 numa_distribute_mode: none inheritThreadPool: 0.
2021-01-12 10:14:46.294 5ffd0616.1 [unknown] 281457534107664 [unknown] 0 dn_6001_6002 01000 0 [BACKEND] WARNING: Failed to initialize the memory protect for g_instance.attr.attr_storage.cstore_buffers (1024 Mbytes) or shared memory (4359 Mbytes) is larger.
2021-01-12 10:14:46.372 5ffd0616.1 [unknown] 281457534107664 [unknown] 0 dn_6001_6002 00000 0 [CACHE] LOG: set data cache size(805306368)
2021-01-12 10:14:46.438 5ffd0616.1 [unknown] 281457534107664 [unknown] 0 dn_6001_6002 00000 0 [CACHE] LOG: set metadata cache size(268435456)
2021-01-12 10:14:46.517 5ffd0616.1 [unknown] 281457534107664 [unknown] 0 dn_6001_6002 00000 0 [BACKEND] LOG: gaussdb: fsync file "/opt/data/db1/gaussdb.state.temp" success
2021-01-12 10:14:46.517 5ffd0616.1 [unknown] 281457534107664 [unknown] 0 dn_6001_6002 00000 0 [BACKEND] LOG: create gaussdb state file success: db state(STARTING_STATE), server mode(Normal)
2021-01-12 10:14:46.732 5ffd0616.1 [unknown] 281457534107664 [unknown] 0 dn_6001_6002 00000 0 [BACKEND] LOG: max_safe_fds = 979, usable_fds = 1000, already_open = 11
bbox_dump_path is set to /opt/data/corefile/
2021-01-12 10:14:46.733 5ffd0616.1 [unknown] 281457534107664 [unknown] 0 dn_6001_6002 00000 0 [BACKEND] LOG: the configure file /opt/data/app/etc/gscgroup_omm.cfg doesn't exist or the size of configure file has changed. Please create it by root user!
2021-01-12 10:14:46.733 5ffd0616.1 [unknown] 281457534107664 [unknown] 0 dn_6001_6002 00000 0 [BACKEND] LOG: Failed to parse cgroup config file.

[2021-01-12 10:14:47.197][553923][][gs_ctl]: done
[2021-01-12 10:14:47.197][553923][][gs_ctl]: server started (/opt/data/db1)
查看进程:

[omm@ecs-268e-0004 data]$ ps ax | grep gaussdb
548647 ? Sl 636:57 /opt/data/app/bin/gaussdb -D /opt/data/dn1 -M primary
553926 pts/1 Sl 0:02 /opt/data/app/bin/gaussdb -D /opt/data/db1
554026 pts/1 S+ 0:00 grep --color=auto gaussdb
主库恢复成当前集群中一台从库
[omm@ecs-268e-0004 ~]$ scp -r /opt/data/db1/ ecs-268e-0005:/opt/data/

Authorized users only. All activities may be monitored and reported.
000000000000 100% 8192 16.5MB/s 00:00
000000000000 100% 8192 22.4MB/s 00:00
gswlm_userinfo.cfg 100% 4800KB 325.2MB/s 00:00
000000000000 100% 8192 24.2MB/s 00:00
cacert.pem 100% 4399 14.4MB/s 00:00
postgresql.conf.lock 100% 1024 3.7MB/s 00:00
server.crt 100% 4402 14.1MB/s 00:00
backup_label.old 100% 228 750.0KB/s 00:00
postgresql.conf 100% 38KB 85.0MB/s 00:00
postmaster.opts 100% 47 159.6KB/s 00:00
pg_hba.conf.lock 100% 1024 3.7MB/s 00:00
server.key 100% 1766 5.4MB/s 00:00
pg_hba.conf.bak 100% 4582 14.9MB/s 00:00
000000000000 100% 256KB 250.0MB/s 00:00
...
将之前从库配置文件覆盖到 db1 目录:

[omm@ecs-268e-0005 ~]$ gs_ctl stop -D /opt/data/dn1/ -m f
[2021-01-12 10:19:47.793][148295][][gs_ctl]: gs_ctl stopped ,datadir is /opt/data/dn1
waiting for server to shut down.... done
server stopped
[omm@ecs-268e-0005 ~]$ cd /opt/data/db1/
[omm@ecs-268e-0005 db1]$ ls
backup_label.old gswlm_userinfo.cfg pg_errorinfo pg_llog pg_serial PG_VERSION postmaster.opts server.key.rand
base mot.conf pg_hba.conf pg_location pg_snapshots pg_xlog postmaster.pid
cacert.pem pg_clog pg_hba.conf.bak pg_multixact pg_stat_tmp postgresql.conf server.crt
gaussdb.state pg_csnlog pg_hba.conf.lock pg_notify pg_tblspc postgresql.conf.bak server.key
global pg_ctl.lock pg_ident.conf pg_replslot pg_twophase postgresql.conf.lock server.key.cipher
[omm@ecs-268e-0005 db1]$ mv postgresql.conf postgresql.conf.primary
[omm@ecs-268e-0005 db1]$ cp ../dn1/postgresql.conf ./
[omm@ecs-268e-0005 db1]$ cd ..
[omm@ecs-268e-0005 data]$ ls
app app_392c0438 corefile db1 dn1 dn1.cp gaussdb_log tmp tool
[omm@ecs-268e-0005 data]$ mv dn1 dn1.org
[omm@ecs-268e-0005 data]$ mv db1 dn1
启动并查看集群状态:

[2021-01-12 10:21:58.576][148447][][gs_ctl]: gs_ctl started,datadir is /opt/data/dn1 -M standby
[2021-01-12 10:21:58.620][148447][][gs_ctl]: waiting for server to start...
.0 LOG: [Alarm Module]can not read GAUSS_WARNING_TYPE env.

0 LOG: [Alarm Module]Host Name: ecs-268e-0005

0 LOG: [Alarm Module]Host IP: ...

0 LOG: [Alarm Module]Cluster Name: gauss_omm

0 LOG: [Alarm Module]Invalid data in AlarmItem file! Read alarm English name failed! line: 52

0 WARNING: failed to open feature control file, please check whether it exists: FileName=gaussdb.version, Errno=2, Errmessage=No such file or directory.
0 WARNING: failed to parse feature control file: gaussdb.version.
0 WARNING: Failed to load the product control file, so gaussdb cannot distinguish product version.
0 LOG: Failed to initialze environment for codegen.
0 WARNING: bbox_dump_path is set to /opt/data/corefile/

2021-01-12 10:21:58.709 5ffd07c6.1 [unknown] 281462476636176 [unknown] 0 dn_6001_6002 DB010 0 [REDO] LOG: Recovery parallelism, cpu count = 4, max = 4, actual = 4
2021-01-12 10:21:58.709 5ffd07c6.1 [unknown] 281462476636176 [unknown] 0 dn_6001_6002 DB010 0 [REDO] LOG: ConfigRecoveryParallelism, true_max_recovery_parallelism:4, max_recovery_parallelism:4
2021-01-12 10:21:58.709 5ffd07c6.1 [unknown] 281462476636176 [unknown] 0 dn_6001_6002 00000 0 [BACKEND] LOG: [Alarm Module]can not read GAUSS_WARNING_TYPE env.

2021-01-12 10:21:58.709 5ffd07c6.1 [unknown] 281462476636176 [unknown] 0 dn_6001_6002 00000 0 [BACKEND] LOG: [Alarm Module]Host Name: ecs-268e-0005

2021-01-12 10:21:58.709 5ffd07c6.1 [unknown] 281462476636176 [unknown] 0 dn_6001_6002 00000 0 [BACKEND] LOG: [Alarm Module]Host IP: ...

2021-01-12 10:21:58.709 5ffd07c6.1 [unknown] 281462476636176 [unknown] 0 dn_6001_6002 00000 0 [BACKEND] LOG: [Alarm Module]Cluster Name: gauss_omm

2021-01-12 10:21:58.709 5ffd07c6.1 [unknown] 281462476636176 [unknown] 0 dn_6001_6002 00000 0 [BACKEND] LOG: [Alarm Module]Invalid data in AlarmItem file! Read alarm English name failed! line: 52

2021-01-12 10:21:58.709 5ffd07c6.1 [unknown] 281462476636176 [unknown] 0 dn_6001_6002 00000 0 [BACKEND] LOG: Transparent encryption disabled.

2021-01-12 10:21:58.712 5ffd07c6.1 [unknown] 281462476636176 [unknown] 0 dn_6001_6002 00000 0 [BACKEND] LOG: loaded library "security_plugin"
2021-01-12 10:21:58.718 5ffd07c6.1 [unknown] 281462476636176 [unknown] 0 dn_6001_6002 00000 0 [BACKEND] LOG: InitNuma numaNodeNum: 1 numa_distribute_mode: none inheritThreadPool: 0.
2021-01-12 10:21:58.718 5ffd07c6.1 [unknown] 281462476636176 [unknown] 0 dn_6001_6002 01000 0 [BACKEND] WARNING: Failed to initialize the memory protect for g_instance.attr.attr_storage.cstore_buffers (1024 Mbytes) or shared memory (4359 Mbytes) is larger.
2021-01-12 10:21:58.718 5ffd07c6.1 [unknown] 281462476636176 [unknown] 0 dn_6001_6002 00000 0 [BACKEND] LOG: choose next key because the shm of key 26000001 is not one of mine
2021-01-12 10:21:58.810 5ffd07c6.1 [unknown] 281462476636176 [unknown] 0 dn_6001_6002 00000 0 [CACHE] LOG: set data cache size(805306368)
2021-01-12 10:21:58.880 5ffd07c6.1 [unknown] 281462476636176 [unknown] 0 dn_6001_6002 00000 0 [CACHE] LOG: set metadata cache size(268435456)
2021-01-12 10:21:58.961 5ffd07c6.1 [unknown] 281462476636176 [unknown] 0 dn_6001_6002 00000 0 [BACKEND] LOG: gaussdb: fsync file "/opt/data/dn1/gaussdb.state.temp" success
2021-01-12 10:21:58.961 5ffd07c6.1 [unknown] 281462476636176 [unknown] 0 dn_6001_6002 00000 0 [BACKEND] LOG: create gaussdb state file success: db state(STARTING_STATE), server mode(Normal)
2021-01-12 10:21:59.045 5ffd07c6.1 [unknown] 281462476636176 [unknown] 0 dn_6001_6002 00000 0 [BACKEND] LOG: max_safe_fds = 979, usable_fds = 1000, already_open = 11
bbox_dump_path is set to /opt/data/corefile/
2021-01-12 10:21:59.047 5ffd07c6.1 [unknown] 281462476636176 [unknown] 0 dn_6001_6002 00000 0 [BACKEND] LOG: the configure file /opt/data/app/etc/gscgroup_omm.cfg doesn't exist or the size of configure file has changed. Please create it by root user!
2021-01-12 10:21:59.047 5ffd07c6.1 [unknown] 281462476636176 [unknown] 0 dn_6001_6002 00000 0 [BACKEND] LOG: Failed to parse cgroup config file.

[2021-01-12 10:21:59.624][148447][][gs_ctl]: done
[2021-01-12 10:21:59.624][148447][][gs_ctl]: server started (/opt/data/dn1)
查看集群状态:

[omm@ecs-268e-0005 data]$ gs_om -t status --detail
[omm@ecs-268e-0004 opengauss0125]$ gs_om -t status --detail
[ Cluster State ]

cluster_state : Normal
redistributing : No
current_az : AZ_ALL

[ Datanode State ]

node node_ip instance state | node node_ip instance state

1 ecs-268e-0004 ... 6001 /opt/data/dn1 P Primary Normal | 2 ecs-268e-0005 ...76 6002 /opt/data/dn1 S Standby Normal
从库恢复为集群中其他从库
查看当前从库备份情况:

[omm@ecs-268e-0005 data]$ gs_probackup show -B /opt/probackupdir/

BACKUP INSTANCE 'opengauss0111'

Instance Version ID Recovery Time Mode WAL Mode TLI Time Data WAL Zratio Start LSN Stop LSN Status

opengauss0111 9.2 QMS0OU 2021-01-11 23:36:35+08 FULL STREAM 1/0 1m:7s 571MB 16MB 1.00 0/C000028 0/C0000A8 OK
opengauss0111 9.2 QMS07L 2021-01-11 23:26:10+08 FULL STREAM 1/0 1m:2s 571MB 16MB 1.00 0/B0006B8 0/B000738 OK
opengauss0111 9.2 QMRZXH ---- FULL STREAM 1/0 11h:4m 96kB 0 1.00 0/A000028 0/0 RUNNING
恢复到指定目录:

[omm@ecs-268e-0005 data]$ gs_probackup restore -B /opt/probackupdir/ --instance opengauss0111 -D /opt/data/dm1 -i QMS0OU
LOG: Restore begin.
LOG: there is no file tablespace_map
LOG: check tablespace directories of backup QMS0OU
LOG: check external directories of backup QMS0OU
WARNING: Process 135121 which used backup QMS0OU no longer exists
INFO: Validating backup QMS0OU
INFO: Backup QMS0OU data files are valid
LOG: Thread [1]: Opening WAL segment "/opt/probackupdir/backups/opengauss0111/QMS0OU/database/pg_xlog/00000001000000000000000C"
INFO: Backup QMS0OU WAL segments are valid
INFO: Backup QMS0OU is valid.
INFO: Restoring the database from backup at 2021-01-11 23:36:30+08
LOG: there is no file tablespace_map
LOG: Restore directories and symlinks...
INFO: Start restoring backup files. PGDATA size: 587MB
LOG: Start thread 1
INFO: Backup files are restored. Transfered bytes: 587MB, time elapsed: 0
INFO: Restore incremental ratio (less is better): 100% (587MB/587MB)
INFO: Syncing restored files to disk
INFO: Restored backup files are synced, time elapsed: 7s
INFO: Restore of backup QMS0OU completed.
关闭当前从库,启动恢复的从库,查看集群状态:

[omm@ecs-268e-0005 data]$ gs_ctl stop -m f -D /opt/data/dn1
[2021-01-12 10:27:54.035][148973][][gs_ctl]: gs_ctl stopped ,datadir is /opt/data/dn1
waiting for server to shut down......... done
server stopped

[2021-01-12 10:28:09.339][148991][][gs_ctl]: gs_ctl started,datadir is /opt/data/dm1
[2021-01-12 10:28:09.383][148991][][gs_ctl]: waiting for server to start...
.0 LOG: [Alarm Module]can not read GAUSS_WARNING_TYPE env.

0 LOG: [Alarm Module]Host Name: ecs-268e-0005

0 LOG: [Alarm Module]Host IP: ...

0 LOG: [Alarm Module]Cluster Name: gauss_omm

0 LOG: [Alarm Module]Invalid data in AlarmItem file! Read alarm English name failed! line: 52

0 WARNING: failed to open feature control file, please check whether it exists: FileName=gaussdb.version, Errno=2, Errmessage=No such file or directory.
0 WARNING: failed to parse feature control file: gaussdb.version.
0 WARNING: Failed to load the product control file, so gaussdb cannot distinguish product version.
0 LOG: Failed to initialze environment for codegen.
0 WARNING: bbox_dump_path is set to /opt/data/corefile/

2021-01-12 10:28:09.473 5ffd0939.1 [unknown] 281473532821520 [unknown] 0 dn_6001_6002 DB010 0 [REDO] LOG: Recovery parallelism, cpu count = 4, max = 4, actual = 4
2021-01-12 10:28:09.473 5ffd0939.1 [unknown] 281473532821520 [unknown] 0 dn_6001_6002 DB010 0 [REDO] LOG: ConfigRecoveryParallelism, true_max_recovery_parallelism:4, max_recovery_parallelism:4
2021-01-12 10:28:09.473 5ffd0939.1 [unknown] 281473532821520 [unknown] 0 dn_6001_6002 00000 0 [BACKEND] LOG: [Alarm Module]can not read GAUSS_WARNING_TYPE env.

2021-01-12 10:28:09.473 5ffd0939.1 [unknown] 281473532821520 [unknown] 0 dn_6001_6002 00000 0 [BACKEND] LOG: [Alarm Module]Host Name: ecs-268e-0005

2021-01-12 10:28:09.473 5ffd0939.1 [unknown] 281473532821520 [unknown] 0 dn_6001_6002 00000 0 [BACKEND] LOG: [Alarm Module]Host IP: ...

2021-01-12 10:28:09.473 5ffd0939.1 [unknown] 281473532821520 [unknown] 0 dn_6001_6002 00000 0 [BACKEND] LOG: [Alarm Module]Cluster Name: gauss_omm

2021-01-12 10:28:09.473 5ffd0939.1 [unknown] 281473532821520 [unknown] 0 dn_6001_6002 00000 0 [BACKEND] LOG: [Alarm Module]Invalid data in AlarmItem file! Read alarm English name failed! line: 52

2021-01-12 10:28:09.473 5ffd0939.1 [unknown] 281473532821520 [unknown] 0 dn_6001_6002 00000 0 [BACKEND] LOG: Transparent encryption disabled.

2021-01-12 10:28:09.476 5ffd0939.1 [unknown] 281473532821520 [unknown] 0 dn_6001_6002 00000 0 [BACKEND] LOG: loaded library "security_plugin"
2021-01-12 10:28:09.482 5ffd0939.1 [unknown] 281473532821520 [unknown] 0 dn_6001_6002 00000 0 [BACKEND] LOG: InitNuma numaNodeNum: 1 numa_distribute_mode: none inheritThreadPool: 0.
2021-01-12 10:28:09.482 5ffd0939.1 [unknown] 281473532821520 [unknown] 0 dn_6001_6002 01000 0 [BACKEND] WARNING: Failed to initialize the memory protect for g_instance.attr.attr_storage.cstore_buffers (1024 Mbytes) or shared memory (4359 Mbytes) is larger.
2021-01-12 10:28:09.482 5ffd0939.1 [unknown] 281473532821520 [unknown] 0 dn_6001_6002 00000 0 [BACKEND] LOG: choose next key because the shm of key 26000001 is not one of mine
2021-01-12 10:28:09.571 5ffd0939.1 [unknown] 281473532821520 [unknown] 0 dn_6001_6002 00000 0 [CACHE] LOG: set data cache size(805306368)
2021-01-12 10:28:09.646 5ffd0939.1 [unknown] 281473532821520 [unknown] 0 dn_6001_6002 00000 0 [CACHE] LOG: set metadata cache size(268435456)
2021-01-12 10:28:09.728 5ffd0939.1 [unknown] 281473532821520 [unknown] 0 dn_6001_6002 00000 0 [BACKEND] LOG: gaussdb: fsync file "/opt/data/dm1/gaussdb.state.temp" success
2021-01-12 10:28:09.728 5ffd0939.1 [unknown] 281473532821520 [unknown] 0 dn_6001_6002 00000 0 [BACKEND] LOG: create gaussdb state file success: db state(STARTING_STATE), server mode(Normal)
2021-01-12 10:28:09.789 5ffd0939.1 [unknown] 281473532821520 [unknown] 0 dn_6001_6002 00000 0 [BACKEND] LOG: max_safe_fds = 979, usable_fds = 1000, already_open = 11
bbox_dump_path is set to /opt/data/corefile/
2021-01-12 10:28:09.791 5ffd0939.1 [unknown] 281473532821520 [unknown] 0 dn_6001_6002 00000 0 [BACKEND] LOG: the configure file /opt/data/app/etc/gscgroup_omm.cfg doesn't exist or the size of configure file has changed. Please create it by root user!
2021-01-12 10:28:09.791 5ffd0939.1 [unknown] 281473532821520 [unknown] 0 dn_6001_6002 00000 0 [BACKEND] LOG: Failed to parse cgroup config file.

[2021-01-12 10:28:10.387][148991][][gs_ctl]: done
[2021-01-12 10:28:10.387][148991][][gs_ctl]: server started (/opt/data/dm1)

[omm@ecs-268e-0005 data]$ gs_om -t status --detail
[ Cluster State ]

cluster_state : Degraded
redistributing : No
current_az : AZ_ALL

[ Datanode State ]

node node_ip instance state | node node_ip instance state

1 ecs-268e-0004 ... 6001 /opt/data/dn1 P Primary Normal | 2 ecs-268e-0005 ...76 6002 /opt/data/dn1 S Down Manually stopped
查看集群状态:

[omm@ecs-268e-0004 ~]$ gs_om -t status --detail
[ Cluster State ]

cluster_state : Degraded
[omm@ecs-268e-0004 opengauss0125]$ gs_om -t status --detail
[ Cluster State ]

cluster_state : Normal
redistributing : No
current_az : AZ_ALL

[ Datanode State ]

node node_ip instance state | node node_ip instance state

1 ecs-268e-0004 ... 6001 /opt/data/dn1 P Primary Normal | 2 ecs-268e-0005 ...76 6002 /opt/data/dn1 S Standby Normal

[omm@ecs-268e-0004 ~]$
正常。

标签:10,01,gs,LOG,unknown,备份,12,2021,probackup
From: https://www.cnblogs.com/helloopenGauss/p/18140214

相关文章

  • openGauss中使用gs_initdb时保留旧配置
    openGauss中使用gs_initdb时保留旧配置一、使用场景该需求来源于社区issue:重建库脚本。在开发过程中,可能会修改系统表,或者各种debug情况下导致的库坏掉的情况,建议增加一种重建数据库的脚本。当前可以通过重新安装或gs_initdb建一个新库解决该问题,但用户觉得重装比较......
  • C:\Windows\System32\spool 目录中,这个目录是与打印相关的系统服务的默认位置。 Pr
    C:\Windows\System32\spool目录中,这个目录是与打印相关的系统服务的默认位置。作用:drivers:这个文件夹包含了打印机驱动程序文件。Windows系统使用这些驱动程序来与不同类型和品牌的打印机进行通信。PRINTERS:这个文件夹通常用于存储正在打印的文档的临时文件。当......
  • MySQL 8:备份&导入【备忘】
    mysql8.0.25、8.0.32--- 序章使用命令(mysqldump)备份旧数据库的数据——sql文件。使用命令(mysql>source)导入备份数据到新数据库。 mysqldump导出为sql文件使用只导出数据不导出结构:整个数据库mysqldump-t数据库名-uroot-p>xxx.sql数据库中某个表my......
  • Settings属性读写
    Settings系统属性存储均为xml,分三种:1.global:所有的偏好设置对系统的所有用户公开,第三方APP有读没有写的权限;对应xml路径:/data/system/users/0/settings_global.xmladb指令读写方法:先adbshell进入终端。读为settingsgetglobal系统属性key写为settingsputglobal系统属......
  • SpringBoot+SpringSecurity6+Jwt最小化代码
    SpringBoot+SpringSecurity6+Jwt最小化代码[toc]零、参考资料https://blog.csdn.net/m0_71273766/article/details/132942056一、快速开始1.1、引入依赖<?xmlversion="1.0"encoding="UTF-8"?><projectxmlns="http://maven.apache.org/POM/4.0.0&quo......
  • 80、SpringBoot3 SpringSecurity Mybatisplus最新版 整合 实现登入权限控制
    1、导入pom依赖<?xmlversion="1.0"encoding="UTF-8"?><projectxmlns="http://maven.apache.org/POM/4.0.0"xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"xsi:schemaLocation="http://maven.apac......
  • [题解][2021-2022年度国际大学生程序设计竞赛第10届陕西省程序设计竞赛] Type The Str
    题目描述给定n个字符串,有以下几种操作:打出一个字符,花费1。删除一个字符,花费1。复制并打出一个之前打出过的字符串,花费k。求打出所有n个字符串的最小花费。(注意,打出顺序和字符串输入的顺序不必相同)题解显然,操作3需要算字符串的最长公共子序列来处理。这个问题可以转换为......
  • TheKingsArmyDiv1
    Topcoder#区间dp考虑\(dp_{l,r,3}\)表示当前考虑区间\([l,r]\),上面一行全部\(H\)的最小代价,下面一行全部\(H\)的最小代价,上下都\(H\)的最小代价转移考虑每次将两段拼起来,或者从现有的拓展一个貌似有贪心做法,不太会喵~~~//Author:xiaruizeconstintN=2e2+10......
  • POI2006ZAB-Frogs
    二分#单调队列#bfs#POI#Year2006具有单调性,二分从上往下考虑每一行,对于每一列维护一个单调队列,考虑维护一个覆盖的区间,表示这一列的最近的圆的位置,然后就可以计算它的覆盖区间用差分计算每个位置是否被覆盖,处理当前长度下每个点是否被覆盖然后\(bfs\)即可//Author:x......
  • PGSQL 问题解决
    1服务无法启动 这里更改安装目录bin下面例如E:\WorkingSoftware\PostgreSql\16\bin更改权限,下面都改下 2  安装时提示database出错,就初始化下执行以下命令E:\WorkingSoftware\PostgreSql\16\bin\pg_ctl.exe-DE:\WorkingSoftware\PostgreSql\16\dat......