[pve-devel] [PATCH ceph 2/2] fix Ceph version string handling

Martin Verges martin.verges at croit.io
Tue Jan 7 17:12:13 CET 2020


Signed-off-by: Martin Verges <martin.verges at croit.io>
---
 PVE/Ceph/Tools.pm | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/PVE/Ceph/Tools.pm b/PVE/Ceph/Tools.pm
index e6225b78..c6259a4e 100644
--- a/PVE/Ceph/Tools.pm
+++ b/PVE/Ceph/Tools.pm
@@ -56,7 +56,7 @@ sub get_local_version {
 	);
 	return undef if !defined $ceph_version;
 
-	if ($ceph_version =~ /^ceph.*\s(\d+(?:\.\d+)+(?:-pve\d+)?)\s+(?:\(([a-zA-Z0-9]+)\))?/) {
+	if ($ceph_version =~ /^ceph.*\s(\d+(?:\.\d+)+(?:-[^\s]+)?)\s+(?:\(([a-zA-Z0-9]+)\))?/) {
 	    my ($version, $buildcommit) = ($1, $2);
 	    my $subversions = [ split(/\.|-/, $version) ];
 
-- 
2.20.1



More information about the pve-devel mailing list