all lists on lists.proxmox.com
 help / color / mirror / Atom feed
* [pve-devel] [PATCH storage 1/2] zfs: handle unexpectedly missing snapshots better
@ 2020-09-22  6:56 Fabian Grünbichler
  2020-09-22  6:56 ` [pve-devel] [PATCH storage 2/2] zfs: rollback: improve error message Fabian Grünbichler
  2020-09-23 13:11 ` [pve-devel] applied-series: [PATCH storage 1/2] zfs: handle unexpectedly missing snapshots better Thomas Lamprecht
  0 siblings, 2 replies; 3+ messages in thread
From: Fabian Grünbichler @ 2020-09-22  6:56 UTC (permalink / raw)
  To: pve-devel

Signed-off-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>
---
 PVE/Storage/ZFSPoolPlugin.pm | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/PVE/Storage/ZFSPoolPlugin.pm b/PVE/Storage/ZFSPoolPlugin.pm
index 10354b3..6fa9127 100644
--- a/PVE/Storage/ZFSPoolPlugin.pm
+++ b/PVE/Storage/ZFSPoolPlugin.pm
@@ -472,6 +472,10 @@ sub volume_rollback_is_possible {
     my ($class, $scfg, $storeid, $volname, $snap) = @_;
 
     my $recentsnap = $class->zfs_get_latest_snapshot($scfg, $volname);
+
+    die "can't rollback, no snapshots exist at all\n"
+	if !defined($recentsnap);
+
     if ($snap ne $recentsnap) {
 	die "can't rollback, more recent snapshots exist\n";
     }
-- 
2.20.1





^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2020-09-23 13:11 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-09-22  6:56 [pve-devel] [PATCH storage 1/2] zfs: handle unexpectedly missing snapshots better Fabian Grünbichler
2020-09-22  6:56 ` [pve-devel] [PATCH storage 2/2] zfs: rollback: improve error message Fabian Grünbichler
2020-09-23 13:11 ` [pve-devel] applied-series: [PATCH storage 1/2] zfs: handle unexpectedly missing snapshots better Thomas Lamprecht

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.
Service provided by Proxmox Server Solutions GmbH | Privacy | Legal