pg_ctl stop returns error

Started by Murakamiabout 25 years ago4 messagesgeneral
Jump to latest
#1Murakami
exit@zaa.att.ne.jp

I've just installed postgreSQL_7.0.3 to my Solaris7.
I can start DB with "postmaster" or "pg_ctl -w start" and create DB with no problem.
But when I try to stop DB with "pg_ctl -w stop", it returns an error.
Error is "Waiting for postmaster shutting down.....pg_ctl: postmaster does not shut down"

Does anyone know about this error?
Please advise.

Murakami

#2Tom Lane
tgl@sss.pgh.pa.us
In reply to: Murakami (#1)
Re: pg_ctl stop returns error

Murakami <exit@zaa.att.ne.jp> writes:

But when I try to stop DB with "pg_ctl -w stop", it returns an error.
Error is "Waiting for postmaster shutting down.....pg_ctl: postmaster does not shut down"

Do you have active clients?

The default behavior of pg_ctl stop is to prevent new client connections
but not to shut down the database until the last old client disconnects.
If you want a more forceful approach to shutting down, read the man
page...

regards, tom lane

#3Murakami
exit@zaa.att.ne.jp
In reply to: Murakami (#1)
Re: pg_ctl stop returns error

Inoue san , Mr.Lane thanks for your quick reply.

I checked manual already.
My DB is just for a test and I don't see any clients working...
Or maybe some clients are working but I can't find them.

I see 7 postmaster process is running at my PC now.
Does it mean that I have 7 DB host process running?
I started DB with "postmaster -S -i ". So it means that I started DB with smart mode, right?

Any further suggestion?

Murakami

Hiroshi>
Hiroshi> See pg_ctl manual.
Hiroshi> Don't you shut down the postmaster in smart mode ?
Hiroshi> If some clients are running, they must be finished before
Hiroshi> calling pg_ctl in smart mode.
Hiroshi>
Hiroshi> regards,
Hiroshi> Hiroshi Inoue
Hiroshi>

#4Richard Huxton
dev@archonet.com
In reply to: Murakami (#1)
Re: pg_ctl stop returns error

From: "Murakami" <exit@zaa.att.ne.jp>

Inoue san , Mr.Lane thanks for your quick reply.

I checked manual already.
My DB is just for a test and I don't see any clients working...
Or maybe some clients are working but I can't find them.

You've not been accessing PG via apache with persistent connections have
you? That'll tend to keep backends running even when not in use. Restart
apache and see if they go away.

I see 7 postmaster process is running at my PC now.
Does it mean that I have 7 DB host process running?

Yep - and you should be able to see the user accessing them too.

I started DB with "postmaster -S -i ". So it means that I started DB with

smart mode, right?

According to "man postmaster" -S = silent (discard logging)

HTH

- Richard Huxton