From: | Scott Marlowe <scott(dot)marlowe(at)gmail(dot)com> |
---|---|
To: | Bruce Momjian <bruce(at)momjian(dot)us> |
Cc: | Bernhard Schrader <bernhard(dot)schrader(at)innogames(dot)de>, Kevin Grittner <Kevin(dot)Grittner(at)wicourts(dot)gov>, pgsql-admin(at)postgresql(dot)org |
Subject: | Re: pg_upgrade 8.3 to 9.0, shutdown is to slow |
Date: | 2011-01-27 16:58:10 |
Message-ID: | AANLkTinYj56gG8mB0X6F57qmMfGqONmZ11d_sUosrdTr@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-admin |
On Thu, Jan 27, 2011 at 9:12 AM, Bruce Momjian <bruce(at)momjian(dot)us> wrote:
> Bernhard Schrader wrote:
>> Am Donnerstag, den 27.01.2011, 09:18 -0600 schrieb Kevin Grittner:
>> > Bernhard Schrader <bernhard(dot)schrader(at)innogames(dot)de> wrote:
>> >
>> > > what maybe is also interesting, if i start the database manually i
>> > > have a huge waiting IO of 23% for a time of maybe 2-5 minutes, i
>> > > think it is because of the fragmentation of the tables.
>> > >
>> > > is the shutdown so slow because of the waiting io? but why can i
>> > > stop it as user root without problems...
>> >
>> > How do you "stop it as user root", exactly? If you kill PostgreSQL
>> > too abruptly, the recovery could easily run for several minutes with
>> > a lot of I/O while it recovers.
>> >
>> > Taking pg_upgrade out of the picture for a minute -- how long do
>> > shutdowns and startups normally take you?
>> >
>> > -Kevin
>> >
>> well, i tested it now with user postgres, the same command as the
>> program, and it didnt shut down the server, the log gives me the notice
>> that it want to shut down but it doesnt happen, maybe this stop method
>> is to "friendly". i tested it with the already running db, so there were
>> no waiting io or anything.. with option "-m fast" it stops without
>> problems.
>>
>> normally i do it as user root with /etc/init.d/postgresql-8.3 (stop|
>> start) and the shutdown takes about 5-10 seconds, the start the same but
>> with some waiting io, which takes up to 5 minutes of bad perfomance.
>
> I suggest you take pg_upgrade out of the testing and find out why you
> are having startup/shutdown delays. Once they are fixed, pg_upgrade
> should work fine.
>
> My initial reaction is that something is wrong with your system, either
> the I/O or the way it is being shutdown by the script. I would start to
> look in the script and do some pg_ctl tests starting/stopping the
> server.
It could be that his application or whatever is making connections
while he's trying to do this. An open connection that's actually
doing something will stop a normal shutdown.
Is there a reason the pg upgrade script does not use -m fast?
From | Date | Subject | |
---|---|---|---|
Next Message | Frank Brendel | 2011-01-27 17:03:11 | asm/ia64regs.h not found on FreeBSD 8.1 IA64 |
Previous Message | Bruce Momjian | 2011-01-27 16:12:42 | Re: pg_upgrade 8.3 to 9.0, shutdown is to slow |