Can't mount smb share in storage but can mount it via CLI

Fazio8

New Member
Jan 9, 2023
17
1
3
Hello,
I was trying to add a samba share (file sharing via macOS, guest in my Proxmox cluster).
I tried to add the SMB share via storage menu on datacenter, but I got error 500:

Code:
create storage failed: storage 'icloud' is not online

If I try to mount it manually using pvesm:
Code:
root@NUC1:/mnt# pvesm add cifs -server 192.168.1.28 -username XXX -password XXXX -share XXXX smb-test
create storage failed: storage 'smb-test' is not online
I have this error on my 3 nodes, I tried to use the FQDN, IP, smbversion 2/3/3.11, declaring the domain WORKGROUP but still same error.

Lastly, as workaround, I manually mounted the share via mount command successfully:

Code:
root@NUC1:/mnt# mount -t cifs -o rw,credentials=/root/.smbicloud //mac/iCloudShare /mnt/icloud-smb/
root@NUC1:/mnt# ls
hd_usb  icloud-smb  vzsnap0
root@NUC1:/mnt# cd icloud-smb/
root@NUC1:/mnt/icloud-smb# ls
 linux  'Nuovo documento di testo.txt'

In this way I'm able to mount the share to LXC directly.
Any hint on why I'm unable to mount the share via pvesm? I don't think there are issues with the share or its configuration since I'm able to mount it via mount.

Thanks!
 
Hello,
I was trying to add a samba share (file sharing via macOS, guest in my Proxmox cluster).
I tried to add the SMB share via storage menu on datacenter, but I got error 500:

Code:
create storage failed: storage 'icloud' is not online

If I try to mount it manually using pvesm:
Code:
root@NUC1:/mnt# pvesm add cifs -server 192.168.1.28 -username XXX -password XXXX -share XXXX smb-test
create storage failed: storage 'smb-test' is not online
I have this error on my 3 nodes, I tried to use the FQDN, IP, smbversion 2/3/3.11, declaring the domain WORKGROUP but still same error.

Lastly, as workaround, I manually mounted the share via mount command successfully:

Code:
root@NUC1:/mnt# mount -t cifs -o rw,credentials=/root/.smbicloud //mac/iCloudShare /mnt/icloud-smb/
root@NUC1:/mnt# ls
hd_usb  icloud-smb  vzsnap0
root@NUC1:/mnt# cd icloud-smb/
root@NUC1:/mnt/icloud-smb# ls
 linux  'Nuovo documento di testo.txt'

In this way I'm able to mount the share to LXC directly.
Any hint on why I'm unable to mount the share via pvesm? I don't think there are issues with the share or its configuration since I'm able to mount it via mount.

Thanks!
Hi,
are you able to see shares when running pvesm scan cifs 192.168.1.28 --username XXX --password XXXX
 
Hi,
are you able to see shares when running pvesm scan cifs 192.168.1.28 --username XXX --password XXXX
Yes
Code:
root@NUC1:/# pvesm scan cifs mac -username user-password pass
Folder
username
sharename
 
Yes
Code:
root@NUC1:/# pvesm scan cifs mac -username user-password pass
Folder
username
sharename
In that case pvesm add cifs smb-icloud --server 192.168.1.28 --share iCloudShare --username XXX --password XXXX should work, given that you use the same credentials as when mounting the share directly. Only reason i can think of is that maybe your password contains characters which are interpreted by the shell. On the other hand, it also fails when trying to connect via the WebUI.

Edit: Also, whats your pveversion -v?
 
Last edited:
Nada unfortunately, the password is just "r00t" as for testing purpose:

Code:
root@NUC1:~# pvesm add cifs smb-icloud --server 192.168.1.28 --share iCloudShare --username username --password r00t
create storage failed: storage 'smb-icloud' is not online
root@NUC1:~# pveversion -v
proxmox-ve: 7.3-1 (running kernel: 5.15.83-1-pve)
pve-manager: 7.3-6 (running version: 7.3-6/723bb6ec)
pve-kernel-helper: 7.3-4
pve-kernel-5.15: 7.3-2
pve-kernel-5.15.85-1-pve: 5.15.85-1
pve-kernel-5.15.83-1-pve: 5.15.83-1
pve-kernel-5.15.74-1-pve: 5.15.74-1
ceph-fuse: 15.2.17-pve1
corosync: 3.1.7-pve1
criu: 3.15-1+pve-1
glusterfs-client: 9.2-1
ifupdown2: 3.1.0-1+pmx3
ksm-control-daemon: 1.4-1
libjs-extjs: 7.0.0-1
libknet1: 1.24-pve2
libproxmox-acme-perl: 1.4.3
libproxmox-backup-qemu0: 1.3.1-1
libpve-access-control: 7.3-1
libpve-apiclient-perl: 3.2-1
libpve-common-perl: 7.3-2
libpve-guest-common-perl: 4.2-3
libpve-http-server-perl: 4.1-5
libpve-storage-perl: 7.3-2
libspice-server1: 0.14.3-2.1
lvm2: 2.03.11-2.1
lxc-pve: 5.0.2-1
lxcfs: 5.0.3-pve1
novnc-pve: 1.3.0-3
proxmox-backup-client: 2.3.3-1
proxmox-backup-file-restore: 2.3.3-1
proxmox-mail-forward: 0.1.1-1
proxmox-mini-journalreader: 1.3-1
proxmox-widget-toolkit: 3.5.5
pve-cluster: 7.3-2
pve-container: 4.4-2
pve-docs: 7.3-1
pve-edk2-firmware: 3.20220526-1
pve-firewall: 4.2-7
pve-firmware: 3.6-3
pve-ha-manager: 3.5.1
pve-i18n: 2.8-2
pve-qemu-kvm: 7.1.0-4
pve-xtermjs: 4.16.0-1
qemu-server: 7.3-3
smartmontools: 7.2-pve3
spiceterm: 3.2-2
swtpm: 0.8.0~bpo11+2
vncterm: 1.7-1
zfsutils-linux: 2.1.9-pve1

Same behavior of all my 3 nodes.
 
Could you try to check if /usr/bin/smbclient //192.168.1.28/iCloudShare -U <username>%<password> -d 0 -c 'echo 1 0' this works for you? This is more or less the logic used to check the connection to the share.
 
Could you try to check if /usr/bin/smbclient //192.168.1.28/iCloudShare -U <username>%<password> -d 0 -c 'echo 1 0' this works for you? This is more or less the logic used to check the connection to the share.
Hello, this is failing:

Code:
echo failed: NT_STATUS_CONNECTION_DISCONNECTED
 
Hello, this is failing:

Code:
echo failed: NT_STATUS_CONNECTION_DISCONNECTED
That is because of the failed protocol negotiation, can you try also with -m SMB3?

Edit: no wait, I was to fast in interpreting the message... it fails because the echo command fails. Try to execute just/usr/bin/smbclient //192.168.1.28/iCloudShare -U <username>%<password>. This should give you a shell, there try to run echo 1 0 and post the output of help echo.
 
Last edited:
It’s strange, for a nanosecond the sub shell was ok and then!
Code:
root@NUC1:~# /usr/bin/smbclient //192.168.1.28/iCloudShare -U user%r00t
Try "help" to get a list of possible commands.
smb: \> SMBecho failed (NT_STATUS_CONNECTION_DISCONNECTED). The connection is disconnected now
 
Not directly related, but what is hosting the SMB?

Tmanok
It's macOS Ventura, using File Sharing features (Windows support enabled).
For sake of completeness, the share is working properly on Windows and Linux hosts. I just have issues on mounting it inside PVE (in PVE I can mount it with mount -t cifs).
 
It’s strange, for a nanosecond the sub shell was ok and then!
Code:
root@NUC1:~# /usr/bin/smbclient //192.168.1.28/iCloudShare -U user%r00t
Try "help" to get a list of possible commands.
smb: \> SMBecho failed (NT_STATUS_CONNECTION_DISCONNECTED). The connection is disconnected now
Seems like the smb server is closing the connection for some reason. Do you have some insights (logs/debug output) on the server site which might indicate why the connection closed?

But yes, this is the reason why PVE does not accept the share as storage, because it looses the connection to the smb server when trying to echo, so it seems offline.
 
Seems like the smb server is closing the connection for some reason. Do you have some insights (logs/debug output) on the server site which might indicate why the connection closed?

But yes, this is the reason why PVE does not accept the share as storage, because it looses the connection to the smb server when trying to echo, so it seems offline.
I'll check if there's any log on the server side.
However, it is correct that pvesm is failing, whilst the storage is working if mounted via mount command?
Thanks!
 
However, it is correct that pvesm is failing, whilst the storage is working if mounted via mount command?
Well, this is how PVE checks if the storage is online, so yes. The echo command should work for all standard smb implementations, afaik.
 
  • Like
Reactions: Tmanok

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!