Upgrade PC and can no longer access shares

I upgraded my PC to Win 11 and now can no longer access the shares on my pc from pi.
I can SSH to the pi and I can ping the PC from the pi.
Uploaded log to: https://paste.osmc.tv/wehobuliwu

Any help would be appreciated.
Thanks

Windows 11 has deprecated older versions of SMB.

You should be able to get things working but is there a reason you are using such an old version of OSMC?

It was working with WIndows 10 on the older PC with that OSMC version. I had issues when I upgraded from that version so I reverted back and left it on that version.

Yes, Windows 11 has deprecated older versions of SMB, including SMBv1.
But you should be able to use a more modern version

Is there any way to get it working with the version I have ?

Not sure – we had two posts recently. One user downgraded to Windows 10 and one never got back to us.

This if from Windows 11. It looks like it does have SMBv2
Get-SmbServerConfiguration
AnnounceComment :
AnnounceServer : False
AsynchronousCredits : 64
AuditSmb1Access : False
AutoDisconnectTimeout : 15
AutoShareServer : True
AutoShareWorkstation : True
CachedOpenLimit : 0
DisableCompression : False
DisableSmbEncryptionOnSecureConnection : True
DurableHandleV2TimeoutInSeconds : 180
EnableAuthenticateUserSharing : False
EnableDirectoryHandleLeasing : True
EnableDownlevelTimewarp : False
EnableForcedLogoff : True
EnableLeasing : True
EnableMultiChannel : True
EnableOplocks : True
EnableSecuritySignature : False
EnableSMB1Protocol : False
EnableSMB2Protocol : True
EnableSMBQUIC : True
EnableStrictNameChecking : True
EncryptData : False
EncryptionCiphers : AES_128_GCM, AES_128_CCM, AES_256_GCM, AES_256_CCM
InvalidAuthenticationDelayTimeInMs : 0
IrpStackSize : 15
KeepAliveTime : 2
MaxChannelPerSession : 32
MaxMpxCount : 50
MaxSessionPerConnection : 16384
MaxThreadsPerQueue : 20
MaxWorkItems : 1
NullSessionPipes :
NullSessionShares :
OplockBreakWait : 35
PendingClientTimeoutInSeconds : 120
RejectUnencryptedAccess : True
RequestCompression : False
RequireSecuritySignature : False
RestrictNamedpipeAccessViaQuic : True
ServerHidden : True
Smb2CreditsMax : 2048
Smb2CreditsMin : 128
SmbServerNameHardeningLevel : 0
TreatHostAsStableStorage : False
ValidateAliasNotCircular : True
ValidateShareScope : True

Hopefully some Windows users can chime in – it’s been a long time for me

Sam

Using SMBv1 is not recommended due to security issues and more recent versions of OSMC will work with later versions of SMB fine so there is no need to use the old SMBv1 anymore.

If you really want to enable SMBv1 on Windows 11 (or Windows 10). Hit Start, then enter “optional features”. It should bring you to Settings->Apps->Optional features. Scroll down the list of features and click the last entry “More Windows features”. In the new dialog, enable “SMB 1.0/CIFS File Sharing Support”. Probably needs a restart to get active. Again, upgrading OSMC is the better option here.

I would suggest to use autofs based mounts and use path substitution if you don’t want to rescan your library that gives you long term stability

1 Like

I tried mounting shares using autofs. I followed the procedure listed.
and the line I added to /etc/auto.smb.shares was:

/mnt/Latest-Movies -fstype=cifs,rw,username=csent,password=chuck00,iocharset=utf8,uid=osmc,gid=osmc ://192.168.1.180/Latest-Movies

I did a Ctrl O and Ctrl X

Then restarted autofs:
sudo systemctl restart autofs

but when I went to check:
osmc@osmc:/mnt/csent$ cd /mnt/Latest-Movies
-bash: cd: /mnt/Latest-Movies: No such file or directory

Does the line I added have the correct syntax?

Looks right, did you used the troubleshooting advice to check if IP address and Share name is correct?

Here is the output that keeps scrolling on the screen. I can’t tell anything from this.

st_ready: st_ready(): state = 2 path /-
st_expire: state 1 path /-
expire_proc: exp_proc = 1946154064 path /-
expire_cleanup: got thid 1946154064 path /- stat 0
expire_cleanup: sigchld: exp 1946154064 finished, switching from 2 to 1
st_ready: st_ready(): state = 2 path /-
st_expire: state 1 path /-
expire_proc: exp_proc = 1946154064 path /-
expire_cleanup: got thid 1946154064 path /- stat 0
expire_cleanup: sigchld: exp 1946154064 finished, switching from 2 to 1

it also had:
mount_mount: mount(generic): calling mkdir_path /mnt/Latest-Movies
mount_mount: mount(generic): calling mount -t cifs -o rw,username=csent,password=chuck00,iocharset=utf8,uid=osmc,gid=osmc //192.168.1.180/Latest-Movies /mnt/Latest-Movies

mount error(112): Host is down
Refer to the mount.cifs(8) manual page (e.g. man mount.cifs)
mount(generic): failed to mount //192.168.1.180/Latest-Movies (type cifs) on /mnt/Latest-Movies

If it’s a SMBv1 protocol issue, you just have to re-enable this protocol in Windows11 to try. it’s obsolete but not totally removed.
Search the “Control Pannel”, “Programs and Functionnalities”, “Enable/Disable Windows Functionalities”, and search the “SMB 1.0 File Sharing Support” you will the Check the “SMB 1.0 Client” (to access a share)

On the pi, going into Kodi settings then services, the SMB client shows min version as none and max version as SMBv3.

I also tried adding vers=3.0 to the line in auto.smb.shares

/mnt/Latest-Movies -fstype=cifs,rw,vers=3.0,username=csent,password=chuck00,iocharset=utf8,uid=osmc,gid=osmc ://192.168.1.180/Latest-Movies

Are you sure you use the right IP address?
Suggest to install smbclient (sudo apt install smbclient ) and run the command:
smbclient -L 192.168.1.180

1 Like

I installed the smbclient:
6:33 AM samsclub: osmc@osmc:~$ sudo apt install smbclient
Reading package lists… Done
Building dependency tree
Reading state information… Done
The following additional packages will be installed:
libarchive13 libsmbclient libwbclient0 samba-common samba-libs
Suggested packages:
lrzip heimdal-clients
Recommended packages:
samba-common-bin
The following NEW packages will be installed:
libarchive13 samba-common smbclient
The following packages will be upgraded:
libsmbclient libwbclient0 samba-libs
3 upgraded, 3 newly installed, 0 to remove and 138 not upgraded.
Need to get 6034 kB of archives.
After this operation, 2192 kB of additional disk space will be used.
Do you want to continue? [Y/n]
6:34 AM samsclub: Do you want to continue? [Y/n] y
Get:1 http://security.debian.org buster/updates/main armhf libarchive13 armhf 3.3.3-4+deb10u2 [277 kB]
Get:2 Index of /debian buster/main armhf libsmbclient armhf 2:4.9.5+dfsg-5+deb10u3 [155 kB]
Get:3 Index of /debian buster/main armhf samba-libs armhf 2:4.9.5+dfsg-5+deb10u3 [4873 kB]
Get:4 Index of /debian buster/main armhf libwbclient0 armhf 2:4.9.5+dfsg-5+deb10u3 [129 kB]
Get:5 Index of /debian buster/main armhf samba-common all 2:4.9.5+dfsg-5+deb10u3 [171 kB]
Get:6 Index of /debian buster/main armhf smbclient armhf 2:4.9.5+dfsg-5+deb10u3 [429 kB]
Fetched 6034 kB in 2s (2606 kB/s)
Preconfiguring packages …
(Reading database … 26860 files and directories currently installed.)
Preparing to unpack …/0-libsmbclient_2%3a4.9.5+dfsg-5+deb10u3_armhf.deb …
Unpacking libsmbclient:armhf (2:4.9.5+dfsg-5+deb10u3) over (2:4.9.5+dfsg-5+deb10u1) …
Preparing to unpack …/1-samba-libs_2%3a4.9.5+dfsg-5+deb10u3_armhf.deb …
Unpacking samba-libs:armhf (2:4.9.5+dfsg-5+deb10u3) over (2:4.9.5+dfsg-5+deb10u1) …
Preparing to unpack …/2-libwbclient0_2%3a4.9.5+dfsg-5+deb10u3_armhf.deb …
Unpacking libwbclient0:armhf (2:4.9.5+dfsg-5+deb10u3) over (2:4.9.5+dfsg-5+deb10u1) …
Selecting previously unselected package samba-common.
Preparing to unpack …/3-samba-common_2%3a4.9.5+dfsg-5+deb10u3_all.deb …
Unpacking samba-common (2:4.9.5+dfsg-5+deb10u3) …
Selecting previously unselected package libarchive13:armhf.
Preparing to unpack …/4-libarchive13_3.3.3-4+deb10u2_armhf.deb …
Unpacking libarchive13:armhf (3.3.3-4+deb10u2) …
Selecting previously unselected package smbclient.
Preparing to unpack …/5-smbclient_2%3a4.9.5+dfsg-5+deb10u3_armhf.deb …
Unpacking smbclient (2:4.9.5+dfsg-5+deb10u3) …
Setting up libarchive13:armhf (3.3.3-4+deb10u2) …
Setting up samba-common (2:4.9.5+dfsg-5+deb10u3) …

Creating config file /etc/samba/smb.conf with new version
Setting up libwbclient0:armhf (2:4.9.5+dfsg-5+deb10u3) …
Setting up samba-libs:armhf (2:4.9.5+dfsg-5+deb10u3) …
Setting up libsmbclient:armhf (2:4.9.5+dfsg-5+deb10u3) …
Setting up smbclient (2:4.9.5+dfsg-5+deb10u3) …
Processing triggers for libc-bin (2.28-10) …
osmc@osmc:~$

osmc@osmc:~$ smbclient -W BEERCLUB1 -U csent -L 192.168.1.180
mkdir failed on directory /var/run/samba/msg.lock: Permission denied
Unable to initialize messaging context
Enter BEERCLUB1\csent’s password: BEERCLUB1\chuck00
session setup failed: NT_STATUS_CONNECTION_RESET
osmc@osmc:~$

Is it something on the PC end?
It’s not seeing the pi. They are both on DOMAIN:BEERCLUB1
C:\Windows\System32>net view /DOMAIN:BEERCLUB1
Server Name Remark


\SAMSCLUB-NEW samsclub-new
The command completed successfully.

This was with Windows firewall turned off.

I can ping the pi from the PC
I can ping the PC from the pi

What gives

sudo smbclient -U=csent -L 192.168.1.180 -m SMB2

and

sudo smbclient -U=csent -L 192.168.1.180 -m SMB3

?

They both come back the same:
osmc@osmc:~$ sudo smbclient -U csent -L 192.168.1.180 -m SMB3
Unable to initialize messaging context!

osmc@osmc:~$ smbclient -W BEERCLUB1 -U csent -L 192.168.1.180
mkdir failed on directory /var/lib/samba/private/msg.sock: Permission denied
Unable to initialize messaging context
Enter BEERCLUB1\csent’s password:
session setup failed: NT_STATUS_LOGON_FAILURE

This sounds like a system which wasn’t updated since ages. Not sure, we’re seeing issues already solved long time ago?