質問編集履歴
5
メモリ情報追加
test
CHANGED
File without changes
|
test
CHANGED
@@ -437,3 +437,15 @@
|
|
437
437
|
2018/09/30 15:39:31 [info] 2335#0: *217 client timed out (110: Connection timed out) while waiting for request, client: 210.130.XXX.XX, server: 0.0.0.0:80
|
438
438
|
|
439
439
|
```
|
440
|
+
|
441
|
+
[2018/09/30 17:20追記]
|
442
|
+
|
443
|
+
```
|
444
|
+
|
445
|
+
total used free shared buff/cache available
|
446
|
+
|
447
|
+
Mem: 1015392 483236 229244 6876 302912 362924
|
448
|
+
|
449
|
+
Swap: 5242872 0 5242872
|
450
|
+
|
451
|
+
```
|
4
ログ追加
test
CHANGED
File without changes
|
test
CHANGED
@@ -425,3 +425,15 @@
|
|
425
425
|
}
|
426
426
|
|
427
427
|
```
|
428
|
+
|
429
|
+
|
430
|
+
|
431
|
+
[2018/09/30 15:41追記]
|
432
|
+
|
433
|
+
```
|
434
|
+
|
435
|
+
2018/09/30 15:38:30 [info] 2336#0: *210 client closed connection while waiting for request, client: 210.130.XXX.XX, server: 0.0.0.0:80
|
436
|
+
|
437
|
+
2018/09/30 15:39:31 [info] 2335#0: *217 client timed out (110: Connection timed out) while waiting for request, client: 210.130.XXX.XX, server: 0.0.0.0:80
|
438
|
+
|
439
|
+
```
|
3
設定ファイルの追加
test
CHANGED
File without changes
|
test
CHANGED
@@ -342,15 +342,7 @@
|
|
342
342
|
|
343
343
|
end
|
344
344
|
|
345
|
-
|
346
|
-
|
347
|
-
|
348
|
-
|
349
|
-
|
350
|
-
|
351
|
-
```
|
345
|
+
```
|
352
|
-
|
353
|
-
|
354
346
|
|
355
347
|
[2018/09/30 10:45追記]
|
356
348
|
|
@@ -371,3 +363,65 @@
|
|
371
363
|
エラーレベルが違うせいで表示されないのでしょうか?
|
372
364
|
|
373
365
|
それとも別の場所に設定されてしまっているのでしょうか?
|
366
|
+
|
367
|
+
```
|
368
|
+
|
369
|
+
以下が該当アプリ用のnginxの設定になります。(hoge.conf)
|
370
|
+
|
371
|
+
|
372
|
+
|
373
|
+
error_log /var/www/hoge/current/log/nginx.error.log;
|
374
|
+
|
375
|
+
access_log /var/www/hoge/current/log/nginx.access.log;
|
376
|
+
|
377
|
+
|
378
|
+
|
379
|
+
client_max_body_size 2G;
|
380
|
+
|
381
|
+
upstream app_server {
|
382
|
+
|
383
|
+
|
384
|
+
|
385
|
+
server unix:/var/www/hoge/current/tmp/sockets/.unicorn.sock fail_timeout=0;
|
386
|
+
|
387
|
+
}
|
388
|
+
|
389
|
+
server {
|
390
|
+
|
391
|
+
listen 80;
|
392
|
+
|
393
|
+
server_name hogehoge.com;
|
394
|
+
|
395
|
+
keepalive_timeout 5;
|
396
|
+
|
397
|
+
root /var/www/hoge/current/public;
|
398
|
+
|
399
|
+
|
400
|
+
|
401
|
+
try_files $uri/index.html $uri.html $uri @app;
|
402
|
+
|
403
|
+
location @app {
|
404
|
+
|
405
|
+
# HTTP headers
|
406
|
+
|
407
|
+
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
408
|
+
|
409
|
+
proxy_set_header Host $http_host;
|
410
|
+
|
411
|
+
proxy_redirect off;
|
412
|
+
|
413
|
+
proxy_pass http://app_server;
|
414
|
+
|
415
|
+
}
|
416
|
+
|
417
|
+
error_page 500 502 503 504 /500.html;
|
418
|
+
|
419
|
+
location = /500.html {
|
420
|
+
|
421
|
+
root /var/www/hoge/current/public;
|
422
|
+
|
423
|
+
}
|
424
|
+
|
425
|
+
}
|
426
|
+
|
427
|
+
```
|
2
一部修正
test
CHANGED
File without changes
|
test
CHANGED
@@ -356,7 +356,7 @@
|
|
356
356
|
|
357
357
|
505のエラーログって、上記に書いた1つ目の記事の6−2
|
358
358
|
|
359
|
-
|
359
|
+
|
360
360
|
|
361
361
|
error_log /var/www/hoge_app/current/log/nginx.error.log;
|
362
362
|
|
1
エラーログの出力場所について
test
CHANGED
File without changes
|
test
CHANGED
@@ -349,3 +349,25 @@
|
|
349
349
|
|
350
350
|
|
351
351
|
```
|
352
|
+
|
353
|
+
|
354
|
+
|
355
|
+
[2018/09/30 10:45追記]
|
356
|
+
|
357
|
+
505のエラーログって、上記に書いた1つ目の記事の6−2
|
358
|
+
|
359
|
+
#各種ログのディレクトリ設定
|
360
|
+
|
361
|
+
error_log /var/www/hoge_app/current/log/nginx.error.log;
|
362
|
+
|
363
|
+
access_log /var/www/hoge_app/current/log/nginx.access.log;
|
364
|
+
|
365
|
+
|
366
|
+
|
367
|
+
ここに出力されるという認識だったのですが、リアルタイムでここにログが載りません。
|
368
|
+
|
369
|
+
ここには最新のエラーログは残っていないのです。
|
370
|
+
|
371
|
+
エラーレベルが違うせいで表示されないのでしょうか?
|
372
|
+
|
373
|
+
それとも別の場所に設定されてしまっているのでしょうか?
|