gpadmin-[CRITICAL]:-Error occurred: non-zero rc: 1

一 问题描述

单机上安装Greenplum,初始化gpinitsystem -c initgp_config时报错:

20201118:11:13:10:005064 gpstart:pc205:gpadmin-[CRITICAL]:-Error occurred: non-zero rc: 1
 Command was: 'env GPSESSID=0000000000 GPERA=ade1c97359a87184_201118111308 $GPHOME/bin/pg_ctl -D /data/greenplum/data/master/gpseg-1 -l /data/greenplum/data/master/gpseg-1/pg_log/startup.log -w -t 600 -o " -p 5432 -E " start'
rc=1, stdout='waiting for server to start.... stopped waiting
', stderr='pg_ctl: could not start server

master进程未起来。

查看上面提到的日志/data/greenplum/data/master/gpseg-1/pg_log/startup.log,发现有如下报错:

FATAL","XX000","could not map anonymous shared memory: Cannot allocate memory",,"This error usually means that PostgreSQL's request for a shared memory segment exceeded available memory, swap space, or huge pages. To reduce the request size (currently 234474364 bytes), reduce PostgreSQL's shared memory usage, perhaps by reducing shared_buffers or max_connections.",,,,,,"CreateAnonymousSegment","pg_shmem.c",587,1    0xbe84ec postgres errstart (elog.c:557)

二 出错原因

内存不足

三 解决办法

① vi /etc/sysctl.conf,添加:

vm.overcommit_memory = 2

#使修改生效

sysctl -p

② 给服务器多分配些内存

如果是自己虚拟机的话,可以杀掉服务器上比较占内存的进程

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值