• Search of SMB shares not working (MacOS client)


    CS01-HS
    • Minor

    I don't search often so I can't say for certain it's the beta but it used to work consistently and now it doesn't, even in safe mode. No results returned no matter how long I wait.

     

    I'm running the latest MacOS Catalina.

    I also tested in MacOS Mojave (unraid VM), same result.

     

    I have a Raspberry Pi shared over SMB where search from the same two clients works fine.

     

    Diagnostics from safe mode attached.

     

    nas-diagnostics-20201027-1319.zip

     

     

    EDIT: Hack "solution" from follow-up post below.

    Hopefully this helps with a fix.

     

    Test:

     

    Mount unraid share system on my mac and check its spotlight status:

    [macbook-pro]:~ $ mdutil -s /Volumes/system
    /System/Volumes/Data/Volumes/system:
    Server search enabled.
    [macbook-pro]:~ $

     

    But "server search" is not in fact enabled.

    Apparently samba 4.12.0 changed the default from Gnome tracker to noindex.

    Note that when upgrading existing installations that 
    are using the previous default Spotlight backend 
    Gnome Tracker must explicitly set "spotlight backend = tracker"
    as the new default is "noindex".

     

    To change it back (as it was in 6.8) I add the following to SMB extras:

    [global]
       spotlight backend = tracker

     

    and explicitly enable spotlight for each share:

    [system]
       path = /mnt/user/system
       spotlight = yes


    Now when I mount it and check spotlight status I get the following:

    [macbook-pro]:~ $ mdutil -s /Volumes/system
    /System/Volumes/Data/Volumes/system:
    Indexing disabled.
    [macbook-pro]:~ $

     

    And search works.

     

    EDIT: 5/18/2022

    I'm enjoying 6.10 improvements but it now marks two major versions and more than a year that basic functionality (search) isn't available to Mac users. Is a fix in the pipeline?

    • Like 2
    • Upvote 1



    User Feedback

    Recommended Comments



    I might try with and without just to see if there’s a noticeable improvement on my system. Would rather leave them though. Really get annoyed when I have to resize the window and adjust sorting every time I open it.

    Link to comment
    11 minutes ago, wgstarks said:

    I might try with and without just to see if there’s a noticeable improvement on my system. Would rather leave them though. Really get annoyed when I have to resize the window and adjust sorting every time I open it.

    Yeah, I get that.  I tend to like to leave my Finder windows uniform in alphabetical sort in list view, just like Explorer in Windows, Nemo in Mint, etc.  Apple has an article that explains this setting but they don't go out of their way to provide details.

     

    https://support.apple.com/en-us/HT208209

    Link to comment
    
    [global]
    
    fruit:metadata = stream
    fruit:posix_rename = yes
    readdir_attr:aapl_max_access = no
    readdir_attr:aapl_finder_info = no
    readdir_attr:aapl_rsize = no

    I will stay as this above settings. For now, most of folders under 4000 items can be shown in 30secs, but for 30000+ items folder, finder keeps loading forever.

    Link to comment
    59 minutes ago, Lilarcor said:
    
    [global]
    
    fruit:metadata = stream
    fruit:posix_rename = yes
    readdir_attr:aapl_max_access = no
    readdir_attr:aapl_finder_info = no
    readdir_attr:aapl_rsize = no

    I will stay as this above settings. For now, most of folders under 4000 items can be shown in 30secs, but for 30000+ items folder, finder keeps loading forever.

    What version of unRAID?

    Link to comment

    I don’t think I have the option to go back to 6.9.3. And 6.9.3 doesn’t have this issue. I didn’t try 6.10.1/2 so not sure if this issue happened since 6.10.3. 

    Link to comment
    5 hours ago, Lilarcor said:

    I don’t think I have the option to go back to 6.9.3. And 6.9.3 doesn’t have this issue. I didn’t try 6.10.1/2 so not sure if this issue happened since 6.10.3. 

    If you go into the previous folder on flash and overwrite the files on the root of the flash drive with the ones in the previous folder it will return you to whatever the previous version was.

     

    You can also download 6.9.2 here.

    Link to comment
    On 11/22/2021 at 11:05 PM, Maxrad said:

    Below I include my Unraid (Version: 6.10.0-rc1) "Samba extra configuration". This configuration is working  well for me accessing Unraid shares from macOS Monterey 12.0.1

     

    I expect these configuration parameters will work okay for Unraid 6.9.2. The "veto" commands speed-up performance to macOS by disabling Finder features (labels/tags, folder/directory views, custom icons etc.) so you might like to include or exclude these lines per your requirements.

     

    Note, there are problems with samba version 4.15.0 in Unraid 6.10.0-rc2 causing unexpected dropped SMB connections… (behavior like this should be anticipated in pre-release) but fixes expected in future releases.

     

    This configuration is based on a Samba configuration recommended for macOS users from 45Drives here: KB450114 – MacOS Samba Optimization.

     

    #unassigned_devices_start
    #Unassigned devices share includes
       include = /tmp/unassigned.devices/smb-settings.conf
    #unassigned_devices_end
    
    [global]
       vfs objects = catia fruit streams_xattr
       fruit:nfs_aces = no
       fruit:zero_file_id = yes
       fruit:metadata = stream
       fruit:encoding = native
       spotlight backend = tracker
    
    [data01]
       path = /mnt/user/data01
       veto files = /._*/.DS_Store/
       delete veto files = yes
       spotlight = yes

     

    My Unraid share is "data01". Give attention to modifying the configuration for your particular shares (and other requirements). I hope providing this might help others to troubleshoot and optimize SMB for macOS.

    Wow! This is great - almost worked perfectly first time but had a spam of errors in syslog about something I've now forgotten (sigh - phantom or virtual directory for every file in the share) - changed fruit:metadata = stream to fruit:metadata = netatalk and transfer speeds at at max and everthing is great.

    Link to comment
    On 10/23/2022 at 1:53 PM, wgstarks said:

    Also, best practice would be to set these configurations in /boot/config/smb-fruit.conf.

    https://forums.unraid.net/bug-reports/prereleases/macos-optimization-r2087

     

    So, if I understand it correctly, I should take those global settings out of smb-extras and put them into the smb-fruit.conf file and I don't need to worry about the [sharename] section as veto isn't working or should I put them in there anyway as it's no harm and eventually smb will be fixed?

     

    also

    Quote

    include = /tmp/unassigned.devices/smb-settings.conf

     

    does that stay in extras? This is already in the smb.conf file

     

    Quote

    # unassigned devices
            include = /etc/samba/smb-unassigned.conf

     Thanks again

     

    Link to comment
    1 hour ago, heppy said:

    I put them in there anyway as it's no harm and eventually smb will be fixed

    I would go ahead and include them with the assumption that smb will get fixed. Just know that in the meantime you’ll need to manually remove them if you don’t want them.

     

    1 hour ago, heppy said:
    Quote

    include = /tmp/unassigned.devices/smb-settings.conf

     

    does that stay in extras? This is already in the smb.conf file

    I wouldn’t change any of those settings without contacting the plugin author. There is a dedicated support thread for UD.

     

    Also, I believe there is a mistake in the thread for macOS optimization. You may need to restart your array to apply settings rather than restarting samba.

    Link to comment
    4 hours ago, heppy said:

    does that stay in extras? This is already in the smb.conf file

    Once you've updated to the newest version of UD, those settings can be removed.

    Link to comment
    2 hours ago, wgstarks said:

    Also, I believe there is a mistake in the thread for macOS optimization. You may need to restart your array to apply settings rather than restarting samba.

    Correct, the settings are not applied when samba is restarted.

    Link to comment
    18 minutes ago, rkassier said:

    in 6.11.1 this is now working for me - at least for my Macbook Pro running Catalina

    Could you post your smb-fruit.conf contents.

    Link to comment
    33 minutes ago, rkassier said:

    in 6.11.1 this is now working for me - at least for my Macbook Pro running Catalina

    Can you share your conf? And do you experience slow performance if a folder containing thousands of items. 

    Link to comment

    I am on macOS 13.1 (22C65) and can not search Windows 10 shares. I used to a year ago but no longer. I've read the threads here, but I am following the correction (work around). Is there a clearer instruction set?

     

    Thank you.

    Link to comment
    On 1/5/2023 at 3:15 PM, Micleeso said:

    I am on macOS 13.1 (22C65) and can not search Windows 10 shares

     

    Am I missing something? What's the relevance to unRAID?

    Link to comment

    Any update here?

    More than 2 years and no official fix.

     

    I appreciate all the updates since but it's frustrating to see a pretty basic function not working and not addressed. 

    • Upvote 1
    Link to comment
    On 2/3/2023 at 1:24 PM, CS01-HS said:

    Any update here?

    More than 2 years and no official fix.

     

    I appreciate all the updates since but it's frustrating to see a pretty basic function not working and not addressed. 

    +1

    Link to comment



    Join the conversation

    You can post now and register later. If you have an account, sign in now to post with your account.
    Note: Your post will require moderator approval before it will be visible.

    Guest
    Add a comment...

    ×   Pasted as rich text.   Restore formatting

      Only 75 emoji are allowed.

    ×   Your link has been automatically embedded.   Display as a link instead

    ×   Your previous content has been restored.   Clear editor

    ×   You cannot paste images directly. Upload or insert images from URL.


  • Status Definitions

     

    Open = Under consideration.

     

    Solved = The issue has been resolved.

     

    Solved version = The issue has been resolved in the indicated release version.

     

    Closed = Feedback or opinion better posted on our forum for discussion. Also for reports we cannot reproduce or need more information. In this case just add a comment and we will review it again.

     

    Retest = Please retest in latest release.


    Priority Definitions

     

    Minor = Something not working correctly.

     

    Urgent = Server crash, data loss, or other showstopper.

     

    Annoyance = Doesn't affect functionality but should be fixed.

     

    Other = Announcement or other non-issue.