Re: Recovery will take 10 hours

From: Brendan Duddridge <brendan(at)clickspace(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: PostgreSQL Performance <pgsql-performance(at)postgresql(dot)org>
Subject: Re: Recovery will take 10 hours
Date: 2006-04-21 00:24:36
Message-ID: 53ACF10A-9240-420B-83AB-E4CBABD2AC56@clickspace.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-performance

Hi Tom,

Well, we started the restore back up with the WAL archives copied to
our local disk.

It's going at about the same pace as with the restore over NFS.

So I tried ktrace -p PID and it created a really big file. I had to
do 'ktrace -p PID -c' to get it to stop.

The ktrace.out file is read using kdump, but there's a lot of binary
data in there intermixed with some system calls.

For example:

15267 postgres RET read 8192/0x2000
15267 postgres CALL lseek(153,0,2)
15267 postgres RET lseek 0
15267 postgres CALL lseek(127,0,2)
15267 postgres RET lseek 0
15267 postgres CALL lseek(138,0,2)
15267 postgres RET lseek 0
15267 postgres CALL lseek(153,0,2)
15267 postgres RET lseek 0
15267 postgres CALL lseek(127,0,2)
15267 postgres RET lseek 0
15267 postgres CALL read(5,25225728,8192)
15267 postgres GIO fd 5 read 8192 bytes
"\M-P]\0\^A\0\0\0\^A\0\0\^A\M^H,\M-5`\0\0\0\^C\M-6r fill,
polyester has a subtle sheen, machine wash\0\0\0Xreverses to\
solid colour, polyester fill, polyester has a subtle sheen,
machine wash\^_\^Y7\M-3\0\0\0\0\0\0\0\0\0\0\0\0\0\0oG\0\
\b\0\^[)\^C \M^Or\M-#\^B\0\0\0\0\0A\M-&\M-]

... lots of data ....

\M^K$\0\0\0\fcomplete\0\0\0HCustom-width Valanceless
Aluminum Mini Blinds 37 1/4-44" w. x 48" l.\0\0\0\M-P1" aluminum\
slats, valanceless headrail and matching bottom rail,
hidden brackets, clear acrylic tilt wand, extra slats with rou\
te holes in the back, can be cut down to minimum width of
14", hardware. . .\0\0\^Aq1" aluminum slats, valanceless he\
adrail and matching bottom rail, hidden brackets, clear
acrylic tilt wand, extra slats with route holes in the back, \
can be cut down to minimum width of 14", hardware and
instructions included, wipe with a dam"
15267 postgres RET read 8192/0x2000
15267 postgres CALL lseek(138,0,2)
15267 postgres RET lseek 0
15267 postgres CALL lseek(158,317251584,0)
15267 postgres RET lseek 0
15267 postgres CALL write(158,35286464,8192)
15267 postgres GIO fd 158 wrote 8192 bytes
"\0\0\^A\M^H+\M^W(at)\M-,\0\0\0\^A\^A\M-D\^P\M-(at)\^_\M-p \^C?\M^X
\M^(at)$?P\M^@$?\b\M^(at)$>\M-(at)\M^@$>x\M^(at)$>0\M^(at)$=\M-h\M^@$=\
\240\M^(at)$#0\M^@$"X\M^(at)$=X\M^@$=\^P\M^(at)$<\M-H\M^(at)$<\M^(at)\M^@$<8
\M^(at)$;\M-p\M^(at)$;\M-(\M^(at)$;`\M^(at)$;\^X\M^(at)$:\M-P\M^(at)$:\M^H\

etc...

I'm not sure that really tells me anything though other than the WAL
archives don't actually archive SQL, but store only the database
changes.

Thanks,

____________________________________________________________________
Brendan Duddridge | CTO | 403-277-5591 x24 | brendan(at)clickspace(dot)com

ClickSpace Interactive Inc.
Suite L100, 239 - 10th Ave. SE
Calgary, AB T2G 0V9

http://www.clickspace.com

On Apr 20, 2006, at 3:19 PM, Tom Lane wrote:

> Brendan Duddridge <brendan(at)clickspace(dot)com> writes:
>> Do you mean do a kill -QUIT on the postgres process in order to
>> generate a stack trace?
>
> Not at all! I'm talking about tracing the kernel calls it's making.
> Depending on your platform, the tool for this is called strace,
> ktrace, truss, or maybe even just trace. With strace you'd do
> something like
>
> strace -p PID-of-process 2>outfile
> ... wait 30 sec or so ...
> control-C
>
> Not sure about the APIs for the others but they're probably roughly
> similar ... read the man page ...
>
> regards, tom lane
>
> ---------------------------(end of
> broadcast)---------------------------
> TIP 9: In versions below 8.0, the planner will ignore your desire to
> choose an index scan if your joining column's datatypes do not
> match
>

In response to

Responses

Browse pgsql-performance by date

  From Date Subject
Next Message Tom Lane 2006-04-21 00:30:55 UPDATE on many-column tables (was Re: [PERFORM] Performance decrease)
Previous Message Brendan Duddridge 2006-04-20 23:43:41 Re: Recovery will take 10 hours