LoginSignup
2
1

More than 5 years have passed since last update.

muninでnginxのステータスを確認する

Posted at

なぜ書こうと思ったか

nginxのステータスをnginxで表示しているのですが、なぜか404エラーが出ていていたので。

予兆

nginxのステータスなのに、バックエンドのログにエラーがでていた。

対応方針

nginx_statusとserver-statusにアクセスがきていたので、両方を許容。

対応前

nginx.domain.conf
location ~ /nginx_status {
  .....(省略)

対応後

nginx.domain.conf
location ~ /(nginx_|server-)status {
        stub_status on;
        access_log off;
        allow 127.0.0.1;
        deny all;
        break;
}
2
1
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
2
1