*zabbix 導入 *zabbix インストール記録1 *zabbix インストール記録2 *zabbix バージョンアップ1 !!!日本語対応 *1.1 で日本語対応した。 *1.4 では一部が日本語表示されている。 *機能追加や変更に対する和訳がそろっていない。 !JavaScript での popup_menu での文字化け (1.4.2) *http://www.zabbix.com/forum/showthread.php?t=8049 *zabbix 文字化け調査 !マップ表示での文字化け (1.4.2) *php-gd の ImageString を利用しているため、ASCIIしか表示できない。 *ImageTTFText?? を使用すると文字化けを解消できた。 !メールでの文字化け (1.4.2) *php ソースでは、日本語に utf-8 を使っている *メールにはトリガの名称がDBに登録された名称で送られてくる。 *初期トリガは英語で登録されている。 *日本語で登録した場合、utf-8 で登録された。 *utf-8 で起動するとJISの日本語メール送信をするスクリプト sendjpmessage を, 上記の記事から引用し用意した。 *zabbix のメディアに登録した。フルパス指定する。 *日本語でのメール通知できた。 !zabbix-1.4.2 野良RPM作成 *{{ref zabbix-agent-1.4.2-3.x86_64.rpm}} *CentOS-4.5 x86_64 で作成 *Red Hat より spec ファイルを取得, RHEL-4 *zabbix-1.4.2 *自宅 p4dc で作成 *jabber 対応削除 --with-jabberを zabbix.spec から除去 *RHEL-4 の curl バージョンが低いため、zabbix-server の web-monitor が無効になっている。 !zabbix でテンプレートの内容がホストのアイテムに反映されない場合の対応 *ホストからテンプレートを切断し保存 *再度、ホストとテンプレートを接続 !日本語が文字化けする ImageString 関数についての調査 *ImageString 関数が記述されている zabbix のファイル # grep -irl imagestring /opt/zabbix/php | grep -v -e orig -e diff /opt/zabbix/php/include/classes/graph.inc.php /opt/zabbix/php/include/config.inc.php /opt/zabbix/php/vtext.php /opt/zabbix/php/chart4.php /opt/zabbix/php/chart5.php /opt/zabbix/php/chart_sla.php /opt/zabbix/php/map.php *ファイルの依存関係 ,ファイル,依存 ,include/classes/graph.inc.php,include/items.inc.php include/hosts.inc.php ,include/config.inc.php,classes 多数 ,vtext.php,include/config.inc.php ,chart4.php,include/config.inc.php include/triggers.inc.php include/page_header.php ,chart5.php,include/config.inc.php include/services.inc.php include/page_header.php ,chart_sla.php,include/config.inc.php include/services.inc.php include/page_header.php ,map.php,include/config.inc.php include/maps.inc.php include/page_header.php !windows 系マシンを perf_counter で監視する場合 *typeperf で文字列を確認する。 typeperf -qx *特に Intel 製 NIC の場合 *「Intel(R)」は「Intel[R]」で登録する *「/」は「_」 *複数NICの場合の「#」は「_」 !!!参考情報 !!php !画像系文字化け修正 *imagestring **文字列を水平に描画する **bool imagestring ( resource image, int font, int x, int y, string sring, int color ) *imagettftext **TrueType フォントを使用してテキストを画像に書き込む **array imagettftext ( resource image, float size, float angle, int x, int y, int color, string fontfile, string text ) *imagettfbbox **TypeType フォントを使用したテキストの bounding box を生成する **array imagettfbbox ( float size, float angle, string fontfile, string text )