[pgpool-hackers: 3823] Re: [pgpool-committers: 6193] pgpool: Adding new wd_cli utility

Muhammad Usama m.usama at gmail.com
Thu Sep 17 16:16:53 JST 2020


Hi Ishii-San

On Thu, Sep 17, 2020 at 2:45 AM Tatsuo Ishii <ishii at sraoss.co.jp> wrote:

> Hi Usama,
>
> Thank you very much!
>
> BTW, in pgpool-general mailing list, multiple users complain that
> if_down_command is not executed when former master watchdog node shuts
> dow or is took over. Any suggestion for this?
>
> https://www.pgpool.net/pipermail/pgpool-general/2020-September/007323.html


I will look into this in detail and get back on this.

Best regards
Muhammad Usama


>
>
> > Hi Ishii-San
> >
> > Sorry for the delay. I have pushed the documentation updates for the
> wd_cli
> > utility
> >
> >
> https://git.postgresql.org/gitweb/?p=pgpool2.git;a=commitdiff;h=904d6facbfd45a53f6ac68dd13aa55cb3705ec75
> >
> > Thanks
> > Best Regards
> > Muhammad Usama
> >
> >
> > On Wed, Sep 16, 2020 at 3:50 AM Tatsuo Ishii <ishii at sraoss.co.jp> wrote:
> >
> >> Hi Usama,
> >>
> >> Any feedback for this?
> >>
> >> Best regards,
> >> --
> >> Tatsuo Ishii
> >> SRA OSS, Inc. Japan
> >> English: http://www.sraoss.co.jp/index_en.php
> >> Japanese:http://www.sraoss.co.jp
> >>
> >> From: Tatsuo Ishii <ishii at sraoss.co.jp>
> >> Subject: [pgpool-hackers: 3807] Re: [pgpool-committers: 6193] pgpool:
> >> Adding new wd_cli utility
> >> Date: Tue, 08 Sep 2020 15:17:19 +0900 (JST)
> >> Message-ID: <20200908.151719.21058270736229900.t-ishii at sraoss.co.jp>
> >>
> >> > Hi Usama,
> >> >
> >> > Have you committed documentation for this?  I am organizing release
> >> > notes for 4.2 now. It's difficult to add a new feature without
> >> > documentations...
> >> >
> >> > Best regards,
> >> > --
> >> > Tatsuo Ishii
> >> > SRA OSS, Inc. Japan
> >> > English: http://www.sraoss.co.jp/index_en.php
> >> > Japanese:http://www.sraoss.co.jp
> >> >
> >> > From: Muhammad Usama <m.usama at gmail.com>
> >> > Subject: [pgpool-committers: 6193] pgpool: Adding new wd_cli utility
> >> > Date: Mon, 23 Sep 2019 20:43:21 +0000
> >> > Message-ID: <E1iCVB3-0007dP-8Q at gothos.postgresql.org>
> >> >
> >> >> Adding new wd_cli utility
> >> >>
> >> >> wd_cli makes it easier to integrate the external health check systems
> >> with the
> >> >> Pgpool-II. It provides a very convenient and easy to use interface to
> >> interact with
> >> >> watchdog and perform health check related node operations.
> >> >>
> >> >> For example:
> >> >> If some external health-check system monitoring the health of the
> >> watchdog
> >> >> cluster detects the remote node failure. It can use wd_cli utility to
> >> inform
> >> >> Pgpool-II about that node failure
> >> >>
> >> >>     $wd_cli  --inform DEAD -N 'Remote watchdog name'  -p 9001 -m
> 'node
> >> 1 failed'
> >> >>
> >> >> Similarly when the node becomes reachable again
> >> >>
> >> >>     $wd_cli  --inform ALIVE -N 'Remote watchdog name'  -p 9001 -m
> 'node
> >> 1 found'
> >> >>
> >> >> This utility can also be used to get the live information of all
> nodes.
> >> >>
> >> >>     $wd_cli -f simple_conf/watchdog/pgpool_wd1.conf --info -v --all
> >> >>
> >> >>     Total Watchdog nodes configured for lifecheck:    2
> >> >>     *****************
> >> >>     Node ID:           0
> >> >>     Node Status code   4
> >> >>     Node Status:       MASTER
> >> >>     Node Name:         localhost:9991 Linux localhost.localdomain
> >> >>     Node Host:         localhost
> >> >>     Node WD Port:      9001
> >> >>     Node Pgpool Port:  9991
> >> >>
> >> >>     Node ID:           1
> >> >>     Node Status code   7
> >> >>     Node Status:       STANDBY
> >> >>     Node Name:         localhost:9992 Linux localhost.localdomain
> >> >>     Node Host:         localhost
> >> >>     Node WD Port:      9002
> >> >>     Node Pgpool Port:  9992
> >> >>
> >> >> wd_cli provides many options for node search criteria.
> >> >> See wd_cli --help for complete list of options.
> >> >>
> >> >> The commit also re-arrange the code related to socket communication
> and
> >> >> watchdog IPC commands and separates the internal and external
> watchdog
> >> >> commands to make the code structure more modular.
> >> >>
> >> >> The regression tests and documentation updates are not part of this
> >> commit
> >> >> and will be taken care of separately.
> >> >>
> >> >> Branch
> >> >> ------
> >> >> master
> >> >>
> >> >> Details
> >> >> -------
> >> >>
> >>
> https://git.postgresql.org/gitweb?p=pgpool2.git;a=commitdiff;h=6156534a7073bc6446b9bcccc1ed4a846fa82f34
> >> >>
> >> >> Modified Files
> >> >> --------------
> >> >> configure                                          |   3 +-
> >> >> configure.ac                                       |   2 +-
> >> >> src/Makefile.am                                    |   1 +
> >> >> src/Makefile.in                                    |  17 +-
> >> >> src/include/utils/fe_ports.h                       |  13 +-
> >> >> src/include/utils/json_writer.h                    |   2 +-
> >> >> src/include/utils/pool_stream.h                    |   7 +-
> >> >> src/include/utils/socket_stream.h                  |  36 +
> >> >> src/include/watchdog/wd_commands.h                 |  66 ++
> >> >> .../{wd_ipc_commands.h => wd_internal_commands.h}  |  66 +-
> >> >> src/include/watchdog/wd_ipc_conn.h                 |  57 ++
> >> >> src/include/watchdog/wd_ipc_defines.h              |   2 +-
> >> >> src/include/watchdog/wd_json_data.h                |  14 -
> >> >> src/include/watchdog/wd_lifecheck.h                |   4 +-
> >> >> src/main/pgpool_main.c                             |  10 +-
> >> >> src/pcp_con/pcp_worker.c                           |   4 +-
> >> >> src/pcp_con/recovery.c                             |   2 +-
> >> >> src/protocol/child.c                               |  16 +-
> >> >> src/protocol/pool_connection_pool.c                |   4 +-
> >> >> src/protocol/pool_process_query.c                  |   8 +-
> >> >> src/tools/Makefile.am                              |   7 +-
> >> >> src/tools/Makefile.in                              |   7 +-
> >> >> src/tools/watchdog/Makefile.am                     |  74 ++
> >> >> src/tools/watchdog/Makefile.in                     | 771
> >> +++++++++++++++++++++
> >> >> src/tools/watchdog/wd_cli.c                        | 749
> >> ++++++++++++++++++++
> >> >> src/utils/pool_stream.c                            | 138 +---
> >> >> src/utils/psprintf.c                               |   4 +-
> >> >> src/utils/socket_stream.c                          | 195 ++++++
> >> >> src/watchdog/Makefile.am                           |   2 +
> >> >> src/watchdog/Makefile.in                           |   3 +
> >> >> src/watchdog/watchdog.c                            |  14 +-
> >> >> src/watchdog/wd_commands.c                         | 757
> >> ++++----------------
> >> >> src/watchdog/wd_internal_commands.c                | 496
> +++++++++++++
> >> >> src/watchdog/wd_ipc_conn.c                         | 282 ++++++++
> >> >> src/watchdog/wd_json_data.c                        |  86 ---
> >> >> src/watchdog/wd_lifecheck.c                        |  12 +-
> >> >> 36 files changed, 2946 insertions(+), 985 deletions(-)
> >> >>
> >> > _______________________________________________
> >> > pgpool-hackers mailing list
> >> > pgpool-hackers at pgpool.net
> >> > http://www.pgpool.net/mailman/listinfo/pgpool-hackers
> >>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.sraoss.jp/pipermail/pgpool-hackers/attachments/20200917/b54b9fa1/attachment.html>


More information about the pgpool-hackers mailing list