Pulled this out of my previous topic where Duplicati still won’t install under Fedora 31 (and possibly other flavours), and see if anyone can help.
I use the SSL certificate options with Duplicati (currently running 2.0.5.103_canary_2020-02-18), and it was fine until I upgraded from Fedora 30 to 31. After overcoming the install issue I now hit a problem where the service crashes when I try to access the web GUI when HTTPS is enabled. Removing the service options to include a certificate and reverting to HTTP allows me access again. Backup appear to be unaffected though I need to check the logs later today.
Both, from other PCs on the network and the duplicati_client app to perform GUI commands in a script, but each uses the fqdn of the machine as that’s the name on the certificate. Not sure if the command line client caused the crash, but accessing it from browser did. And this is a headless machine so not using a browser on it either.
Was finally able to upgrade Duplicati without needing to hack the RPM for my Fedora 31 server (the dependencies were all screwed before) to v2.0.5.106-2.0.5.106_canary_2020-05-11, but this issue with my certificate not working is still present.
This is the information from the logs when the service attempts to run:
May 12 11:48:32 MAGGIE.mydomain.com mono[1490294]: A serious error occurred in Duplicati: System.PlatformNotSupportedException: Operation is not supported on this platform.
May 12 11:48:32 MAGGIE.mydomain.com mono[1490294]: at Duplicati.Server.Database.ServerSettings.get_ServerSSLCertificate () [0x00115] in <6afe22724f244985bae35015d56196db>:0
May 12 11:48:32 MAGGIE.mydomain.com mono[1490294]: at Duplicati.Server.WebServer.Server..ctor (System.Collections.Generic.IDictionary`2[TKey,TValue] options) [0x002a4] in <6afe22724f244985bae35015d56196db>:0
May 12 11:48:32 MAGGIE.mydomain.com mono[1490294]: at Duplicati.Server.Program.StartWebServer (System.Collections.Generic.Dictionary`2[TKey,TValue] commandlineOptions) [0x00000] in <6afe22724f244985bae35015d56196db>:0
May 12 11:48:32 MAGGIE.mydomain.com mono[1490294]: at Duplicati.Server.Program.RealMain (System.String[] _args) [0x00227] in <6afe22724f244985bae35015d56196db>:0
May 12 11:48:32 MAGGIE.mydomain.com systemd[1]: duplicati.service: Main process exited, code=exited, status=100/n/a
Hi!
I just posted the same issue yesterday , so probably is something recent.
I found the problem is not something related to Mono, but seems caused from data reading from the database.
I found a workaround: before starting duplicati, I cleanup the “server-ssl-certificate” option inside the Duplicati-server.sqlite db:
update option set value='' where Name='server-ssl-certificate';
You should do every time, before starting the server.
Yes, it will work again as you will pass the .pfx (and the password) in your service start string.
I didn’t check the code yet (I just discovered Duplicati few days ago and I’m really a newbie), but I suppose it doesn’t like to overwrite the ssl option if that is already set.
Just realised, I don’t know how to access a SQLite db in Linux, have only ever done it in Windows to run some commands and that was a with a GUI app. Is there is a command-line equivalent?
Oh and it was ExecStartPre not PreExecStart - perhaps it’s a Fedora thing, but no error seems to be thrown when using the wrong one, only the fact that SSL still fails because it didn’t run the fix.
It was the same for me, the manual test obviously fixed the issue for the next service run, but on a reboot after installing some OS updates it was broken again