linux列出和删除共享内存段
List all shared memories in your Linux Systems
> $ ipcs -m
Delete specific one
> $ ipcrm -M 0x0001869c
如果是pg启动时报错,如下:
FATAL: pre-existing shared memory block (key 5432001, ID 0) is still in use
HINT: If you're sure there are no old server processes still running, remove the shared memory block with the command "ipcrm", or just delete the file "/var/lib/pgsql/data/postmaster.pid".
直接删除postmaster.pid文件即可。