Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1gJROF-0004cE-TO for pgsql-general@arkaria.postgresql.org; Sun, 04 Nov 2018 23:01:08 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1gJROD-0000oO-RQ for pgsql-general@arkaria.postgresql.org; Sun, 04 Nov 2018 23:01:05 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1gJROD-0000oH-B2 for pgsql-general@lists.postgresql.org; Sun, 04 Nov 2018 23:01:05 +0000 Received: from mail-oi1-x234.google.com ([2607:f8b0:4864:20::234]) by makus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1gJROA-0008D9-9S for pgsql-general@lists.postgresql.org; Sun, 04 Nov 2018 23:01:03 +0000 Received: by mail-oi1-x234.google.com with SMTP id c25-v6so5951607oiy.0 for ; Sun, 04 Nov 2018 15:01:02 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:to:references:from:message-id:date:user-agent:mime-version :in-reply-to:content-language; bh=y8EXFhnYW/rF+gBeihZYy+agX95FBHVkSESntVpJX2Q=; b=Mw7jDSlUw3yYB7hcEHQX2xisQ0b3F0pAzKS07EpfycywoLurMozI9XN+UtowveG5Q5 LYoIzi8GfmG8tytvvAsYogVH7PMYp+xF6P9D66luy7YK/ooWC72EIMlZP8g3eKYcc3+R TRmShlmPNJ7v6Dg/wILmb+Ycmll1uNq1m+dF8U8HXLe7IsIlNVEKjnBOBRsidvBipwTn pSOhzBUjprHZqqQIaUVX3I9C68VNJNhDMym4xFmLIUte/v0u8LDNM+/gzlJNFmZlpvEH wOjfN92WxMLCF4fK5GMkMV9wHcLH6jgEKCOg9D0CdeyR+VdgDKIEyr3N/95y4Ysajb+T o/6g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language; bh=y8EXFhnYW/rF+gBeihZYy+agX95FBHVkSESntVpJX2Q=; b=BxZUhs8AOxRVobHj5ryyy1bnJU/uJbOKzREB9jm2Ujr5yL6V/AezSPZuP9qgcp3xBs COPiY32ZYfKv+Smq26sGnpWYwFcK8mNlILaUF27Xc/9ijKS+7vxQw5tPUsGVWdnHdJxG MZZYONyQNutF9kFG7zNqMFi2BLoo/7IknQrIZpKoOSNzGBwUQbWnX0kxQwXcgfc0TtOJ DJGsRdgenGzZco9/975/vp2SbcjNca7+UPh3guynEWqUxm+SduUc/2yPV/74PncdJSSS cS4XAKpDFlZ4BfpAcunZ8VqDyFqTHXaSVF7jPDYD2v+Uj2ohL+cRJC+krvqG2hqs6i2E RWfQ== X-Gm-Message-State: AGRZ1gIeF40pLrrogDDWP+x/OKHByInTJ7bHzWNf2zNr2bq8Ipf9OkEf cV0MpYPURP+F4VigqWAqdxfMKetl X-Google-Smtp-Source: AJdET5ckiRMhBCeqLzyLLP5mZE7U298GOQcRESsZ/W+gW0EZrToCtmK00uH1xM+qMBZ4u69utYUfqw== X-Received: by 2002:aca:68cc:: with SMTP id o73-v6mr3759547oik.293.1541372460976; Sun, 04 Nov 2018 15:01:00 -0800 (PST) Received: from [192.168.1.10] (ip70-171-116-89.no.no.cox.net. [70.171.116.89]) by smtp.googlemail.com with ESMTPSA id q16sm13197955otf.35.2018.11.04.15.00.59 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sun, 04 Nov 2018 15:00:59 -0800 (PST) Subject: Re: Trouble Upgrading Postgres To: pgsql-general@lists.postgresql.org References: <529c7e29-38eb-0b22-379a-f78e638b97bd@aklaver.com> <18968e03-6342-a01e-3423-04642e15390b@aklaver.com> <10885f27-4b59-6e93-38f7-a03c0b96e906@aklaver.com> From: Ron Message-ID: <104d2faa-12c3-1d61-3196-0300c3ef4b93@gmail.com> Date: Sun, 4 Nov 2018 17:00:59 -0600 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.9.1 MIME-Version: 1.0 In-Reply-To: Content-Type: multipart/alternative; boundary="------------DB2CC0B4F3B25AE9FAFE6CEF" Content-Language: en-US List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk This is a multi-part message in MIME format. --------------DB2CC0B4F3B25AE9FAFE6CEF Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit Not enough swap space? On 11/04/2018 04:55 PM, Charles Martin wrote: > Yep, you called it: > > Nov  2 20:30:45 localhost kernel: Out of memory: Kill process 30438 > (postmaster) score 709 or sacrifice child > Nov  2 20:30:45 localhost kernel: Killed process 30438, UID 26, > (postmaster) total-vm:3068900kB, anon-rss:1695392kB, file-rss:1074692kB > > So it's running out of memory when trying to dump this table. The "old" > server has 4GB of ram, the "new" server 20GB. > > > On Sun, Nov 4, 2018 at 3:13 PM Adrian Klaver > wrote: > > On 11/4/18 8:38 AM, Charles Martin wrote: > > > > Adtrian said: > >>> pg_dump: Error message from server: server closed the connection > >>> unexpectedly > > > >  >Is this error the client reporting? > >  >Is this the same that is showing up in the server log? > > > > Yes, that's the client message, i.e. what appeared in the terminal > > window that gave the command. The server log shows: > > > > 2018-11-02 20:30:46 EDT [20405]: [4-1] user=,db= LOG: server process > > (PID 30438) was terminated by signal 9: Killed > > > > 2018-11-02 20:30:46 EDT [20405]: [5-1] user=,db= DETAIL: Failed process > > was running: COPY public.docfile (docfile_pkey, docfileoriginalname, > > ordernumber, versionnum, docfilecontents, docfilepath, d$ > > > > 2018-11-02 20:30:46 EDT [20405]: [6-1] user=,db= LOG: terminating any > > other active server processes > > > > 2018-11-02 20:30:46 EDT [20415]: [10-1] user=,db= WARNING:  terminating > > connection because of crash of another server process > > > > 2018-11-02 20:30:46 EDT [20415]: [11-1] user=,db= DETAIL:  The > > postmaster has commanded this server process to roll back the current > > transaction and exit, because another server process exited abnor$ > > > > > > > >>So where is the server located relative to the pg_dump client? > >>On the same machine? > >>If so is it a virtual machine e.g AWS? > >>Across a local or remote network? > > > > > >   I gave the command in a terminal session after SSHing to the server > > from the same network. It is not a virtual machine. > > > > > > Lsaurenz said: > > > > > >>You probably have a corrupted database. > >>You should get that fixed first, then you can upgrade. > >>Maybe you should hire a professional for that. > > > > > > I suspect this is is correct, both that there is corruption in the > table > > and that I need a professional to help. If someone here is available, > > I'm interested. > > Given that this involves your largest table I would confirm that the > signal 9 kill was not coming from the system OOM killer. Take a look at > the system logs to see what they show over the same time period. > > > > > > > Andreas said: > > > > > >  >which exact minor version please? > > > > > > PostgreSQL 9.6.10 on x86_64-pc-linux-gnu, compiled by gcc (GCC) 4.4.7 > > 20120313 (Red Hat 4.4.7-23), 64-bit > > > > > > > -- > Adrian Klaver > adrian.klaver@aklaver.com > -- Angular momentum makes the world go 'round. --------------DB2CC0B4F3B25AE9FAFE6CEF Content-Type: text/html; charset=utf-8 Content-Transfer-Encoding: 8bit Not enough swap space?

On 11/04/2018 04:55 PM, Charles Martin wrote:
Yep, you called it:

Nov  2 20:30:45 localhost kernel: Out of memory: Kill process 30438 (postmaster) score 709 or sacrifice child
Nov  2 20:30:45 localhost kernel: Killed process 30438, UID 26, (postmaster) total-vm:3068900kB, anon-rss:1695392kB, file-rss:1074692kB

So it's running out of memory when trying to dump this table. The "old" server has 4GB of ram, the "new" server 20GB. 


On Sun, Nov 4, 2018 at 3:13 PM Adrian Klaver <adrian.klaver@aklaver.com> wrote:
On 11/4/18 8:38 AM, Charles Martin wrote:
>
> Adtrian said:
>>> pg_dump: Error message from server: server closed the connection
>>> unexpectedly
>
>  >Is this error the client reporting?
>  >Is this the same that is showing up in the server log?
>
> Yes, that's the client message, i.e. what appeared in the terminal
> window that gave the command. The server log shows:
>
> 2018-11-02 20:30:46 EDT [20405]: [4-1] user=,db= LOG:  server process
> (PID 30438) was terminated by signal 9: Killed
>
> 2018-11-02 20:30:46 EDT [20405]: [5-1] user=,db= DETAIL:  Failed process
> was running: COPY public.docfile (docfile_pkey, docfileoriginalname,
> ordernumber, versionnum, docfilecontents, docfilepath, d$
>
> 2018-11-02 20:30:46 EDT [20405]: [6-1] user=,db= LOG:  terminating any
> other active server processes
>
> 2018-11-02 20:30:46 EDT [20415]: [10-1] user=,db= WARNING:  terminating
> connection because of crash of another server process
>
> 2018-11-02 20:30:46 EDT [20415]: [11-1] user=,db= DETAIL:  The
> postmaster has commanded this server process to roll back the current
> transaction and exit, because another server process exited abnor$
>
>
>
>>So where is the server located relative to the pg_dump client?
>>On the same machine?
>>If so is it a virtual machine e.g AWS?
>>Across a local or remote network?
>
>
>   I gave the command in a terminal session after SSHing to the server
> from the same network. It is not a virtual machine.
>
>
> Lsaurenz said:
>
>
>>You probably have a corrupted database.
>>You should get that fixed first, then you can upgrade.
>>Maybe you should hire a professional for that.
>
>
> I suspect this is is correct, both that there is corruption in the table
> and that I need a professional to help. If someone here is available,
> I'm interested.

Given that this involves your largest table I would confirm that the
signal 9 kill was not coming from the system OOM killer. Take a look at
the system logs to see what they show over the same time period.

>
>
> Andreas said:
>
>
>  >which exact minor version please?
>
>
> PostgreSQL 9.6.10 on x86_64-pc-linux-gnu, compiled by gcc (GCC) 4.4.7
> 20120313 (Red Hat 4.4.7-23), 64-bit
>
>


--
Adrian Klaver
adrian.klaver@aklaver.com

--
Angular momentum makes the world go 'round.
--------------DB2CC0B4F3B25AE9FAFE6CEF--