Coda Distributed File System
Public Member Functions | Protected Member Functions | Protected Attributes | Friends | List of all members
reintvol Class Reference

#include <venusvol.h>

Inheritance diagram for reintvol:
Inheritance graph
[legend]
Collaboration diagram for reintvol:
Collaboration graph
[legend]

Public Member Functions

 reintvol (Realm *r, VolumeId volid, const char *volname)
 
long LengthOfCML ()
 
void ResetStats ()
 
void ClearRepairCML ()
 
ClientModifyLogGetCML ()
 
int ContainUnrepairedCML ()
 
int IsSync (void)
 
int WriteDisconnect (unsigned int age=V_UNSETAGE, unsigned int time=V_UNSETREINTLIMIT) EXCLUDES_TRANSACTION
 
void Reintegrate () EXCLUDES_TRANSACTION
 
int IncReintegrate (int) EXCLUDES_TRANSACTION
 
int PartialReintegrate (int, unsigned long *reint_time) EXCLUDES_TRANSACTION
 
int IsReintegrating ()
 
int ReadyToReintegrate () EXCLUDES_TRANSACTION
 
int GetReintId () EXCLUDES_TRANSACTION
 
void CheckTransition ()
 
void IncAbort (int) EXCLUDES_TRANSACTION
 
int SyncCache (VenusFid *fid=NULL) EXCLUDES_TRANSACTION
 
void ReportVolState (void)
 
int AllowASR (uid_t)
 
int DisallowASR (uid_t)
 
void EnableASR (uid_t)
 
int DisableASR (uid_t)
 
int IsASRAllowed ()
 
int IsASREnabled ()
 
void lock_asr ()
 
void unlock_asr ()
 
int asr_running ()
 
void asr_pgid (pid_t new_pgid)
 
pid_t asr_pgid ()
 
int AllocFid (ViceDataType, VenusFid *, uid_t, int=0) EXCLUDES_TRANSACTION
 
VenusFid GenerateLocalFid (ViceDataType) EXCLUDES_TRANSACTION
 
int GetConn (connent **c, uid_t uid, mgrpent **m, int *ph_ix, struct in_addr *phost) EXCLUDES_TRANSACTION
 
int LogStore (time_t, uid_t, VenusFid *, RPC2_Unsigned, int prepend) REQUIRES_TRANSACTION
 
int LogSetAttr (time_t, uid_t, VenusFid *, RPC2_Unsigned, Date_t, UserId, RPC2_Unsigned, int prepend) REQUIRES_TRANSACTION
 
int LogTruncate (time_t, uid_t, VenusFid *, RPC2_Unsigned, int prepend) REQUIRES_TRANSACTION
 
int LogUtimes (time_t, uid_t, VenusFid *, Date_t, int prepend) REQUIRES_TRANSACTION
 
int LogChown (time_t, uid_t, VenusFid *, UserId, int prepend) REQUIRES_TRANSACTION
 
int LogChmod (time_t, uid_t, VenusFid *, RPC2_Unsigned, int prepend) REQUIRES_TRANSACTION
 
int LogCreate (time_t, uid_t, VenusFid *, char *, VenusFid *, RPC2_Unsigned, int prepend) REQUIRES_TRANSACTION
 
int LogRemove (time_t, uid_t, VenusFid *, char *, const VenusFid *, int, int prepend) REQUIRES_TRANSACTION
 
int LogLink (time_t, uid_t, VenusFid *, char *, VenusFid *, int prepend)
 
int LogRename (time_t, uid_t, VenusFid *, char *, VenusFid *, char *, VenusFid *, const VenusFid *, int, int prepend) REQUIRES_TRANSACTION
 
int LogMkdir (time_t, uid_t, VenusFid *, char *, VenusFid *, RPC2_Unsigned, int prepend) REQUIRES_TRANSACTION
 
int LogRmdir (time_t, uid_t, VenusFid *, char *, const VenusFid *, int prepend) REQUIRES_TRANSACTION
 
int LogSymlink (time_t, uid_t, VenusFid *, char *, char *, VenusFid *, RPC2_Unsigned, int prepend) REQUIRES_TRANSACTION
 
int LogRepair (time_t, uid_t, VenusFid *, RPC2_Unsigned, Date_t, UserId, RPC2_Unsigned, int prepend) REQUIRES_TRANSACTION
 
int CheckPointMLEs (uid_t, char *) EXCLUDES_TRANSACTION
 
int LastMLETime (unsigned long *)
 
int PurgeMLEs (uid_t) EXCLUDES_TRANSACTION
 
void ListCML (FILE *fp)
 
void PreserveAllLocalMutation (char *msg)
 
void PreserveLocalMutation (char *msg)
 
void DiscardAllLocalMutation (char *msg)
 
void DiscardLocalMutation (char *msg)
 
int HaveCallBack ()
 
int CallBackBreak () EXCLUDES_TRANSACTION
 
void ClearCallBack ()
 
void SetCallBack ()
 
int WantCallBack ()
 
int ValidateFSOs () EXCLUDES_TRANSACTION
 
int GetVolAttr (uid_t) EXCLUDES_TRANSACTION
 
void UpdateVCBInfo (RPC2_Integer VS, CallBackStatus CBStatus) EXCLUDES_TRANSACTION
 
void PackVS (int, RPC2_CountedBS *)
 
int HaveStamp ()
 
- Public Member Functions inherited from volent
void hold ()
 
void release ()
 
int Enter (int, uid_t) EXCLUDES_TRANSACTION
 
void Exit (int, uid_t) EXCLUDES_TRANSACTION
 
void TakeTransition () EXCLUDES_TRANSACTION
 
int TransitionPending ()
 
void Wait () EXCLUDES_TRANSACTION
 
void Signal ()
 
void Lock (VolLockType, int=0) EXCLUDES_TRANSACTION
 
void UnLock (VolLockType)
 
int Collate (connent *, int code, int TranslateEINCOMP=1)
 
int GetVolStat (VolumeStatus *, RPC2_BoundedBS *, VolumeStateType *, unsigned int *age, unsigned int *hogtime, int *conflict, int *cml_size, uint64_t *cml_bytes, RPC2_BoundedBS *, RPC2_BoundedBS *, uid_t, int local_only) EXCLUDES_TRANSACTION
 
int SetVolStat (VolumeStatus *, RPC2_BoundedBS *, RPC2_BoundedBS *, RPC2_BoundedBS *, uid_t) EXCLUDES_TRANSACTION
 
void GetHosts (struct in_addr hosts[VSG_MEMBERS])
 
void GetVids (VolumeId out[VSG_MEMBERS])
 
int AVSGsize ()
 
int IsBackup ()
 
int IsReplicated ()
 
int IsReadWriteReplica ()
 
int IsNonReplicated ()
 
int IsReadWrite ()
 
int IsUnreachable ()
 
int IsReachable ()
 
int IsResolving ()
 
int IsLocalRealm ()
 
void GetMountPath (char *, int=1)
 
void GetBandwidth (unsigned long *bw)
 
VenusFid GenerateFakeFid () REQUIRES_TRANSACTION
 
RealmId GetRealmId ()
 
VolumeId GetVolumeId ()
 
const char * GetName ()
 
fsobjNewFakeDirObj (const char *comp) REQUIRES_TRANSACTION
 Instantiate a new fake directory object. More...
 
fsobjNewFakeMountLinkObj (VenusFid *fid, const char *comp) REQUIRES_TRANSACTION
 Instantiate a new fake mountlink object. More...
 
int IsRepairVol (void)
 
void print ()
 
void print (FILE *fp)
 
void print (int)
 
void ListCache (FILE *, int long_format=1, unsigned int valid=3)
 

Protected Member Functions

void ResetCMLTransients () EXCLUDES_TRANSACTION
 
- Protected Member Functions inherited from volent
void operator delete (void *) REQUIRES_TRANSACTION
 
 volent (Realm *r, VolumeId vid, const char *name) REQUIRES_TRANSACTION
 
 ~volent () REQUIRES_TRANSACTION
 
void ResetVolTransients ()
 
ViceVolumeType VolStatType (void)
 

Protected Attributes

FidRange FileFids
 
FidRange DirFids
 
FidRange SymlinkFids
 
ClientModifyLog CML
 
struct Lock CML_lock
 
int reint_id_gen
 
int cur_reint_tid
 
unsigned int ReintLimit
 
unsigned int AgeLimit
 
int RecordsCancelled
 
int RecordsCommitted
 
int RecordsAborted
 
int FidsRealloced
 
long BytesBackFetched
 
cmlentreintegrate_done
 
CallBackStatus VCBStatus
 
int VCBHits
 
ViceVersionVector VVV
 
- Protected Attributes inherited from volent
char * name
 
VolumeId vid
 
Realmrealm
 
VolFlags flags
 
VolumeStateType state
 
Unique_t FidUnique
 
rec_olink handle
 
struct dllist_head fso_list
 
short mutator_count
 
short observer_count
 
short resolver_count
 
short shrd_count
 
int pgid
 

Friends

class ClientModifyLog
 
class fsobj
 
class volent
 
class cmlent
 
class vdb
 
long VENUS_CallBackFetch (RPC2_Handle, ViceFid *, SE_Descriptor *)
 

Constructor & Destructor Documentation

◆ reintvol()

reintvol::reintvol ( Realm r,
VolumeId  volid,
const char *  volname 
)

Member Function Documentation

◆ AllocFid()

int reintvol::AllocFid ( ViceDataType  Type,
VenusFid target_fid,
uid_t  uid,
int  force = 0 
)

◆ AllowASR()

int reintvol::AllowASR ( uid_t  uid)

◆ asr_pgid() [1/2]

pid_t reintvol::asr_pgid ( )
inline

◆ asr_pgid() [2/2]

void reintvol::asr_pgid ( pid_t  new_pgid)

◆ asr_running()

int reintvol::asr_running ( )
inline

◆ CallBackBreak()

int reintvol::CallBackBreak ( )

◆ CheckPointMLEs()

int reintvol::CheckPointMLEs ( uid_t  uid,
char *  ckpdir 
)

◆ CheckTransition()

void reintvol::CheckTransition ( )

◆ ClearCallBack()

void reintvol::ClearCallBack ( )

◆ ClearRepairCML()

void reintvol::ClearRepairCML ( )

◆ ContainUnrepairedCML()

int reintvol::ContainUnrepairedCML ( )

◆ DisableASR()

int reintvol::DisableASR ( uid_t  uid)

◆ DisallowASR()

int reintvol::DisallowASR ( uid_t  uid)

◆ DiscardAllLocalMutation()

void reintvol::DiscardAllLocalMutation ( char *  msg)

◆ DiscardLocalMutation()

void reintvol::DiscardLocalMutation ( char *  msg)

◆ EnableASR()

void reintvol::EnableASR ( uid_t  uid)

◆ GenerateLocalFid()

VenusFid reintvol::GenerateLocalFid ( ViceDataType  fidtype)

◆ GetCML()

ClientModifyLog * reintvol::GetCML ( )
inline

◆ GetConn()

int reintvol::GetConn ( connent **  c,
uid_t  uid,
mgrpent **  m,
int *  ph_ix,
struct in_addr *  phost 
)

◆ GetReintId()

int reintvol::GetReintId ( )

◆ GetVolAttr()

int reintvol::GetVolAttr ( uid_t  uid)

◆ HaveCallBack()

int reintvol::HaveCallBack ( )
inline

◆ HaveStamp()

int reintvol::HaveStamp ( )
inline

◆ IncAbort()

void reintvol::IncAbort ( int  tid)

◆ IncReintegrate()

int reintvol::IncReintegrate ( int  tid)

◆ IsASRAllowed()

int reintvol::IsASRAllowed ( )
inline

◆ IsASREnabled()

int reintvol::IsASREnabled ( )
inline

◆ IsReintegrating()

int reintvol::IsReintegrating ( )
inline

◆ IsSync()

int reintvol::IsSync ( void  )
inline

◆ LastMLETime()

int reintvol::LastMLETime ( unsigned long *  time)

◆ LengthOfCML()

long reintvol::LengthOfCML ( )
inline

◆ ListCML()

void reintvol::ListCML ( FILE *  fp)

◆ lock_asr()

void reintvol::lock_asr ( )

◆ LogChmod()

int reintvol::LogChmod ( time_t  Mtime,
uid_t  uid,
VenusFid Fid,
RPC2_Unsigned  NewMode,
int  prepend 
)

◆ LogChown()

int reintvol::LogChown ( time_t  Mtime,
uid_t  uid,
VenusFid Fid,
UserId  NewOwner,
int  prepend 
)

◆ LogCreate()

int reintvol::LogCreate ( time_t  Mtime,
uid_t  uid,
VenusFid PFid,
char *  Name,
VenusFid CFid,
RPC2_Unsigned  Mode,
int  prepend 
)

◆ LogLink()

int reintvol::LogLink ( time_t  Mtime,
uid_t  uid,
VenusFid PFid,
char *  Name,
VenusFid CFid,
int  prepend 
)

◆ LogMkdir()

int reintvol::LogMkdir ( time_t  Mtime,
uid_t  uid,
VenusFid PFid,
char *  Name,
VenusFid CFid,
RPC2_Unsigned  Mode,
int  prepend 
)

◆ LogRemove()

int reintvol::LogRemove ( time_t  Mtime,
uid_t  uid,
VenusFid PFid,
char *  Name,
const VenusFid CFid,
int  LinkCount,
int  prepend 
)

◆ LogRename()

int reintvol::LogRename ( time_t  Mtime,
uid_t  uid,
VenusFid SPFid,
char *  OldName,
VenusFid TPFid,
char *  NewName,
VenusFid SFid,
const VenusFid TFid,
int  LinkCount,
int  prepend 
)

◆ LogRepair()

int reintvol::LogRepair ( time_t  Mtime,
uid_t  uid,
VenusFid Fid,
RPC2_Unsigned  Length,
Date_t  Date,
UserId  Owner,
RPC2_Unsigned  Mode,
int  prepend 
)

◆ LogRmdir()

int reintvol::LogRmdir ( time_t  Mtime,
uid_t  uid,
VenusFid PFid,
char *  Name,
const VenusFid CFid,
int  prepend 
)

◆ LogSetAttr()

int reintvol::LogSetAttr ( time_t  Mtime,
uid_t  uid,
VenusFid Fid,
RPC2_Unsigned  NewLength,
Date_t  NewDate,
UserId  NewOwner,
RPC2_Unsigned  NewMode,
int  prepend 
)

◆ LogStore()

int reintvol::LogStore ( time_t  Mtime,
uid_t  uid,
VenusFid Fid,
RPC2_Unsigned  NewLength,
int  prepend 
)

◆ LogSymlink()

int reintvol::LogSymlink ( time_t  Mtime,
uid_t  uid,
VenusFid PFid,
char *  Name,
char *  Contents,
VenusFid CFid,
RPC2_Unsigned  Mode,
int  prepend 
)

◆ LogTruncate()

int reintvol::LogTruncate ( time_t  Mtime,
uid_t  uid,
VenusFid Fid,
RPC2_Unsigned  NewLength,
int  prepend 
)

◆ LogUtimes()

int reintvol::LogUtimes ( time_t  Mtime,
uid_t  uid,
VenusFid Fid,
Date_t  NewDate,
int  prepend 
)

◆ PackVS()

void reintvol::PackVS ( int  nstamps,
RPC2_CountedBS BS 
)

◆ PartialReintegrate()

int reintvol::PartialReintegrate ( int  tid,
unsigned long *  reint_time 
)

◆ PreserveAllLocalMutation()

void reintvol::PreserveAllLocalMutation ( char *  msg)

◆ PreserveLocalMutation()

void reintvol::PreserveLocalMutation ( char *  msg)

◆ PurgeMLEs()

int reintvol::PurgeMLEs ( uid_t  uid)

◆ ReadyToReintegrate()

int reintvol::ReadyToReintegrate ( )

◆ Reintegrate()

void reintvol::Reintegrate ( )

◆ ReportVolState()

void reintvol::ReportVolState ( void  )

◆ ResetCMLTransients()

void reintvol::ResetCMLTransients ( void  )
protected

◆ ResetStats()

void reintvol::ResetStats ( )
inline

◆ SetCallBack()

void reintvol::SetCallBack ( )

◆ SyncCache()

int reintvol::SyncCache ( VenusFid fid = NULL)

◆ unlock_asr()

void reintvol::unlock_asr ( )

◆ UpdateVCBInfo()

void reintvol::UpdateVCBInfo ( RPC2_Integer  VS,
CallBackStatus  CBStatus 
)

◆ ValidateFSOs()

int reintvol::ValidateFSOs ( )

◆ WantCallBack()

int reintvol::WantCallBack ( )

◆ WriteDisconnect()

int reintvol::WriteDisconnect ( unsigned int  age = V_UNSETAGE,
unsigned int  time = V_UNSETREINTLIMIT 
)

Friends And Related Function Documentation

◆ ClientModifyLog

friend class ClientModifyLog
friend

◆ cmlent

friend class cmlent
friend

◆ fsobj

friend class fsobj
friend

◆ vdb

friend class vdb
friend

◆ VENUS_CallBackFetch

long VENUS_CallBackFetch ( RPC2_Handle  RPCid,
ViceFid *  Fid,
SE_Descriptor BD 
)
friend

◆ volent

friend class volent
friend

Member Data Documentation

◆ AgeLimit

unsigned int reintvol::AgeLimit
protected

◆ BytesBackFetched

long reintvol::BytesBackFetched
protected

◆ CML

ClientModifyLog reintvol::CML
protected

◆ CML_lock

struct Lock reintvol::CML_lock
protected

◆ cur_reint_tid

int reintvol::cur_reint_tid
protected

◆ DirFids

FidRange reintvol::DirFids
protected

◆ FidsRealloced

int reintvol::FidsRealloced
protected

◆ FileFids

FidRange reintvol::FileFids
protected

◆ RecordsAborted

int reintvol::RecordsAborted
protected

◆ RecordsCancelled

int reintvol::RecordsCancelled
protected

◆ RecordsCommitted

int reintvol::RecordsCommitted
protected

◆ reint_id_gen

int reintvol::reint_id_gen
protected

◆ reintegrate_done

cmlent* reintvol::reintegrate_done
protected

◆ ReintLimit

unsigned int reintvol::ReintLimit
protected

◆ SymlinkFids

FidRange reintvol::SymlinkFids
protected

◆ VCBHits

int reintvol::VCBHits
protected

◆ VCBStatus

CallBackStatus reintvol::VCBStatus
protected

◆ VVV

ViceVersionVector reintvol::VVV
protected

The documentation for this class was generated from the following files: