Manjaro Linux

How to extract rar files on Manjaro

RAR is a file format used to combine multiple files/folders in a single compressed file. The .rar file extension refers to the RAR files, and several applications can create these files. The RAR file format is practiced compressing files used for various purposes like you can keep various types of files inside one compressed file. These compressed files are then extracted to access the files contained by them.

The rar files can be extracted by using the graphical interface and terminal support of Manjaro. In Linux-based systems, unrar command-line utility is required to extract .rar files.

In this piece of writing, we have provided possible ways to extract rar file in Manjaro Linux. As the interaction with rar files is impossible without the unrar package. So, we will also provide the installation procedure of the unrar package as well.

Pre-requisites

The unrar is a well-known command-line utility in Linux-based systems. The major prerequisite of this writeup is that you must have the unrar on your system.

How to install unrar on Manjaro Linux

Fortunately, the unrar package is available in the official repository of Manjaro Linux.

Step 1 : Firstly, fire up the Manjaro terminal. Now, run the below-stated command to synchronize as well as update the database to get the latest packages.

$ sudo pacman -Syu

Step 2 : After the updates, install unrar with the help of the following command.

$ sudo pacman -S unrar

How to extract .rar files in Manjaro Linux using terminal

As discussed earlier, the unrar command in Manjaro is the primary tool to manage rar files. Before going towards the extraction procedure, let’s have a look at the support provided by unrar command in Manjaro Linux. For this, just type unrar Manjaro’s terminal to get the list of support provided by this tool.

$ unrar

The following part of this section contains several steps that are recommended to carry out to extract rar files.

For example, we have placed a .rar file in our home directory and named it “linuxhint.rar“. The primary purpose of unrar command is to extract the files for you. To do so, the following command will extract all files of linuxhint.rar file to our present working directory.

Note: The unrar command will not execute until unless you pass an option.

How to extract .rar files to or from other locations

There are two major possibilities while extracting .rar files in Manjaro.

  • To get the extracted files at some other location
  • To extract a .rar file placed at other location

For instance, it is possible that the user may want the extracted files at some other location. In this case, you can also give a path where unrar extracts the files for you. For instance, the command written below will extract the files of linuxhint.rar to the Desktop directory.

$ unrar e linuxhint.rar /home/adnan/Desktop/

Moreover, if the .rar file is placed at some other location then you have to specify the complete address to that file. For example, there is a rar file named “linux” placed in the Downloads directory. To extract it, we have executed the following command.

$ unrar e /home/adnan/Downloads/linux.rar

How to list down the files contained by a .rar file

The unrar command does not only extract the .rar files. However, it can be used to list or test the files contained by a .rar file as well. For instance, the l option supported by unrar command will print the details of files present in .rar file.

The command written below will list all the files contained by linuxhint.rar file.

$ unrar l linuxhint.rar

How to extract files with complete path

The x option in unrar command enables you to get the same structure as that of the parent directory and extract the files by showing the path of each file. In our case, the below-mentioned command will extract the files by following the same structure as that of the parent file (linuxhint.rar).

$ unrar x linuxhint.rar

How to test .rar files in Manjaro

Other than e option of unrar command, you can test the archived files by issuing the t option as shown below. Observe that the option will not extract files, it just tests the files contained by “linuxhint.rar“.

$ unrar t linuxhint.rar

How to extract .rar files in Manjaro using Graphical Interface

The graphical use of Manjaro is quite easy and simple to extract .rar files. The following steps may be carried out to perform the extraction.

Step 1 : Firstly, navigate to the location where the .rar file resides.

Step 2 : Once you have traced the .rar file, right-click on it and choose “Extract Here” to get the extracted files in the current working directory.

After the successful extraction, a folder will be created with the same name (linuxhint).

Step 3 (Optional) : If you want to extract files other than the present directory, then you may need to perform this step. So, right click on the file from your mouse and then choose “Extract to” .

After that, set the folder/directory location and click on “Select” to start extracting. It will take a few moments, depending on the size of the file.

Once the files are extracted, a prompt message will be displayed at the top of the current window that tells you that files have been extracted successfully.

Moreover, you can open the folder by clicking on the “Open Documents” option displayed in the above image.

Conclusion

RAR format of files is used to compress and store multiple files inside a single directory. This format is used widely to keep the files safe from any malware attack. In this article, we have demonstrated several ways to extract .rar files in Manjaro. One may use a terminal to extract .rar files with the help of unrar command-line utility of Manjaro. Moreover, the graphical interface users can also follow this guide to extract .rar files in Manjaro.

About the author

Adnan Shabbir