Hi all, We're having trouble with Macintosh clients (at least) being disconnected from Samba. Below is one macintosh console output when this happens, filtered by "smb". (Yeah, maybe some clues are missing...) ATM I don't see anything that stands out in the Samba log file. However one thing I don't see in the samba log file is session disconnects. Does anyone know how to log disconnects? I've found one such way on stackexchange involving 'postexec' https://unix.stackexchange.com/a/478881/275843, but I thought maybe there was a log subsection and level which would also work. (I don't want to set log 10 b/c that would generate so much log file it would either fill the drive or get rotated out.) Thanks! Chad. apt-cache policy samba samba: Installed: 2:4.9.5+dfsg-5+deb10u1 macintosh client console filtered with word "smb": 12/18/19 8:14:42.000 AM kernel[0]: smbfs_down: Remounting smb.physics.wisc.edu/SMB 12/18/19 8:14:42.000 AM kernel[0]: smb2_smb_parse_change_notify: smb_rq_reply failed 60 12/18/19 8:14:42.000 AM kernel[0]: smb2_smb_parse_change_notify: smb_rq_reply failed 60 12/18/19 8:14:42.000 AM kernel[0]: smb2_smb_parse_change_notify: smb_rq_reply failed 60 12/18/19 8:14:42.000 AM kernel[0]: smb2_smb_parse_change_notify: smb_rq_reply failed 60 12/18/19 8:14:42.000 AM kernel[0]: smb2_smb_parse_change_notify: smb_rq_reply failed 60 12/18/19 8:14:42.775 AM smbremountserver[23160]: isReferralPathNotCovered Dfs Check path on /smb.physics.wisc.edu/smb return ntstatus = 0xc000000d, syserr = Invalid argument 12/18/19 8:15:39.000 AM kernel[0]: smb2_rq_sign: No session key for signing. 12/18/19 8:15:40.000 AM kernel[0]: smbfs_vnop_strategy: READ on 4867_rylander_timesheet_2016.xlsx failed with an error of 57 12/18/19 8:15:40.000 AM kernel[0]: smbfs_lookup: Server failed Query Info 57 12/18/19 8:15:40.403 AM KernelEventAgent[101]: tid 54485244 type 'smbfs', mounted on '/Volumes/smb', from '//lefkow at smb.physics.wisc.edu/smb', dead 12/18/19 8:15:40.403 AM KernelEventAgent[101]: tid 54485244 force unmount //lefkow at smb.physics.wisc.edu/smb from /Volumes/smb 12/18/19 8:15:40.455 AM deleted[2105]: volumeFreespace:548 statfs failed for /Volumes/smb : No such file or directory 12/18/19 8:15:40.456 AM deleted[2105]: normalizeUserMountpoint:791 volRoot failed for /Volumes/smb 12/18/19 8:15:40.456 AM deleted[2105]: _validateVolume:813 unable to normalize volume: "/Volumes/smb", vol: (null) 12/18/19 8:15:40.458 AM deleted[2105]: volumeFreespace:548 statfs failed for /Volumes/smb : No such file or directory 12/18/19 8:15:40.458 AM deleted[2105]: normalizeUserMountpoint:791 volRoot failed for /Volumes/smb 12/18/19 8:15:40.458 AM deleted[2105]: _validateVolume:813 unable to normalize volume: "/Volumes/smb", vol: (null) 12/18/19 8:15:40.471 AM deleted[2105]: volumeFreespace:548 statfs failed for /Volumes/smb : No such file or directory 12/18/19 8:15:40.471 AM deleted[2105]: normalizeUserMountpoint:791 volRoot failed for /Volumes/smb 12/18/19 8:15:40.471 AM deleted[2105]: _validateVolume:813 unable to normalize volume: "/Volumes/smb", vol: (null) 12/18/19 8:15:40.547 AM TMCacheDelete[2183]: Couldn't get resource value 'NSURLVolumeIsLocalKey' for 'file:///Volumes/smb/': Error Domain=NSCocoaErrorDomain Code=4 "The file ?smb? doesn?t exist." UserInfo={NSURL=file:///Volumes/smb/, NSFilePath=/Volumes/smb} 12/18/19 8:15:40.548 AM deleted[2105]: volumeFreespace:548 statfs failed for /Volumes/smb : No such file or directory 12/18/19 8:15:40.548 AM deleted[2105]: normalizeUserMountpoint:791 volRoot failed for /Volumes/smb 12/18/19 8:15:40.548 AM deleted[2105]: _validateVolume:813 unable to normalize volume: "/Volumes/smb", vol: (null) 12/18/19 8:15:40.568 AM deleted[2105]: normalizeUserMountpoint:791 volRoot failed for /Volumes/smb 12/18/19 8:15:40.568 AM deleted[2105]: _validateVolume:813 unable to normalize volume: "/Volumes/smb", vol: (null) 12/18/19 8:15:40.568 AM deleted[2105]: -[CacheDeleteOperation initWithInfo:services:]:33 Unable to validate volume: /Volumes/smb 12/18/19 8:15:40.547 AM TMCacheDelete[2183]: Couldn't get resource value 'NSURLVolumeIsLocalKey' for 'file:///Volumes/smb/': Error Domain=NSCocoaErrorDomain Code=4 "The file ?smb? doesn?t exist." UserInfo={NSURL=file:///Volumes/smb/, NSFilePath=/Volumes/smb} I'm having trouble with Macintosh clients being disconnected https://unix.stackexchange.com/a/478881/275843
On 23/12/2019 18:06, Chad W Seys via samba wrote:> Hi all, > We're having trouble with Macintosh clients (at least) being > disconnected from Samba. Below is one macintosh console output when > this happens, filtered by "smb". (Yeah, maybe some clues are missing...) > ATM I don't see anything that stands out in the Samba log file. > However one thing I don't see in the samba log file is session disconnects. > Does anyone know how to log disconnects? I've found one such way on > stackexchange involving 'postexec' > https://unix.stackexchange.com/a/478881/275843, but I thought maybe > there was a log subsection and level which would also work. (I don't > want to set log 10 b/c that would generate so much log file it would > either fill the drive or get rotated out.) > > Thanks! > Chad. > > apt-cache policy samba > samba: > Installed: 2:4.9.5+dfsg-5+deb10u1 > > macintosh client console filtered with word "smb": > > 12/18/19 8:14:42.000 AM kernel[0]: smbfs_down: Remounting > smb.physics.wisc.edu/SMB > 12/18/19 8:14:42.000 AM kernel[0]: smb2_smb_parse_change_notify: > smb_rq_reply failed 60 > 12/18/19 8:14:42.000 AM kernel[0]: smb2_smb_parse_change_notify: > smb_rq_reply failed 60 > 12/18/19 8:14:42.000 AM kernel[0]: smb2_smb_parse_change_notify: > smb_rq_reply failed 60 > 12/18/19 8:14:42.000 AM kernel[0]: smb2_smb_parse_change_notify: > smb_rq_reply failed 60 > 12/18/19 8:14:42.000 AM kernel[0]: smb2_smb_parse_change_notify: > smb_rq_reply failed 60 > 12/18/19 8:14:42.775 AM smbremountserver[23160]: > isReferralPathNotCovered Dfs Check path on /smb.physics.wisc.edu/smb > return ntstatus = 0xc000000d, syserr = Invalid argument > 12/18/19 8:15:39.000 AM kernel[0]: smb2_rq_sign: No session key for signing. > 12/18/19 8:15:40.000 AM kernel[0]: smbfs_vnop_strategy: READ on > 4867_rylander_timesheet_2016.xlsx failed with an error of 57 > 12/18/19 8:15:40.000 AM kernel[0]: smbfs_lookup: Server failed Query Info 57 > 12/18/19 8:15:40.403 AM KernelEventAgent[101]: tid 54485244 type > 'smbfs', mounted on '/Volumes/smb', from > '//lefkow at smb.physics.wisc.edu/smb', dead > 12/18/19 8:15:40.403 AM KernelEventAgent[101]: tid 54485244 force > unmount //lefkow at smb.physics.wisc.edu/smb from /Volumes/smb > 12/18/19 8:15:40.455 AM deleted[2105]: volumeFreespace:548 statfs failed > for /Volumes/smb : No such file or directory > 12/18/19 8:15:40.456 AM deleted[2105]: normalizeUserMountpoint:791 > volRoot failed for /Volumes/smb > 12/18/19 8:15:40.456 AM deleted[2105]: _validateVolume:813 unable to > normalize volume: "/Volumes/smb", vol: (null) > 12/18/19 8:15:40.458 AM deleted[2105]: volumeFreespace:548 statfs failed > for /Volumes/smb : No such file or directory > 12/18/19 8:15:40.458 AM deleted[2105]: normalizeUserMountpoint:791 > volRoot failed for /Volumes/smb > 12/18/19 8:15:40.458 AM deleted[2105]: _validateVolume:813 unable to > normalize volume: "/Volumes/smb", vol: (null) > 12/18/19 8:15:40.471 AM deleted[2105]: volumeFreespace:548 statfs failed > for /Volumes/smb : No such file or directory > 12/18/19 8:15:40.471 AM deleted[2105]: normalizeUserMountpoint:791 > volRoot failed for /Volumes/smb > 12/18/19 8:15:40.471 AM deleted[2105]: _validateVolume:813 unable to > normalize volume: "/Volumes/smb", vol: (null) > 12/18/19 8:15:40.547 AM TMCacheDelete[2183]: Couldn't get resource value > 'NSURLVolumeIsLocalKey' for 'file:///Volumes/smb/': Error > Domain=NSCocoaErrorDomain Code=4 "The file ?smb? doesn?t exist." > UserInfo={NSURL=file:///Volumes/smb/, NSFilePath=/Volumes/smb} > 12/18/19 8:15:40.548 AM deleted[2105]: volumeFreespace:548 statfs failed > for /Volumes/smb : No such file or directory > 12/18/19 8:15:40.548 AM deleted[2105]: normalizeUserMountpoint:791 > volRoot failed for /Volumes/smb > 12/18/19 8:15:40.548 AM deleted[2105]: _validateVolume:813 unable to > normalize volume: "/Volumes/smb", vol: (null) > 12/18/19 8:15:40.568 AM deleted[2105]: normalizeUserMountpoint:791 > volRoot failed for /Volumes/smb > 12/18/19 8:15:40.568 AM deleted[2105]: _validateVolume:813 unable to > normalize volume: "/Volumes/smb", vol: (null) > 12/18/19 8:15:40.568 AM deleted[2105]: -[CacheDeleteOperation > initWithInfo:services:]:33 Unable to validate volume: /Volumes/smb > > 12/18/19 8:15:40.547 AM TMCacheDelete[2183]: Couldn't get resource value > 'NSURLVolumeIsLocalKey' for 'file:///Volumes/smb/': Error > Domain=NSCocoaErrorDomain Code=4 "The file ?smb? doesn?t exist." > UserInfo={NSURL=file:///Volumes/smb/, NSFilePath=/Volumes/smb} > > I'm having trouble with Macintosh clients being disconnected > https://unix.stackexchange.com/a/478881/275843It looks like it cannot find/see the share, how are you running Samba ? Can you please post your smb.conf. Rowland
On 2019-12-23 19:06, Chad W Seys via samba wrote:> Hi all, > We're having trouble with Macintosh clients (at least) being > disconnected from Samba.Hello. I'm seeing them too (see my messages from a few days ago).> However one thing I don't see in the samba log file is session disconnects.Neither do I. I've skimmed briefly a level 10 log and didn't see anything useful, but I'd need to look better before I state this for sure. However I see smbd crashing on notifications and I'm still investigating why and whether the two things are related. Do you also see crashes? Also when did this start? Did you do some upgrade? Did it work before? In my case it started when I moved shares from a base 4.8 installation to a jailed 4.10. bye & Thanks av.
Hi Andrea,> Neither do I. > I've skimmed briefly a level 10 log and didn't see anything useful, but > I'd need to look better before I state this for sure.The preexec / postexec hooks mentioned at https://unix.stackexchange.com/a/478881/275843 work well for this. I see Mac clients disconnecting when they have problems, but haven't yet correlated that occurrence to anything suspicous in the log.smbd file yet.> However I see smbd crashing on notifications and I'm still investigating > why and whether the two things are related. > Do you also see crashes?I haven't noticed this. What do you look for to find this?> > Also when did this start? > Did you do some upgrade? > Did it work before?These questions are hard to answer. I have the suspicion that there is more than one problem going on AND my end users have just lived with it for awhile. I need to do more testing before I have enough to go on before using someone like Rowland's time. :) For example, one failure mode is that sometimes macOS (10.13 ,10.15, ?) will block access to paths hosted by Samba. It is most easily reproducible if a DFS link is involved. So far I know this happens with Samba 4.9.17, 4.10.11, and 4.11.4 . Try searching for "finder" and "sandbox" in Console of a Macintosh which is having problems. Press "return" after each term so you're not searchign for "finder sandbox" but "finder" AND "sandbox". Eventually I'll submit a bug report on that, but need to write it up. That is not the only problem however. Chad.