Mac OS X 10.8 - Configure smbd to follow symbolic links

6,128

Adding no-symlinks as a program argument in smbd's launchdaemon plist did the trick.

The file sharing services do need a restart after changing the file.

/System/Library/LaunchDaemons/com.apple.smbd.plist

<array>
        <string>/usr/sbin/smbd</string>
        <string>-no-symlinks</string>  
</array>
Share:
6,128

Related videos on Youtube

walli
Author by

walli

Updated on November 23, 2022

Comments

  • walli
    walli over 1 year

    Is there a way to change the configuration for smbd in mountain lion to follow symbolic links?

    I was looking to apply this fix for linux: http://littlehandytips.com/samba-symbolic-links-do-not-work/

    To fix the samba problem with accessing symbolic links, you will need to modify the samba config file, smb.conf which is normally at /etc/samba/smb.conf and add the following lines to the [global] section in that file.

    follow symlinks = yes

    wide links = yes

    unix extensions = no

    But I can't seem to find the configuration file for smbd.

    Looking at the man pages for smbd in OS X lion https://developer.apple.com/library/Mac/#documentation/Darwin/Reference/ManPages/man8/smbd.8.html

    -no-symlinks

              In normal operation, smbd will respond to client symlink requests but will never follow sym-links symlinks
              links itself. This flag causes smbd to restrict client access to symlink operations and to
              always follow symlinks. In this case, clients will not be aware that symlinks are in use
              because they will always be directed to the symlink target.
    

    I tried adding 'no-symlinks' as a program argument in smbd's launchdaemon plist, but no success.

    **Update: solved Adding the -no-symlinks parameter to the plist did fix the issue, the file sharing services just needed a restart after that.

    /System/Library/LaunchDaemons/com.apple.smbd.plist

    <array>
            <string>/usr/sbin/smbd</string>
            <string>-no-symlinks</string>  
    </array>
    
  • CharlesB
    CharlesB over 10 years
    It's Bad to change a file in /System. It might be overwritten at system update
  • DanielSmedegaardBuus
    DanielSmedegaardBuus over 4 years
    This is a bit weird. Reading the smbd --help would suggest that -no-symlinks (disable support for symbolic links) removes support for them entirely, which indeed is the case in Finder when mounted. They're simply not listed. I cannot even Cmd+G my way to a symlinked folder. In Terminal, however, they're all there, and functional — resolved similar to how "wide links" and friends work on a Linux server share. Have you had any success in getting Finder to show these symlinked resources? Cheers :)