Обсуждение: Troubleshooting Postgres7.4

Поиск
Список
Период
Сортировка

Troubleshooting Postgres7.4

От
Bobb Shields
Дата:
Hi all. 

I'm running 7.4, and I recently did a few upgrades, which seem to have broken it.  I believe that all of them were php updates.  Anywho, my service configuration shows that postmaster is stopped.  I can't find an instance of it in my system monitor.

Can you help me to figure out if its still running, and if its not, why it won't start like it should?

Sorry for the lack of information.  Yell at me if you need more.   I'm relatively new to linux, so I'm trying to learn, and the wealth of information on the net is a bit overwhelming. 

Thanks in advance,
~Bobb

Re: Troubleshooting Postgres7.4

От
Michael Fuhr
Дата:
On Tue, Apr 19, 2005 at 02:11:47PM -0400, Bobb Shields wrote:
>
> I'm running 7.4, and I recently did a few upgrades, which seem to have
> broken it.

Could you expand on "seem to have broken it"?  What are you doing
and what unexpected behavior or error messages are you seeing?

> I believe that all of them were php updates.

What exactly did you change?  The version of PHP?  Application code
written in PHP?  Something else, like settings in postgresql.conf?

> Anywho, my service configuration shows that postmaster is stopped. I
> can't find an instance of it in my system monitor.
>
> Can you help me to figure out if its still running, and if its not, why it
> won't start like it should?

You could use ps from a shell prompt to verify whether the postmaster
is running.  For example, "ps ax | grep postmaster" should work on
your system (you said you were using Linux).

Try to start the postmaster from the shell and see what happens.
If it doesn't start but you see nothing on the screen, then look
through postgresql.conf and the PostgreSQL startup script to see
where log messages are going, then look through those messages to
see what's happening.

As I recall, some PostgreSQL packages for Linux redirect the
postmaster's output to /dev/null -- if this is the case on your
system, then I'd suggest changing that so you can see startup errors.

--
Michael Fuhr
http://www.fuhr.org/~mfuhr/

Re: Troubleshooting Postgres7.4

От
Bobb Shields
Дата:
I'm using two php apps on my website that I'm serving on the same linux box (FC3).  Both titles (phpbb, tikipro) report that they cannot connect to the database.

I believe the updates were php code updates.  I downloaded them via yum when I noticed my up2date blinking.

ps ax | grep postmaster does not return anything.  I don't know what it should return anyways...

I tried to start postgres by su'ing from root to " - postgres", and running postmaster.  I get an error that says that the lock file already exists, and asks whether another instance of postmaster is already running.

Service Configuration once again reports that it is stopped, and I can't connect via pgAdmin3.

How can I check what the last updates were from yum?  My command that I ran was "yum -y update"

Thanks!
~Bobb

On 4/20/05, Michael Fuhr <mike@fuhr.org> wrote:
On Tue, Apr 19, 2005 at 02:11:47PM -0400, Bobb Shields wrote:
>
> I'm running 7.4, and I recently did a few upgrades, which seem to have
> broken it.

Could you expand on "seem to have broken it"?  What are you doing
and what unexpected behavior or error messages are you seeing?

> I believe that all of them were php updates.

What exactly did you change?  The version of PHP?  Application code
written in PHP?  Something else, like settings in postgresql.conf?

> Anywho, my service configuration shows that postmaster is stopped. I
> can't find an instance of it in my system monitor.
>
> Can you help me to figure out if its still running, and if its not, why it
> won't start like it should?

You could use ps from a shell prompt to verify whether the postmaster
is running.  For example, "ps ax | grep postmaster" should work on
your system (you said you were using Linux).

Try to start the postmaster from the shell and see what happens.
If it doesn't start but you see nothing on the screen, then look
through postgresql.conf and the PostgreSQL startup script to see
where log messages are going, then look through those messages to
see what's happening.

As I recall, some PostgreSQL packages for Linux redirect the
postmaster's output to /dev/null -- if this is the case on your
system, then I'd suggest changing that so you can see startup errors.

--
Michael Fuhr
http://www.fuhr.org/~mfuhr/

Re: Troubleshooting Postgres7.4

От
Alvaro Herrera
Дата:
On Thu, Apr 21, 2005 at 09:53:37AM -0400, Bobb Shields wrote:

> ps ax | grep postmaster does not return anything. I don't know what it
> should return anyways...
>
> I tried to start postgres by su'ing from root to " - postgres", and running
> postmaster. I get an error that says that the lock file already exists, and
> asks whether another instance of postmaster is already running.

Since you already confirmed that there isn't (because ps ax | grep
postmaster returned empty), you can delete the PID file mentioned in the
error message and retry.

After it's up, try the ps | grep trick again and see what it looks like,
just so you know what it should look like under normal operation.

--
Alvaro Herrera (<alvherre[@]dcc.uchile.cl>)
"Endurecerse, pero jamás perder la ternura" (E. Guevara)