资源描述:
《容器里面乾坤大采用容器部署应用的庄振运》由会员上传分享,免费在线阅读,更多相关内容在学术论文-天天文库。
1、容器里面乾坤大:采用容器部署应用的性能考虑Memory-relatedPerformancePi3allsandSolu7onsforLinuxCgroup’sbasedDeploymentsଢഄᬩ1OutlineqIntroduc7onqMemoryrelatedperformancepi3allsqStrategiesqDiscussionsqConclusion2SelfIntroduc7onqLinkedInorMicrosoC?§N/AqPerformanceengineering§Applica7ons(HTTP,P2P,Had
2、oop,streaming,etc.)§Java(JVM,GC,etc.)§VM/Container(cgroups,etc.)§Linux(Memorymanagement,filesystem,cpuscheduling,etc.)§Networking(Wireless/mobile,TCP/IP,etc.)§Storage(HDD,SSD,etc.)qOtherinterest§Chineseculture(History,Poems,etc.)3ProblemcontextqContainer§Linuxcgroups,Docker
3、,CoreOSqNewchallengesinAPM§Performancemetricsmonitoring§Deploymentconcerns§Debugging/aler7ngqKnowledgesharing,discussions§Cgroups,performance,memoryqBlog§hYps://engineering.linkedin.com/blog/2016/08/don_t-let-linux-control-groups-uncontrolled4Technicalbackgrounds(Cgroups)R
4、egularcgroupRootcgroupUsermemoryUsermemory(Anonymous)Memorylimit(Anonymous)Pagecache(bounded)(unbounded)PagecacheusageusageMemnotallocatedSwappiness=0Swappiness=1Overcommit_memorypolicySwapspace5OutlineqIntroduc7onqMemoryrelatedperformancepi3allsqStrategiesqDiscussionsqCon
5、clusion6Memoryrelatedperformancepi3allsqMemoryisnotallocatedqPagecacheispartofmemorylimit,canbeevictedbyanonymousmemoryrequestqOScanreclaimsystem-widepagecacheqOScanswapsystem-wideanonymousmemoryqVirtualmemoryspaceisnotlimited7ExperimentsetupqHardware§IntelXeonE5-2680,dual
6、sockets(12physicalcores)§64GBRAM(NUMAsetup)qOS§RHEL(RedHatLinuxEnterprise)7,3.10.0-327.10.1§16GBswap,swappiness=1forroot,0forregularcgroupsqWorkload§Javaapplica7onqOtherperformancemetrics§Cgroupstat(swap,rss,pagecache),“free”8Pi3all1:Memoryisnotallocated(aswithVM)qMemoryli
7、mitofacgroup§Onlyupperbound§“Useasyougo”modelqMemoryrequestfromcgroups§Freememory§OSreclaiming(pagecacheorswapping)qPerformancewhenwrite-backingdirtycaches§Taking20secondstoobtain16GBofmemory§VariesdependingonthedirtycachesizeandIOcapacity9Pi3all2:Pagecacheispartofmemoryli
8、mitqMemorylimitofacgroup§Anonymousmemory(userspace)§Pagecacheused(Kernelspace)§Needtoes7m