SSHFS backup on windows not working after upgrading to Cloudron 8.0.1
-
Hello people!
I have been updating my Cloudron install to migrate to another machine using Ubuntu 24, but After the upgrade it looks like I am not able to do backups like I used to. I do backups using SSHFS, on a remote server running Windows, and I did not change any of the backup settings before upgrading.
When I try to manually back up, I get this error from the logs:
[no timestamp] at ChildProcess._handle.onexit (node:internal/child_process:305:5) { [no timestamp] at ChildProcess.emit (node:events:518:28) [no timestamp] at ChildProcess.exithandler (node:child_process:422:12) [no timestamp] at Object.copy (/home/yellowtent/box/src/storage/filesystem.js:189:30) [no timestamp] at genericNodeError (node:internal/errors:984:15) [no timestamp] at maybeClose (node:internal/child_process:1105:16) [no timestamp] at process.processTicksAndRejections (node:internal/process/task_queues:95:5) [no timestamp] at wrappedFn (node:internal/errors:538:14) [no timestamp] cmd: 'ssh -o "StrictHostKeyChecking no" -i /home/yellowtent/platformdata/sshfs/id_rsa_[Backup IP] -p 22 [Backup User]@[Backup IP] cp -al snapshot/app_0f9d09df-539e-4f8b-bedf-91597c6ff778.tar.gz 2024-07-19-152601-428/app_music.ganyuss.com_v1.17.0.tar.gz' [no timestamp] code: 1, [no timestamp] killed: false, [no timestamp] signal: null, [no timestamp] copy errored with code 1 message Command failed: ssh -o "StrictHostKeyChecking no" -i /home/yellowtent/platformdata/sshfs/id_rsa_[Backup IP] -p 22 [Backup User]@[Backup IP] cp -al snapshot/app_0f9d09df-539e-4f8b-bedf-91597c6ff778.tar.gz 2024-07-19-152601-428/app_music.ganyuss.com_v1.17.0.tar.gz [no timestamp] n'est pas reconnu en tant que commande interne, externe, un programme ex�cutable ou un fichier de commandes.
Only those lines have "no timestamp", the rest of the logs look fine
Error message translation: 'cp' is not recognized as an internal or external command.
Here are my configuration details for backing up:
Let me know if I missed something, of it is an actual regression.
Thank you for your time,
ganyuss -
@ganyuss said in SSHFS backup on windows not working after upgrading to Cloudron 8.0.1:
Let me know if I missed something, of it is an actual regression.
It is a regression. The code was written assuming the cp tool will be available in the remote .
As a workaround:
- Edit
/home/yellowtent/box/src/storage/filesystem.js
. - In the copy function, there is a line
if (apiConfig.provider === PROVIDER_SSHFS) {
. Just disable this.. You can do it like this:
if (false && apiConfig.provider === PROVIDER_SSHFS) {
We will make a proper fix. cc @nebulon
- Edit
-
Indeed, I wasn't even aware Windows can act as an SSH server! Have to see what can be done here. For a start does windows have any shell tool which supports hardlinks? If so maybe we can try to figure out which endpoint this is and run another tool for windows?
-
Hey @girish, @nebulon, thanks for coming back to me so quickly!
Happy to report that the fix worked wonders, and the backup completed successfully.
As for our setup, we set up the backup server a while ago now, my memories are not the freshest. But IIRC we are using OpenSSH Server for Windows Server.
And from what I can see Windows shell usesmklink
to create hard links. But I have never used it. -
-