What's new

Samba Issue

  • SNBForums Code of Conduct

    SNBForums is a community for everyone, no matter what their level of experience.

    Please be tolerant and patient of others, especially newcomers. We are all here to share and learn!

    The rules are simple: Be patient, be nice, be helpful or be gone!

marksb

New Around Here
I have been having an issue with my Sonos speaker having trouble connecting to a drive connected to my AC88U. I have my iTunes library stored there and added that same location to the Sonos Music Library. The Mac never has an issue connecting and accessing the files.

When I look in the log, I see this message

mb2_validate_message_id: client used more credits than granted, mid 1025, credits_granted 0, seqnum low/range: 1025/0

If I go to the Samba page on the web interface to the router and just press the apply button, the speaker is able to play the songs fine. Next time I try I get the same error again.

Has anyone else experienced anything like this? This is a recent development in the last couple of months so I don't know if it is an Asus or a Sonos issue. Thanks for any help
 
Uhh, I'm having exactly the same issues with Sonos. But i have official Asus firmware.
I mangaed to add the file path to USB Drive after a few attempts. But when I add more songs and then rescan the HDD library, Sonos says it cannot see the \\.... However, after a few days it managed to rescan the library.

Asus log had the same error as explained by the topic starter.

Can anybody help with this?
 
Last edited:
As I understand it, it is the clients responsibility to request a sufficient number of credits (the number of future expected simultaneous connections) from the server. It's also the client's responsibility to increase that request when required. I suspect this is a problem more with your Sonos speaker than it is with Asus. That said, Samba on Merlin (at least my AC86U) is Version 3, so there may be issues with how that version in managing credits.
 
Thanks Jeffrey. Quite possible, because all Sonos products use SMB1.
If you are on Sonos S2 version 14+, the products are now also Samba 2 capable. Even with this update, I still have connection issues.
 
If you are on Sonos S2 version 14+, the products are now also Samba 2 capable. Even with this update, I still have connection issues.
Have you formated the USB drive using the router "format usb drive" option? I have Sonos v1, btw.
 
Thanks ninjabob & Igs. I've had both authentication and access errors since Sonos version 8.4, when SMB1 was the only option.

Formatting the USB stick, resetting sonos, adjusting SMB1 and 2 settings, sometimes work, temporarily. Invariably instabilities arise within a month. This is the first time I've seen consistent reporting of the error noted by the OP. A discussion has been started here -- https://en.community.sonos.com/music-services-and-sources-228994/asus-rt-routers-samba-6871630
 
Last edited:
If you folks want to troubleshoot this further, I would recommend using a /jffs/scrips/smb.postconf and replace the current log level = 0 in the /e t c/smb.conf file to something more verbose.
 
I have upp'ed my Samba connections to 99 through the GUI with the latest update (386.7), and enabled multicast as recommended on the Sonos forums.

If you folks want to troubleshoot this further, I would recommend using a /jffs/scrips/smb.postconf and replace the current log level = 0 in the /e t c/smb.conf file to something more verbose.

What's a good log level number? I see the log level is zero in smb.conf... how do I add the change to smb.postconf? Right now there are no files in /jffs/scripts
 
Last edited:
I have upp'ed my Samba connections to 99 through the GUI with the latest update (386.7), and enabled multicast as recommended on the Sonos forums.



What's a good log level number? I see the log level is zero in smb.conf... how do I add the change to smb.postconf? Right now there are no files in /jffs/scripts

You need to build your own /jffs/scripts/smb.postconf script using nano or vi. The content of the script would be something like;

Code:
#!/bin/sh
CONFIG=$1
source /usr/sbin/helper.sh

pc_replace "log level = 0" "log level = 3" $CONFIG

Don't forget to make the file executable

Using Custom Config Scripts
 
Thanks gents. I added the script (+x) into jffs/scripts, no change in output in the log file:
Code:
Jul  9 11:09:49 smbd[6192]: [2022/07/09 11:09:49.601964,  0] smbd/smb2_server.c:401(smb2_validate_message_id)
Jul  9 11:09:49 smbd[6192]:   smb2_validate_message_id: client used more credits than granted, mid 1025, credits_granted 0, seqnum low/range: 1025/0

And this is the same Sonos System Error Log pull from the Window's app:
Code:
Saturday, July 9, 2022 - 11:09 AM
'//RT-AC68U-SAMBA/MP3's/Main' is no longer available. The device where the music files are stored may not be powered on, or the path may have changed.
Go to Settings > System > Music Library > Music Library Setup to check the path.

** Note, that other locations down the same directory tree and physical drive read OK, e.g. '//RT-AC68U-SAMBA/MP3's/Latest' **

After a reboot, /etc/smb.conf still shows:
Code:
admin@RT-AC68U-1040:/tmp/etc# cat smb.conf  | grep level
username level = 20
log level = 0
level2 oplocks = yes
os level = 255

When I run the script from the command line, I get this:
Code:
admin@RT-AC68U-1040:/jffs/scripts# ./smb.postconf
sed: -i requires an argument

Is that the problem? Is there a way to check that the script update took?
 
When I run the script from the command line, I get this:
Code:
admin@RT-AC68U-1040:/jffs/scripts# ./smb.postconf
sed: -i requires an argument

Is that the problem? Is there a way to check that the script update took?
You don't run the script like that. Do this instead:
Code:
service restart_samba
 
Have you enabled scripts in the GUI?
Do you see any messages in the syslog indicating that it's trying to run the script?
 
Thanks for your patience. Indeed, scripts were disabled. Log level is showing 3, now. Sorry about that.

This has not added more verbosity to the samba messages scrolling through the log. I'm posting a slightly sanitized (anonymized) version.
 
Thanks for your patience. Indeed, scripts were disabled. Log level is showing 3, now. Sorry about that.

This has not added more verbosity to the samba messages scrolling through the log. I'm posting a slightly sanitized (anonymized) version.

I just tested changing log level from 0 to 3 on my AC86U and the log in /v a r/log/samba.log and /v a r/log/log.smbd got a whole lot more chatty. Especially the samba.log
 
Attaching files from /var/log

samba.log is regularly rewritten and the previous version is written to samba.log.old I tried saving all the old ones as they got rewritten, and have added extensions .1 to .4 with .old being the most recent. The Update Music Library error happened at the end of samba.log.2
 

Attachments

  • samba_logs.zip.txt
    16.6 KB · Views: 75

Similar threads

Support SNBForums w/ Amazon

If you'd like to support SNBForums, just use this link and buy anything on Amazon. Thanks!

Sign Up For SNBForums Daily Digest

Get an update of what's new every day delivered to your mailbox. Sign up here!
Top