3

There are a million sites on how to set up user/group quotas, but none actually explain what a group quota is. Is it

  1. The maximum disk space for the entire group (ie 100GB for 100 users)
  2. The disk space to be evenly distributed amongst all members of a group (ie. 100 GB for 100 users = 1 GB per user).
Zoredache
  • 130,897
  • 41
  • 276
  • 420
puk
  • 285
  • 1
  • 6
  • 18

1 Answers1

6

A group quota is the maximum amount of disk space that can be used by all files owned by a particular group. There is no attempt to divide it up by users, and in practice there would be no sensible way to do that.

David Schwartz
  • 31,449
  • 2
  • 55
  • 84
  • If you wanted it divided by user you'd have made it a user quota in the first place. – DerfK Nov 04 '11 at 00:08
  • That's a shame b/c that's what I want. How does gmail do it? They divide their disk space evenly amongst their account holders. – puk Nov 04 '11 at 00:08
  • @DerfK I will make a new question for this, but I am having a difficult time automating the quota process b/c `edquota` opens up vim – puk Nov 04 '11 at 00:09
  • 1
    @puk: Gmail simply gives each user a fixed quota. – David Schwartz Nov 04 '11 at 00:11
  • 1
    @puk, don't use edquota to modify your quotas then. Setup a template account and use setquota. See this answer. http://serverfault.com/questions/226917/setting-up-disk-quota-on-ubuntu-for-multiple-users/226921#226921 – Zoredache Nov 04 '11 at 00:13
  • @DavidSchwartz I meant gmail, probably, divides their disk space evenly amongst users, not that they use the group quota approach – puk Nov 04 '11 at 00:14
  • @puk: They don't divide their disk space evenly. They have a huge pool of disk space which they allocate to users on demand. Their quota is strictly per-user. This is exactly the result you would get if you assigned each user a user quota. – David Schwartz Nov 04 '11 at 00:16
  • @DavidSchwartz you lost me. Why does it say `16% full Using 1291 MB of your 7643 MB` in my Gmail account. – puk Nov 04 '11 at 00:18
  • Gmail almost certainly is not using a standard *nix filesystem for mail storage. So does it really matter what they are doing? I suspect they have some kind of magical distributed database type system. The usage counts, and assigned quota values are almost certainly stored in a database somewhere. – Zoredache Nov 04 '11 at 00:19
  • BTW gmail storage is not divided evenly. Google Apps users get more, and you can pay for additional storage for a standard account. – Zoredache Nov 04 '11 at 00:24
  • I think this is a distinction without a difference. I want to evenly distribute disk space amongst my users, and everytime I add more space, I want to update that 'fixed quota'. – puk Nov 04 '11 at 00:26
  • The link Zoredache provided is exactly what I am looking for. – puk Nov 04 '11 at 00:29
  • @puk: It says that because you have a user quota of 7643 MB. – David Schwartz Nov 04 '11 at 00:39
  • @DavidSchwartz and I assume that user quota gets updated regularly (ie. when more space is added) – puk Nov 04 '11 at 00:41
  • @puk: The quota is actually a function of the *date*, believe it or not (look at the JavaScript!). Google also adds storage regularly to keep up with the actual storage use. It is unknown whether Google would have enough storage if every gmail user went up to their quota at the same time. – David Schwartz Nov 04 '11 at 00:48
  • @DavidSchwartz LOL google emulating the banking systems, they are creating space that doesn't exist. – puk Nov 04 '11 at 01:02