The Coda File Server: Server RVM layout

Next Previous Contents

## 4. Server RVM layout

The initial RVM layout of a coda server is simple:

        boolean_t       already_initialized;
        struct VolHead VolumeList[MAXVOLS];
        struct VnodeDiskObject    *SmallVnodeFreeList[SMALLFREESIZE];
        struct VnodeDiskObject    *LargeVnodeFreeList[LARGEFREESIZE];
        short    SmallVnodeIndex;
        short    LargeVnodeIndex;
        VolumeId    MaxVolId;
        long    Reserved[MAXVOLS];

These fields are accessed through the CAMLIB_REC macro. The SmallVnodeIndex is the index of the highest pointer in the array, pointing to a free vnode.

The RVM layout is initialized in coda_init (recovc.cc) which allocates small and large vnodes in RVM for each of the entries in the free vnode list arrays. The vnodes are zeroed out.

## 4.1 Vnodes for volumes

The VolumeData structure has a pointer to the arrays: smallVnodeLists and largeVnodeLists.

## 4.2 Resolution Logs for vnode lists.

Next Previous Contents