[pgpool-general: 7194] Re: The best way to enable PgPool and PostgreSQL server start automatically in the Pgpool + WatchDog Mode
J.L.
wantdrink at gmail.com
Wed Aug 12 01:33:12 JST 2020
Hi Wolf,
I didn't use repmgr. All the rpms I installed is postgresql-12 +
pgpool-II-release + pgpool-II-pg12-*, the same as the
8.3. Pgpool-II + Watchdog Setup Example
The link looks great! Let me read and try it first.
Thanks a lot!
On Tue, Aug 11, 2020 at 11:04 PM Wolf Schwurack <wolf at uen.org> wrote:
> Hey JL
>
> I have the same configuration setup. There are some things to consider
> after a reboot which I check before starting pgpool. Make sure PostgreSQL
> database are replicating. Are you using repmgr? This also would need to be
> started before pgpool.
> Here's a link I used to help setup my system Which may help you
> http://saule1508.github.io/pgpool/
>
>
> Wolfgang Schwurack
> Database/System Administrator
> Utah Education Network
> 801-587-9444
> wolf at uen.org
>
>
>
> On 8/11/20, 8:47 AM, "pgpool-general-bounces at pgpool.net on behalf of Bo
> Peng" <pgpool-general-bounces at pgpool.net on behalf of pengbo at sraoss.co.jp>
> wrote:
>
> Hi,
>
> On Sun, 9 Aug 2020 17:05:01 +0800
> "J.L." <wantdrink at gmail.com> wrote:
>
> > Hi there,
> >
> > I've installed pgpool 4.1.2 and postgresql 12.3 with watchdog based
> on
> > https://www.pgpool.net/docs/latest/en/html/example-cluster.html.
> > That is 3 machines with a VIP, pgpool service + watchdog service +
> > postgresql service running on each of them, 1 primary + 2 standby
> > postgresql.
> > The question is: is that possible to enable those services as auto
> started
> > even if I reboot all of them?
> >
> > I checked running services on them:
> >
> > [root at primary ~]# systemctl status postgresql-12
> > > postgresql-12.service - PostgreSQL 12 database server
> > > Loaded: loaded (/usr/lib/systemd/system/postgresql-12.service;
> > > disabled; vendor preset: disabled)
> > > Active: active (running) since Thu 2020-07-02 22:17:35 CDT; 1
> months 6
> > > days ago
> > >
> > > [root at secondary1 ~]# systemctl status postgresql-12
> > > postgresql-12.service - PostgreSQL 12 database server
> > > Loaded: loaded (/usr/lib/systemd/system/postgresql-12.service;
> > > disabled; vendor preset: disabled)
> > > Active: inactive (dead)
> > >
> > > [root at secondary2 ~]# systemctl status postgresql-12
> > > postgresql-12.service - PostgreSQL 12 database server
> > > Loaded: loaded (/usr/lib/systemd/system/postgresql-12.service;
> > > disabled; vendor preset: disabled)
> > > Active: inactive (dead)
> >
> >
> > So the postgresql service on secondary 1 & 2 is not started by
> postgresql
> > service, they are triggered by pgpool with command like:
> >
> > > /usr/pgsql-12/bin/postgres -D /var/lib/pgsql/12/data
>
> Sorry, I could not understand the configuration.
> May I ask how you configure pgpool to execute command above?
>
> > And on the primary the ps aux shows
> >
> > > /usr/pgsql-12/bin/postmaster -D /var/lib/pgsql/12/data/
> >
> >
> > Which means I can enable pgpool service on all 3 machines:
> >
> > > systemctl enable pgpool
> >
> >
> > But shouldn't do the same for postgresql service like systemctl
> enable
> > postgresql-12.
> > Also I'm not sure if enabling services to start automatically will
> lead to
> > any issue.
> >
> > Any suggestion or guidance about this is appreciated. I just want to
> make
> > the DB system recover even after rebooting.
> >
> > Thanks.
>
>
> --
> Bo Peng <pengbo at sraoss.co.jp>
> SRA OSS, Inc. Japan
> _______________________________________________
> pgpool-general mailing list
> pgpool-general at pgpool.net
> http://www.pgpool.net/mailman/listinfo/pgpool-general
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.pgpool.net/pipermail/pgpool-general/attachments/20200812/e3f94084/attachment.htm>
More information about the pgpool-general
mailing list