103
How to proceed when 1 000 call agents tell you: ’My Computer is slow‘ Tobias Oetiker <[email protected]> OETIKER+PARTNER AG 22nd Large Installation System Administration Conference

How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

Embed Size (px)

Citation preview

Page 1: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

How to proceed when 1 000 call agents tell you:’My Computer is slow‘

Tobias Oetiker <[email protected]>

OETIKER+PARTNER AG

22nd Large Installation System Administration Conference

Page 2: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

boot up

I users blame IT performanceI stop watch and heisenbugsI sysinternals toolsI autoit and winspyI sorry, no quick fixI but we can monitor it

Page 3: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

boot up

I users blame IT performanceI stop watch and heisenbugsI sysinternals toolsI autoit and winspyI sorry, no quick fixI but we can monitor it

Page 4: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

boot up

I users blame IT performanceI stop watch and heisenbugsI sysinternals toolsI autoit and winspyI sorry, no quick fixI but we can monitor it

Page 5: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

boot up

I users blame IT performanceI stop watch and heisenbugsI sysinternals toolsI autoit and winspyI sorry, no quick fixI but we can monitor it

Page 6: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

boot up

I users blame IT performanceI stop watch and heisenbugsI sysinternals toolsI autoit and winspyI sorry, no quick fixI but we can monitor it

Page 7: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

boot up

I users blame IT performanceI stop watch and heisenbugsI sysinternals toolsI autoit and winspyI sorry, no quick fixI but we can monitor it

Page 8: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

design goals

I passive monitoring from users perspectiveI let users give their inputI minimal impactI simple setup and updateI central data store

Page 9: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

design goals

I passive monitoring from users perspectiveI let users give their inputI minimal impactI simple setup and updateI central data store

Page 10: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

design goals

I passive monitoring from users perspectiveI let users give their inputI minimal impactI simple setup and updateI central data store

Page 11: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

design goals

I passive monitoring from users perspectiveI let users give their inputI minimal impactI simple setup and updateI central data store

Page 12: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

design goals

I passive monitoring from users perspectiveI let users give their inputI minimal impactI simple setup and updateI central data store

Page 13: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

three tools

I CPV monitor: observe the systemI CPV reporter: easy problem reportingI CPV explorer: view the results

Page 14: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

three tools

I CPV monitor: observe the systemI CPV reporter: easy problem reportingI CPV explorer: view the results

Page 15: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

three tools

I CPV monitor: observe the systemI CPV reporter: easy problem reportingI CPV explorer: view the results

Page 16: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

cpv monitor and perl/CPAN

Look it’s perl honey!I AutoItI use Win32::GuiTest;I use Win32::API;I use Win32::OLE;I use Win32::GUI;I use FSA::Rules;I use threads;

Page 17: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

cpv monitor and perl/CPAN

Look it’s perl honey!I AutoItI use Win32::GuiTest;I use Win32::API;I use Win32::OLE;I use Win32::GUI;I use FSA::Rules;I use threads;

Page 18: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

cpv monitor and perl/CPAN

Look it’s perl honey!I AutoItI use Win32::GuiTest;I use Win32::API;I use Win32::OLE;I use Win32::GUI;I use FSA::Rules;I use threads;

Page 19: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

cpv monitor and perl/CPAN

Look it’s perl honey!I AutoItI use Win32::GuiTest;I use Win32::API;I use Win32::OLE;I use Win32::GUI;I use FSA::Rules;I use threads;

Page 20: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

cpv monitor and perl/CPAN

Look it’s perl honey!I AutoItI use Win32::GuiTest;I use Win32::API;I use Win32::OLE;I use Win32::GUI;I use FSA::Rules;I use threads;

Page 21: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

cpv monitor and perl/CPAN

Look it’s perl honey!I AutoItI use Win32::GuiTest;I use Win32::API;I use Win32::OLE;I use Win32::GUI;I use FSA::Rules;I use threads;

Page 22: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

cpv monitor and perl/CPAN

Look it’s perl honey!I AutoItI use Win32::GuiTest;I use Win32::API;I use Win32::OLE;I use Win32::GUI;I use FSA::Rules;I use threads;

Page 23: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

cpv system overview

Page 24: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

cpv monitor structure

Page 25: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

lesson #1: fsm are cool

Page 26: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

lesson #1: seemingly simple

Page 27: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

lesson #1: complexity trap

Page 28: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

cpv monitor

Page 29: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

cpv monitor monitor

Page 30: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

cpv reporter

Page 31: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

cpv explorer

Page 32: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

thinking BIG

wants

I ∼ 1500 clients in the call-centerI dynamic configurationI individual profiles

infrastructure

data store : PostgreSQLconfiguration : Apache, CPVservice.cgi

analysis : Apache, Qooxdoo, CPVjson.cgi, Gnuplot

Page 33: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

thinking BIG

wants

I ∼ 1500 clients in the call-centerI dynamic configurationI individual profiles

infrastructure

data store : PostgreSQLconfiguration : Apache, CPVservice.cgi

analysis : Apache, Qooxdoo, CPVjson.cgi, Gnuplot

Page 34: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

thinking BIG

wants

I ∼ 1500 clients in the call-centerI dynamic configurationI individual profiles

infrastructure

data store : PostgreSQLconfiguration : Apache, CPVservice.cgi

analysis : Apache, Qooxdoo, CPVjson.cgi, Gnuplot

Page 35: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

thinking BIG

wants

I ∼ 1500 clients in the call-centerI dynamic configurationI individual profiles

infrastructure

data store : PostgreSQLconfiguration : Apache, CPVservice.cgi

analysis : Apache, Qooxdoo, CPVjson.cgi, Gnuplot

Page 36: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

thinking BIG

wants

I ∼ 1500 clients in the call-centerI dynamic configurationI individual profiles

infrastructure

data store : PostgreSQLconfiguration : Apache, CPVservice.cgi

analysis : Apache, Qooxdoo, CPVjson.cgi, Gnuplot

Page 37: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

thinking BIG

wants

I ∼ 1500 clients in the call-centerI dynamic configurationI individual profiles

infrastructure

data store : PostgreSQLconfiguration : Apache, CPVservice.cgi

analysis : Apache, Qooxdoo, CPVjson.cgi, Gnuplot

Page 38: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

observation tools

I GetWindowText and friendsI Reading log filesI Windows WMI (Load, Processes)I Active Probing (Ping, HTTP)I HTTPAnalyzer ($$$) for http(s)I Full Custom Probes

Page 39: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

observation tools

I GetWindowText and friendsI Reading log filesI Windows WMI (Load, Processes)I Active Probing (Ping, HTTP)I HTTPAnalyzer ($$$) for http(s)I Full Custom Probes

Page 40: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

observation tools

I GetWindowText and friendsI Reading log filesI Windows WMI (Load, Processes)I Active Probing (Ping, HTTP)I HTTPAnalyzer ($$$) for http(s)I Full Custom Probes

Page 41: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

observation tools

I GetWindowText and friendsI Reading log filesI Windows WMI (Load, Processes)I Active Probing (Ping, HTTP)I HTTPAnalyzer ($$$) for http(s)I Full Custom Probes

Page 42: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

observation tools

I GetWindowText and friendsI Reading log filesI Windows WMI (Load, Processes)I Active Probing (Ping, HTTP)I HTTPAnalyzer ($$$) for http(s)I Full Custom Probes

Page 43: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

observation tools

I GetWindowText and friendsI Reading log filesI Windows WMI (Load, Processes)I Active Probing (Ping, HTTP)I HTTPAnalyzer ($$$) for http(s)I Full Custom Probes

Page 44: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

lesson #2: finding outlook errors

I outlook modal popup send button does not workI GetAsyncKeyState: Although the least significant bit of the

return value indicates whether the key has been pressed since thelast query, due to the pre-emptive multitasking nature ofWindows, another application can call GetAsyncKeyState andreceive the “recently pressed” bit instead of your application.The behavior of the least significant bit of the return valueis retained strictly for compatibility with 16-bit Windowsapplications (which are non-preemptive) and should not berelied upon.

I GetClassName(WindowFromPoint(GetCursorPos()))eq ’MsoCommandBar’;

Page 45: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

lesson #2: finding outlook errors

I outlook modal popup send button does not workI GetAsyncKeyState: Although the least significant bit of the

return value indicates whether the key has been pressed since thelast query, due to the pre-emptive multitasking nature ofWindows, another application can call GetAsyncKeyState andreceive the “recently pressed” bit instead of your application.The behavior of the least significant bit of the return valueis retained strictly for compatibility with 16-bit Windowsapplications (which are non-preemptive) and should not berelied upon.

I GetClassName(WindowFromPoint(GetCursorPos()))eq ’MsoCommandBar’;

Page 46: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

lesson #2: finding outlook errors

I outlook modal popup send button does not workI GetAsyncKeyState: Although the least significant bit of the

return value indicates whether the key has been pressed since thelast query, due to the pre-emptive multitasking nature ofWindows, another application can call GetAsyncKeyState andreceive the “recently pressed” bit instead of your application.The behavior of the least significant bit of the return valueis retained strictly for compatibility with 16-bit Windowsapplications (which are non-preemptive) and should not berelied upon.

I GetClassName(WindowFromPoint(GetCursorPos()))eq ’MsoCommandBar’;

Page 47: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

lesson #3: WMGetText

I GetWindowText or WMGetTextI Application becomes real busy with WMGetTextI stay with GetWindowText

Page 48: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

lesson #3: WMGetText

I GetWindowText or WMGetTextI Application becomes real busy with WMGetTextI stay with GetWindowText

Page 49: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

lesson #3: WMGetText

I GetWindowText or WMGetTextI Application becomes real busy with WMGetTextI stay with GetWindowText

Page 50: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

lesson #4: server issues

I 2008-10-27: 1,459 devices sent 2,417,807 samplesI 4 Core / 32-bit / 4 GB ramI 40 days of data 100,000,000 samplesI index does not fit in ramI too much data for processing

Page 51: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

lesson #4: server issues

I 2008-10-27: 1,459 devices sent 2,417,807 samplesI 4 Core / 32-bit / 4 GB ramI 40 days of data 100,000,000 samplesI index does not fit in ramI too much data for processing

Page 52: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

lesson #4: server issues

I 2008-10-27: 1,459 devices sent 2,417,807 samplesI 4 Core / 32-bit / 4 GB ramI 40 days of data 100,000,000 samplesI index does not fit in ramI too much data for processing

Page 53: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

lesson #4: server issues

I 2008-10-27: 1,459 devices sent 2,417,807 samplesI 4 Core / 32-bit / 4 GB ramI 40 days of data 100,000,000 samplesI index does not fit in ramI too much data for processing

Page 54: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

lesson #4: server issues

I 2008-10-27: 1,459 devices sent 2,417,807 samplesI 4 Core / 32-bit / 4 GB ramI 40 days of data 100,000,000 samplesI index does not fit in ramI too much data for processing

Page 55: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

lesson #5: index compaction

I function based indexI hours since 2007 is good for 7 years with 2 byteI 2 byte for metric idI 2 byte for workstation idI two WHERE conditions

Page 56: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

lesson #5: index compaction

I function based indexI hours since 2007 is good for 7 years with 2 byteI 2 byte for metric idI 2 byte for workstation idI two WHERE conditions

Page 57: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

lesson #5: index compaction

I function based indexI hours since 2007 is good for 7 years with 2 byteI 2 byte for metric idI 2 byte for workstation idI two WHERE conditions

Page 58: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

lesson #5: index compaction

I function based indexI hours since 2007 is good for 7 years with 2 byteI 2 byte for metric idI 2 byte for workstation idI two WHERE conditions

Page 59: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

lesson #5: index compaction

I function based indexI hours since 2007 is good for 7 years with 2 byteI 2 byte for metric idI 2 byte for workstation idI two WHERE conditions

Page 60: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

lesson #6: random data reduction

I too much data for statisticsI how to get 12% of the samples?I add 2 byte random value to each sampleI select all sample with rand < maxrand 12

100

Page 61: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

lesson #6: random data reduction

I too much data for statisticsI how to get 12% of the samples?I add 2 byte random value to each sampleI select all sample with rand < maxrand 12

100

Page 62: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

lesson #6: random data reduction

I too much data for statisticsI how to get 12% of the samples?I add 2 byte random value to each sampleI select all sample with rand < maxrand 12

100

Page 63: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

lesson #6: random data reduction

I too much data for statisticsI how to get 12% of the samples?I add 2 byte random value to each sampleI select all sample with rand < maxrand 12

100

Page 64: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

lesson #7: threaded perl

I works very well on win32I full copy — lots of memoryI save require modules after creating the threadI only thread where really necessary

Page 65: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

lesson #7: threaded perl

I works very well on win32I full copy — lots of memoryI save require modules after creating the threadI only thread where really necessary

Page 66: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

lesson #7: threaded perl

I works very well on win32I full copy — lots of memoryI save require modules after creating the threadI only thread where really necessary

Page 67: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

lesson #7: threaded perl

I works very well on win32I full copy — lots of memoryI save require modules after creating the threadI only thread where really necessary

Page 68: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

lesson #8: measuring boot and logon time

t

GWP boot

WMI SystemUpTime

Services.exestarted

WMI ProcessCreateDate

Logon

WMI LogonSessionStartTime

Explorer.exeor CPV.exe

started

WMI ProcessCreateDate

Load.Gwp.StartUp.Logon2CpvLoad.Gwp.StartUp.Boot2Service

Load.Gwp.StartUp.Logon2Explorer

Page 69: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

lesson #9: detecting crashes

I no wait but process handleI no signals only exit codesI 0xC0000005 - segfaultI 0x00000103 - still runningI TerminateProcess can define exit code

ImplementationI find active windowI attach process handleI poll for exit code

Page 70: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

lesson #9: detecting crashes

I no wait but process handleI no signals only exit codesI 0xC0000005 - segfaultI 0x00000103 - still runningI TerminateProcess can define exit code

ImplementationI find active windowI attach process handleI poll for exit code

Page 71: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

lesson #9: detecting crashes

I no wait but process handleI no signals only exit codesI 0xC0000005 - segfaultI 0x00000103 - still runningI TerminateProcess can define exit code

ImplementationI find active windowI attach process handleI poll for exit code

Page 72: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

lesson #9: detecting crashes

I no wait but process handleI no signals only exit codesI 0xC0000005 - segfaultI 0x00000103 - still runningI TerminateProcess can define exit code

ImplementationI find active windowI attach process handleI poll for exit code

Page 73: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

lesson #9: detecting crashes

I no wait but process handleI no signals only exit codesI 0xC0000005 - segfaultI 0x00000103 - still runningI TerminateProcess can define exit code

ImplementationI find active windowI attach process handleI poll for exit code

Page 74: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

lesson #9: detecting crashes

I no wait but process handleI no signals only exit codesI 0xC0000005 - segfaultI 0x00000103 - still runningI TerminateProcess can define exit code

ImplementationI find active windowI attach process handleI poll for exit code

Page 75: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

lesson #9: detecting crashes

I no wait but process handleI no signals only exit codesI 0xC0000005 - segfaultI 0x00000103 - still runningI TerminateProcess can define exit code

ImplementationI find active windowI attach process handleI poll for exit code

Page 76: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

lesson #9: detecting crashes

I no wait but process handleI no signals only exit codesI 0xC0000005 - segfaultI 0x00000103 - still runningI TerminateProcess can define exit code

ImplementationI find active windowI attach process handleI poll for exit code

Page 77: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

lesson #10: application hangs - symptoms

Page 78: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

lesson #10: application hangs - symptoms

Page 79: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

lesson #10: application hangs - symptoms

Page 80: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

lesson #10: application hangs - symptoms

Page 81: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

lesson #10: application hangs - symptoms

Page 82: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

lesson #10: application hangs - detection

I dead apps don’t process messagesI explorer fakes responsiveness

ImplementationI find active windowI window ping: SendMessage WM_NULLI wait until the window is back

Page 83: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

lesson #10: application hangs - detection

I dead apps don’t process messagesI explorer fakes responsiveness

ImplementationI find active windowI window ping: SendMessage WM_NULLI wait until the window is back

Page 84: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

lesson #10: application hangs - detection

I dead apps don’t process messagesI explorer fakes responsiveness

ImplementationI find active windowI window ping: SendMessage WM_NULLI wait until the window is back

Page 85: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

lesson #10: application hangs - detection

I dead apps don’t process messagesI explorer fakes responsiveness

ImplementationI find active windowI window ping: SendMessage WM_NULLI wait until the window is back

Page 86: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

lesson #10: application hangs - detection

I dead apps don’t process messagesI explorer fakes responsiveness

ImplementationI find active windowI window ping: SendMessage WM_NULLI wait until the window is back

Page 87: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

positive

I CPV reporter - being part of the solutionI CPV explorer - data accessibilityI case: CRM crash detectionI ongoing: webapp monitoringI structured problem solvingI closed feedback loopI SLA benchmarks

Page 88: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

positive

I CPV reporter - being part of the solutionI CPV explorer - data accessibilityI case: CRM crash detectionI ongoing: webapp monitoringI structured problem solvingI closed feedback loopI SLA benchmarks

Page 89: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

positive

I CPV reporter - being part of the solutionI CPV explorer - data accessibilityI case: CRM crash detectionI ongoing: webapp monitoringI structured problem solvingI closed feedback loopI SLA benchmarks

Page 90: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

positive

I CPV reporter - being part of the solutionI CPV explorer - data accessibilityI case: CRM crash detectionI ongoing: webapp monitoringI structured problem solvingI closed feedback loopI SLA benchmarks

Page 91: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

positive

I CPV reporter - being part of the solutionI CPV explorer - data accessibilityI case: CRM crash detectionI ongoing: webapp monitoringI structured problem solvingI closed feedback loopI SLA benchmarks

Page 92: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

positive

I CPV reporter - being part of the solutionI CPV explorer - data accessibilityI case: CRM crash detectionI ongoing: webapp monitoringI structured problem solvingI closed feedback loopI SLA benchmarks

Page 93: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

positive

I CPV reporter - being part of the solutionI CPV explorer - data accessibilityI case: CRM crash detectionI ongoing: webapp monitoringI structured problem solvingI closed feedback loopI SLA benchmarks

Page 94: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

challenge

I CPV drama triangle - victim / rescuerI who is begin observedI mapping the human waysI side effectsI high observability assumptions

Page 95: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

challenge

I CPV drama triangle - victim / rescuerI who is begin observedI mapping the human waysI side effectsI high observability assumptions

Page 96: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

challenge

I CPV drama triangle - victim / rescuerI who is begin observedI mapping the human waysI side effectsI high observability assumptions

Page 97: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

challenge

I CPV drama triangle - victim / rescuerI who is begin observedI mapping the human waysI side effectsI high observability assumptions

Page 98: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

challenge

I CPV drama triangle - victim / rescuerI who is begin observedI mapping the human waysI side effectsI high observability assumptions

Page 99: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

future work

I DLL injectionI webapps, webapps, webappsI dealing with the data

Page 100: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

future work

I DLL injectionI webapps, webapps, webappsI dealing with the data

Page 101: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

future work

I DLL injectionI webapps, webapps, webappsI dealing with the data

Page 102: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

Questions

Page 103: How to proceed when 1000 call agents tell you: 'My ... · PDF filecpvmonitorandperl/CPAN Lookit’sperlhoney! I AutoIt I use Win32::GuiTest; I use Win32::API; I use Win32::OLE; I use

Tobi Oetiker <[email protected]>OETIKER+PARTNER AG

Commercial Contact:Claus Henning Simon <[email protected]>Swisscom IT Services AG