Mac OS X High Sierra Permissions


#1

I am one of the many thrown out by CrashPlan. Currently I backup up to a freenas system using sftp. All clients systems are OS X 10.12 / 10.13 Most machines with multiple users and get read errors.
Looking at the options of loading duplicati on startup with a plist, but really want to get backup working properly first. The machines are logged and running duplicati as the initial administrator account.

And duplicati-monitoring.com… very cool.

----------error-------

Error reported while accessing file: /Users/mikehathaway/Pictures
System.UnauthorizedAccessException: Access to the path '/Users/mikehathaway/Pictures' is denied.
  at System.IO.__Error.WinIOError (System.Int32 errorCode, System.String maybeFullPath) [0x00129] in <6e9b92f0d119424382ef180639777acb>:0 
  at System.IO.FileSystemEnumerableIterator`1[TSource].HandleError (System.Int32 hr, System.String path) [0x00006] in <6e9b92f0d119424382ef180639777acb>:0 
  at System.IO.FileSystemEnumerableIterator`1[TSource].CommonInit () [0x00054] in <6e9b92f0d119424382ef180639777acb>:0 
  at System.IO.FileSystemEnumerableIterator`1[TSource]..ctor (System.String path, System.String originalUserPath, System.String searchPattern, System.IO.SearchOption searchOption, System.IO.SearchResultHandler`1[TSource] resultHandler, System.Boolean checkHost) [0x000d6] in <6e9b92f0d119424382ef180639777acb>:0 
  at System.IO.FileSystemEnumerableFactory.CreateFileNameIterator (System.String path, System.String originalUserPath, System.String searchPattern, System.Boolean includeFiles, System.Boolean includeDirs, System.IO.SearchOption searchOption, System.Boolean checkHost) [0x00009] in <6e9b92f0d119424382ef180639777acb>:0 
  at System.IO.Directory.InternalGetFileDirectoryNames (System.String path, System.String userPathOriginal, System.String searchPattern, System.Boolean includeFiles, System.Boolean includeDirs, System.IO.SearchOption searchOption, System.Boolean checkHost) [0x00000] in <6e9b92f0d119424382ef180639777acb>:0 
  at System.IO.Directory.InternalGetFiles (System.String path, System.String searchPattern, System.IO.SearchOption searchOption) [0x00000] in <6e9b92f0d119424382ef180639777acb>:0 
  at System.IO.Directory.GetFiles (System.String path) [0x0000e] in <6e9b92f0d119424382ef180639777acb>:0 
  at Duplicati.Library.Snapshots.NoSnapshot.ListFiles (System.String folder) [0x00000] in <77daa5b4404f4a3f88c47ead1428ebeb>:0 
  at Duplicati.Library.Utility.Utility+<EnumerateFileSystemEntries>d__22.MoveNext () [0x00244] in <1cb5198b00f34ae59d97ee7fe7a3a16c>:0

#2

Hi @Mike_Hathaway, welcome to the forum!

Due to how Duplicati stores configuring and database files I think you’ll find it easier to get the plist based service / daemon working first. Shifting from tray-icon to daemon often involves extras steps that can be avoided by starting as daemon.

If you still want to wait on that shift, I suspect you need to be running Duplicati as root rather than administrator.


#3

I have 3 machines, I am working on one of them I am switching to the plist service daemon. Just not quite working yet.


#4

I have duplicati working as a service and no more permissions errors. I installed the server.plist into the /Library/LaunchDaemons and the client .plist into /Library/LaunchAgents Works like a charm on 10.13 and 10.12

These are the plists


#5

Great! Does that mean we can flag your post as the solution or is there something else that needs to be address?

(By the way, I edited your initial post by adding “~~~” before and after the er message to make it more readable.)


#6

Yes this is a solution that could be flagged. Running on 3 systems. One completely remote from the sftp server.


#7

Running perfectly for me on 10.14.1, thank you!


#8

Welcome to the forum, @jbmfc - and thanks for letting us know this worked for you!


#9

I see it works for you, but my understanding is that this is part of security/privacy measures in MacOS Mojave.

At some point I will modify the build script to notarize the MacOS builds so they get this access. But until then you can use the workaround you found, or you can go to system settings -> security & privacy -> anonymity -> full disk access, and add Duplicati.app there.


#10

Actually looking for a nice way to cleanly start/stop/restart Duplicati on macOS Mojave, command line or otherwise, and was again set to the tray-icon path for that.

Followed all the right steps (I think), backups running nicely, but never got the tray-icon to work.

Forcing reloading and executing the tray-icon plist as follows:

sudo launchctl unload -w /Library/LaunchAgents/net.duplicati.tray-icon.plist 
sudo launchctl load -w /Library/LaunchAgents/net.duplicati.tray-icon.plist 

I got the following from tail -f /var/log/system.log:

Dec  9 11:41:03 Transmogrifier com.apple.xpc.launchd[1] (com.apple.xpc.launchd.domain.system): Could not import service from caller: caller = open.3877, service = com.duplicati.app.17984, error = 134: Service cannot load in requested session
Dec  9 11:41:03 Transmogrifier com.apple.xpc.launchd[1] (net.duplicati.tray-icon[3877]): Service exited with abnormal code: 1

Any ideas to get this resolved?
Or have another possibility for clean start/stop/restart?


#11

I’m not a Mac expert but could this be caused by the MacOS permission changes @kenkendk mentioned in the previous post?


#12

initially don’t think so. The duplicati and duplicati-server scripts are both in the Duplicati.app packet, and this app has the right privacy settings. But I will dig deeper.

Furthermore, what is the best way of stopping, starting and restarting the Duplicati components?


#13

On Windows I use Task Manager, Services, or sc command line.
On Linux I use systemd’s systemctl command.
On MacOS, um, I restart the machine. :blush:

I’m guessing @Pectojin might have a suggestion on what would be better for controlling the Duplicati service on MacOS.


#14

I gotta be honest. I’m hopelessly stuck in denial about the high sierra permissions. I’m not affected so I just use the default configured by the .pkg installer.

It’ll start by itself on boot, if I need to restart it I’ll exit from the tray icon and then start it through spotlight :slight_smile: