logical replication snapshots

From: Dimitri Maziuk <dmaziuk(at)bmrb(dot)wisc(dot)edu>
To: pgsql-general <pgsql-general(at)lists(dot)postgresql(dot)org>
Subject: logical replication snapshots
Date: 2018-07-23 20:23:04
Message-ID: 3bf34856-efb9-01e8-3147-1e0dff1f7131@bmrb.wisc.edu
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Hi everyone,

I'm playing with logical replication in postgres-10 and I got it to hang
on startup with

> 2018-07-23 13:15:06.577 CDT [18624] FATAL: the database system is starting up
> 2018-07-23 13:15:06.577 CDT [18624] DEBUG: shmem_exit(1): 0 before_shmem_exit callbacks to make
> 2018-07-23 13:15:06.577 CDT [18624] DEBUG: shmem_exit(1): 0 on_shmem_exit callbacks to make
> 2018-07-23 13:15:06.577 CDT [18624] DEBUG: proc_exit(1): 1 callbacks to make
> 2018-07-23 13:15:06.577 CDT [18624] DEBUG: exit(1)
> 2018-07-23 13:15:06.577 CDT [18624] DEBUG: shmem_exit(-1): 0 before_shmem_exit callbacks to make
> 2018-07-23 13:15:06.577 CDT [18624] DEBUG: shmem_exit(-1): 0 on_shmem_exit callbacks to make
> 2018-07-23 13:15:06.577 CDT [18624] DEBUG: proc_exit(-1): 0 callbacks to make
... forever ...

After poking around:

# find /var/lib/pgsql/10/data/pg_logical/snapshots -printf . | wc -c
12727975

It looks like ZFS simply can't handle this many files: `ls` etc. hang
forever.

So my question is, does it have to be that many? And if not, is there a
knob to keep the number down?

TIA
--
Dimitri Maziuk
Programmer/sysadmin
BioMagResBank, UW-Madison -- http://www.bmrb.wisc.edu

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Kevin Brannen 2018-07-23 21:54:07 RE: Improving pg_dump performance
Previous Message Adrian Klaver 2018-07-23 19:58:17 Re: Connections on cluster not being logged