Magento: backup

This may also apply to any e-commerce business such as Magento.

I have a new Magento installation, and I want to be prepared for when a client asks me about backups. I know about all (or most) backup methods, as well as the various bits that are protected by each type, but I have to do with open orders. What happens to orders placed after the most recent database backup in case of recovery? I assume that the backup copy of the database will store open orders in the system, but, obviously, I cannot take and store backups every second of the day.

So, what happens to orders made after the last backup if the database is damaged and needs to be restored? I suppose there will be at least some chance that some orders may be lost. Am I mistaken? If not, then what is standard practice for? The products my client sells are not so cheap, so typical orders are at least hundreds (euros).

+1
source share
2 answers

Now I can think of two things:

1) Installation replication. This ensures that your backup is always up to date and that you can quickly switch to a subordinate if something happens to the wizard.

2) , . magento/observer - , , .

+3

, , , , .

magento. , . - , ASAP , .

script , gziped , . . , tar magento.

!/bin/sh
m_user='databaseusername'
m_pass='databasepasswd'
db_name='databasename'
od='/home/user/backups/website/' #output directory of the backups
id='/var/www/html/' #the location of the site
name=$od$db_name
name+="_"
mysqldump --opt -u $m_user -p$m_pass $db_name | gzip -c | cat > $name$(date +%m-%d).sql.gz; tar -zcvf $name$(date +%m-%d).tar.gz $id

, , .

+4

Source: https://habr.com/ru/post/1728094/


All Articles