Backup functionality with basic command in Magento2.3.x:

Magento backup functionality is helpful to backup the,
1. Magento file system (excluding var and pub/static directories)
2. pub/media directory
3. Magento 2 database

Backup File Path :
Backups are stored into following path, root/var/backups directory and can be restored at any time. Automatically maintenance mode will enable once after hit the backup commands. Once backup is done than maintenance mode will be deactivate by default.

Backup command for code and DB:
–code : Backup the Magento files(except var and pub/static)
Ex: var/backups/1557567895_filesystem_code.zip

–media : Backup the pub/media folder
Ex: var/backups/1557570584_filesystem_media

–db : Backup the Database.
Ex: var/backups/1557567895_db.sql

>php bin/magento setup:backup –code –db –media

We have the option to do the backup all 3 sections together  single CLI command , or individually will do the backup.

To List the Backup:


>php bin/magento info:backups:list

 

Save Tree !!!

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s