# Why My bench result was so strange， rps too low

**URL:** <https://discuss.hashicorp.com/t/why-my-bench-result-was-so-strange-rps-too-low/37176>\
**Category:** Consul\
**Created:** [March 17, 2022, 3:22am UTC](https://discuss.hashicorp.com/t/why-my-bench-result-was-so-strange-rps-too-low/37176 "2022-03-17T03:22:38Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![domyway](https://sea2.discourse-cdn.com/hashicorp/user_avatar/discuss.hashicorp.com/domyway/32/26757_2.png) [@domyway](https://discuss.hashicorp.com/u/domyway)\
**Post date:** [March 17, 2022, 3:22am UTC](https://discuss.hashicorp.com/t/why-my-bench-result-was-so-strange-rps-too-low/37176/1 "2022-03-17T03:22:38Z")

</div>

I start consul like this :

> consul agent -enable-script-checks=false -log-level error -config-file=./config.hcl -bootstrap=true

config.hcl content :

```auto
bind_addr = "127.0.0.1"
data_dir = "./data_dir"
server = true
client_addr = "127.0.0.1"
node_name = "nodename"
enable_debug = true
ui_config = {
  enabled = true,
  content_path = "/ui/"
}

ports = {
  server = 8300
  serf_lan = 8301
  serf_wan = 8302
  http = 8500
  dns = 8600
}

limits {
  http_max_conns_per_client = 65530
}

```

Then I use wrk , the result is strange, can somebody tell me why?

> wrk -t128 -c500 -s reg\_svc.lua -d60 [http://127.0.0.1:8500](http://127.0.0.1:8500)  
> Running 1m test @ [http://127.0.0.1:8500](http://127.0.0.1:8500)  
> 128 threads and 500 connections  
> Thread Stats Avg Stdev Max +/- Stdev  
> Latency 1.08s 549.54ms 1.99s 56.58%  
> Req/Sec 5.25 6.50 20.00 87.93%  
> 2635 requests in 1.00m, 344.81KB read  
> Socket errors: connect 0, read 0, write 0, timeout 2559  
> Requests/sec: 43.84  
> Transfer/sec: 5.74KB

the Result Requests/sec is only 43.84, is that normal?

the reg\_svc.lua content :

```auto
wrk.method = "PUT"
wrk.body = ""
wrk.headers["Content-Type"] = "application/x-www-form-urlencoded"

math.randomseed(os.time())
local path = "/v1/agent/service/register?replayce-existing-checks=false"
local i = os.time()
local body = [[{
  "ID": "mysql%d",
  "Name": "mysql%d",
  "Address": "127.0.0.1",
  "Port": 3306,
  "EnableTagOverride": false
}]]
request = function()
    query = string.format(body, i, i)
    local body = wrk.format(nil, path, nil, query)
    i = math.random(0,9000000)
    return body
end

```
