Posted On March 28, 2019

mysqldump & gunzip

kimconnect 0 comments
blog.KimConnect.com >> Database , Linux >> mysqldump & gunzip
Create SQL Dump:
# Higher compression if bzip2 is installed on the system
# mysqldump -uwebadmin -p –all-databases | bzip2 > kimconnect.sql.bz2
mysqldump -uwebadmin -p –all-databases | gzip > kimconnect.sql.gz
 
Uncompress and import:
# If compressed by bzip2
# bunzip2 < kimconnect.sql.bz2 | mysql -uwebadmin -p
gunzip < kimconnect.sql.gz | mysql -uwebadmin -p

Leave a Reply

Your email address will not be published. Required fields are marked *

Related Post

PowerShell: Microsoft SQL Database Migration

Update 9/25/20: There's another version of this script has has been rewritten form scratch. IMO,…

PowerShell: Maintain Linux Services via SSH Remoting

Version 2: # maintainLinuxServices.ps1 # Version 0.0.2 # Description: this is a simple script to…

Install ScreenConnect on CentOS

If this server is not behind a firewall, then the below instructions would suffice:1. Install…