From fb53986a801bc36067a5b5b64cb23b05e3aa6d60 Mon Sep 17 00:00:00 2001 From: isaacs Date: Tue, 6 Mar 2012 18:19:11 -0800 Subject: [PATCH] Bash script for running http-simple benchmarks --- benchmark/http.sh | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100755 benchmark/http.sh diff --git a/benchmark/http.sh b/benchmark/http.sh new file mode 100755 index 0000000..22b4b7c --- /dev/null +++ b/benchmark/http.sh @@ -0,0 +1,10 @@ +#!/bin/bash +cd "$(dirname "$(dirname $0)")" +sudo sysctl -w net.inet.ip.portrange.first=12000 +sudo sysctl -w net.inet.tcp.msl=1000 +sudo sysctl -w kern.maxfiles=1000000 kern.maxfilesperproc=1000000 +ulimit -n 100000 +./node benchmark/http_simple.js || exit 1 & +sleep 1 +ab -n 30000 -c 100 http://127.0.0.1:8000/bytes/123 | grep Req +killall node -- 2.7.4