{"id":5800,"date":"2024-05-24T11:49:54","date_gmt":"2024-05-24T16:49:54","guid":{"rendered":"https:\/\/www.incredigeek.com\/home\/?p=5800"},"modified":"2024-05-24T11:52:05","modified_gmt":"2024-05-24T16:52:05","slug":"locate-large-files-on-linux","status":"publish","type":"post","link":"https:\/\/www.incredigeek.com\/home\/locate-large-files-on-linux\/","title":{"rendered":"Locate large files on Linux"},"content":{"rendered":"\n<p>Show size of directories.  The -h option prints the size in human readable format.<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">du -h --max=1 .\/<\/pre>\n\n\n\n<p>We can use sort and tail to filter and only show the 10 largest files and directories.  The -a option shows all files and directories. <\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">du -ah .\/ | sort -h | tail -n10<\/pre>\n\n\n\n<p>We can use the find command to show all files over xMB.  In this case 100MB<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">fine . -type f -size +100M -print<\/pre>\n\n\n\n<p><a href=\"https:\/\/linuxhandbook.com\/find-biggest-files-linux\">https:\/\/linuxhandbook.com\/find-biggest-files-linux<\/a><br><a href=\"https:\/\/linuxize.com\/post\/find-large-files-in-linux\/\">https:\/\/linuxize.com\/post\/find-large-files-in-linux\/<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Show size of directories. The -h option prints the size in human readable format. du -h &#8211;max=1 .\/ We can use sort and tail to filter and only show the 10 largest files and directories. The -a option shows all &hellip; <a href=\"https:\/\/www.incredigeek.com\/home\/locate-large-files-on-linux\/\">Continue reading <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[3],"tags":[1676,677,1677],"class_list":["post-5800","post","type-post","status-publish","format-standard","hentry","category-linux","tag-du","tag-find","tag-fine"],"_links":{"self":[{"href":"https:\/\/www.incredigeek.com\/home\/wp-json\/wp\/v2\/posts\/5800","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.incredigeek.com\/home\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.incredigeek.com\/home\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.incredigeek.com\/home\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.incredigeek.com\/home\/wp-json\/wp\/v2\/comments?post=5800"}],"version-history":[{"count":3,"href":"https:\/\/www.incredigeek.com\/home\/wp-json\/wp\/v2\/posts\/5800\/revisions"}],"predecessor-version":[{"id":5803,"href":"https:\/\/www.incredigeek.com\/home\/wp-json\/wp\/v2\/posts\/5800\/revisions\/5803"}],"wp:attachment":[{"href":"https:\/\/www.incredigeek.com\/home\/wp-json\/wp\/v2\/media?parent=5800"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.incredigeek.com\/home\/wp-json\/wp\/v2\/categories?post=5800"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.incredigeek.com\/home\/wp-json\/wp\/v2\/tags?post=5800"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}