dirkabc 发表于 2016-6-1 13:25:52

压力测试碰到的问题,求指点

今天用loadrunner做一个.net程序的压测,测试结果发现只要有并发的情况,就会有部分的请求响应时间很慢,但看服务器,iis没有排队的进程,其他cpu等指标也不高。
程序只是一个普通的查询,数据库也没压力。不知道有没有碰到过类似情况的高手?
data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAMcAAAGGCAIAAABAFALsAAASN0lEQVR4nO2aQdKkNgyFuVpytNTcLFUss0lVzpIdWUyHaVqyJMuykej3lWuKwRiree+3hfH2z99/oaDElu3HHz9QUGLL9vtvv6OgxJbt+J9t+3UMkpNcrO3nRPjjjx8/A719SkZRS36x4Kp6Jb9YcFW9kl8s3lXbldUx9fd4b8C9gQ1GmF8saaxaHOJIdx9tUxkrPJ78YsFV2X8aLfnF6nDVxxhOh/SPEZj9r3DmPO7qpRWq2u9HrRyY49ep4b036bpbfrH6XNV6XmzQrVYfF7SasBe0brtdadnL2Evvr2v1qLrqo9Z4t/xiOV31ISH7IAThhR/Qpbf6X9ZtRtvJ/baeRoir5LvlF8vjKrvexiaWQIVejKG6f0vXr5O7Y28r/HC25BdrlqscFpntqvHA7DdpaSDcxH63/GJ5XPWPeVAVmryfESL+uN4SWyvUjzOtqIz9yk1GXKXeLb9Ykqu+obSUy1zyi/Vrf9XPQG/fmoNiKcnF2gCI59wTs/+5H/9v3MG/yf/9KVZaLq56NxnITCVX3RgHsIOxCkyhkqsuFSTxEqqEi0E47Fhlf/gjMrWS8s/LzqP3serDMa2Y3lPI8YiBHYerAqXR+zqP3gPtclVXf2AcOlbRP2+2VWAAygXnkXus6uoPhGBx1cc8dR5/nPkQ3ZLJsB1d7skG6nAV8qplfIxVrCJCotLKW6jDhACE/x4Yq4rS5Sq2aiQ/li0ROVZZogEh0LGKvpfd4qpfB2cd3gELcbqq5R7fDPhxpkWfqz4ubXn/o4o9A+bxPlbJYxKVSbhg1gwIW1Sh2Nr6u53xb9p/F7hqI3S03f/cUVBiSzOvAplJLhZcVZLkY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 发表于 2016-6-1 14:30:07

不能贴图,只能贴数据了,大部分响应时间为0.03s,慢的要十几秒。
Host Name        Scenario Elapsed Time        Transaction Response Time        Transaction Name       
localhost        20.738        0.033        Action_Transaction       
localhost        20.77        0.032        Action_Transaction       
localhost        20.801        0.031        Action_Transaction       
localhost        20.831        0.03        Action_Transaction       
localhost        20.86        0.029        Action_Transaction       
localhost        20.889        0.029        Action_Transaction       
localhost        20.918        0.029        Action_Transaction       
localhost        20.95        0.031        Action_Transaction       
localhost        20.979        0.029        Action_Transaction       
localhost        21.01        0.031        Action_Transaction       
localhost        21.041        0.03        Action_Transaction       
localhost        21.071        0.03        Action_Transaction       
localhost        21.102        0.031        Action_Transaction       
localhost        21.131        0.029        Action_Transaction       
localhost        21.16        0.028        Action_Transaction       
localhost        21.189        0.03        Action_Transaction       
localhost        21.221        0.032        Action_Transaction       
localhost        21.248        0.027        Action_Transaction       
localhost        21.272        18.537        Action_Transaction       
localhost        21.3        0.028        Action_Transaction       
localhost        21.328        0.028        Action_Transaction       
localhost        21.355        0.027        Action_Transaction       
localhost        21.383        0.028        Action_Transaction       
localhost        21.41        0.027        Action_Transaction       
localhost        21.437        0.027        Action_Transaction       
localhost        21.465        0.028        Action_Transaction       
localhost        21.493        0.028        Action_Transaction       
localhost        21.522        19.021        Action_Transaction       
localhost        21.551        0.029        Action_Transaction       
localhost        21.578        0.028        Action_Transaction       
localhost        21.606        0.028        Action_Transaction       
localhost        21.638        0.032        Action_Transaction       

不锈钢老鼠 发表于 2016-6-2 10:33:25

遇到没法定位的时候,建议让开发或者自己在事务的每个阶段加上日志输出,将时间打出来,看下哪一个子逻辑耗时较大

seagull1985 发表于 2016-6-2 11:05:40

楼上正确,这种情况主要去看下日志,打详细一点,看下哪里的代码处理慢了。。

jingzizx 发表于 2016-6-2 13:52:23

或者能不能只对这个请求加压看看呢

jjnha 发表于 2016-6-2 19:18:32

都说了慢了,先把慢查询日志打开看看
页: [1]
查看完整版本: 压力测试碰到的问题,求指点