Measuring Linux Latency With LatencyTOP On Ubuntu 8.10 And Debian Lenny
Measuring Linux Latency With LatencyTOP On Ubuntu 8.10 And Debian LennyVersion 1.0 LatencyTOP is a tool that lets you identify where in the system latency is happening, and what kind of operation/action is causing the latency to happen. This article shows how you can use LatencyTOP on Ubuntu 8.10 and Debian Lenny. I do not issue any guarantee that this will work for you!
1 Ubuntu 8.101.1 Preliminary NoteLatencyTOP needs a kernel that was built with CONFIG_HAVE_LATENCYTOP_SUPPORT=y and CONFIG_LATENCYTOP=y which is the case for the standard Ubuntu 8.10 kernels (whereas on Debian Lenny, for example, only CONFIG_HAVE_LATENCYTOP_SUPPORT=y is set which means you'd have to rebuild the kernel to make LatencyTOP work on Debian Lenny). grep -i latencytop /boot/config-`uname -r` falko@falko-desktop:~$ grep -i latencytop /boot/config-`uname -r`
1.2 Installing LatencyTOPLatencyTOP is available as an Ubuntu package, so we can install it as follows: sudo apt-get install latencytop
1.3 UsageUsage is similar to the top program, you just type sudo latencytop and you will get a table of actions that cause latency: Type q to leave LatencyTOP. To learn more about LatencyTOP and additional options, take a look at its man page: man latencytop
2 Debian Lenny2.1 Preliminary NoteLatencyTOP needs a kernel that was built with CONFIG_HAVE_LATENCYTOP_SUPPORT=y and CONFIG_LATENCYTOP=y which is not the case for the standard Debian Lenny kernels. On Debian Lenny only CONFIG_HAVE_LATENCYTOP_SUPPORT=y is set which means we have to rebuild the kernel (see chapter 2.3) to make LatencyTOP work on Debian Lenny. grep -i latencytop /boot/config-`uname -r` server1:~# grep -i latencytop /boot/config-`uname -r`
2.2 Installing LatencyTOPLatencyTOP is available as a Debian Lenny package, so we can install it as follows: apt-get install latencytop
2.3 Rebuilding The KernelIf you run LatencyTOP now, you will get an error message like this one: server1:~# latencytop This means we must rebuild the kernel with CONFIG_LATENCYTOP=y. We can do this as follows: apt-get build-dep linux-image-`uname -r` apt-get install kernel-package libncurses5-dev fakeroot wget bzip2 build-essential cd /usr/src/ tar xjvf linux-source-2.6.26.tar.bz2 Next we run make menuconfig where you can change the kernel configuration if necessary (but we've added CONFIG_LATENCYTOP=y to the configuration already in the previous step, so if the rest of the kernel configuration is ok for you, you can exit make menuconfig straight away without changing anything). Now we build the new kernel: make-kpkg clean This can take some time. Afterwards, we can find the new kernel in /usr/src... cd /usr/src server1:/usr/src# ls -l ... and install it as follows: dpkg -i linux-headers-2.6.26-custom_2.6.26-custom-10.00.Custom_i386.deb linux-image-2.6.26-custom_2.6.26-custom-10.00.Custom_i386.deb Open /boot/grub/menu.lst and make sure that the new kernel (2.6.26-custom) is the default one: vi /boot/grub/menu.lst
Then reboot the system: reboot Afterwards, uname -r should show the new kernel: uname -r server1:~# uname -r
2.4 UsageUsage is similar to the top program, you just type latencytop and you will get a table of actions that cause latency. Type q to leave LatenyTOP. To learn more about LatencyTOP and additional options, take a look at its man page: man latencytop
3 Links
|




Recent comments
1 day 3 hours ago
1 day 8 hours ago
1 day 9 hours ago
1 day 10 hours ago
1 day 12 hours ago
1 day 16 hours ago
1 day 17 hours ago
1 day 19 hours ago
2 days 9 hours ago
2 days 10 hours ago