[Zetaback-devel] [zetaback commit] r179 - branches/sendr

svn-commit at lists.omniti.com svn-commit at lists.omniti.com
Thu Mar 10 18:13:00 EST 2011


Author: mark
Date: 2011-03-10 18:13:00 -0500 (Thu, 10 Mar 2011)
New Revision: 179

Modified:
   branches/sendr/zetaback_agent.in
Log:
Apply performance improvements to zetaback_agent.in from Digital Measures

Modified: branches/sendr/zetaback_agent.in
===================================================================
--- branches/sendr/zetaback_agent.in	2011-03-10 22:28:38 UTC (rev 178)
+++ branches/sendr/zetaback_agent.in	2011-03-10 23:13:00 UTC (rev 179)
@@ -327,19 +327,19 @@
 
 sub zfs_agent_list {
   my %zfs;
-  open(ZFSLIST, "__ZFS__ list -H -t snapshot,filesystem,volume |");
+  open(ZFSLIST, "__ZFS__ list -H -o name,com.omniti.labs.zetaback:exclude -t snapshot,filesystem,volume |");
   while(<ZFSLIST>) {
     chomp;
     my @line = split /\t/;
-    (my $fs = $line[0]) =~ s/\@.+//;
-    my $excl = (split(/\s+/,`__ZFS__ get -H com.omniti.labs.zetaback:exclude $fs`))[2];
-    if(($excl ne "on") && ($fs =~ /$conf{pattern}/)) {
-      my $fsname = $line[0];
-      my $snapname = "";
-      if($line[0] =~ /(\S+)\@([^\@]+)$/) {
-        $fsname = $1;
-        $snapname = $2;
-      }
+    my $fsname = $line[0];
+    my $snapname = "";
+    if($line[0] =~ /(\S+)\@([^\@]+)$/) {
+      $fsname = $1;
+      $snapname = $2;
+    }
+    my $excl = $line[1];
+
+    if(($excl ne "on") && ($fsname =~ /$conf{pattern}/)) {
       if ($DSET_RECURSE) {
         # We don't display child filesystems if the parent has already been
         # listed and we are using zfs send -R



More information about the Zetaback-devel mailing list