[OpenAFS] Many partitions: How?
Jeffrey Hutzelman
jhutz@cmu.edu
Thu, 13 May 2004 15:21:25 -0400
On Thursday, May 13, 2004 20:57:52 +0200 Sensei <senseiwa@tin.it> wrote:
> On Thu, 2004-05-13 at 18:45, Derek Atkins wrote:
>> Create additional volumes.
>>
>> NO DATA should live in root.cell. root.cell should contain additional
>> volumes, like user, project, etc. And THOSE should contain YET MORE
>> volumes, like user.warlord, user.senseiwa, project.afs, etc.
>
> Ok, I make a step back. How to make an afs cell and have it usable?
>
> 1. vos create ... /vicepa ... root.afs ...
> 2. set acls for /afs
> 3. vos create ... /vicepa ... root.cell ...
> 4. fs mkmount /afs/my.cell root.cell (and .my.cell)
> 5. mkdir /afs/my.cell/users, set acls, chown to what I want
>
> 6. pts to add a user (I use kerberos, so no KAS)
> 7. mkdir the directory /afs/my.cell/users/user_a
> 8. chown and set acls on user_a directory
No. If you do that, you're putting user_a in the root.cell volume, instead
of in his own volume.
> 9. vos create ... /vicepa ... users.user_a ... (eg. with 1gb quota)
> 10. fs mkmount /afs/my.cell/users/user_a users.user_a ...
Do this instead. The 'fs mkmount' creates an object in the filesystem
which is a pointer to the new volume. When clients see the mount point,
they'll transparently substitute the mounted volume. In that way, you
build up one global filespace out of a large number of volumes.
> Now, since for every user I have to make a volume specifying the
> partition and the quota, it seems that the total quota on a partition
> can be greater than the space available on a partition, if not carefully
> checked... So, I have a 100 mb partition and assign 20 mb of quota for
> each of my 10 users. The sum of possible volume space is 200 mb!
Yup; that's fine. Quota isn't reserved space; it's a restriction on the
amount of space that can be used in that particular volume. Just like an
airline, you can "overbook" a partition, giving out more in total quota
than there is actually space on the partition, with the expectation that
most people won't use all the quota you give them -- especially if you set
the same quota on every user's home directory. If a partition does start
to get full, you can just move one or more volumes to another partition
(see below).
> I thought there was the possibility of having different partitions seen
> as one ``global'' space, and in this space you create the volumes, which
> are logical, with a quota. So you can get rid of the partition location,
> but you mount them and that's all.
That's almost right. Every volume exists on exactly one partition
somewhere (well, replicated volumes will have multiple copies, each on a
different server, but we'll ignore that detail for the moment). The exact
location of a volume is invisible to clients -- if you move users.user_a
from one location to another, user_a won't even notice -- his client will
continue to be able to access the volume, even during the move. However,
you as an administrator need to decide where each volume will be located,
keep track of the amount of space in use, and move volumes as necessary.
-- Jeffrey T. Hutzelman (N3NHS) <jhutz+@cmu.edu>
Sr. Research Systems Programmer
School of Computer Science - Research Computing Facility
Carnegie Mellon University - Pittsburgh, PA