HP解决方案中心性能调优方法论.ppt
《HP解决方案中心性能调优方法论.ppt》由会员分享,可在线阅读,更多相关《HP解决方案中心性能调优方法论.ppt(48页珍藏版)》请在三一办公上搜索。
1、何建波解决方案拓展部中国惠普有限公司Oct 2004,Performance Tuning MethodologyTechnology&Best practise,本文中的大部分内容是个人观点经验教训,仅供参考,2023/11/7,2,Concept,What is performance tuning?It is experts responsibilitiesMeans working day and nightMuch efforts,little gains.性能优化是一个充满激情的工作,是一种爱的行为,真诚地帮助别人,.运用我们所知道的,所感觉到的,或者曾经承受过地来减轻他人的负担,
2、2023/11/7,3,Concept,Why performance tuning/Testing?改善“客户体验”,提供一个可预期的系统降低 I.T.成本,提供一个经济有效的系统Number of CPU Storage capacity(ZheJiang Public security-23%savings)不仅检验厂商的产品,而且考验people根本原因:Modern computer/application is not fast/intelligence enough,through it,provide a intelligence system,2023/11/7,4,Conc
3、ept,When tune performance?新开发的系统&正在运行的生产系统Performance tuning?En It is vendors responsibilitiesBegins at system architect stage,follow on outline design,coding,modification and implementation through all apps life cycle.Include App architect,EJB design,table/index designBut,how to tune the system per
4、formance?,2023/11/7,5,Methodology-How,0.与客户建立信任关系以询问开始 Ask questions first理解应用的体系结构(搭建与应用特性匹配的系统)使用记录工具确定“基准线”查看/检查系统隔离问题/简化问题每次改变一个参数(通常不可能)Know when to stop tuning,2023/11/7,6,1.Ask questions first,磨刀不误砍材功,理解系统性能问题,了解症状明确目标了解历史,不知从哪里来,就不知道要到哪里去设计问题,询问技巧-找出在什么情况下发生了什么变化,产生了什么现象SMIC file number incr
5、ease to 3.5 Millions,cpu sys is too highE-BUPT SMS testing,jvm version,2023/11/7,7,系统架构(两层,多层?中间件?)逐层细化了解整个应用的体系架构,关键问题要追溯到函数调用一级业务/数据处理流程多少个(并发)用户(Keep connect v.s.Active)系统/用户范围内的进程,线程数量、堆栈的需求虚拟和物理内存需求IPC(共享内存,信号灯,消息队列)打开的/文件Opened and mapped file requirements.How much I/O?访问模式(顺序,随机?持续稳定的还是突发的)?W
6、hat kind of networking resources are needed?(how many sockets,),2.Understand application architecture,2023/11/7,8,2.Understand application architecture,flat files,process 1,process 2,process 3,memory-resident database,directory,signal,signal,directory,Oracle shadow,pipe,database,shared memory/semaph
7、ore sets,sigtimedwait(),sigtimedwait(),semop(),semop(),semop(),semop(),2023/11/7,9,3.使用监控工具,使用你适合/喜欢的工具记录系统的性能数据measureware/sar/glance/OV performance mgt掌握系统的历史性能数据可以帮助你解决问题,优化系统进行对比正常情况/出现问题的对比优化步骤之间的对比易于roll-back进行容量规划通过检查系统的资源利用率和对应业务量的增减关系,2023/11/7,10,4.看什么?,第一印象系统资源利用率以及队列长度细心观察global wait sta
8、tes and global system calls仔细研究process system calls and process waits Is the process running?If not,what is it waiting on?If it is,where is it spending it time?Whatever it is doing,is it suppose to be doing it this way?,2023/11/7,11,5.确定问题域Where is the problem?,硬件?操作系统?数据库?中间件?应用?隔离问题上海浦东发展银行GuoXin
9、Lucent 电信网管软件ICBC 信贷台帐系统备份24小时哈尔冰商业银行轧张3小时简化问题,2023/11/7,12,6.对症下药cure it,方法直接定位法排除法一次改变一个地方观察结果时间安排Repeat,2023/11/7,13,6.何时结束,满足业务的需求,而不是系统资源利用率吞吐量响应时间系统中最昂贵的资源得以充分的利用CPUMEMI/O理解80/20原则,2023/11/7,14,Performance tuning-technology,Four layerApplicationMiddlewareDatabaseO.S.H.W.ResourcesCPUMEMStorageN
10、etwork,2023/11/7,15,Tools工欲善其事,必先利其器,2023/11/7,HP World 2003 Solutions and Technology Conference&Expo,16,Tools for Application profiling,Application layer(too idle,too busy)太闲进程阻塞,系统资源利用率低(特别是CPU),哪里被阻塞?所需资源被谁占用?为何它不能及时释放?回答:where is that process spending its time?What kernel code is it executing?Wh
11、at user space code is it executing?Wait for what?Who had the resouce I needed?ICBC credit system,太忙资源利用率太高,进程的时间花在什么地方了?Where is the thread/process spending its time?Kernel code active or sleeping?User space active or sleeping?Neusoft Insurance applicationWhatever its doing,is it suppose to be doing
12、 it this way?Between the application developers,the customer and HP,somebody had better know.我可以改用其它资源吗?ToolsTrace in application source code,not in H.W.,O.S.,Middleware,DB levelFor C,tusc,prospect,caliperFor Java,HPJconfig,HPJmeter,HPJtuneDo not work for a applications bug!solutionsapplication ites
13、elf,chatr,psrset,mpctl,wlm,prm,ICBC ATM/SMICNeusoft Insurance Application-sorting,2023/11/7,HP World 2003 Solutions and Technology Conference&Expo,17,Prospect,Key to performance is“how does my application spend its time?”Prospect provides:System-wide summary,yawn,but alsoPer-process and per-thread d
14、ata:Execution/blocked进程在哪里阻塞,阻塞多长时间Userspace(application and library)and kernel profileEven instruction-level profiling!Provides per-CPU informationUser,Idle,SystemInterrupt,TrapContext switches.etc缺点:No use for IO bottlenecksIntimidating output,2023/11/7,18,Caliper,General purpose performance analy
15、sis tool for Itanium based systemsWorks directly on the binary as-isFeaturesVarious metrics measurement Eg:fprof,dtlb_miss,itlb_miss,dcache_miss,icache_miss,branch_prediction,func_coveretcPerformance data and source correlationEasy inclusion/exclusion of specific load modulesPer thread/aggregated th
16、read reportMulti-process selection capabilityText/HTML output,2023/11/7,19,Caliper-Metrics,Various metrics Measure Configuration File-hot spots fprof,cgprof call graph cgprof cache/TLB behavior dcache_miss,icache_miss,dtlb_miss,itlb_miss branch prediction branch_prediction call counts func_count,cgp
17、rof function coverage func_cover CPU events total_cpu compiler feedback pbo,2023/11/7,20,Tusc,Trace Unix System Calls for a specified processRun command under tusc,or attach to PIDShowsSystem calls,input parameters and their return valuesSystem call durationThread id of the thread making system call
18、sSignal information.etcUsage:tusc-T-f-e-l-o Useful options:-cSummary of syscall counts,errors and CPU time-cccCPU time for every syscall-T%TPrint a timestamp before every trace-rallDisplay read buffer for all reads-wallDisplay write buffer for all writes-fFollow fork()s,2023/11/7,Backup slide,21,Gla
19、ncePlus Options(backup slide),GlancePlus Commands Menuh-Online Help q-exit(or e)A-Application Listg-Process List d-Disk Report P-PRM Group Lista-CPU By Processor i-IO By File System Y-Global System Callsc-CPU Report u-IO By Disk F-Process Open Filesm-Memory Report v-IO By Logical Volume M-Process Me
20、mory Regionst-System Tables N-NFS Global Activity R-Process Resourcesw-Swap Space n-NFS By System W-Process Wait StatesB-Global Waits l-Network By Interface L-Process System CallsZ-Global Threads T-Trans Tracker y-Renice ProcessG-Process Threads H-Alarm History s-Select ProcessI-Thread Resource J-Th
21、read WaitS-Select Disk/NFS/Appl/Trans/Thread,2023/11/7,22,Performance tuning-Middleware,Transaction Process monitor tuxedoMSSQ(seperate reply and send queue)MSMQApplication ServerCore serverWeb ApplicationsJDBCEJB,2023/11/7,23,Core Server,JVM heap size 32bit/64bit gcThread-countBest tuned empiricall
22、y tune for high CPU utilization and throughputDo not overdo!Effect may be constrained by pool sizes(SLSB,MDB,connection pool)Application/Module Specific Execute QueuesUseful in preventing deadlocksUseful in handling request burst/surges,2023/11/7,24,Core Server,Chunk tuning:Required only for large r
- 配套讲稿:
如PPT文件的首页显示word图标,表示该PPT已包含配套word讲稿。双击word图标可打开word文档。
- 特殊限制:
部分文档作品中含有的国旗、国徽等图片,仅作为作品整体效果示例展示,禁止商用。设计者仅对作品中独创性部分享有著作权。
- 关 键 词:
- HP 解决方案 中心 性能 方法论
链接地址:https://www.31ppt.com/p-6507495.html