Minituff / nautical-backup

A simple Docker volume backup tool.
https://minituff.github.io/nautical-backup/
GNU General Public License v3.0
229 stars 3 forks source link

Fatal errors while backing up #117

Closed gottsman closed 5 months ago

gottsman commented 9 months ago

I've had the error only with the Radarr and Sonarr containers. The src is the local file system and the destination is an NFS mount within Docker Compose.

Not sure if its how the Linux Server teams build their images. Here is the debug log from the console:

image: lscr.io/linuxserver/radarr:latest
image: lscr.io/linuxserver/sonarr:latest
DEBUG: Checking  radarr.
DEBUG: Enabling radarr based on label.
DEBUG: Skipping stopping of radarr because of label.
INFO: Backing up radarr data...
DEBUG: RUNNING: 'rsync -ahq --exclude='*.log' --exclude='*.txt' --no-owner --no-perms --no-group /app/source/radarr/ /app/destination/radarr/'
s6-sudoc: fatal: unable to get exit status from server: Operation timed out
s6-rc: fatal: timed out
INFO: radarr completed.
Minituff commented 9 months ago

I haven't seen an s6-sudoc error before. I also use the S6 Overlay like LinuxServer does for Sonarr and Radarr, but I think this error is on the Nautical end.

I also see that you have some custom rsync arguments applied. If you remove rsync args do you still get this error?

Could you post your Nautical and Sonarr/Radarr config? I can try to replicate this on my side.

gottsman commented 9 months ago

I get permission errors without the custom rsync commands -- I believe its permissions issues with my local Synology. I've had the same issues with my custom written scripts. Here is the relevant parts of my docker-compose.yaml file.

  radarr:
    image: lscr.io/linuxserver/radarr:latest
    container_name: radarr
    restart: always
    profiles: ['all', 'media']
    depends_on:
      - prowlarr
      - dozzle
      - transmission
    networks:
      - homelab
    expose:
      - 7878
    volumes:
      - /var/run/docker.sock:/var/run/docker.sock
      - ${APPDATA}/radarr:/config
      - movies:/movies
      - transmission:/data
    environment:
      - PUID=${PUID}
      - PGID=${PGID}
      - TZ=America/New_York
      - DOCKER_MODS=linuxserver/mods:radarr-striptracks
    labels:
      - "traefik.enable=true"
      - "traefik.http.routers.radarr.entryPoints=https"
      - "traefik.http.routers.radarr.service=radarr"
      - "traefik.http.services.radarr.loadbalancer.server.port=7878"
      - "nautical-backup.enable=true"
      - "nautical-backup.stop-before-backup=false"

  nautical-backup:
    image: minituff/nautical-backup:1.3
    profiles: ['all', 'backup']
    networks:
      - homelab
    container_name: nautical-backup
    volumes:
      - /var/run/docker.sock:/var/run/docker.sock
      - ${APPDATA}:/app/source
      - nautical:/app/destination
    environment: # Optional variables
      - TZ=America/New_York
      - REQUIRE_LABEL=true
      - BACKUP_ON_START=true
      # - RSYNC_CUSTOM_ARGS=--exclude='*.log' --exclude='*.txt' --no-owner --no-perms --no-group

volumes:
  nautical:
    driver_opts:
      type: nfs
      o: "addr=192.168.3.2,nolock,soft,rw"
      device: ":/volume1/Nautical"
Minituff commented 9 months ago

It would make sense that it is permission issues. One way to test this out would be to console into Nautical and then run the rsync command manually and you might get a more verbose output.

docker exec -it nautical-backup
rsync -ahq --exclude='*.log' --exclude='*.txt' --no-owner --no-perms --no-group /app/source/radarr/ /app/destination/radarr/

I do plan on adding a PUID and PGID setting to Nautical which hopefully allows you to add a user which has the correct permissions for your Synology NAS.

Minituff commented 8 months ago

@gottsman Any update on the troubleshooting?

gottsman commented 7 months ago

@gottsman Any update on the troubleshooting?

I'm switching over from Synology to Truenas, but experiencing the same issue. I did a NFS mapall user to the owner of the export and am still getting the messages. Not noticing any issues except the message in the log. Here is a couple quick restart of the containers...

INFO: Nautical Backup Version: 1.3.11
INFO: Starting backup since BACKUP_ON_START is true
INFO: Initialization complete. Awaiting CRON schedule: 0 4 * * *
INFO: Starting backup...
INFO: Processing 12 containers...
INFO: Backed up additional folder 'poppincentsv2'
INFO: Backing up db-backup data...
INFO: db-backup completed.
INFO: Backing up abs data...
INFO: abs completed.
INFO: Backing up tdarr data...
s6-sudoc: fatal: unable to get exit status from server: Operation timed out
s6-rc: fatal: timed out
INFO: tdarr completed.
INFO: Backing up recyclarr data...
INFO: recyclarr completed.
INFO: Success. 4 containers backed up! 8 skipped.
INFO: Nautical Backup Version: 1.3.11
INFO: Starting backup since BACKUP_ON_START is true
INFO: Initialization complete. Awaiting CRON schedule: 0 4 * * *
INFO: Starting backup...
INFO: Processing 32 containers...
INFO: Backed up additional folder 'poppincentsv2'
INFO: Stopping jellyseer...
INFO: Backing up jellyseer data...
INFO: Starting jellyseer container...
INFO: jellyseer completed.
INFO: Backing up radarr data...
INFO: radarr completed.
INFO: Backing up sonarr data...
INFO: sonarr completed.
INFO: Backing up lidarr data...
INFO: lidarr completed.
INFO: Backing up bazarr data...
INFO: bazarr completed.
INFO: Backing up prowlarr data...
INFO: prowlarr completed.
INFO: Backing up jellyfin data...
s6-sudoc: fatal: unable to get exit status from server: Operation timed out
s6-rc: fatal: timed out
INFO: jellyfin completed.
INFO: Backing up db-backup data...
INFO: db-backup completed.
INFO: Backing up abs data...
INFO: abs completed.
INFO: Backing up tdarr data...
INFO: tdarr completed.
INFO: Backing up recyclarr data...
INFO: recyclarr completed.
INFO: Success. 12 containers backed up! 20 skipp
Minituff commented 7 months ago

I'm backing up remotely to TrueNAS as well so I should be able to to help you with this.

Check out this guide I made: image

If you follow these steps to mount your NFS share: https://minituff.github.io/nautical-backup/advanced/nfs-share/#connect-to-an-nfs-share-on-container-host-linux

Have you also tried manually running the Rsync command like this to test permissions:

docker exec -it nautical-backup
rsync -ahq --exclude='*.log' --exclude='*.txt' --no-owner --no-perms --no-group /app/source/radarr/ /app/destination/radarr/
Minituff commented 5 months ago

Hello,

I'm going to close this issue for 2 reasons:

  1. Inactivity - I haven't seen anything on this issue for a few months
  2. Nautical Version 2.0.0 Release - I re-wrote the entire code base in Python, so this bug from the older versions will either be squashed or different in this new version.

If you sill have any problems, feel free to re-open this issue or create a new one.