6 #include <sys/statfs.h>
13 #include <netinet/in.h>
16 #include <afs/voldefs.h>
19 #include <afs/vlserver.h>
22 #include <afs/cellconfig.h>
25 #include <afs/afsint.h>
26 #include <afs/volser.h>
27 #include <afs/volint.h>
28 #include "../../volser/lockdata.h"
29 #include "../../vlserver/vlclient.h"
30 #include <afs/com_err.h>
32 #include <afs/kautils.h>
35 #include <afs/afs_Admin.h>
36 #include "../adminutil/afs_AdminInternal.h"
38 #define CLOCKSKEW 2 /* not really skew, but resolution */
40 extern afs_int32 AFSVolPartitionInfo();
41 extern afs_int32 AFSVolTransCreate();
42 extern afs_int32 AFSVolEndTrans();
43 extern afs_int32 AFSVolSetInfo();
44 extern afs_int32 AFSVolDeleteVolume();
45 extern afs_int32 AFSVolNukeVolume();
46 extern afs_int32 AFSVolCreateVolume();
47 extern afs_int32 AFSVolSetFlags();
48 extern afs_int32 AFSVolReClone();
49 extern afs_int32 AFSVolClone();
50 extern afs_int32 AFSVolGetStatus();
51 extern afs_int32 AFSVolSetIdsTypes();
52 extern afs_int32 AFSVolSetDate();
53 extern afs_int32 AFSVolXListPartitions();
54 extern afs_int32 AFSVolListPartitions();
55 extern afs_int32 AFSVolListVolumes();
56 extern afs_int32 AFSVolMonitor();
57 extern afs_int32 AFSVolGetName();
58 extern afs_int32 AFSVolForward();
59 extern afs_int32 AFSVolSetForwarding();
60 extern afs_int32 AFSVolXListVolumes();
61 extern afs_int32 AFSVolXListOneVolume();
62 extern afs_int32 AFSVolForwardMultiple();
63 extern afs_int32 AFSVolListOneVolume();
64 extern afs_int32 StartAFSVolDump();
65 extern afs_int32 StartAFSVolRestore();
67 extern int ubik_Call();
68 extern int ubik_Call_New();
71 extern int UV_NukeVolume(
72 afs_cell_handle_p cellHandle,
73 struct rx_connection *server,
74 unsigned int partition,
75 unsigned int volumeId,
79 extern int UV_CreateVolume(
80 afs_cell_handle_p cellHandle,
81 struct rx_connection *server,
82 unsigned int partition,
83 const char *volumeName,
85 unsigned int *volumeId,
89 extern int UV_DeleteVolume(
90 afs_cell_handle_p cellHandle,
91 struct rx_connection *server,
92 unsigned int partition,
93 unsigned int volumeId,
97 extern int UV_MoveVolume(
98 afs_cell_handle_p cellHandle,
100 afs_int32 afromserver,
107 extern int UV_BackupVolume(
108 afs_cell_handle_p cellHandle,
115 extern int UV_ReleaseVolume(
116 afs_cell_handle_p cellHandle,
118 afs_int32 afromserver,
124 extern int UV_DumpVolume(
125 afs_cell_handle_p cellHandle,
127 afs_int32 afromserver,
130 const char *filename,
134 extern int UV_RestoreVolume(
135 afs_cell_handle_p cellHandle,
139 const char *tovolname,
141 const char *dumpFile,
145 extern int UV_AddSite(
146 afs_cell_handle_p cellHandle,
153 extern int UV_RemoveSite(
154 afs_cell_handle_p cellHandle,
161 extern int UV_ListPartitions(
162 struct rx_connection *server,
163 struct partList *ptrPartList,
168 extern int UV_XListVolumes(
169 struct rx_connection *server,
172 struct volintXInfo **a_resultPP,
173 afs_int32 *a_numEntsInResultP,
177 extern int UV_XListOneVolume(
178 struct rx_connection *server,
181 struct volintXInfo **a_resultPP,
185 extern int UV_SyncVldb(
186 afs_cell_handle_p cellHandle,
187 struct rx_connection *server,
194 extern int CheckVldb(
195 afs_cell_handle_p cellHandle,
196 struct nvldbentry *entry,
201 extern int UV_SyncServer(
202 afs_cell_handle_p cellHandle,
203 struct rx_connection *server,
210 extern int UV_VolserStatus(
211 struct rx_connection *server,
212 transDebugInfo **rpntr,
217 extern int UV_VolumeZap(
218 afs_cell_handle_p cellHandle,
219 struct rx_connection *serverHandle,
220 unsigned int partition,
221 unsigned int volumeId,
225 extern int UV_SetVolume(
226 struct rx_connection *server,
235 extern int UV_RenameVolume(
236 afs_cell_handle_p cellHandle,
237 struct nvldbentry *entry,