注:本试卷中题目所涉及性能测试工具如无特殊说明则均为LoadRunner。

一、        简答题(2*10=20分)

  1. 1.     客户交付一个性能测试项目,请阐述你的实施流程。
  2. 2.     解释5个常用的性能指标的名称与具体含义。
  3. 3.     写出5个Loadrunner中常用函数,并对其中2个举例说明用法。
  4. 4.     简述LoadRunner的工作原理?
  5. 5.     什么是集合点?设置集合点有什么意义?LoadRunner中设置集合点的函数是哪个?
  6. 6.     HTML-based script与URL-based script的脚本有什么区别?
  7. 7.     如何设置LaodRunner才能让集合点只对一半的用户生效?
  8. 8.     LoadRunner的Controller组件中Pacing参数的作用是什么?
  9. 9.     LoadRunner中如何监控Windows资源?
  10. 10.  如果让QALoad模拟LoadRunner中只对关注的性能点进行迭代测试,你有什么好方法?
  11. 11.  什么是负载测试
  12. 12.  什么是性能测试?
  13. 13.  说明负载测试过程?
  14. 14.  我们什么时候做负载和性能测试?
  15. 15.  什么是LoadRunner的组件?
  16. 16.  你用LoadRunner的哪个组件录制脚本?
  17. 17.  在多用户模式下你用LoadRunnner的哪个组件来回放脚本?
  18. 18.  在多用户模式下你用LoadRunnner的哪个组件来回放脚本?
  19. 19.  什么是场景
  20. 20.  解释Web Vuser脚本的录制模式
  21. 21.  为什么创建参数?
  22. 22.  什么是关联?解释自动关联和手动关联的区别
  23. 23.  什么是关联?解释自动关联和手动关联的区别
  24. 24.  你在哪里设置自动关联的选项
  25. 25.  什么函数可以捕捉到web Vuser脚本的动态值?
  26. 26.  什么时候你在虚拟用户产生器中禁用日志,什么时候选择标准日志和扩展日志?
  27. 27.  你如何调试LoadRunner的脚本?
  28. 28.  你怎么写LR中用户自定义的函数?写几个你以前项目中的函数?
  29. 29.  在run-time setting里你可以设置哪些改变?
  30. 30.  你在哪里设置Vuser测试时迭代?
  31. 31.  你如何在负载下执行功能测试?
  32. 32.  什么是Ramp up?你如何设置?
  33. 33.  Vuser作为线程运行的优势是什么?
  34. 34.  如果你想停止执行出错的脚本,怎么做?
  35. 35.  响应时间和吞吐量间的关系是什么?
  36. 36.  你如何识别性能瓶颈?
  37. 37.  如果web服务器、数据库服务器、网络都一切正常,那么哪里可能有问题?
  38. 38.  你如何找出web服务器相关的问题?
  39. 39.  你是怎么找到数据库中的相关问题?
  40. 40.  覆盖图和关联图之间的区别是什么?
  41. 41.  你是怎么计划负载的?标准是什么?
  42. 42.  vuser_init动作包含什么?
  43. 43.  vuser_end动作包含什么?
  44. 44.  什么是Think Time?你如何改变这个阈值?
  45. 45.  简述使用Loadrunner的步骤
  46. 46.  什么是集合点?设置集合点有什么意义?Loadrunner中设置集合点的函数是哪个?
  47. 47.  请解释一下如何录制web脚本?
  48. 48.  请解释一下自动关联和手动关联的不同。
  49. 49.  哪个函数是用来截取虚拟用户脚本中的动态值?(手工关联)
  50. 50.  你如何在负载测试模式下执行功能测试?
  51. 51.  什么是逐步递增?你如何来设置?
  52. 52.  当你需要在出错时停止执行脚本,你怎么做?
  53. 53.  响应时间和吞吐量之间的关系是什么?
  54. 54.  说明一下如何在LR中配置系统计数器?
  55. 55.  .如果web服务器、数据库以及网络都正常,问题会出在哪里?
  56. 56.  如何发现web服务器的相关问题?
  57. 57.  .如何发现数据库的相关问题?
  58. 58.  解释所有web录制配置?
  59. 59.  你如何设计负载?标准是什么?
  60. 60.  什么是吞吐量?
  61. 61.  在LoadRunner中为什么要设置思考时间和pacing
  62. 62.  如何理解TPS?
  63. 63.  loadrunner中的设置线程和进程的区别
  64. 64.  loadrunner如何遍历一个页面中的url并进行访问?
  65. 65.  HTML-Based scrīpt 和URL-Based scrīpt 录制的区别?
  66. 66.  LoadRunner如何创建脚本?
  67. 67.  LoadRunner如何设置Recording Options 选项?(以单协议http/html为例)
  68. 68.  LoadRunner如何选择协议?
  69. 69.  Loadrunner支持哪些常用协议?
  70. 70.  性能测试的类型都有哪些?
  71. 71.  Loadrunner常用的分析点都有哪些?
  72. 72.  LoadRunner请求无法找到如何解决?
  73. 73.  LoadRunner HTTP服务器状态代码都有哪些?如何解决?
  74. 74.  HTTP的超时有哪三种?
  75. 75.  在什么地方设置HTTP页面filter?
  76. 76.  如何设置可以让一个虚拟IP对应到一个Vuser?
  77. 77.  什么是contentcheck?如何来用?
  78. 78.  network中的speed simulation是模拟的什么带宽?
  79. 79.  生成WEB性能图有什么意义?大概描述即可。
  80. 80.  WAN emulation是模拟什么的?
  81. 81.  如何设置才能让集合点只对一半的用户生效?
  82. 82.  在设置windows资源图监控的时候,用到的是什么端口和协议?在这一过程中,会有大概哪些问题?(大概描述)
  83. 83.  树视图和脚本视图各有什么优点?
  84. 84.  需要关联的数据怎么确定?
  85. 85.  解释以下函数及他们的不同之处。
  86. 86.  Lr_debug_message

Lr_output_message

Lr_error_message

Lrd_stmt

Lrd_fetch

 

二、选择题(2*5=10

  1. 1.     During the run of a scenario, which LoadRunner component stores the performance monitoring data?

A. Analysis   B. Controller   C. File server    D. Load generator/host

  1. 2.     Where are the results stored during the run of a scenario?

A. Analysis    B. Controller    C. Utility server     D. Load generator

  1. 3.     A script was recorded with an average think time for an advanced user. An advanced user pauses 5 seconds between clicks. A first-time user pauses an average of 10 seconds between clicks. How can you modify the think time run-time settings to emulate a first-time user?
    A. Set the think time to s recorded
    B. Set the think time to multiply the recorded think time by 4
    C. Set the think time to a random percentage between 150% - 250%
    D. Set the think time to replay as recorded, but limit the think time to 10 seconds
  2. 4.     Which HTTP error code indicates that an individual business process is failing under load or the web application itself has crashed?
    1. A.   200   B. 403   C. 401    D. 500
    2. 5.     What is an intersection point in a business process?

A. Scenario    B. Rendezvous   C. Transaction     D. Service level agreement

 

三、LoadRunner工具使用题:(10*2=20分)

  1. 1.     web系统中,username参数表为file类型,表中有12个值,分别A、B、C、D、E、F、G、H、I、J、K、L。测试场景中虚拟并发用户数设为4,迭代次数设为3,参数中Select next row与Update value on分别为(Sequential, Each Iteration)与(Unique, Once)时,写出迭代3次的取值情况。

(Select next row, Update value on)        虚拟用户取值(VUi:迭代时取值)

(Sequential, Each Iteration)

VU1

VU2

VU3

VU4

(Unique, Once)       

VU1

VU2

VU3

VU4

  1. 2.     web系统脚本录制过程中,两次录制同一功能点,在View Tree的Server Response中产生的字符串分别为:

Server Response:name="_id_Node " value=" RSDP0013425" />", ENDITEM,

Server Response:name="_id_Node " value=" RSDP1203655" />", ENDITEM,

为脚本回放成功,需要对字符串中某些字符做一定处理,写出详细实现方法。

 

四、 英文面试题

1. What is load testing?

2. What is Performance testing?

3. Did u use LoadRunner?

4. Explain the Load testing process?

5. When do you do load and performance Testing?

6. What are the components of LoadRunner?

7. What Component of LoadRunner would you use to record a Script?

8. What Component of LoadRunner would you use to play Back the script in multi user mode?

9. What is a rendezvous point?

10. What is a scenario?

11. Explain the recording mode for web Vuser script?

12. Why do you create parameters?

13. What is correlation?

14. How do you find out where correlation is required?

15. Where do you set automatic correlation options?

16. What is a function to capture dynamic values in the web Vuser script?

17. When do you disable log in Virtual User Generator, When do you choose standard and extended logs?

18. How do you debug a LoadRunner script?

19. How do you write user defined functions in LR?

20. What are the changes you can make in run-time settings?

21. Where do you set Iteration for Vuser testing?

22. How do you perform functional testing under load?

23. What is Ramp up? How do you set this?

24. What is the advantage of running the Vuser as thread?

25. If you want to stop the execution of your script on error, how do you do that?

26. What is the relation between Response Time and Throughput?

27. Explain the Configuration of your systems?

28. How do you identify the performance bottlenecks?

29. If web server, database and Network are all fine where could be the problem?

30. How did you find web server related issues?

31. How did you find database related issues?

五.项目分析题

(试题一)阅读下列说明,回答问题1 至问题3,将解答填入答题纸的对应栏内。
【说明】软件系统性能调优的关键是首先作好性能故障定位,面对软件系统中运行在不同平台上的多个服务器、多种应用、大量工作站以及局域网、广域网和其他类型的网络体系结构,故障点交错,故障定位测试非常复杂。下述是《工作流平台系统》的性能测试案例描述及结果数据:
  ● 测试案例描述:模拟多用户登录《工作流平台系统》,针对工作流A、B、C 分别连续创建20 个实例,在单机和集群运行环境下分别对系统进行负载压力性能测试。单机环境下测试用机与一台应用服务器连在同一交换机上,压力直接加在一台应用服务器上。集群环境下测试用机与服务器集群连接在同一交换机上,压力由负载均衡模块分摊到俩台应用服务器上。在单机和集群运行环境中应用服务器和一台数据库服务器连接。
  ● 客户端交易并发执行测试数据:

1 单机运行环境

测试
案例

并发用
户数

响应时间(秒)

最大值

平均值

最小值

创建
工作
流A
实例

120

0.675

0.686

0.03

 240

0.756

0.479

0.034

 

2 集群运行环境

测试
案例

并发用
户数

响应时间(秒)

最大值

平均值

最小值

创建
工作
流A
实例

120

0.113

0.088

0.01

 240

0.103

0.117

0.01

 

  ● 服务器资源占用情况
  1 单机运行环境①应用服务器资源占用情况

测试案例

并发用户数

资源占用指标

最大值

平均值

最小值

创建工作流
A 实例

120

CPU Utilization(%)

33.8

10.054

2.9

Paging Rate(page/s)

2.5

0.082

0

Disk traffic(Mbyte/s)

9.75

0.813

0

240

CPU Utilization(%)

38.1

8.713

0.875

Paging Rate(page/s)

0.25

0.015

0

Disk traffic(Mbyte/s)

2.6

0.336

0

②数据库服务器资源占用情况

测试案例

并发用户数

资源占用指标

最大值

平均值

最小值

创建工作流
A 实例

120

CPU Utilization(%)

44.875

5.085

0.5

Paging Rate(page/s)

4.75

0.274

0

Disk traffic(Mbyte/s)

8.8

1.824

0.6

240

CPU Utilization(%)

12.2

1.766

0.5

Paging Rate(page/s)

5.4

0.244

0

Disk traffic(Mbyte/s)

7.2

1.584

0.6

 

测试案例

并发用户数

资源占用指标

最大值

平均值

最小值

创建工作流
B 实例和工
作流C 实例

60

CPU Utilization(%)

100

87.082

0.875

Paging Rate(page/s)

268.992

158.865

0

Disk traffic(Mbyte/s)

193.319

110.948

2.25

120

CPU Utilization(%)

99.3

88.419

1.15

Paging Rate(page/s)

751.358

189.785

1.8

Disk traffic(Mbyte/s)

217.775

146.304

2

240

CPU Utilization(%)

100

88.909

0.6

Paging Rate(page/s)

521.447

151.829

0

Disk traffic(Mbyte/s)

197.725

146.285

0.6

  2 集群运行环境①俩台应用服务器资源占用情况

测试
案例

并发用户数

资源占用指标

应用服务器1

应用服务器2

最大值

平均值

最小值

最大值

平均值

最小值

创建工
作流
A 实例

120

CPU Utilization(%)

46

21.005

14

46.25

14.025

7.667

Paging Rate(page/s)

3.5

0.392

0

2.167

0.206

0

Disk traffic(Mbyte/s)

65.334

6.647

0

73.833

7.588

0

240

CPU Utilization(%)

42

27.163

1.583

37.333

17.856

0.75

Paging Rate(page/s)

3

0.206

0

0.667

0.045

0

Disk traffic(Mbyte/s)

7

0.849

0

6

0.674

0

  ②数据库服务器资源占用情况

测试案例

并发用户数

资源占用指标

最大值

平均值

最小值

创建工作流
A 实例

120

CPU Utilization(%)

13

2.868

0.333

Paging Rate(page/s)

0

0

0

Disk traffic(Mbyte/s)

6.667

1.767

0.6

240

CPU Utilization(%)

34.5

5.644

0.25

Paging Rate(page/s)

10.667

0.508

0

Disk traffic(Mbyte/s)

5.6

1.596

0.75

【问题1】单机运行环境和集群运行环境下,系统能够提供的客户端并发性能服务等级哪种更好?为什么?
【问题2】试分析系统应用服务器和数据库服务器资源使用情况如何?是否有瓶颈存在?单机运行环境和集群运行环境相比,哪种环境下资源占用率更高?为什么?随着系统并发负载的加大,试预测哪种环境下资源占用率递增更快?
【问题3】
集群对系统性能有哪些贡献?有哪些弊端?该系统是否应该采用此集群部署策略?

 

(试题二)

下面是一个项目的性能测试结果,请分析可能存在的性能问题。

 


 

 

Unix服务器性能监控(数据库服务器内存8G,上千万行大量数据)

监控对象

性能参数

说明

内存

Memory

Real Free MBytes

可用自由内存总量,单位是兆字节

Virtual Free MBytes

可用自由虚拟内存总量,单位是兆字节

网络Network Interface

Bytes Total/s

网络发送和接收的速率,单位是字节/秒

磁盘

Physical Disk

Disk Read KB/s

磁盘读取速率,单位是千字节/秒

Disk Write KB/s

磁盘写入速率,单位是千字节/秒

处理器

Processor

CPU Time%

处理器执行非闲置线程时间的百分比

Wait Time%

处理器执行等待时间的百分比

       

 

Linux服务器性能监控(应用服务器内存4G)

监控对象

性能参数

说明

内存

Memory

Available Swap MBytes

显示Swap空间的剩余量,单位是千字节

Free Memory MBytes

可用自由内存总量,单位是千字节

网络Network Interface

Bytes Total/s

网络发送和接收的速率,单位是字节/秒

磁盘

Physical Disk

Disk Read KB/s

磁盘读取速率,单位是千字节/秒

Disk Write KB/s

磁盘写入速率,单位是千字节/秒

处理器

Processor

CPU Time%

处理器执行非闲置线程时间的百分比

Wait Time%

处理器执行等待时间的百分比

       

 


 

表1  单用户执行XX查询

时间特性表

测试过程说明

测 试 结 果  (时间单位:秒)

用户数

响应时间

XX查询

1

51.77

资源特性表

最小值

平均值

最大值

数据库服务器资源特性

内存

Memory

Real Free MBytes

4474.00

4479.05

4487.40

Virtual Free MBytes

16116.60

16116.60

16116.60

网络Network Interface

Bytes Total/sec

0.00

11.36

393.00

磁盘

Physical Disk

Disk Read KB/s

0.00

5539.28

8437.50

Disk Write KB/s

0.00

21.99

339.80

处理器

Processor

CPU Time%

0.00

1.78

3.60

Wait Time%

0.00

13.67

17.30

应用服务器资源特性

内存

Memory

Available Swap KBytes

2045.60

2045.60

2045.60

Free Memory KBytes

49.40

49.44

49.50

网络Network Interface

Bytes Total/sec

0.00

24.29

807.40

磁盘

Physical Disk

Disk Read KB/s

0.00

0.00

0.00

Disk Write KB/s

0.00

15.25

143.20

处理器

Processor

CPU Time%

0.00

0.26

4.00

Wait Time%

0.00

0.00

0.00

 

 

 


 

表2  20用户并发执行XX查询

时间特性表

测试过程说明

测 试 结 果  (时间单位:秒)

并发用户数

成功用户数

最小响应时间

平均响应

时间

最大响应

时间

90%响应

时间

XX查询

20

20

82.29

83.15

84.42

83.60

资源特性表

最小值

平均值

最大值

数据库服务器资源特性

内存

Memory

Real Free MBytes

4430.50

4963.65

6477.20

Virtual Free MBytes

16115.70

16116.97

16120.90

网络Network Interface

Bytes Total/sec

2.40

175.82

2198.20

磁盘

Physical Disk

Disk Read KB/s

0.00

110732.71

196719.10

Disk Write KB/s

0.00

30.80

441.60

处理器

Processor

CPU Time%

0.10

23.30

59.00

Wait Time%

0.20

39.17

86.60

应用服务器资源特性

内存

Memory

Available Swap KBytes

2045.60

2045.60

2045.60

Free Memory KBytes

48.00

49.26

49.80

网络Network Interface

Bytes Total/sec

0.00

494.85

6245.60

磁盘

Physical Disk

Disk Read KB/s

0.00

0.00

0.00

Disk Write KB/s

0.00

19.53

163.20

处理器

Processor

CPU Time%

0.00

2.70

36.80

Wait Time%

0.00

0.00

0.00

 


 

 

posted on 2020-04-21 10:13  璇子的蓝色城堡  阅读(1149)  评论(0编辑  收藏  举报