So far, no exclusions have been accounted for as fargs has not been passed.
Rework the logic for fargs parsing based on domain exclusions and pass fargs to the tar command.
Also add --anchored based on 37c69b8f4c
This change will fix issues with files like `public_html/wp-content/plugins/sitepress-multilingual-cms/classes/logs/interface-wpml-log.php` from being excluded, but still exclude the intended main logs directory. Fixes a semi-widespread issue with VestaCP and WPML.
Well, in one db.conf I found duplicated entry for the same database.
root@btvc:~# cat /usr/local/vesta/data/users/btvc2011/db.conf
DB='btvc2011_cart' DBUSER='btvc2011_9091dn' MD5='*' HOST='localhost' TYPE='mysql' CHARSET='UTF8' U_DISK='1' SUSPENDED='no' TIME='' DATE=''
DB='btvc2011_cart' DBUSER='btvc2011_admin' MD5='*' HOST='localhost' TYPE='mysql' CHARSET='UTF8' U_DISK='0' SUSPENDED='no' TIME='' DATE=''
DB='btvc2011_cart' DBUSER='btvc2011_david' MD5='*' HOST='localhost' TYPE='mysql' CHARSET='UTF8' U_DISK='0' SUSPENDED='no' TIME='' DATE=''
DB='btvc2011_cart' DBUSER='btvc2011_djn' MD5='*' HOST='localhost' TYPE='mysql' CHARSET='UTF8' U_DISK='0' SUSPENDED='no' TIME='' DATE=''
DB='btvc2011_cart' DBUSER='btvc2011_jd' MD5='*' HOST='localhost' TYPE='mysql' CHARSET='UTF8' U_DISK='0' SUSPENDED='no' TIME='' DATE=''
DB='btvc2011_cart' DBUSER='btvc2011_oscar' MD5='*' HOST='localhost' TYPE='mysql' CHARSET='UTF8' U_DISK='0' SUSPENDED='no' TIME='' DATE=''
Obviously different users has access to the same database.
I know that this is impossible to create in Vesta.
But @Skamasle thirt-party script for importing cPanels backup obviously CAN do that... and many people use that cPanel importer.
This fix will avoid databases that are already dumped.
Without this fix backup script get stuck on stdin waiting for:
gzip: /backup/tmp.4YlV9Yr4m5/db/btvc2011_cart/btvc2011_cart.mysql.sql.gz already exists; do you wish to overwrite (y or n)?
* Backup filename changed
Changed the backup filename for running more backup each day - for example every 4 hours
* Restore user fix with new backup date
* Check if the backup name has an old notation
* Fix backup permission check
* fixed regex
* fix
I noticed that I always seemed to have 1 less backup than I was supposed to in my VestaCP. This fix resolves the issue for me.
Problem outlined:
- My VestaCP package says that I'm supposed to be allowed 3 backups.
- The backups tab of the GUI showed that I had 3 backups.
- I was never able to access the oldest backup (Almost like it wasn't actually there).
- I checked the backup folder using SSH and I found that I only ever have the latest 2 backups available.
- It was clear that a script was deleting the 3rd backup prematurely.