Zip is a compression method and utility program in Linux. You can compress single files and folders with it.
Create .tar.gz when you want to compress an entire folder - not only single file.
To extract .gz file to another directory, you need to set gunzip to output the content to the standard output and forward it to a new file.
.tar.gz is a compressed tar archive file created with tar using -z parameter (gzip compression). You can easily extract this type of file by using tar command.
.gz is a compressed file created with Gzip. Extract files created with Gzip is straight-forward in Linux
In Linux, you cannot gzip the folder directly. Instead, you must create a tar file and compress that. This can be done with a one-liner.
Reset the MySQL root password in CentOS 7 by using MySQL server Safe Mode.