]> git.proxmox.com Git - pve-storage.git/blobdiff - PVE/Storage/CIFSPlugin.pm
drbd: comment that the builtin plugin is depreacated
[pve-storage.git] / PVE / Storage / CIFSPlugin.pm
index 72ec757b0beb7885e43f9ff5623947c3ccc474ab..be06cc761e4e7244358ce72379ef50d7e2a93edd 100644 (file)
@@ -134,6 +134,7 @@ sub options {
        nodes => { optional => 1 },
        disable => { optional => 1 },
        maxfiles => { optional => 1 },
+       'prune-backups' => { optional => 1 },
        content => { optional => 1 },
        format => { optional => 1 },
        username => { optional => 1 },
@@ -167,6 +168,8 @@ sub on_add_hook {
     } else {
        cifs_delete_credentials($storeid);
     }
+
+    return;
 }
 
 sub on_update_hook {
@@ -182,12 +185,16 @@ sub on_update_hook {
     } else {
        cifs_delete_credentials($storeid);
     }
+
+    return;
 }
 
 sub on_delete_hook {
     my ($class, $storeid, $scfg) = @_;
 
     cifs_delete_credentials($storeid);
+
+    return;
 }
 
 sub status {
@@ -261,14 +268,12 @@ sub check_connection {
     } else {
        push @$cmd, '-U', 'Guest','-N';
     }
-
     push @$cmd, '-c', 'echo 1 0';
 
     my $out_str;
-    eval {
-       run_command($cmd, timeout => 2, outfunc => sub {$out_str .= shift;},
-                   errfunc => sub {});
-    };
+    my $out = sub { $out_str .= shift };
+
+    eval { run_command($cmd, timeout => 10, outfunc => $out, errfunc => sub {}) };
 
     if (my $err = $@) {
        die "$out_str\n" if defined($out_str) &&
@@ -279,4 +284,13 @@ sub check_connection {
     return 1;
 }
 
+sub get_volume_notes {
+    my $class = shift;
+    PVE::Storage::DirPlugin::get_volume_notes($class, @_);
+}
+sub update_volume_notes {
+    my $class = shift;
+    PVE::Storage::DirPlugin::update_volume_notes($class, @_);
+}
+
 1;