{"id":761,"date":"2021-01-06T21:35:05","date_gmt":"2021-01-06T21:35:05","guid":{"rendered":"https:\/\/www.kolkataonweb.com\/code-bank\/?p=761"},"modified":"2021-01-06T23:22:31","modified_gmt":"2021-01-06T23:22:31","slug":"disk-quota-on-amazon-ec2","status":"publish","type":"post","link":"https:\/\/www.kolkataonweb.com\/code-bank\/miscellaneous\/disk-quota-on-amazon-ec2\/","title":{"rendered":"Disk Quota on Amazon EC2"},"content":{"rendered":"<p>The Linux AMIs available for AWS EC2 may not have the packages required for activating Disk Quota.<\/p>\n<p>This article is based on Ubuntu 20.04.<\/p>\n<p>There are many articles and suggestions on the internet. Following one of the suggestions caused my system to become read-only. Lastly found a solution which looks the most legit, simple and works perfect.<\/p>\n<p>It needs installation of the package &#8220;<span style=\"color: #0000ff;\"><em>linux-modules-extra-aws<\/em><\/span>&#8221;<\/p>\n<ol>\n<li>\n<pre class='wp-code-highlight prettyprint'>apt-get install linux-modules-extra-aws<\/pre>\n<\/li>\n<li>\n<pre class='wp-code-highlight prettyprint'>apt-get -y install quota quotatool<\/pre>\n<\/li>\n<li>\n<pre class='wp-code-highlight prettyprint'>mount -o remount &lt;disk partition&gt;\u00a0 e.g - mount -o remount \/<\/pre>\n<\/li>\n<li>\n<pre class='wp-code-highlight prettyprint'>quotacheck -avugm<\/pre>\n<\/li>\n<li>\n<pre class='wp-code-highlight prettyprint'>quotaon -avug<\/pre>\n<\/li>\n<li>\n<pre class='wp-code-highlight prettyprint'>Edit the fstab file and add the necessary<\/pre>\n<ul>\n<li>\n<pre class='wp-code-highlight prettyprint'>nano \/etc\/fstab<\/pre>\n<\/li>\n<li>\n<pre class='wp-code-highlight prettyprint'>add the following to the end of the existing parameters <strong><span style=\"color: #0000ff;\"><em>,usrjquota=quota.user,grpjquota=quota.group,jqfmt=vfsv0<\/em><\/span><\/strong><\/pre>\n<\/li>\n<li>\n<pre class='wp-code-highlight prettyprint'>Save the file<\/pre>\n<\/li>\n<li>\n<pre class='wp-code-highlight prettyprint'><span style=\"color: #ff0000;\">Please note - wrong entry in the fstab file can make the system unusable. Please check the file first before rebooting.\u00a0 Use <em>mount -a <\/em>to check if the entries in fstab file is good. <\/span><\/pre>\n<\/li>\n<\/ul>\n<\/li>\n<\/ol>\n","protected":false},"excerpt":{"rendered":"<p>The Linux AMIs available for AWS EC2 may not have the packages required for activating Disk Quota. This article is based on Ubuntu 20.04. There are many articles and suggestions on the internet. Following one of the suggestions caused my system to become read-only. Lastly found a solution which looks the most legit, simple and&hellip; <a class=\"more-link\" href=\"https:\/\/www.kolkataonweb.com\/code-bank\/miscellaneous\/disk-quota-on-amazon-ec2\/\">Continue reading <span class=\"screen-reader-text\">Disk Quota on Amazon EC2<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[244,247,246,248,245],"class_list":["post-761","post","type-post","status-publish","format-standard","hentry","category-miscellaneous","tag-disk-quota","tag-disk-quota-on-amazon-ec2","tag-disk-quota-on-aws-ec2","tag-disk-quota-on-ubuntu-20-04","tag-linux-quota","entry"],"aioseo_notices":[],"_links":{"self":[{"href":"https:\/\/www.kolkataonweb.com\/code-bank\/wp-json\/wp\/v2\/posts\/761","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.kolkataonweb.com\/code-bank\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.kolkataonweb.com\/code-bank\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.kolkataonweb.com\/code-bank\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.kolkataonweb.com\/code-bank\/wp-json\/wp\/v2\/comments?post=761"}],"version-history":[{"count":4,"href":"https:\/\/www.kolkataonweb.com\/code-bank\/wp-json\/wp\/v2\/posts\/761\/revisions"}],"predecessor-version":[{"id":773,"href":"https:\/\/www.kolkataonweb.com\/code-bank\/wp-json\/wp\/v2\/posts\/761\/revisions\/773"}],"wp:attachment":[{"href":"https:\/\/www.kolkataonweb.com\/code-bank\/wp-json\/wp\/v2\/media?parent=761"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.kolkataonweb.com\/code-bank\/wp-json\/wp\/v2\/categories?post=761"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.kolkataonweb.com\/code-bank\/wp-json\/wp\/v2\/tags?post=761"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}