Pgpool-II

https://www.pgpool.net/mediawiki/index.php/Main_Page

動作モード設定の集約
Pgpool-II にはさまざまな動作モードがあります。動作モードはバージョンを重ねるたびに増えてきたこともあり、バージョン 4.1 以前では、replication_mode、master_slave_mode、master_slave_sub_mode の 3 つのパラメータで設定していました。バージョン 4.2 では、これらがクラスタリングモードとして 1 つのパラメータ backend_clustering_mode に集約され、設定がシンプルになりました。
Pgpool-II 4.2 で何がどう変わったか? - Qiita 2021

For some reason the status is unused, it should be up or down.
I think you should stop pgpool, remove the file /tmp/pgpool_status, then restart pgpool. The file /tmp/pgpool_status is used by pgpool to record the status of the node. When the file is not there it will create it at startup

https://www.sraoss.jp/pipermail/pgpool-general/2019-March/006516.html

/usr/local/etc/rc.d/pgpool stop

rm /tmp/pgpool_status

/usr/local/etc/rc.d/pgpool start

psql -U postgres -h 127.0.0.1 -p 9999 -c "SHOW POOL_HEALTH_CHECK_STATS;"

pgpool-II環境構築 - Qiita 2018

公式ドキュメントは3.5.4が一覧性がよい

https://www.pgpool.net/docs/pgpool-II-3.5.4/doc/pgpool-ja.html

pcp

pcp.conf でユーザとパスワードを設定
pcpコマンド実行時パスワード入力を省略する場合は .pcppass ファイルが必要

https://www.pgpool.net/docs/pgpool-II-3.5.4/doc/pgpool-ja.html#password_file

旧バージョン

pgpool-II 4.0.5

PostgreSQL11でpgpool-IIを使って負荷分散 - Qiita 2019

Dell 11G R610 firmware update

R610 PERC 6/i のファームウェアを更新する。

https://www.dell.com/support/home/ja-jp/product-support/product/poweredge-r610/drivers

https://www.dell.com/support/home/ja-jp/drivers/driversdetails?driverid=f96nr

この方法

Manually Updating the Firmwares on a Dell PowerEdge R610 | RobWillis.info 2018

  • USBドライブを2つ用意
  • Support Live ISO Image (SLI_3.0.0_A00.iso) のブータブルUSBをRufusで作成する
  • もう1つのUSBにファームウェア (SAS-RAID_Firmware_F96NR_LN_6.3.3-0002_X00.BIN) をコピー
  • SLI USBで起動
  • BIN 実行時の Inventory collection failed 回避のため libstorelibir.so.5 を libstorelibir-3.so のシンボリックにする
  • SAS-RAID_Firmware_F96NR_LN_6.3.3-0002_X00.BIN 実行

Root cause of problem is subroutine "sasdupie" from "SAS-RAID_Firmware_3P52K_LN_6.3.3-0002_X00.BIN" that fail while trying to use "libstorelibir.so.5"(or newer) located in /opt/dell/srvadmin/lib64, where for normal operation "sasdupie" expect to have "libstorelibir.so.3"(older than 5).

We may fix the problem next way:

cd /opt/dell/srvadmin/lib64
mv libstorelibir.so.5 libstorelibir.so.5.old
ln -s libstorelibir-3.so libstorelibir.so.5

(We presume that in path "/opt/dell/srvadmin/lib64" we have also "libstorelibir.so.3")

https://www.dell.com/community/PowerEdge-HDD-SCSI-RAID/Dell-PERC-6-i-Integrated-Firmware-Update-fails-with-inventory/td-p/4605951

chmod

FAT で BINファイルに実行権限つけられない場合は /tmp にコピーしてから chmod する

FAT32 formatted drives do not support file permissions. The permissions for everything are determined by how the drive is mounted.

How do I change file permissions on a FAT32 drive? - Ask Ubuntu

chmod etc does not work on NTFS / FAT formatted drives. Only works on Linux EXTx formatted drives.
Look into setting permissions in FSTAB or format the drive EXT4.

chmod not working on USB drive on Raspberry PI - Raspberry Pi Forums

PostgreSQL レプリケーション コンフリクト

ERROR:  canceling statement due to conflict with recovery
DETAIL:  User query might have needed to see row versions that must be removed.

PostgreSQLのレプリケーションのコンフリクトについて言いたい - Qiita 2017

PostgreSQLのレプリケーションのコンフリクトについて - そーだいなるらくがき帳 2017

pgroonga tuning

pgroonga.match_escalation_threshold

https://pgroonga.github.io/ja/reference/parameters/match-escalation-threshold.html

pgroonga.match_escalation_threshold
いつマッチエスカレーションが実行されるかを制御します。
マッチエスカレーションとは自動で条件のゆるい検索をする機能のことです。ヒット数が「pgroonga.match_escalation_threshold」パラメーターで指定した閾値よりも小さい時、自動で条件のゆるい検索をします。「-1」を指定することでマッチエスカレーションを無効にできます。デフォルト値は「0」です。これは1件もヒットしない時は自動で条件のゆるい検索を再度行うという意味です。詳細な検証が必要ですが、Groongaのエスカレーション動作によると「完全一致検索」→「非分かち書き検索」→「部分一致検索」の順に行うようです。内部的に複数回の検索をするため、高速化するという観点では「-1」を推奨します。
PGroongaの設定値チューニング | 株式会社インサイト

You need to use something PGroonga feature to show the parameter. If PGroonga isn't loaded, the parameter isn't visible.
SELECT pgroonga_command('status') will be the easiest way to use the PGroonga feature.
https://github.com/pgroonga/pgroonga/issues/169#issuecomment-777920917

# SELECT pgroonga_command('status');
# SHOW pgroonga.match_escalation_threshold;
 pgroonga.match_escalation_threshold
-------------------------------------
 0
(1 row)

nginx User-Agentで制限 UA

NGINX to block bad bots. (add Twenga|TwengaBot if you want to exclude them too) · GitHub

次に、拒否設定した User-Agent を使ってアクセスしてみます。
403 はアクセス拒否を示しています。

$ curl -H "User-Agent: Mozilla/5.0 Jorgee" -I http://<サーバー IP>/
HTTP/1.1 403 Forbidden

https://%E3%82%B5%E3%83%BC%E3%83%90%E3%83%BC%E6%A7%8B%E7%AF%89%E3%81%A8%E8%A8%AD%E5%AE%9A.com/?p=764


snippets/block-badbots.conf