Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1hq5EC-0007g0-Mv for pgsql-hackers@arkaria.postgresql.org; Wed, 24 Jul 2019 00:33:57 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1hq5EB-0002XO-Be for pgsql-hackers@arkaria.postgresql.org; Wed, 24 Jul 2019 00:33:55 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1hq5EA-0002VH-Tq for pgsql-hackers@lists.postgresql.org; Wed, 24 Jul 2019 00:33:55 +0000 Received: from mail-io1-xd43.google.com ([2607:f8b0:4864:20::d43]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1hq5E4-0002yt-2K for pgsql-hackers@postgresql.org; Wed, 24 Jul 2019 00:33:54 +0000 Received: by mail-io1-xd43.google.com with SMTP id f4so85842721ioh.6 for ; Tue, 23 Jul 2019 17:33:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=telsasoft-com.20150623.gappssmtp.com; s=20150623; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=cC771xIbSfOYKBaSz+lV4fFu6Y5nrqUF/MqkjVclLGA=; b=HF9LwjDr3Xwt740bFxJtaFhx7Zt4hqhfM3cCv4jaTNULNf4rEqTI1UZaqduOdYVF3M lEx1CD1v95ckZCSv2dQC/CmqeDoODw8lWcN4K7FqVI/kxLDDEpe9TcS5Zha5huc05iD1 oUG8hpHmbEIzIuqjb2vDr7Qlwakere3OppkBIckYdXwT6laLFzxHrXOGtWySCN5Pl2Nl jiwMEPpVc0Bq4LEUU6RyGJFTLehRUI//0eaaUbl4DJBYEQrp2SGreP9YJ04+1956vhP/ ouYu6vde9/wHvriBevfmwE5SMfx4cjRyiRdfbnqLcCfewnSG6tYFZYLOq22wH9UXHpzG kelA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=cC771xIbSfOYKBaSz+lV4fFu6Y5nrqUF/MqkjVclLGA=; b=HLa4Yh756SenQYq8ytqpmMzCfxSGeEERT/lOfEEME6RZ1BwVti8ZG46+9XGjKeUEr9 vsyhIabbYXOgjV4kPohAQDYRrd/DyD8p0WBooNCLzZ6MpSHlgp2lE45c+woUQ7qdrK/+ m0W5Ah+tCnUHqj0V8Zp6VQYU3RuFsTAtanYuslW83ZBtc8gf84vQMo7mwboPjWjnU3f8 pNMKiQHK+RqzMjsrJk/D045tpMi7LZ/Ii/f266TzlGfFLZD9BQmwTOsXtHwYUG03VlvF APpwzVxfxDyI15UXh2lXX30uITYa6fTdgT4IA63iSM7KiIf3R98XOcAWHTmClKeo/xeX t5rA== X-Gm-Message-State: APjAAAV2SyET1HWB5sAX6C1X45q1S3N/ndxhLfk7OUGd6b9QeNZFNq/W xg0XEhcRTY2StrD027CgKjk= X-Google-Smtp-Source: APXvYqx9IqdLFXxMv2QLSrixrZd5QaooRfv4CtOuxAsdj57HAqFrHhqV42NOh9UhGqJmERGfzmQPgg== X-Received: by 2002:a02:13c3:: with SMTP id 186mr80613741jaz.30.1563928425920; Tue, 23 Jul 2019 17:33:45 -0700 (PDT) Received: from pryzbyj (charmander.telsasoft.com. [50.244.222.1]) by smtp.gmail.com with ESMTPSA id t133sm65426356iof.21.2019.07.23.17.33.44 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 23 Jul 2019 17:33:45 -0700 (PDT) Received: by pryzbyj (Postfix, from userid 1000) id B86FD8008C2; Tue, 23 Jul 2019 19:33:43 -0500 (CDT) Date: Tue, 23 Jul 2019 19:33:43 -0500 From: Justin Pryzby To: Thomas Munro Cc: Tom Lane , pgsql-hackers Subject: Re: stress test for parallel workers Message-ID: <20190724003343.GV22387@telsasoft.com> References: <20190723162703.GM22387@telsasoft.com> <6762.1563902927@sss.pgh.pa.us> <20190723174222.GO22387@telsasoft.com> <20190723224255.GT22387@telsasoft.com> <20190723230440.GU22387@telsasoft.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.24 (2015-08-30) List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk On Wed, Jul 24, 2019 at 11:32:30AM +1200, Thomas Munro wrote: > On Wed, Jul 24, 2019 at 11:04 AM Justin Pryzby wrote: > > I ought to have remembered that it *was* in fact out of space this AM when this > > core was dumped (due to having not touched it since scheduling transition to > > this VM last week). > > > > I want to say I'm almost certain it wasn't ENOSPC in other cases, since, > > failing to find log output, I ran df right after the failure. I meant it wasn't a trivial error on my part of failing to drop the previously loaded DB instance. It occured to me to check inodes, which can also cause ENOSPC. This is mkfs -T largefile, so running out of inodes is not an impossibility. But seems an unlikely culprit, unless something made tens of thousands of (small) files. [pryzbyj@alextelsasrv01 ~]$ df -i /var/lib/pgsql Filesystem Inodes IUsed IFree IUse% Mounted on /dev/mapper/data-postgres 65536 5605 59931 9% /var/lib/pgsql > Ok, cool, so the ENOSPC thing we understand, and the postmaster death > thing is probably something entirely different. Which brings us to > the question: what is killing your postmaster or causing it to exit > silently and unexpectedly, but leaving no trace in any operating > system log? You mentioned that you couldn't see any signs of the OOM > killer. Are you in a situation to test an OOM failure so you can > confirm what that looks like on your system? $ command time -v python -c "'x'*4999999999" |wc Traceback (most recent call last): File "", line 1, in MemoryError Command exited with non-zero status 1 ... Maximum resident set size (kbytes): 4276 $ dmesg ... Out of memory: Kill process 10665 (python) score 478 or sacrifice child Killed process 10665, UID 503, (python) total-vm:4024260kB, anon-rss:3845756kB, file-rss:1624kB I wouldn't burn too much more time on it until I can reproduce it. The failures were all during pg_restore, so checkpointer would've been very busy. It seems possible it for it to notice ENOSPC before workers...which would be fsyncing WAL, where checkpointer is fsyncing data. > Admittedly it is quite hard for to distinguish between a web browser > and a program designed to eat memory as fast as possible... Browsers making lots of progress here but still clearly 2nd place. Justin