You are on page 1of 2

When to Go for horizontal or vertical scaling

Horizontal scaling :
In Horizontal scaling we will increase server CPUs and Disks. Say we have 2 CPU's and 1 DIsk which we scaled to 8 and 2 res ectively. which !eans we rovide " ti!es as !#ch CPU ca acity$ %y increasing the n#!%er o& CPUs. 'he disk ca acity is do#%led %y roviding twice as !any disks. 'his is called horizontal scaling.

Vertical scaling :
In (ertical scaling CPUs o& Server are re laced %y ones that are &o#r ti!es as &ast. witho#t changing original CPU and Disks.In addition the disks are re laced %y ones that are twice as &ast. 'his !eans that we increase the ca acities %y the sa!e &actors as we did %y horizontal scaling$ however this ti!e not %y increasing the n#!%ers %#t the s eed o& the reso#rces. Note : The effect on resource behavior is the same for both horizontal and vertical scaling. )&ter scaling say &inal res#lt with a%ove new scaling gives #s clear that increasing the CPU ca acity %y a &actor " decreases the #tilization %y the sa!e &actor down to **+. Since the n#!%er o& disks increased %y a &actor 2 the #tilization o& the disks decreases %y the sa!e &actor 2 &ro! ,+ to -+. .ith horizontal scaling the res onse ti!e !ight %e red#ced %y &ew seconds$ however o&&ered vol#!e and thro#gh #t will %e e/#al and sa!e again which con&ir!s that we got rid o& the %ottleneck. .itho#t change in n#!%er o& #sers. only the /#e#ing &or the CPUs was red#ced d#e to the lower #tilization o& the CPUs a&ter Horizontal scaling Co! aring horizontal and vertical scaling we !ay concl#de0 1 .ith horizontal scaling the er&or!ance i! roves only when we have a %ottleneck %eca#se the #tilization o& the %ottleneck2reso#rce is red#ced$ which leads to shorter waiting ti!es. 1 .ith vertical scaling a lication er&or!ance i! roves always %eca#se the Per&or!ance i! roves. In addition to er&or!ance i! rove!ent in case o& a %ottlenecks the waiting ti!e decreases.

(ertical scaling see!s to %e !ore advantageo#s$ %#t one has to consider the costs too. Increased CPU2s eed is a rare heno!enon these days. 3ote0 'oday CPU s eed does not increase as s ectac#lar as it #sed to. Instead the !arket o&&ers increasing n#!%ers o& cores. In order to convert that into s eed$ o#r ind#stry is challenged now to a ly internal arallel rocessing in a lications. Per&or!ance !odels sho#ld %e ca a%le o& handling arallel co! #ting. In !odeling we #se the relative s eed o& reso#rces$ which is the ratio %etween the %aseline and the target s eeds. 4or !ost CPUs yo# can &ind their s eed at S ec5ark$ which is &or %ench!arking CPUs. 'he s eed o& single CPUs is e6 ressed in the CI3'277, %ench!ark.Hardware s eci&ication

(irt#al servers0 (irt#al servers a&&ect er&or!ance in two ways0 1. (irt#alizing i! oses e6tra overhead that !aterializes in e6tending the CPU2 co! onents o& the Per&or!ance. 8o# have to &ind o#t how !#ch overhead &or all reso#rces. 4or CPU co!!only 9 17+ to 1*+ has to %e added. 2. (irt#alizing allows &or roviding CPU ca acity %y &ractions o& CPUs. 'his res#lts in a &or! o& vertical scaling. I& the a lication is assigned 7." o& a CPU this sho#ld %e !odeled as the original CPU at 7." relative s eed.