0

First I want to describe the environment:

Server:

Windows Server 2016 (holds the network SMB share folder)

Clients:

Mac OS X (El Capitan/Sierra), all users use that and have FULL ACCESS to the network-share root and all subfolders etc. They are not in the domain, but use all the same credentials to connect to the network-shares. The use a software that isn't compatible with with the newest MAC OS.

Now to the problem:

When users access an excel file on the network-share, they cannot save it again under the same name. They can delete the files, rename them, move them etc. So right now they have to open an excel file, save it under a different name, delete the previous one and then rename the new one back to the old one. It's not super bad, but pretty annoying. Other Office Software products work as intended (Word, Powerpoint and so on), only Excel causing this issue.

What have I tried/checked so far:

  • Made sure that .temporaryitems in the network-share root gives full access to the users.
  • Made sure that nobody else was accessing the same file that I was using
  • Disabled auto-save function in Excel
  • Disabled .DS_Store creation on network shares

What is the error-message:

Couldn't save it under bla.xlsx, saved the file as [random hexa-decimal filename with about 8 digits]. (Note: That file can than be found in the .temporaryitems folder)

Solutions that my boss wont accept:

  • Change network share to cifs or afp instead of smb (Reasons behind it don't matter)

Workaround that I thought of, but my boss isn't too happy about:

  • Created a network share (smb) on their NAS. Works perfect there. Boss complains that it wont be included within the backups. So I thought just create a VM on the server and back that up. Boss is somewhat ok with it, but would prefer a solution without a workaround.

I might have forgotten things that I've tried, because the initial error messages and error behaviour were FUBAR, and I adjusted the settings to now look as described above.

Fyi, if I save an excel file under a new name, I can save it under the same name again as often as I want, unless I close the file. After closing the file and reopening it, the "fun" begins.

0

Ok, after I spent several more hours and tried a truckload of new options, I found a solution that worked like a charm.

So here is how it goes:

1) Disable the Apple-Products to create .DS_Store files on network shares

defaults write com.apple.desktopservices DSDontWriteNetworkStores true
defaults write com.apple.desktopservices DSDontWriteNetworkStores -bool true

2) Go to the share-root and find the hidden folder .temporaryItems and give the apple-users FULL ACCESS to it. For example if your networkshare is \\server01\Files and your document is at \\server01\Files\Excel-Docs\excel-file.xlsx, then the hidden folder is at \\server01\Files\.temporaryItems

3) On each apple-product, you have open the finder and navigate to the folder that holds the excel-documents. Then on top go to View and then to Hide View Options. There uncheck the document-preview options.

Alternatively you can do it right after opening the finder and turn it off for all folders. In my case the customers wants to generally see previews of their documents, so I put all excel-documents into one folder and disabled the preview there.

4) Delete all temporary files on the network-share and .DS_Store files that are still present. This includes the documents that start have $ around the start of the filename.

5) Reboot!


For a better understanding, I should add some words. At least to the extent I was able to understand it (might include incorrect information, as I'm by far no MAC-specialised)

Usually FULL ACCESS is too much for a normal windows-environment. But if that .temporaryitems folder doesn't give that permission to apple-users, then they get weird behaviours, because they cannot save their temporary-files in there.

The preview options is a pain, even in normal windows-environments. For the preview the system opens the file already. So if you open a file by double-clicking, you open its preview too. So when you try to save the document under the same name, it says "No Way, Jose! File is still open!". That's why the customer could save an excel document under a new name and then as often as they wanted, unless they reopened the file. Because when they save it under a new name, then they don't have it selected on the Finder, thus no preview.

Deleting those .DS_Store files and temporary files, you get rid of any "tagging" (I dunno the proper term) that might still remain, that the file might be opened by any Apple-user or even be locked by one of them.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.