projects
/
sysadmin-cookbook
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
00ffed0
)
zfs list -t snapshot fix for newer zfs versions which don't return snapshots by default
author
Dobrica Pavlinusic
<dpavlin@rot13.org>
Thu, 26 May 2011 18:22:29 +0000
(18:22 +0000)
committer
Dobrica Pavlinusic
<dpavlin@rot13.org>
Thu, 26 May 2011 18:22:29 +0000
(18:22 +0000)
git-svn-id: svn://svn.rot13.org/sysadmin-cookbook@263
191e9f34
-6774-4a6d-acfc-
7664dacd4a2a
recepies/zfs/zfs-expire-snapshot.pl
patch
|
blob
|
history
diff --git
a/recepies/zfs/zfs-expire-snapshot.pl
b/recepies/zfs/zfs-expire-snapshot.pl
index
2b1fa0f
..
82b56fc
100755
(executable)
--- a/
recepies/zfs/zfs-expire-snapshot.pl
+++ b/
recepies/zfs/zfs-expire-snapshot.pl
@@
-6,7
+6,7
@@
use strict;
use DateTime;
use Data::Dump qw/dump/;
-my $debug = 0;
+my $debug =
$ENV{DEBUG} ||
0;
my $config = {
'default' => {
@@
-28,7
+28,7
@@
my $now = DateTime->now();
my $last_backup;
-open(my $fs, '-|', 'zfs list -H');
+open(my $fs, '-|', 'zfs list -
t snapshot -
H');
while(<$fs>) {
chomp;
my ( $name, $used, $avail, $refer, $mountpoint ) = split(/\t/,$_,6);