static struct ubik_client *uclient;
static int GetClientAddrsCmd(), SetClientAddrsCmd(), FlushMountCmd();
-static int RxStatProcCmd(), RxStatPeerCmd(), GetFidCmd();
+static int RxStatProcCmd(), RxStatPeerCmd(), GetFidCmd(), NewUuidCmd();
extern char *hostutil_GetNameByINet();
extern struct hostent *hostutil_GetHostByName();
}
static int
+NewUuidCmd(struct cmd_syndesc *as, char *arock)
+{
+ afs_int32 code;
+ struct ViceIoctl blob;
+
+ blob.in_size = 0;
+ blob.out_size = 0;
+ code = pioctl(0, VIOC_NEWUUID, &blob, 1);
+ if (code) {
+ Die(errno, 0);
+ return 1;
+ }
+
+ printf("New uuid generated.\n");
+ return 0;
+}
+
+static int
FlushCmd(struct cmd_syndesc *as, char *arock)
{
afs_int32 code;
ts = cmd_CreateSyntax("nukenfscreds", NukeNFSCredsCmd, 0, "nuke credentials for NFS client");
cmd_AddParm(ts, "-addr", CMD_SINGLE, 0, "host name or address");
+ ts = cmd_CreateSyntax("newuuid", NewUuidCmd, 0,
+ "force a new uuid");
+
code = cmd_Dispatch(argc, argv);
if (rxInitDone)
rx_Finalize();
fprintf(stderr, "%s:'%s'", pn, filename);
else
fprintf(stderr, "%s", pn);
- fprintf(stderr, ": %s\n", error_message(errnum));
+ fprintf(stderr, ": %s\n", afs_error_message(errnum));
break;
}
}