Commit 91d2b34b authored by Mike Hibler's avatar Mike Hibler

For now, save off the diffs between old/new exports file in /tmp.

In case I need to correlate mountd behavior with what exports looked like.
parent 074370cd
......@@ -149,9 +149,21 @@ system("cat $exportstail >> $exportsnew") == 0 or
#
# Do nothing if no change.
#
system("/usr/bin/diff -q $exports $exportsnew >/dev/null");
# Note that for now, we are actually saving the diffs so we can
# compare to the new differential behavior of mountd in case of
# an inconsisency. But only for mountd, not smbd.
#
my $outfile;
if (defined($opts{'S'})) {
system("/usr/bin/diff -q $exports $exportsnew >/dev/null");
} else {
$outfile = "/tmp/exports_diff." . time();
system("/usr/bin/diff $exports $exportsnew >$outfile 2>&1");
}
if (! $?) {
# print "No changes to $exports; skipping ...\n";
unlink($outfile)
if ($outfile);
exit(0);
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment