/* salvager data structures */
struct InodeSummary { /* Inode summary file--an entry for each
* volume in the inode file for a partition */
- VolId volumeId; /* Volume id */
- VolId RWvolumeId; /* RW volume associated */
+ VolumeId volumeId; /* Volume id */
+ VolumeId RWvolumeId; /* RW volume associated */
int index; /* index into inode file (0, 1, 2 ...) */
int nInodes; /* Number of inodes for this volume */
int nSpecialInodes; /* Number of special inodes, i.e. volume
* volume in a volume directory.
* Assumption: one volume directory per
* partition */
- char *fileName; /* File name on the partition for the volume
- * header */
struct VolumeHeader header;
/* volume number, rw volume number, inode
* numbers of each major component of
* the volume */
IHandle_t *volumeInfoHandle;
+ char deleted; /* did we delete this volume? */
byte wouldNeedCallback; /* set if the file server should issue
* call backs for all the files in this volume when
* the volume goes back on line */
+ byte unused; /* is this volume 'extra'? i.e. not referenced
+ * by anything? */
};
struct VnodeInfo {
extern int Fork(void);
extern int Wait(char *prog);
extern char *ToString(const char *s);
+extern int AskDAFS(void);
extern void AskOffline(struct SalvInfo *salvinfo, VolumeId volumeId);
extern void AskOnline(struct SalvInfo *salvinfo, VolumeId volumeId);
+extern void AskDelete(struct SalvInfo *salvinfo, VolumeId volumeId);
extern void CheckLogFile(char * log_path);
#ifndef AFS_NT40_ENV
extern void TimeStampLogFile(char * log_path);
struct VolumeSummary *vsp);
extern void DistilVnodeEssence(struct SalvInfo *salvinfo, VolumeId vid,
VnodeClass class, Inode ino, Unique * maxu);
-extern int GetInodeSummary(struct SalvInfo *salvinfo, FILE *inodeFile,
+extern int GetInodeSummary(struct SalvInfo *salvinfo, FD_t inodeFile,
VolumeId singleVolumeNumber);
extern int GetVolumeSummary(struct SalvInfo *salvinfo,
VolumeId singleVolumeNumber);
extern void ObtainSharedSalvageLock(void);
extern void PrintInodeList(struct SalvInfo *salvinfo);
extern void PrintInodeSummary(struct SalvInfo *salvinfo);
-extern void PrintVolumeSummary(struct SalvInfo *salvinfo);
extern int QuickCheck(struct SalvInfo *salvinfo, struct InodeSummary *isp,
int nVols);
extern void RemoveTheForce(char *path);
extern void SalvageFileSys(struct DiskPartition64 *partP, VolumeId singleVolumeNumber);
extern void SalvageFileSys1(struct DiskPartition64 *partP,
VolumeId singleVolumeNumber);
-extern int SalvageHeader(struct SalvInfo *salvinfo, struct stuff *sp,
+extern int SalvageHeader(struct SalvInfo *salvinfo, struct afs_inode_info *sp,
struct InodeSummary *isp, int check, int *deleteMe);
extern int SalvageIndex(struct SalvInfo *salvinfo, Inode ino, VnodeClass class,
int RW, struct ViceInodeInfo *ip, int nInodes,
extern void DoSalvageVolumeGroup(struct SalvInfo *salvinfo,
struct InodeSummary *isp, int nVols);
#ifdef AFS_NT40_ENV
-extern void SalvageVolumeGroup(struct InodeSummary *isp, int nVols);
-#else
-#define SalvageVolumeGroup DoSalvageVolumeGroup
+extern void nt_SalvageVolumeGroup(struct SalvInfo *salvinfo, struct InodeSummary *isp, int nVols);
#endif
extern int SalvageVolumeHeaderFile(struct SalvInfo *salvinfo,
struct InodeSummary *isp,
struct ViceInodeInfo *inodes, int RW,
int check, int *deleteMe);
-extern void showlog(void);
extern int UseTheForceLuke(char *path);