Disable .DS_Store files on network shares

Apple's Mac OS X automatically creates a hidden file called .DS_store on any file system it encounters, including SMB (Windows) networks, similar to Windows' desktop.ini file.

To prevent its creation on network shares, follow these steps on the Apple computer:

  1. Open Terminal (/Applications/Utilities/Terminal or click the magnifying glass in the top right of the screen and type Terminal)
  2. Execute the following command
    defaults write com.apple.desktopservices DSDontWriteNetworkStores true
  3. Either restart the computer or log out and back in.

To disable .DS_store creation on network drives for all users see Apple's article.

References

Mac OS X v10.4 and later: How to prevent .DS_Store file creation over network connections
http://support.apple.com/kb/HT1629

.DS_Store
http://en.wikipedia.org/wiki/.DS_Store

Disable .DS_Store files on network shares