80 likes | 448 Views
Tutorial 6. Tutorial 6. Overview. Predicting Performance Simulation vs Analytical Models Mathematical Modelling of Distributions Operational Variables Operational Laws Tutorial 5 Solutions are posted on eLearning Question 2 Review – Average Request time and saturation Tutorial 6.
E N D
Tutorial 6 Tutorial 6
Overview • Predicting Performance • Simulation vs Analytical Models • Mathematical Modelling of Distributions • Operational Variables • Operational Laws • Tutorial 5 • Solutions are posted on eLearning • Question 2 Review – Average Request time and saturation • Tutorial 6
Predicting performance Tutorial 6
Question 1 • Given Parameters: • τ = 10*60 = 600s (observation period) • C0 = 1200 tasks (total requests completed) • Cdisk = 2400 accesses • Sdisk = 0.1 s (mean disk service time) • Required Equations: • a) Ui = ? (Ui = Sdisk x Xdisk) • = 0.1 x (2400/600) • = 0.4 (40% utilization) • b) Ddisk = Udisk / X0 • = 0.4 / (1200/600) • = 0.2 • c) Accesses per second = (2400/600 = 4 per scond) • Time between each access is therefore ¼ =0.25 s.
Question 2 • Average number of visits to each device per arriving packet. • Given: information required to work out average number of requests per second at each resource: • B= 0.5*A (requests per second at B) • A = 20 + 0.75*B (requests per second at A) • Solving simultaneously: A = 32, B=16 • For 20 requests there are 32 visits at A: 1.6 visits at a per request. • For 20 requests there are 16 visits at B: 0.8 visits at b per request.
Question 3 (a) • Given Parameters: • N=20 • Z=5s • Ra=0.1s (requests of type A made 50% of the time) • Rb=3s (requests of type B made 50% of the time) • Xa =? • Required Equations: • R= (N/X) – Z (“Interactive Response Time Law”) • Ravg = (0.5)(0.1) + (0.5)(3) = 1.55 • 1.55 = (20/Xavg) – 5 • Xavg = 20/6.55 = around 3 completions per second • Xa = around 1.5 completions per second since half of the requests are of type A.
Question 3 (b) • What’s the effect if half of the clients submit type A request, and half submit type B requests? • Use Response time law again: • For type A: Ra=(Na/Xa) – Z • 0.1=(10/Xa) – 5 • Xa=around 2 • For type B: Rb=(Nb/Xb) – Z • 3=(10/Xb) -5 • Xb=1.25 More short requests can be completed per second because they are not held up by long type B requests. Less type B requests completed because there are less clients to service them. As an architect you can trial many system configurations until performance metrics suit your needs.
PART B • The resource with the largest service demand / highest utilization corresponds to the bottleneck resource. • Often we need to identify the resource that represents this bottleneck and take appropriate action to remove this bottleneck: add an additional disk, or multi-core CPUs, faster disks, faster CPUs, etc. • Chapter 5 of “Performance By Design” goes through a practical database example where bottlenecks are identified and removed in an iterative fashion