Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

File overwrite every backup run #145

Open
e36Alex opened this issue May 5, 2024 · 3 comments
Open

File overwrite every backup run #145

e36Alex opened this issue May 5, 2024 · 3 comments

Comments

@e36Alex
Copy link

e36Alex commented May 5, 2024

  • Unifi Protect Backup version: latest
  • Unifi Protect version: 3.0.26 (latest)
  • Python version:
  • Operating System: Linux
  • Are you using a docker container or native?: Docker

Description

I backup my protect files from docker container to a SMB share on my NAS.
Every 5 minutes all files (even existing) get a new Timestamp.
This causes, that the sync job from my NAS to OneDrive uploads all files again because it thinks there is an update.

It would be great, if just new or changed files could be updated.

What I Did

docker-compose.yml

services:
  protect-backup:
    container_name: protect-backup
    image: ghcr.io/ep1cman/unifi-protect-backup:latest
    restart: unless-stopped
    env_file:
      - ./.env
    volumes:
      - /srv/docker-volumes/unifi-protect-backup/database:/config/database/
      - cam-data:/data
      - /etc/timezone:/etc/timezone:ro
      - /etc/localtime:/etc/localtime:ro
          

volumes:
  cam-data:
    driver: local
    driver_opts:
      type: cifs
      device: "//192.168.10.72/cam-data"
      o: "username=${SMB_USER},password=${SMB_PASS},vers=3.0,file_mode=0777,dir_mode=0777"

.env:

UFP_USERNAME=xxx
UFP_PASSWORD=xxx
UFP_ADDRESS=192.168.1.1
UFP_SSL_VERIFY=false
SMB_USER=xxx
SMB_PASS=xxx
@ep1cman
Copy link
Owner

ep1cman commented Oct 26, 2024

Did you ever get this resolved? I am not sure why the timestamps of all the files would be reset like this. UPB only touches the files at two points:

  • When they are created
  • When they are deleted

It seems like this might be an rclone issue?

@e36Alex
Copy link
Author

e36Alex commented Oct 27, 2024

No, i didnt.

@ep1cman
Copy link
Owner

ep1cman commented Oct 27, 2024

Which timestamp is changing? Linux has three:

  • created time
  • last modified time
  • Last accessed time

it would make sense for the latter of those to change

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants