About Me

I'm a ambitious Software Engineer form the Netherlands working at Kingsquare Information Services. I graduated for a masters degree in Software Engineering in August 2011. This site is not really a public thing, but since you are here take a peek at my CV, code, and blog like ramblings.

Contact: info@demadred.nl

Blog like ramblings

EC2 instance inequality

16-12-2011 14:43

Recently I came across a performance problem with a LAMP stack running on Amazon EC2. The stack consists of about a dozen machines of which the application servers are in a scalable array.

The problem presenting itself was that sometimes one of the servers booting in the scalable array suffered a substantial higher load than its identical peers. Such behaviour could have many different causes. Perhaps It could be that the instance could share the host system with instances which were under heavy utilisation and in turn would steal more processor time. This does however seem unlikely and would be hard to proof. The cause could also lie in the place the instance is located within an AZ. Combined with some unfortunate routing and an application which relies on other services also within Amazon it could be imaginable that this would cause some problems.

After inspecting many of these cases I came up with a different cause for the performance problems. Its hard to imagine that all the EC2 host machines have an identical hardware configuration. As described here. for small instances there is about a 10% chance this will be hosted on a machine with an AMD Dual-Core Opteron 2218 HE Processor. If in our case an application server would run on an instance with such a core the load would be high relative to its peers.

Regretably I have no accurate numbers to substantiate my claims. These might follow when I find the time to do some decent research. In the mean time there is this incredible benchmark which is very thorough but doesn't touch this particular issue. In the mean time I provide a table with the different encountered 'cat /proc/cpuinfo' results for small EC2 instances in AZ EU-west-a.

vendor_id GenuineIntel GenuineIntel GenuineIntel AuthenticAMD
cpu family 6 6 6 15
model 26 44 23 65
model name Intel(R) Xeon(R) CPU E5507 @ 2.27GHz Intel(R) Xeon(R) CPU E5645 @ 2.40GHz Intel(R) Xeon(R) CPU E5430 @ 2.66GHz Dual-Core AMD Opteron(tm) Processor 2218 HE
stepping 5 2 10 3
cpu MHz 2266.746 2000.070 2659.998 2599.998
cache size 4096 KB 12288 KB 6144 KB 1024 KB
flags fpu de tsc msr pae cx8 apic sep cmov pat clflush acpi mmx fxsr sse sse2 ss ht nx constant_tsc up tsc_reliable nonstop_tsc pni ssse3 sse4_1 sse4_2 popcnt hypervisor fpu de tsc msr pae cx8 apic sep cmov pat clflush acpi mmx fxsr sse sse2 ss ht nx constant_tsc up tsc_reliable nonstop_tsc pni pclmulqdq ssse3 sse4_1 sse4_2 popcnt aes hypervisor fpu tsc msr pae mce cx8 apic mca cmov pat pse36 clflush dts ac pi mmx fxsr sse sse2 ss ht tm pbe nx lm constant_tsc up arch_perfmon pebs bts pni dtes64 monitor ds_cpl vmx est tm2 ssse3 cx16 xtpr pdcm dca sse4_1 xsave lahf_lm tpr_shadow vnmi flexpriority fpu tsc msr pae mce cx8 apic mca cmov pat pse36 clflush mmx fx sr sse sse2 ht nx mmxext fxsr_opt rdtscp lm 3dnowext 3dnow up pni cx16 lahf_lm cmp_legacy svm extapic cr8_legacy
bogomips 4542.86 4002.51 5322.16 5201.77
power management ts fid vid ttp tm stc

Why blog like ramblings

11-12-2011 17:35

I have too much distractions (or too little disciplin) too keep up with a serious blog. I don't feel narcisistic enough to try to big on twitter and I don't need an audience... Almost orthogonal to that I actually do need a place to write about interesting stuff I come across. The subjects which capture my intrest are very diverse and are hard to publish in a single format. I don't want to be restricted by the media I publish on.