On Tue, Oct 10, 2017 at 2:40 PM, pinker <pinker@xxxxxxx> wrote: > Hi to all! > > We've got problem with a very serious repetitive incident on our core > system. Namely, cpu load spikes to 300-400 and the whole db becomes > unresponsive. From db point of view nothing special is happening, memory > looks fine, disks io's are ok and the only problem is huge cpu load. Kernel > parameters that are increasing with load are always the same: The solution here is to reduce the number of connections usually via some kind of connection pooling. Any db server will have a max throughput at around the number of cpu cores == connections (give or take a factor of 2). Outside that performance falls off, and has a very sharp knee on the other side as the # of conns goes up. Reduce connections, db runs faster. Increase it slows until it eventually falls over. pgbouncer and pgpool II are useful on the db end, look at pooling options on the app side as well. -- Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general