[pve-devel] applied: [Patch storage] use mkdir option in CIFS instead always create dir
Thomas Lamprecht
t.lamprecht at proxmox.com
Thu Jun 14 07:55:11 CEST 2018
On 6/13/18 1:21 PM, Wolfgang Link wrote:
> see commit c7616abcb278e2b888febc082b557f60676fc376
> ---
> PVE/Storage/CIFSPlugin.pm | 3 ++-
> 1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/PVE/Storage/CIFSPlugin.pm b/PVE/Storage/CIFSPlugin.pm
> index ff24c8d..ffd16e3 100644
> --- a/PVE/Storage/CIFSPlugin.pm
> +++ b/PVE/Storage/CIFSPlugin.pm
> @@ -126,6 +126,7 @@ sub options {
> password => { optional => 1},
> domain => { optional => 1},
> smbversion => { optional => 1},
> + mkpath => {optional => 1 },
s/mkpath/mkdir/
I fixed this up to mkdir, as the option is called, directly in the
applied commit...
> };
> }
>
> @@ -168,7 +169,7 @@ sub activate_storage {
>
> if (!cifs_is_mounted($server, $share, $path, $cache->{mountdata})) {
>
> - mkpath $path;
> + mkpath $path if !(defined($scfg->{mkdir}) && !$scfg->{mkdir});
>
> die "unable to activate storage '$storeid' - " .
> "directory '$path' does not exist\n" if ! -d $path;
>
More information about the pve-devel
mailing list