数据库重启一直显示8001 server is initializing

根据您提供的信息,OceanBase 数据库版本为 4.3.1.0,并且在没有进行任何特殊配置更改或操作的情况下进行了重启。由于数据库无法登录而进行了重启操作,但即使等待了一天时间,OBServer 节点仍然处于初始化状态。这种情况表明 OBServer 节点在启动过程中遇到了某些问题,导致其无法完成初始化。

针对您遇到的情况,建议采取以下步骤进行排查和处理:

  1. 检查日志文件:查看 OBServer 的日志文件,特别是启动期间的日志,以了解更详细的错误信息。日志通常位于 /home/admin/oceanbase/log 目录下。关注日志中是否有明显的错误信息或警告,这些信息可能会揭示初始化失败的原因。

  2. 使用 obdiag 工具进行诊断:如之前所述,使用 obdiag 工具来收集集群的基础信息和其他相关日志,这对于后续的故障排查非常重要。您可以运行如下命令来收集日志:

    obdiag gather scene run --scene=observer.base
    

    收集完成后,将生成的日志压缩包发送给 OceanBase 技术支持团队,以便他们能够帮助您进一步分析问题。

  3. 检查系统资源:确保服务器有足够的资源(如 CPU、内存、磁盘空间等)来支持 OBServer 的启动。资源不足可能导致初始化过程缓慢或失败。

  4. 检查网络状况:确保 OBServer 节点与其他节点之间的网络通信正常,没有丢包或延迟过高的情况。网络问题也可能影响 OBServer 的初始化过程。

  5. 检查配置文件:确认 OBServer 的配置文件(如 config.ini)设置正确,没有错误或遗漏的关键配置项。错误的配置可能导致 OBServer 无法正常启动。

  6. 联系技术支持:如果上述方法均未能解决问题,建议及时联系 OceanBase 的技术支持团队,他们拥有更多的经验和工具来帮助您解决复杂的问题。

希望以上建议能帮助您解决遇到的问题。如果您还有其他疑问或需要进一步的帮助,请随时告知。

检索到的文档如下:

  1. 4000 ~ 4499
  2. 恢复完成后升级租户
  3. 部署 OceanBase 集群
  4. (可选)查看资源
  5. 重启节点
  6. DATABASE
  7. 物理备库同步过程中卡住

(小助手的答复已结束,如未能解决您的问题,请继续提问并等待其他同学的回复,谢谢!)

1 个赞

日志文件太大 我该如何发送呢?

1 个赞

log.7z (29.6 MB)

1 个赞

我刚刚解决了这个问题, 我也发了类似的帖子,咱们的版本还一样。 哈哈哈

我求证几个问题,看看是不是您那边遇到的 , 和我雷同不。

  1. 是否能登录到sys租户 --截图发出来
  2. select * from oceanbase.dba_ob_servers; 看看server的状态 --截图发出来
  3. 是否是obd 如果是obd部署 将该集群的 config.yaml 发出来 文件
1 个赞

你好,
1.无法使用sys登录


2.sql语句无法执行
3.config.yaml文件如下

Only need to configure when remote login is required

#user:

username: root

password: your password if need

key_file: /root/.ssh/id_rsa

port: your ssh port, default 22

timeout: ssh connection timeout (second), default 30

oceanbase-ce:
servers:
# Please don’t use hostname, only IP can be supported

  • 127.0.0.1
    global:

    The working directory for OceanBase Database. OceanBase Database is started under this directory. This is a required field.

    home_path: /data/observer

    The directory for data storage. The default value is $home_path/store.

    data_dir: /data/obdata

    The directory for clog, ilog, and slog. The default value is the same as the data_dir value.

    redo_dir: /data/obredo

    Starting from observer version 4.2, the network selection for the observer is based on the ‘local_ip’ parameter, and the ‘devname’ parameter is no longer mandatory.

    If the ‘local_ip’ parameter is set, the observer will first use this parameter for the configuration, regardless of the ‘devname’ parameter.

    If only the ‘devname’ parameter is set, the observer will use the ‘devname’ parameter for the configuration.

    If neither the ‘devname’ nor the ‘local_ip’ parameters are set, the ‘local_ip’ parameter will be automatically assigned the IP address configured above.

    #devname: enp1s0
    mysql_port: 2881 # External port for OceanBase Database. The default value is 2881. DO NOT change this value after the cluster is started.
    rpc_port: 2882 # Internal port for OceanBase Database. The default value is 2882. DO NOT change this value after the cluster is started.
    zone: zone1

    if current hardware’s memory capacity is smaller than 50G, please use the setting of “mini-single-example.yaml” and do a small adjustment.

    memory_limit: 10G # The maximum running memory for an observer

    The reserved system memory. system_memory is reserved for general tenants. The default value is 30G.

    system_memory: 4G
    datafile_size: 20G # Size of the data file.
    log_disk_size: 10G # The size of disk space used by the clog files.
    enable_syslog_wf: false # Print system logs whose levels are higher than WARNING to a separate log file. The default value is true.
    enable_syslog_recycle: true # Enable auto system log recycling or not. The default value is false.
    max_syslog_file_count: 4 # The maximum number of reserved log files before enabling auto recycling. The default value is 0.
    production_mode: false

    observer cluster name, consistent with obproxy’s cluster_name

    appname: obcluster
    root_password: *** # root user password, can be empty

    proxyro_password: # proxyro user pasword, consistent with obproxy’s observer_sys_password, can be empty

    cluster_id: 1723180277
    proxyro_password: ***
    obproxy-ce:

Set dependent components for the component.

When the associated configurations are not done, OBD will automatically get the these configurations from the dependent components.

depends:

  • oceanbase-ce
    servers:
  • 127.0.0.1
    global:
    listen_port: 2883 # External port. The default value is 2883.
    prometheus_listen_port: 2884 # The Prometheus port. The default value is 2884.
    home_path: /data/obproxy

    oceanbase root server list

    format: ip:mysql_port;ip:mysql_port. When a depends exists, OBD gets this value from the oceanbase-ce of the depends.

    rs_list: 192.168.1.2:2881;192.168.1.3:2881;192.168.1.4:2881

    enable_cluster_checkout: false

    observer cluster name, consistent with oceanbase-ce’s appname. When a depends exists, OBD gets this value from the oceanbase-ce of the depends.

    cluster_name: obcluster

    skip_proxy_sys_private_check: true
    enable_strict_kernel_release: false

    obproxy_sys_password: # obproxy sys user password, can be empty. When a depends exists, OBD gets this value from the oceanbase-ce of the depends.

    observer_sys_password: # proxyro user pasword, consistent with oceanbase-ce’s proxyro_password, can be empty. When a depends exists, OBD gets this value from the oceanbase-ce of the depends.

    obproxy_sys_password: ***
    127.0.0.1:
    proxy_id: 5521
    client_session_id_version: 2
1 个赞

初始化没完成肯定无法登陆啊。
你这个问题我上周碰到过,你的日志里也是有 ,就是无法分配更多的磁盘,所以一直在初始化。

1、先查看下你的obd edit-config 配置 和 节点的上 ~/etc/observer.config.bin 是否一致,具体内存、磁盘分配是多少。
2、检查数据是否占满。
3、用参数手动在server节点启动,
如 :./bin/observer -o “memory_limit=36G,log_disk_size=108G,datafile_size=150G”
根据实际情况,比你当前所配置要扩大磁盘启动。
4、启动好后等待初始化。

2 个赞

memory_limit: 10G
log_disk_size: 10G
datafile_size: 20G

这三个参数 能增加的话 都翻倍。

1 个赞

租户初始化问题导致,这边打不开你发的日志,如果不能扩容参照如下修改试试
使用带参启动 例:./bin/observer -o “memory_limit: 10G”
memory_limit: 10G
system_memory: 2G
log_disk_size: 30G
datafile_size: 50G

1 个赞

您好 kill进程后执行命令报错

配置一下环境变量再试试呢
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:~/oceanbase/lib

使用obd cluster edit-config 修改yaml文件中的参数,与手动启动带的参数一致

datafile_size和log_disk_size配置空间不足这个问题,用什么方式能看当前的使用情况呢?这个配置能否做自动扩容呢?

数据盘分为两种参数1.固定写死datafile_size 2. datafile_disk_percentage(按照磁盘百分比大小分配)部署台ocp服务监控方便进行扩容。


为什么两种查询结果显示的大小不一致呢

你当前参数是怎么设置的

当前参数是这样的

咨询了下相关存储同学,这个查看显示不一致是预期内的。
一个是当前预分配了磁盘大小 另一个是集群存储最大为多少

那就是说当前预分配了100G,集群存储最大是50G,那么超过50G就需要扩还是超过100G需要扩?

快达到100G需要扩容。需要您黑屏去查询监控所有副本大小总和
建议部署个ocp,方便运维

好的了解了