]> git.proxmox.com Git - pve-container.git/commitdiff
provide a better error message for rbd without krbd
authorWolfgang Bumiller <w.bumiller@proxmox.com>
Mon, 11 Jul 2016 10:19:14 +0000 (12:19 +0200)
committerFabian Grünbichler <f.gruenbichler@proxmox.com>
Mon, 11 Jul 2016 10:21:29 +0000 (12:21 +0200)
src/PVE/LXC.pm

index caadce11d2b03d4d2c04050354cacd53b4e92f9c..6cd4c719a6013b048f088ac4548ff972acf1e4b9 100644 (file)
@@ -1175,6 +1175,12 @@ sub mountpoint_mount {
     if ($storage) {
 
        my $scfg = PVE::Storage::storage_config($storage_cfg, $storage);
+
+       # early sanity checks:
+       # we otherwise call realpath on the rbd url
+       die "containers on rbd storage without krbd are not supported\n"
+           if $scfg->{type} eq 'rbd' && !$scfg->{krbd};
+
        my $path = PVE::Storage::path($storage_cfg, $volid, $snapname);
 
        my ($vtype, undef, undef, undef, undef, $isBase, $format) =