Saturday, March 1, 2008

Linux on Z

For the last two years, the majority of my work had been focused on helping customers deploy linux on system z. System z, or the mainframe, has had virtualization capabilities since the 60's. So it's a natural leader and great platform for virtualization. I'm often asked how to tune DB2 on Linux for System z. Much of the tuning techniques used in DB2 LUW apply across all platforms, so many of the same techniques apply. I've documented in this post, the top 5 tips to look at in a Linux on z environment. Of course, these are only five. There are other considerations for tuning. But, rather than make this blog and entire paper on tuning. I've picked out 5 to look for. Thanks for reading.

1) The number one issue when running under z/VM is that customers over configure linux memory for the guest. Steven Wehr has put together some nice tips in this paper. Although the topic discusses Websphere, the concepts again apply for DB2.

2) Disable the linux on demand timer .
All distrubtions for Linux on z have the jiffy timer patch, ensure that it this is enabled by verifying kernel.hz_timer.

3) Check on and modify the linux i/o scheduler. There are several options: as,noop,cfq and deadline. The as (anticipatory scheduler) is not a good option.

4) Use DIO and AIO .

– Configure maximum number of channel paths
– Spread disks over different ranks within a storage server
– Use logical volumes with striping
– Consider exploiting PAV

5) Of course, this is somewhat application dependent - but generally it's best to turn off read ahead . On LVM disable this with lvchange, on block devices set the value with the blockdev command. At the DB2 tablespace level, prefetchsize to zero.

For more information on tuning databases for Linux on System z, check out this website: