require 'global.defs';
require 'local.defs';
require $backuplib_perl;
 
$exitstatus = 0;
 
delete $ENV{'KRBTKFILE'};       # use the default
 
if (system("/usr/local/bin/ksrvtgt rcmd `/bin/hostname`")) {
        die "kinit failed.\n";
}
 
$exitstatus = system("/usr/athena/bin/rsh", @ARGV);
if ($exitstatus) {
    warn "rsh failed.\n";
}
 
if (system("/usr/athena/bin/kdestroy")) {
    die "kdestroy failed.\n";
}
 
exit($exitstatus);
