PBS Sync error when creating directory

sebastian.k.e

Member
Feb 7, 2022
14
1
8
25
Hallo zusammen, folgender Fehler.
Ich habe zwei PBS. Einen hier und einen für off site backup.
Beide kennen sich. (als Remotes konfiguriert user jeweils root@pam)
Beim pbs beim off site backup ist ein sync job konfiguriert. Er holt sich die backups von hier (z.B. täglich nachts)

Das Problem:
es kam ein neues Backup file dazu, dh der remote pbs muss eine neue directory auf dem datastore erstellen. Dabei kommt ein Fehler:


Code:
2024-03-26T14:49:51+01:00: Starting datastore sync job 'pxb01:zfs-pool-backup:pbs-local:Kat0:s-049dbeed-f045'
2024-03-26T14:49:51+01:00: sync datastore 'pbs-local' from 'pxb01/zfs-pool-backup'
2024-03-26T14:49:51+01:00: ----
2024-03-26T14:49:51+01:00: Syncing datastore 'zfs-pool-backup', namespace 'Kat0' into datastore 'pbs-local', namespace 'Kat0'
2024-03-26T14:49:51+01:00: found 2 groups to sync (out of 2 total)
2024-03-26T14:49:51+01:00: skipped: 2 snapshot(s) (2024-03-21T22:00:07Z .. 2024-03-22T22:00:01Z) - older than the newest local snapshot
2024-03-26T14:49:51+01:00: re-sync snapshot vm/9704/2024-03-25T22:00:02Z
2024-03-26T14:49:51+01:00: no data changes
2024-03-26T14:49:51+01:00: percentage done: 50.00% (1/2 groups)
2024-03-26T14:49:51+01:00: sync group vm/9944 failed - group lock failed: unable to create backup group "/mnt/datastore/pbs-local/ns/Kat0/vm/9944" - Permission denied (os error 13)
2024-03-26T14:49:51+01:00: create_locked_backup_group failed
2024-03-26T14:49:51+01:00: Finished syncing namespace Kat0, current progress: 1 groups, 0 snapshots
2024-03-26T14:49:51+01:00: TASK ERROR: sync failed with some errors.

Ich bin jeweils überall root und die Sync jobs werden auch mit root erstellt.
Wie kann ich den Fehler beheben? Es gibt schon einen forum beitrag aber ohne wirkliche lösung.
 
Hey,

Backups gehören dem user backup, dieser sollte also berechtigt sein unter /mnt/datastore/pbs-local zu schreiben. Mit ls -la kannst du die Berechtigungen einfach überprüfen. Ist was unter /mnt/datastore/pbs-local gemounted, oder ist das lokaler Speicher?
 
  • Like
Reactions: sebastian.k.e
Hi, es gibt bei mir keinen User Backup. Weder hier noch auf dem remote server.
1711462348802.png

pbs-local sind festplatten im server als ZFS
 
Ich meinte nicht so einen user, es geht darum wem die Dateien im Datastore Verzeichnis gehören uns als welcher user der backup Prozess auf diese zugreift. Kannst du ls -la unter /mnt/datastore/pbs-local und /mnt/datastore/pbs-local/ns/Kat0/vm ausführen und die Ausgabe die posten.
 
  • Like
Reactions: sebastian.k.e
Code:
root@pxb02:~# cd /mnt/datastore/
root@pxb02:/mnt/datastore# ls -la
total 20
drwxr-xr-x 3 root   root   4096 Mar 28  2023 .
drwxr-xr-x 3 root   root   4096 Mar 28  2023 ..
drwxr-xr-x 5 backup backup    7 Mar 24 00:44 pbs-local
root@pxb02:/mnt/datastore# cd pbs-local/
root@pxb02:/mnt/datastore/pbs-local# ls -la
total 11998
drwxr-xr-x     5 backup backup     7 Mar 24 00:44 .
drwxr-xr-x     3 root   root    4096 Mar 28  2023 ..
drwxr-x--- 65538 backup backup 65538 Mar 28  2023 .chunks
-rw-r--r--     1 backup backup   327 Mar 24 00:44 .gc-status
-rw-r--r--     1 backup backup     0 Mar 28  2023 .lock
drwxr-xr-x    13 backup backup    13 Jun 19  2023 ns
drwxr-xr-x     3 backup backup     3 Jun 19  2023 vm
root@pxb02:/mnt/datastore/pbs-local# cd ns/Kat0/
root@pxb02:/mnt/datastore/pbs-local/ns/Kat0# ls -la
total 13
drwxr-xr-x  3 backup backup  3 Jun 19  2023 .
drwxr-xr-x 13 backup backup 13 Jun 19  2023 ..
drwxr-xr-x  4 root   root    4 Mar 26 14:52 vm
root@pxb02:/mnt/datastore/pbs-local/ns/Kat0# cd vm/
root@pxb02:/mnt/datastore/pbs-local/ns/Kat0/vm# ls -la
total 2
drwxr-xr-x 4 root   root   4 Mar 26 14:52 .
drwxr-xr-x 3 backup backup 3 Jun 19  2023 ..
drwxr-xr-x 3 backup backup 4 Mar 26 02:00 9704
drwxr-xr-x 2 root   root   2 Mar 26 14:52 9944
root@pxb02:/mnt/datastore/pbs-local/ns/Kat0/vm#
 
Code:
root@pxb02:/mnt/datastore/pbs-local/ns/Kat0# ls -la
...
drwxr-xr-x  4 root   root    4 Mar 26 14:52 vm
das sollte nicht so sein, hast du da manuell mal was angelegt?
Mit
Code:
chown -R backup:backup /mnt/datastore/pbs-local/ns/Kat0/vm
kannst du den "Owner" der Dateien/Verzeichnisse ändern, dann sollte auch das Backup klappen.
 
  • Like
Reactions: sebastian.k.e
Danke! Es funktioniert wieder.

Ja wir hatten damals manuell die Backup files in die Kat0 verschoben.
Wir haben die Backups in Kathegorien unterteilt ja wir nicht alles gleich oft syncen wollen. Dass man nicht nochmal alle Backups machen mussten haben wir da manuell rum geschoben.
Heut würden wir das nicht mehr brauchen da ja bessere Filter vorhanden sind.
 
  • Like
Reactions: Hannes Laimer

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!