edit-icon download-icon

The error caused by max_connections during restoring PostgreSQL to local database

Last Updated: Aug 11, 2017

Error description

When restoring the database on ApsaraDB for PostgreSQL to the local database, the following error occurs.

  1. HINT: This error does *not* mean that you have run out of disk space. It occurs when either the system limit for the maximum number of semaphore sets (SEMMNI), or the system wide maximum number of semaphores (SEMMNS), would be exceeded. You need to raise the respective kernel parameter. Alternatively, reduce PostgreSQL's consumption of semaphores by reducing its max_connections parameter.

Solution

This error is caused by the large number of connections. To solve this problem, we recommend that you set the max_connections values of both the master and slave instances to 800 or less.

The max_connections values for the master and slave instances are required to be the same. For details, see Server Configuration and Server Setup and Operation on the official website of PostgreSQL.

Thank you! We've received your feedback.