{"id":2347,"date":"2016-08-03T11:39:18","date_gmt":"2016-08-03T15:39:18","guid":{"rendered":"https:\/\/www.globo.tech\/learning-center\/?p=2347"},"modified":"2017-12-12T15:39:09","modified_gmt":"2017-12-12T20:39:09","slug":"install-iotop-ubuntu-14","status":"publish","type":"post","link":"https:\/\/www.globo.tech\/learning-center\/install-iotop-ubuntu-14\/","title":{"rendered":"How to Install and Use Iotop on Ubuntu 14"},"content":{"rendered":"<h1>How to Install and Use Iotop on Ubuntu 14<\/h1>\n<p>Iotop is a tool that complements top. Whereas top monitors CPU load, iotop monitors input and output (I\/O). Iotop provides information regarding the total disk read and write bandwidth in use, the read and write bandwidth consumed by each process and the swap activity per process. By default, it presents active processes in an ordered list by I\/O usage. Alternatively, iotop can track accumulated read, write, and swap bandwidth used. In either mode, it can help identify processes that are not stressing the CPU but are nonetheless creating a performance bottleneck by driving a high level of I\/O activity. The present tutorial describes how to install and use iotop on an Ubuntu 14.04 server.<\/p>\n<h2>Getting Started<\/h2>\n<p>To complete this guide, you will need the following:<br \/>\n\u2022 1 Node (<a href=\"https:\/\/www.globo.tech\/cloud-server-pricing\" target=\"_blank\">Cloud Server<\/a> or <a href=\"http:\/\/www.globo.tech\/dedicated-server-hosting\" target=\"_blank\">Dedicated Server<\/a>) running Ubuntu 14. <\/p>\n<h2>Install<\/h2>\n<p>In order to install iotop from the official repositories, you must run the following command:<\/p>\n<p><code>apt-get update && apt-get install iotop<\/code><\/p>\n<p>Now that the installation is finished, we can now explore Iotop features. <\/p>\n<h2>Explore the Features of Iotop<\/h2>\n<p>A few simple commands are all that you need to learn to take advantage of the full range of capabilities built into iotop.<br \/>\nOur first test will be to run it without any options turned on.<\/p>\n<p><code>iotop<\/code><\/p>\n<p>You will see a list of processes running on your server. Unless you were deliberately running a process that demands a lot of I\/O bandwidth, your output probably indicates the server&#8217;s hard drive and swap space was largely idle, much like the example here:<\/p>\n<p><a href=\"https:\/\/www.globo.tech\/learning-center\/wp-content\/uploads\/2016\/08\/iotop1.png\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.globo.tech\/learning-center\/wp-content\/uploads\/2016\/08\/iotop1.png\" alt=\"iotop\" width=\"1061\" height=\"543\" class=\"aligncenter size-full wp-image-2348\" \/><\/a><\/p>\n<p>Any process that is consuming a lot of I\/O resources immediately gets placed at the top of the list. In this mode, iotop provides a continuous update of the instantaneous I\/O bandwidth consumed by each process. <\/p>\n<p>The SwapIn column in iotop provides data regarding the swap activity per process. Along with the read and write columns, iotop thereby provides a full accounting of all I\/O activity on the server each time it samples the system.<\/p>\n<p>The command options provide the means for more precisely controlling the information it collects and displays. For instance, if you are interested in checking the accumulated disk usage data by process and thread since iotop was initiated, this command will get you what you want:<\/p>\n<p><code>root@iotop:~# iotop -btoqq --iter=1<\/code><br \/>\n<code class=\"gris\">17:53:54 Total DISK READ :       0.00 B\/s | Total DISK WRITE :       0.00 B\/s<br \/>\n17:53:54 Actual DISK READ:       0.00 B\/s | Actual DISK WRITE:       0.00 B\/s<\/code><\/p>\n<p>This mode allows you to easily compare the IO% value of each of the most demanding active processes and threads with the total amount of read and write activity on the disk to determine the I\/O bandwidth each process is consuming over whatever time interval you choose to sample. The larger the number of iterations you set the longer the time interval the final output will represent. This command also tells iotop to ignore applications that are not consuming significant I\/O resources.<\/p>\n<p>If an application&#8217;s I\/O demands increase above the minimum threshold during the time iotop is sampling you will see its process in the output.<\/p>\n<p><code>root@iotop:~# iotop -btoqq --iter=5<\/code><br \/>\n<code class=\"gris\">17:55:00 Total DISK READ :       0.00 B\/s | Total DISK WRITE :       0.00 B\/s<br \/>\n17:55:00 Actual DISK READ:       0.00 B\/s | Actual DISK WRITE:       0.00 B\/s<br \/>\n17:55:01 Total DISK READ :       0.00 B\/s | Total DISK WRITE :       0.00 B\/s<br \/>\n17:55:01 Actual DISK READ:       0.00 B\/s | Actual DISK WRITE:       0.00 B\/s<br \/>\n17:55:02 Total DISK READ :       0.00 B\/s | Total DISK WRITE :      98.57 K\/s<br \/>\n17:55:02 Actual DISK READ:       0.00 B\/s | Actual DISK WRITE:     220.79 K\/s<br \/>\n17:55:02   142 be\/3 root        0.00 B\/s   55.20 K\/s  0.00 %  0.20 % [jbd2\/sda3-8]<br \/>\n17:55:02 21522 be\/4 postfix     0.00 B\/s    3.94 K\/s  0.00 %  0.06 % cleanup -z -t unix -u -c<br \/>\n17:55:02 23849 be\/4 postfix     0.00 B\/s    0.00 B\/s  0.00 %  0.00 % local -t unix<br \/>\n17:55:02 31183 be\/4 mysql       0.00 B\/s   11.83 K\/s  0.00 %  0.00 % mysqld<br \/>\n17:55:02   470 be\/4 syslog      0.00 B\/s   19.71 K\/s  0.00 %  0.00 % rsyslogd [rs:main Q:Reg]<br \/>\n17:55:03 Total DISK READ :       0.00 B\/s | Total DISK WRITE :     772.34 K\/s<br \/>\n17:55:03 Actual DISK READ:       0.00 B\/s | Actual DISK WRITE:     985.80 K\/s<br \/>\n17:55:03 12082 be\/4 nagios      0.00 B\/s  461.85 K\/s  0.00 %  0.20 % nagios -d \/usr\/local\/nagios\/etc\/nagios.cfg<br \/>\n17:55:03   142 be\/3 root        0.00 B\/s  252.27 K\/s  0.00 %  0.05 % [jbd2\/sda3-8]<br \/>\n17:55:03 31215 be\/4 mysql       0.00 B\/s   58.22 K\/s  0.00 %  0.00 % mysqld<\/code><\/p>\n<p>The following command is built to sample 5 iterations of the iotop instance and to identify the applications demanding the most I\/O resources during the measured interval:<\/p>\n<p><code>root@iotop:~# iotop -botqqq --iter=5<\/code><br \/>\n<code class=\"gris\">17:59:50 24333 be\/4 root        0.00 B\/s    0.00 B\/s  0.00 %  0.48 % [kworker\/u4:2]<br \/>\n17:59:51 12082 be\/4 nagios      0.00 B\/s    3.91 K\/s  0.00 %  0.00 % nagios -d \/usr\/local\/nagios\/etc\/nagios.cfg<br \/>\n17:59:52   142 be\/3 root        0.00 B\/s   66.50 K\/s  0.00 %  0.31 % [jbd2\/sda3-8]<br \/>\n17:59:52 12082 be\/4 nagios      0.00 B\/s  465.48 K\/s  0.00 %  0.16 % nagios -d \/usr\/local\/nagios\/etc\/nagios.cfg<br \/>\n17:59:52  5604 be\/4 postfix     0.00 B\/s    3.91 K\/s  0.00 %  0.00 % tlsmgr -l -t unix -u -c<\/code><\/p>\n<p>The above commands provide the means to visually monitor I\/O bandwidth usage on the server. Iotop can also be used to monitor and log disk usage. Thus, it can track which processes are consuming disk resources at all times.<\/p>\n<p>To create a log file that retains a complete record of I\/O usage on your server you will need to create a crontab job:<\/p>\n<p><code>crontab -e<\/code><\/p>\n<p>Once you are in the crontab configuration, add the lines below. The specific options you use will depend on your needs. In our example, we have configured the job so that the log will only include data from applications that are using significant I\/O resources.<\/p>\n<p><code class=\"gris\">* * * * * root iotop -botqqq --iter=3 >> \/var\/log\/iotop<\/code><\/p>\n<p>Once you have selected the options you want, save the crontab file. Wait a short time and then check the logs in \/var\/log\/iotop to make sure the crontab job is working. <\/p>\n<p>You will be able to identify the applications that consume the most I\/O bandwidth over whatever time period you wish by using different parsing techniques and fine tuning the crontab job. <\/p>\n<h2>Conclusion<\/h2>\n<p>You have now installed iotop on your Ubuntu 14.04 server. Just as top helps to track down memory leaks, now this new tool will help to track down unwanted or unexpected I\/O activity.  If this guide was helpful to you, kindly share it with others who may also be interested. <\/p>\n<!-- AddThis Advanced Settings generic via filter on the_content --><!-- AddThis Share Buttons generic via filter on the_content -->","protected":false},"excerpt":{"rendered":"<p>How to Install and Use Iotop on Ubuntu 14 Iotop is a tool that complements top. Whereas top monitors CPU load, iotop monitors input and output (I\/O). Iotop provides information regarding the total disk read and write bandwidth in use, the read and write bandwidth consumed by each process and the swap activity per process.<!-- AddThis Advanced Settings generic via filter on get_the_excerpt --><!-- AddThis Share Buttons generic via filter on get_the_excerpt --><\/p>\n","protected":false},"author":3,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[72],"tags":[],"class_list":["post-2347","post","type-post","status-publish","format-standard","hentry","category-monitoring","operating_system-ubuntu-14-04"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v26.0 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>How to Install and Use Iotop on Ubuntu 14 - Globo.Tech<\/title>\n<meta name=\"description\" content=\"This tutorial will show you how to install and use Iotop on your Ubuntu 14 server. Read now &amp; Start monitoring your server&#039;s resources.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.globo.tech\/learning-center\/install-iotop-ubuntu-14\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"How to Install and Use Iotop on Ubuntu 14 - Globo.Tech\" \/>\n<meta property=\"og:description\" content=\"This tutorial will show you how to install and use Iotop on your Ubuntu 14 server. Read now &amp; Start monitoring your server&#039;s resources.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.globo.tech\/learning-center\/install-iotop-ubuntu-14\/\" \/>\n<meta property=\"og:site_name\" content=\"Globo.Tech\" \/>\n<meta property=\"article:published_time\" content=\"2016-08-03T15:39:18+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2017-12-12T20:39:09+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/www.globo.tech\/learning-center\/wp-content\/uploads\/2016\/08\/iotop1.png\" \/>\n<meta name=\"author\" content=\"GloboTech Communications\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"GloboTech Communications\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"5 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.globo.tech\/learning-center\/install-iotop-ubuntu-14\/\",\"url\":\"https:\/\/www.globo.tech\/learning-center\/install-iotop-ubuntu-14\/\",\"name\":\"How to Install and Use Iotop on Ubuntu 14 - Globo.Tech\",\"isPartOf\":{\"@id\":\"https:\/\/www.globo.tech\/learning-center\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/www.globo.tech\/learning-center\/install-iotop-ubuntu-14\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/www.globo.tech\/learning-center\/install-iotop-ubuntu-14\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/www.globo.tech\/learning-center\/wp-content\/uploads\/2016\/08\/iotop1.png\",\"datePublished\":\"2016-08-03T15:39:18+00:00\",\"dateModified\":\"2017-12-12T20:39:09+00:00\",\"author\":{\"@id\":\"https:\/\/www.globo.tech\/learning-center\/#\/schema\/person\/e17784b37f4a4f49b7bc611847912e87\"},\"description\":\"This tutorial will show you how to install and use Iotop on your Ubuntu 14 server. Read now & Start monitoring your server's resources.\",\"breadcrumb\":{\"@id\":\"https:\/\/www.globo.tech\/learning-center\/install-iotop-ubuntu-14\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.globo.tech\/learning-center\/install-iotop-ubuntu-14\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/www.globo.tech\/learning-center\/install-iotop-ubuntu-14\/#primaryimage\",\"url\":\"https:\/\/www.globo.tech\/learning-center\/wp-content\/uploads\/2016\/08\/iotop1.png\",\"contentUrl\":\"https:\/\/www.globo.tech\/learning-center\/wp-content\/uploads\/2016\/08\/iotop1.png\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.globo.tech\/learning-center\/install-iotop-ubuntu-14\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/www.globo.tech\/learning-center\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"How to Install and Use Iotop on Ubuntu 14\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.globo.tech\/learning-center\/#website\",\"url\":\"https:\/\/www.globo.tech\/learning-center\/\",\"name\":\"Globo.Tech\",\"description\":\"Welcome to the Official Globo.Tech Learning Center\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/www.globo.tech\/learning-center\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Person\",\"@id\":\"https:\/\/www.globo.tech\/learning-center\/#\/schema\/person\/e17784b37f4a4f49b7bc611847912e87\",\"name\":\"GloboTech Communications\",\"sameAs\":[\"http:\/\/www.gtcomm.net\"]}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"How to Install and Use Iotop on Ubuntu 14 - Globo.Tech","description":"This tutorial will show you how to install and use Iotop on your Ubuntu 14 server. Read now & Start monitoring your server's resources.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.globo.tech\/learning-center\/install-iotop-ubuntu-14\/","og_locale":"en_US","og_type":"article","og_title":"How to Install and Use Iotop on Ubuntu 14 - Globo.Tech","og_description":"This tutorial will show you how to install and use Iotop on your Ubuntu 14 server. Read now & Start monitoring your server's resources.","og_url":"https:\/\/www.globo.tech\/learning-center\/install-iotop-ubuntu-14\/","og_site_name":"Globo.Tech","article_published_time":"2016-08-03T15:39:18+00:00","article_modified_time":"2017-12-12T20:39:09+00:00","og_image":[{"url":"https:\/\/www.globo.tech\/learning-center\/wp-content\/uploads\/2016\/08\/iotop1.png","type":"","width":"","height":""}],"author":"GloboTech Communications","twitter_misc":{"Written by":"GloboTech Communications","Est. reading time":"5 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/www.globo.tech\/learning-center\/install-iotop-ubuntu-14\/","url":"https:\/\/www.globo.tech\/learning-center\/install-iotop-ubuntu-14\/","name":"How to Install and Use Iotop on Ubuntu 14 - Globo.Tech","isPartOf":{"@id":"https:\/\/www.globo.tech\/learning-center\/#website"},"primaryImageOfPage":{"@id":"https:\/\/www.globo.tech\/learning-center\/install-iotop-ubuntu-14\/#primaryimage"},"image":{"@id":"https:\/\/www.globo.tech\/learning-center\/install-iotop-ubuntu-14\/#primaryimage"},"thumbnailUrl":"https:\/\/www.globo.tech\/learning-center\/wp-content\/uploads\/2016\/08\/iotop1.png","datePublished":"2016-08-03T15:39:18+00:00","dateModified":"2017-12-12T20:39:09+00:00","author":{"@id":"https:\/\/www.globo.tech\/learning-center\/#\/schema\/person\/e17784b37f4a4f49b7bc611847912e87"},"description":"This tutorial will show you how to install and use Iotop on your Ubuntu 14 server. Read now & Start monitoring your server's resources.","breadcrumb":{"@id":"https:\/\/www.globo.tech\/learning-center\/install-iotop-ubuntu-14\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.globo.tech\/learning-center\/install-iotop-ubuntu-14\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.globo.tech\/learning-center\/install-iotop-ubuntu-14\/#primaryimage","url":"https:\/\/www.globo.tech\/learning-center\/wp-content\/uploads\/2016\/08\/iotop1.png","contentUrl":"https:\/\/www.globo.tech\/learning-center\/wp-content\/uploads\/2016\/08\/iotop1.png"},{"@type":"BreadcrumbList","@id":"https:\/\/www.globo.tech\/learning-center\/install-iotop-ubuntu-14\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.globo.tech\/learning-center\/"},{"@type":"ListItem","position":2,"name":"How to Install and Use Iotop on Ubuntu 14"}]},{"@type":"WebSite","@id":"https:\/\/www.globo.tech\/learning-center\/#website","url":"https:\/\/www.globo.tech\/learning-center\/","name":"Globo.Tech","description":"Welcome to the Official Globo.Tech Learning Center","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.globo.tech\/learning-center\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Person","@id":"https:\/\/www.globo.tech\/learning-center\/#\/schema\/person\/e17784b37f4a4f49b7bc611847912e87","name":"GloboTech Communications","sameAs":["http:\/\/www.gtcomm.net"]}]}},"_links":{"self":[{"href":"https:\/\/www.globo.tech\/learning-center\/wp-json\/wp\/v2\/posts\/2347","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.globo.tech\/learning-center\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.globo.tech\/learning-center\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.globo.tech\/learning-center\/wp-json\/wp\/v2\/users\/3"}],"replies":[{"embeddable":true,"href":"https:\/\/www.globo.tech\/learning-center\/wp-json\/wp\/v2\/comments?post=2347"}],"version-history":[{"count":5,"href":"https:\/\/www.globo.tech\/learning-center\/wp-json\/wp\/v2\/posts\/2347\/revisions"}],"predecessor-version":[{"id":3976,"href":"https:\/\/www.globo.tech\/learning-center\/wp-json\/wp\/v2\/posts\/2347\/revisions\/3976"}],"wp:attachment":[{"href":"https:\/\/www.globo.tech\/learning-center\/wp-json\/wp\/v2\/media?parent=2347"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.globo.tech\/learning-center\/wp-json\/wp\/v2\/categories?post=2347"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.globo.tech\/learning-center\/wp-json\/wp\/v2\/tags?post=2347"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}