monit-general
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[monit] Postgresql weirdness: ESTrootFATAL


From: David Paper
Subject: [monit] Postgresql weirdness: ESTrootFATAL
Date: Thu, 13 Nov 2008 16:18:09 -0500

Hi monit gurus,

While I anxiously await 5.0 getting out of beta, I have run into the following problem w/ postgres: When started via monit, postgres spits out the following errors every 22 seconds in the postgres startup log::

2008-11-13 16:07:04 ESTrootFATAL:  database "root" does not exist
2008-11-13 16:07:04 ESTrootFATAL:  database "root" does not exist
2008-11-13 16:07:04 ESTrootFATAL:  database "root" does not exist
2008-11-13 16:07:04 ESTrootFATAL:  database "root" does not exist
2008-11-13 16:07:26 ESTrootFATAL:  database "root" does not exist
2008-11-13 16:07:26 ESTrootFATAL:  database "root" does not exist
2008-11-13 16:07:26 ESTrootFATAL:  database "root" does not exist
2008-11-13 16:07:26 ESTrootFATAL:  database "root" does not exist

4 entries in each group, forever.
Environment: Monit v 4.10.1 (started out of inittab), Postgres 8.3.4, SuSE Linux 11.0 x86-64.

This is what the monit job looks like:

check process postgresql with pidfile /opt/postgres/data/postmaster.pid
   group database
   start program = "/opt/postgres/bin/pg_ctl start"
        as uid postgres and gid postgres
   stop  program = "/opt/postgres/bin/pg_ctl stop"
        as uid postgres and gid postgres
   if failed unixsocket /tmp/.s.PGSQL.5432 protocol pgsql then restart
   if failed unixsocket /tmp/.s.PGSQL.5432 protocol pgsql then alert
if failed host localhost port 5432 protocol pgsql then restart if failed host localhost port 5432 protocol pgsql then alert
   if 5 restarts within 5 cycles then timeout

I've also tried doing it like this:

check process postgresql with pidfile /opt/postgres/data/postmaster.pid
   group database
   start program = "/etc/init.d/postgresql start"
   stop  program = "/etc/init.d/postgresql stop"
   if failed unixsocket /tmp/.s.PGSQL.5432 protocol pgsql then restart
   if failed unixsocket /tmp/.s.PGSQL.5432 protocol pgsql then alert
if failed host localhost port 5432 protocol pgsql then restart if failed host localhost port 5432 protocol pgsql then alert
   if 5 restarts within 5 cycles then timeout

Same result.

If I fire up postgres manually using the following methods, I don't see the error:

su - postgres; /opt/postgres/bin/pg_ctl start
su - postgres; /opt/postgres/bin/pg_ctl start -w -D /opt/postgres/data -l /opt/postgres/data/startup.log su - postgres -c "LD_LIBRARY_PATH=/opt/postgres/lib /opt/postgres/bin/ pg_ctl -w start -D \"/opt/postgres/data\" -l \"/opt/postgres/data/ startup.log\""
(as root) /etc/init.d/postgresql start

It seems that only when fired up via a monit job is this an issue.

According to our DB guy, the error means that postgres is trying to find a database called "root", which of course, doesn't exist.

I know that Monit doesn't set any environment variables at time of start up of a jobs process. but I'm baffled as to where this is coming from.

Has anyone else that's running postgres seen this?

Thanks!

-dave

--
Dave Paper

"Hello, I must be going." --Groucho





reply via email to

[Prev in Thread] Current Thread [Next in Thread]