启动检查
1、查看进程是否启动
kubectl get pod --all-namespaces
2、登录云基础平台管理后台
https://IP地址/console
例如:https://192.168.0.145/console
3、登录平台租户管理中心(MC)
http://IP地址:8090/mc
例如:http://192.168.0.145:8090/mc
问题简述:
Gpass容器环境,服务器重启后,打开MC提示数据库连接失败。
据库配置或表结构不正确;Conection to refused;TCP/IP connections
{"description”:"数据库配置或表结构不正确,请联系系统管理员。。原因:Get db conmection failed: Connection to 192.168.18.47:5432 refused. Check that the hostnam and port are correct and that the postmaster is accepting 1CP/IP connections.","description_cn”:”数据库配置或表结构不正确,请联系系统管理员。”,"errorcode":"bos.sQLConnection"}
处理方法
检查PostgreSQL是否启动:ss -tulpn | grep 5432,发现PostgreSQL并没有启动。
可通过下面的命令启动PostgreSQL,等待几分钟,检查是否恢复正常。
# CentOS/RHEL
sudo systemctl start postgresql
# Debian/Ubuntu
sudo service postgresql start
建议发方法
设置开机启动pg数据库
# 启动PostgreSQL服务
sudo systemctl start postgresql
# 设置PostgreSQL服务开机启动
sudo systemctl enable postgresql
# 检查PostgreSQL服务的启动状态
sudo systemctl status postgresql