Addressing backup failures on DR server for CIFS, NFS, and VMware sources

Problem:
Upon transitioning to the DR instance, initiating a restore for CIFS, NFS, or VMware sources leads to subsequent backup failures at any level (0 or 1). The encountered error message is: "Permission denied - open debug directory /var/log/amanda/client/<backupset>/."

Cause:

When the restore is initiated, it creates a backup set logs directory on /var/log/amanda/client with root ownership instead of the required amandabackup ownership. Therefore, the next backup fails because it cannot write logs into a directory owned by the root user.

Workaround:

This issue can be resolved using either of the following two methods:

  1. Change ownership manually:

    • Execute the following command to change the ownership of the log directory manually:

      chown amandabackup: /var/log/amanda/client/<backupset>
  2. Trigger a backup first after switching to Disaster Recovery (DR) instance:

    • To automatically create the log directory with the correct ownership, initiate a backup of any level immediately after switching to the DR instance. This backup process will create the log directory with the correct amandabackup ownership.

Implementing either of these workarounds should resolve the backup failures encountered for CIFS, NFS, and VMware sources on the DR server.