Compressed Files rar zip tar.gz

Our servers can compress to and extract .zip, .bz2, .gz, .tar, .tar.bz2 and .tar.gz files.

Our servers will allow you to upload .rar files, but note that rar is a closed source software which is NOT distributed with Linux and cannot normally be extracted via shell or the File Manger in cPanel.

This video will demonstrate how to compress and decompress files using the File Manger in your cPanel. Simply select the file(s) or folder(s) that you would like to extract or compress.
(Single click to enlarge an image, double click to reduce.)

At the top of the page click Extract, and choose the location you would like to extract the file to, or leave it blank to extract into the current directory.

To compress files, at the top of File Manger click Compress. A dialog box will pop up with a few options of the type of archive you would like to create.

You can also extract and compress files via SSH:

To extract .zip files the command would be as follows:
 user@server ~ $ unzip 
To compress:
 user@server ~ $ zip -v file.ext 
 user@server ~ $ zip -v directory/* 

To extract .bz2 files:
 user@server ~ $ bunzip2 archive.bz2 
To compress:
 user@server ~ $ bzip2 file.ext 

To extract .gz files:
 user@server ~ $ gzip -d archive.gz 
To compress:
 user@server ~ $ gzip file.ext 

To extract .tar files:
 user@server ~ $ tar -xvf archive.tar 
To compress:
 user@server ~ $ tar -cvf archive.tar file1.ext file2.ext directory/ 

To extract .tar.bz2 files:
 user@server ~ $ tar -xvjf archive.tar.bz2 
To compress:
 user@server ~ $ tar -cvjf file.tar.bz2 file1.ext file2.ext directory/ 

To extract .tar.gz files:
 user@server ~ $ tar -xvzf archive.tar.gz 
To compress:
 user@server ~ $ tar -cvzf file.tar.gz file1.ext file2.ext directory/ 

Please note that these are the most basic forms of the commands, and have many options that are possible. HostGator does not provide support for using these commands, however to learn more about each command you can type  user@server ~ $ man <command>  Where <command> is the command you would like to learn more about, such as "tar" or "gzip."