Repair RAR Archive How to Add Files to RAR Archive The rar r command is used to repair and recover data from damaged or corrupted RAR archives in Linux. ![]() Delete Files in the RAR Archive How to Repair RAR Files in Linux In the above command, the randfile001 and randfile002 files will be deleted from the tecmint.rar RAR archive. $ rar d tecmint.rar randfile001 randfile002 The d option directly modifies the existing RAR archive by removing the specified files. The rar d command is used to delete files from an existing RAR archive in Linux. So, here we need to install the RAR command-line utility to create archive files. It has no option for creating RAR files under Linux. The unrar command only extracts, lists, or tests archive files. To check the integrity of an RAR archive file, you can use the unrar t command, which will perform a complete integrity check for each file for errors and displays the status of the file. Listing Content of RAR Files How to Check Integrity of RAR File in Linux To list the contents of an RAR file in Linux, you can use the unrar l command, which will display the list of files with their sizes, dates, times, and permissions. ![]() $ unrar x tecmint.rarĮxtracting RAR Files with Directory Structure How to List RAR Files in Linux To open/extract an RAR file with its original directory structure, just issue the below command with the x option, which will extract according to their folder structure see below the output of the command. $ unrar e tecmint.rar /home/tecmint/rarfilesĮxtracting RAR Files to the Directory How to Extract RAR File with Directory Structure To open/extract a RAR file in a specific path or destination directory, use the e option, it will extract all the files in the specified destination directory. $ unrar e tecmint.rarĮxtracting RAR Files How to Extract RAR File to a Specific Directory Once you have unrar installed, you can easily open or extract the contents of a RAR file in the current working directory by using the following command with the e option. $ rar a tecmint.rar tecmintĬreating RAR File in Linux How to Extract RAR Files in Linux To create an RAR archive file in Linux, run the following command with a option, which will create an archive file for a tecmint directory. If your distribution does not offer rar and unrar packages, you need to download the latest unrar/rar file and install it using the following commands. On other popular Linux distributions, you can install it using your default package manager as shown. ![]() If you are using RHEL-based distributions, you can use the dnf command or yum command to install it. To install rar and unrar, open a terminal and use the default package manager specific to your Linux distribution.įor example, on Debian and Ubuntu-based distributions, you can easily install the rar and unrar packages using the apt-get or apt program as shown.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |