Hi Author,
i have some weird issues i cannot comprehend. here is the scenario.
- i created multiple profile both backup to local drives, and backup to remote drive at both google and onedrive
- all manually executed backup works without issues
- all scheduled executed backups to remote drive works without issues
- however, all scheduled executed backups to local drive failed repeatedly.
i am using windows 10, and scheduled the backup using "resticprofile -n p01 schedule
". when it was at the time of backup, it failed. even if i manually execute it in task scheduler, it still failed.
i tried both this way to write the repo in windows in .yaml file. using this repository: “G:\100 Backups\restic\mine” works perfectly to backup manually executed using command line. and also work perfectly for rclone backend for both manual and schedule.
repository: “G:\100 Backups\restic\mine”
commented out repository: “G:/100 Backups/restic/mine”
in window task schedule, this is the setting for action:
C:\resticprofile\resticprofile.exe
argument: --no-ansi --config c:\resticprofile\profiles.yaml --name p01 --log c:/resticprofile/p01/backup.log --lock-wait 2h0m0s backup
start in: C:\Users\myusername
i use this in the .yaml to create backup.log
schedule-log: “{{ .ConfigDir }}/{{ .Profile.Name }}/backup.log”
in linux, schedule-log: “{{ .ConfigDir }}/{{ .Profile.Name }}-backup.log” work without issues
one of the status.json file:
{“profiles”:{“p01”:{“backup”:{“success”:false,“time”:“2024-06-19T01:08:24.7599288+08:00”,“error”:“exit status 1”,“stderr”:“Fatal: unable to open config file: CreateFile \\?\G:\100 Backups\restic\mine\config: The system cannot find the path specified.\nIs there a repository at the following location?\nG:/100 Backups/restic/mine\n”,“duration”:1,“files_new”:0,“files_changed”:0,“files_unmodified”:0,“dirs_new”:0,“dirs_changed”:0,“dirs_unmodified”:0,“files_total”:0,“bytes_added”:0,“bytes_total”:0},“retention”:{“success”:true,“time”:“2024-06-16T15:30:53.3917985+08:00”,“error”:“”,“stderr”:“”,“duration”:2}}}}
msg from backup.log
. Backup started at 19 Jun 2024 01:32 SGT
2024/06/19 01:32:14 INFO profile ‘p01’: starting ‘backup’
Fatal: unable to open config file: CreateFile \?\G:\100 Backups\restic\mine\config: The system cannot find the path specified.
Is there a repository at the following location?
G:\100 Backups\restic\mine
. Backup Failed