[pgpool-general: 3015] role "nobody" does not exist / online recovery fails

Attila Heidrich attila.heidrich at gmail.com
Wed Jul 9 16:39:26 JST 2014


Hi,

I have found this error in the postgresql log. I have looked over it on
Google, but the only thing I have found, that the health_check_user should
be set up.

My health_check parameters are:
    /etc/pgpool2/pgpool.conf:health_check_period = 15
    /etc/pgpool2/pgpool.conf:health_check_timeout = 5
    /etc/pgpool2/pgpool.conf:health_check_user = 'postgres'
    /etc/pgpool2/pgpool.conf:health_check_password = 'validpassword'
    /etc/pgpool2/pgpool.conf:health_check_max_retries = 2
    /etc/pgpool2/pgpool.conf:health_check_retry_delay = 1

I can check the database connection by hand:

root at swe-openfire-1:~# psql -h swe-postgres-1 -p 5433 -U postgres -W
postgres -c "select 1"
Password for user postgres:
 ?column?
----------
        1
(1 row)

All pool members generate the error several times after I add the backend
to the pool:

2014-07-09 07:05:24 UTC:10.100.2.5(39907):nobody at postgres:[5969]: FATAL:
 role "nobody" does not exist
2014-07-09 07:05:24 UTC:10.100.2.4(48155):nobody at postgres:[5970]: FATAL:
 role "nobody" does not exist
2014-07-09 07:05:24 UTC:10.100.2.6(43736):nobody at postgres:[5971]: FATAL:
 role "nobody" does not exist
2014-07-09 07:05:24 UTC:10.100.2.10(41561):nobody at postgres:[5972]: FATAL:
 role "nobody" does not exist
2014-07-09 07:05:24 UTC:10.100.2.11(37456):nobody at postgres:[5973]: FATAL:
 role "nobody" does not exist
2014-07-09 07:05:25 UTC:10.100.2.5(39909):nobody at postgres:[5974]: FATAL:
 role "nobody" does not exist
2014-07-09 07:05:25 UTC:10.100.2.4(48157):nobody at postgres:[5975]: FATAL:
 role "nobody" does not exist
2014-07-09 07:05:25 UTC:10.100.2.6(43738):nobody at postgres:[5976]: FATAL:
 role "nobody" does not exist
2014-07-09 07:05:25 UTC:10.100.2.10(41563):nobody at postgres:[5977]: FATAL:
 role "nobody" does not exist
2014-07-09 07:05:25 UTC:10.100.2.11(37458):nobody at postgres:[5978]: FATAL:
 role "nobody" does not exist

Messages appeares only when I attach the node.

And the other.... I can do online recovery by hand:

su postgres -c "/var/lib/pgsql/scripts/pgpool_remote_stop swe-postgres-2
/var/lib/postgresql/9.3/main/"
su postgres -c "/var/lib/pgsql/scripts/basebackup.sh swe-postgres-2
/var/lib/postgresql/9.3/main/"
su postgres -c "/var/lib/pgsql/scripts/pgpool_remote_start swe-postgres-2
/var/lib/postgresql/9.3/main/"

streaming replication starts fine, I can use the database in readonly mode,
pgpool can loadbalance read queries after I attache the new node.

But when I try pcp to do the recovery, I got this messages:

pcp returns Backend Error, and in the log there are the following lines:


Jul  9 07:02:35 swe-postgres-1 pgpool: 2014-07-09 07:02:35 LOG:   pid
13221: starting recovering node 1
Jul  9 07:02:35 swe-postgres-1 pgpool: 2014-07-09 07:02:35 LOG:   pid
13221: starting recovery command: "SELECT
pgpool_recovery('/var/lib/pgsql/scripts/basebackup.sh', 'swe-postgres-2',
'/var/lib/postgresql/9.3/main')"
Jul  9 07:02:35 swe-postgres-1 pgpool: 2014-07-09 07:02:35 ERROR: pid
13221: exec_recovery: /var/lib/pgsql/scripts/basebackup.sh command failed
at 1st stage

my recovery setup is
    /etc/pgpool2/pgpool.conf:recovery_user = 'postgres'
    /etc/pgpool2/pgpool.conf:recovery_password = ''
    /etc/pgpool2/pgpool.conf:recovery_1st_stage_command =
'/var/lib/pgsql/scripts/basebackup.sh'
    /etc/pgpool2/pgpool.conf:recovery_2nd_stage_command = ''
    /etc/pgpool2/pgpool.conf:recovery_timeout = 90
    /etc/pgpool2/pgpool.conf:client_idle_limit_in_recovery = 0
    /etc/pgpool2/pgpool.conf:                                   # of online
recovery


Best regards,

Attila
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.sraoss.jp/pipermail/pgpool-general/attachments/20140709/888da634/attachment.html>


More information about the pgpool-general mailing list