<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-2022-jp">
<style type="text/css" style="display:none;"> P {margin-top:0;margin-bottom:0;} </style>
</head>
<body dir="ltr">
$B=i$a$^$7$F!"(BYASSEE $B$H?=$7$^$9!#(B
<div>watchdog$B$N<+F02>A[(BIP$B@ZBX$,$&$^$/F0:n$7$J$$$?$a(B</div>
<div>$B>:3J$7$?%5!<%PB&$,MxMQ$G$-$J$$>u67$K$J$C$F$*$j$^$9!#(B</div>
<div><br>
</div>
<div>$B:#2s=i$a$F(BPgpool-II$B4D6-$r9=C[$7$?$?$aM}2rITB-$,$"$k$+$b$7$l$^$;$s$,(B</div>
<div>$B$h$m$7$/$*4j$$$7$^$9!#(B</div>
<div><br>
</div>
<div>https://www.pgpool.net/docs/latest/ja/html/example-cluster.html</div>
<div><br>
</div>
<div>$B$3$A$i$N%Z!<%8$r;29M$K@_Dj$7$^$7$?!#9=@.$b$[$\F1$8$G$9!#(B</div>
<div><br>
</div>
<div>zabbix$B$N(BDB$B$r#3Bf>iD99=@.$K$9$k$3$H$,L\I8$G$9!#(B</div>
<div><br>
</div>
<div>OS: Almalinux 8.5</div>
<div>Kernel: 4.18.0-348.23.1.el8_5.x86_64</div>
<div>PosrgreSQL: 14.2</div>
<div>timescaleDB: 2.6.1</div>
<div><br>
</div>
<div>$B%[%9%H$O(B Windos10 Hyper-V$B!"2>A[%^%7%s#3Bf$O%/%m!<%s$G$O$J$/(B</div>
<div>$B8DJL$K%$%s%9%H!<%k$7$F:n@.!#(B</div>
<div><br>
</div>
<div>$B!&(Bpg-a (192.168.0.92)</div>
<div>$B!&(Bpg-b (192.168.0.93)</div>
<div>$B!&(Bpg-c (192.168.0.94)</div>
<div>$B!&(BVIP  192.168.0.100</div>
<div><br>
</div>
<div>$B8=>u!"<+F0%U%'%$%k%*!<%P!"%*%s%i%$%s%j%+%P%j$J$I$9$Y$F@5>oF0:n$7$F$$$^$9!#(B</div>
<div><br>
</div>
<div>pg-a primary VIP</div>
<div>pg-b stanby</div>
<div>pg-c stanby</div>
<div><br>
</div>
<div>$B$J>u67$@$H$7$F!"(Bpg-a$B$N(BPostgreSQL$B$r<jF0Dd;_!#%U%'%$%k!<%P!<F0:n$7$F(B pg-b$B$,>:3J$7$F$b(B</div>
<div>VIP$B$O(B pg-a$B$N$^$^$G(B pg-b $B$K@ZBX$H$J$i$J$$$?$a(BDB$B@\B3$G$-$J$$>u67$K$J$j$^$9!#(B</div>
<div><br>
</div>
<div>pg-a $B$G(Bsystemctl restart pgpool $B$r<B9T$9$l$P(BVIP$B2rJ|$5$l$^$9!#(B</div>
<div><br>
</div>
<div>/etc/pgpool-II/escalation.sh$B!!$O%5%s%W%k$=$N$^$^$J$N$G$9$,!"(B</div>
<div>$B;n$7$K$=$N$^$^(B $B%3%s%=!<%k$G(B IP$BJQ$($?$@$1$G<B9T(B</div>
<div><br>
</div>
<div>/usr/bin/sudo /sbin/ip addr add 192.168.0.101/24 dev eth0 label eth0:1</div>
<div>/usr/bin/sudo /sbin/ip addr del 192.168.0.101/24 dev eth0</div>
<div><br>
</div>
<div>$B@5>o$K(BIP$BDI2C$H:o=|$,F0:n$7$^$9!#$G$b(B</div>
<div><br>
</div>
<div>/usr/bin/sudo /sbin/ip addr del 192.168.0.100/24 dev eth0</div>
<div><br>
</div>
<div>$B$r$d$C$F$b2?$bJQ2=$7$^$;$s!#$I$&$b(B pgpool$B$,5/F0Cf$O(BVIP$B$O<jF03+J|$G$-$J$$F0$-$K8+$($^$9!#(B</div>
<div><br>
</div>
<div>$B$*5$$E$-$NE@$,$"$l$P$465<x$/$@$5$$!#(B</div>
<br>
</body>
</html>