Bug Report - Backup and Restore Ignores */logs/*
Posted: Fri May 14, 2021 10:55 pm
Encountered a bug in the backup and restore process that I couldn't find reported anywhere else.
Both v-backup-user and v-restore-user are configured to ignore "logs/*" when creating the tar of the website files.
It appears, at least on CentOS and Ubuntu, that the "--exclude" parameter for tar treats the value as a pattern instead of an explicit value.
Normally, this wouldn't be an issue, but WPML on WordPress has a class called "logs" that exists in the plugin folder under "classes/logs/" and it does not get backed up or restored. The absence of this folder and the file it contains will cause a 500 error.
I fixed the issue by editing the --exclude parameter to include the $domain variable:
$domain/logs/*
This limits it to only the logs folder that I believe it was intended for.
Both v-backup-user and v-restore-user are configured to ignore "logs/*" when creating the tar of the website files.
It appears, at least on CentOS and Ubuntu, that the "--exclude" parameter for tar treats the value as a pattern instead of an explicit value.
Normally, this wouldn't be an issue, but WPML on WordPress has a class called "logs" that exists in the plugin folder under "classes/logs/" and it does not get backed up or restored. The absence of this folder and the file it contains will cause a 500 error.
I fixed the issue by editing the --exclude parameter to include the $domain variable:
$domain/logs/*
This limits it to only the logs folder that I believe it was intended for.