何度かWebサーバーが停止したので

負荷テストしてみた。

あと、abのテスト結果も・・・。
※abは手元にあるMacbook Proからなので無線経由

$ ab -n 10240 -c 128 http://blog.cecily.jp/
This is ApacheBench, Version 2.3 <$Revision: 655654 $>
Copyright 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/
Licensed to The Apache Software Foundation, http://www.apache.org/

Benchmarking blog.cecily.jp (be patient)
Completed 1024 requests
~~~~~snip~~~~~
Finished 10240 requests

Server Software:        cloudflare-nginx
Server Hostname:        blog.cecily.jp
Server Port:            80

Document Path:          /
Document Length:        35704 bytes

Concurrency Level:      128
Time taken for tests:   47.175 seconds
Complete requests:      10240
Failed requests:        0
Write errors:           0
Total transferred:      370193273 bytes
HTML transferred:       365886593 bytes
Requests per second:    217.06 [#/sec] (mean)
Time per request:       589.694 [ms] (mean)
Time per request:       4.607 [ms] (mean, across all concurrent requests)
Transfer rate:          7663.23 [Kbytes/sec] received

Connection Times (ms)
              min  mean[+/-sd] median   max
Connect:        6  113 337.2     17    3588
Processing:   121  470 474.1    371    7792
Waiting:      105  154 135.6    131    3977
Total:        129  582 591.4    399    7806

Percentage of the requests served within a certain time (ms)
  50%    399
  66%    528
  75%    685
  80%    843
  90%   1380
  95%   1730
  98%   2257
  99%   2944
 100%   7806 (longest request)


とりあえずFailed requestsやWrite errorがないので大丈夫かな・・・。
Webサーバーが停止したのはメモリー不足だったみたいだけど・・・nginxにngx_pagespeedを組み込んだのが問題なのかな?
とりあえずswapを作成してマウントしてみた。。

# dd if=/dev/zero of=/swap.extended bs=1M count=1024
# mkswap /swap.extended
# swapon /swap.extended 
# cat /proc/swaps
Filename				Type		Size	Used	Priority
/swap.extended                          file		1048568	114948	-1
# vi /etc/fstab 
#
# /etc/fstab
# Created by anaconda on Tue Dec 17 15:22:08 2013
~~~~~snip~~~~~
LABEL=DOROOT		/                       ext4    defaults        1 1
tmpfs                   /dev/shm                tmpfs   defaults        0 0
~~~~~snip~~~~~
/swap.extended		swap			swap	defaults	0 0←追加した行

関連記事

  1. NO IMAGE
  2. NO IMAGE
  3. NO IMAGE
  4. NO IMAGE

    2022.07.26

    NASが……?
  5. NO IMAGE
  6. NO IMAGE

    2013.12.22

    VPSを契約した

コメントをお待ちしております

CALENDAR

2024年11月
 12
3456789
10111213141516
17181920212223
24252627282930

ARCHIVES

CATEGORIES