Copyright © 2008 VMware, Inc. All rights reserved. 16
Installing and Configuring Linux Guest Operating Systems
Asynchronous I/O
SupportforasynchronousI/OinthekernelandcorrespondingsystemcallsareincludedinLinuxkernel
version2.6.ButtheAPIfortheappropriatesystemcallsdiffersfromtheoriginalfunctions,soasimple
recompilationofexistingapplicationsmightbeinsufficienttousethenewchange.Thechangerequiressource
code
modificationthathasoccurredindifferentapplicationsatdifferentrates.
BeawareofthisissuewhenconsideringapplicationsthatuseasynchronousI/O.Inbenchmarking,for
example,IometerisatoolthatcanbeusedforstoragesystemperformancemeasurementsonbothWindows
andLinux.However,becauseitssourcecodewasnever
updatedtousethenew,correctedasynchronousI/O
systemcallsonLinux,thenumbersitproducesonLinux(usingrawdevices)areartificiallyandunfairlylow.
ConsiderthiswhendoingLinux‐to‐WindowscomparisonsanduseasynchronousI/O‐awaretoolssuchas
aiostress,whenneeded.
Linux Timer Rates for Virtual Machines on VMware ESX
Modernsystemsuseahardwaretimerforavarietyoffine‐grainedoperationsattheoperatingsystemlevel.
VMware’svirtualizationplatformsvirtualizethistimerintheESXkernel.Becausethevirtualtimerprovided
tothevirtualmachineisactuallysoftware,itissubjecttothesameresourcerestrictionsasotherprocesses.
The
busierthesystem,themorethetimerexecutionmustcontendwithotherhypervisoractivities.Therearetwo
implicationsofthis:
Whenthesystemisverybusy,thesoftwaretimermightnotexecuteasregularlyasitdoeswhenthe
systemislessbusyandvirtualtimecanfallbehind.
Dependingonhowfrequentlytheoperatingsystemisinterruptedbythetimer,thehypervisormustdo
differentamountsofwork.
TheamountofworkrequiredtomanagethevirtualtimerisgreatestwithRedHatEnterpriseLinux5SMP
systems,whichuseaclockfrequencyof1000Hzandsufferfroma
multiplicativeamountofworkbecauseof
SMPsupport.Forinstance,thefollowingtableshowsthenumberoftimerinterruptsona1000HzRedHat
EnterpriseLinux5virtualmachine:
Theamountofworkthatneedstobedonebythehypervisorincreasesdramaticallywiththeadditionof
virtualCPUs.Inaddition,
decreasingthetimerinterruptrategreatlydecreasestheworkthatneedstobedone
bytheVMkerneltovirtualizethetimer.RedHatEnterpriseLinux5.1andRedHatEnterpriseLinux4.7offer
aLinuxkernelthatenablesreducingthetimerrate.Byaddingtheparameterdivider=10totheboot
parametersasdescribedin“LinuxTimeSynchronizationRecommendations”onpage 12,youcanreducethe
amountofworkrequiredoftheVMkerneltovirtualizethetimerbyanorderofmagnitude.
Table 6. Timer Interrupts for Multiple Virtual CPUs in Red Hat Enterprise Linux 5
Virtual CPU Count Timer Interrupts per Second per Virtual Machine
11000
26000
4 20000
8 72000
Table 7. Timer Interrupts for Selected Linux Distributions
Linux Version Timer Interrupts per Second per Virtual CPU
RedHatEnterpriseLinux51000
RedHatEnterpriseLinux4100
SUSELinuxEnterpriseServer10SP1 250
SUSELinuxEnterpriseServer91000
SUSELinuxEnterpriseServer8100
Commentaires sur ces manuels