YMatrix 运维常见问题

本文档介绍 YMatrix 运维的常见问题。

1 忘记密码


问题描述

使用 YMatrix 忘记密码。

解决方案

  1. 数据库密码忘记 给数据库用户重新设置一个新的密码。
    =# alter user mxadmin with password 'you password';
  2. 图形化界面的登录密码忘记 查看 /etc/matrixdb/auth.conf
    # sudo cat /etc/matrixdb/auth.conf

2 ssh_exchange_identification: Connection closed by remote host


问题描述 在使用 gpssh 命令,或者使用 ssh 登录命令的时候会遇到如下报错:

ssh_exchange_identification: Connection closed by remote host

问题分析

ssh 连接数超过了限制。

解决方案

  1. 打开目标服务器的 sshd 配置文件
    # vim /etc/ssh/sshd_config
  2. 找到 MaxStartup 参数配置

# MaxStartup 10:30:60

参数配置含义: MaxStartup 三元组形式 10:30:60 10:当连接数达到 10 时就开始拒绝连接,不过不是全部拒绝。 30:当连接数到达 10 时,之后的连接有 30 的概率被拒绝掉。 60:当连接数达到 60 时,之后的连接就全部拒绝了。

  1. 修改参数并将 # 去掉,MaxStartup 30:30:60
  2. 重启 sshd 服务
    systemctl restart sshd 
    # or 
    service sshd restart
  3. 使用 ssh 重新登录。

3 psql: WARNING: database "testdb" must be vacuumed within 529926866 transactions (seg35 192.168.247.129:6005 pid=448116)


日志

psql: WARNING:  database "testdb" must be vacuumed within 529926866 transactions  (seg35 10.162.115.5:6005 pid=448116)
HINT:  To avoid a database shutdown, execute a database-wide VACUUM in that database.
You might also need to commit or roll back old prepared transactions, or drop stale replication slots.
VACUUM

问题分析

事务的 age 超过限制。

解决方案

$ psql -d testdb -c "vacuum freeze;"