How to install Rar/Unrar on CentOS

rwsorensen

Well-known member
Registered
Joined
Mar 12, 2014
Messages
115
Points
18
I have backup files with large sizes in rar format. After upload them to my VPS how can I unrar these files on my Centos. Please guide me!
 

MooseLucifer

Well-known member
Registered
Joined
May 20, 2016
Messages
149
Points
28
In the first step, you need to know which CentOS version you are using to choosing right commands and installing it. After that you must add the rar/unrar yum repository information

Here I am using CentOS 6 64 Bit, if you are using same Centos version, running the following commands

Code:
wget http://dl.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm
The output should be

Code:
[root@server ~]# wget http://dl.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm
--2016-12-29 03:23:31--  http://dl.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm
Resolving dl.fedoraproject.org... 209.132.181.26, 209.132.181.27, 209.132.181.23, ...
Connecting to dl.fedoraproject.org|209.132.181.26|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 14540 (14K) [application/x-rpm]
Saving to: epel-release-6-8.noarch.rpm”

100%[===============================================================================>] 14,540      --.-K/s   in 0.08s

2016-12-29 03:23:31 (175 KB/s) - epel-release-6-8.noarch.rpm” saved [14540/14540]
Code:
rpm -ivh epel-release-6-8.noarch.rpm
The output should be
Code:
[root@server ~]# rpm -ivh epel-release-6-8.noarch.rpm
warning: epel-release-6-8.noarch.rpm: Header V3 RSA/SHA256 Signature, key ID 0608b895: NOKEY
Preparing...                ########################################### [100%]
   1:epel-release           ########################################### [100%]

Install rar/unrar
Type the following command to install Rar/Unrar

Code:
yum install rar unrar
The output should be

Code:
[root@server ~]# yum install rar unrar
Loaded plugins: fastestmirror, presto
Setting up Install Process
Loading mirror speeds from cached hostfile
epel/metalink                                                                                     |  13 kB     00:00
 * epel: ca.mirror.babylon.network
epel  
........
Congratulation's! You have successfully installed rar/unrar on your CentOS.

And now, you can use following commands to rar/unrar your files on the VPS.

Code:
# unrar x (file_name).rar*****      extract with full path
# unrar e -kb (file_name).rar*      (Keep broken)
# unrar l (file_name).rar*****      list files inside
# unrar e (file_name).rar*****      dump files excluding folders
# rar a (file_name).rar (file_name) create a archive Rar file
# rar r (file_name).rar*            recover or fix a archive file or files
# rar a -p (file_name).rar          create a archive Rar file with password
In the case, you don't use CentOS 6 64 Bit that you use CentOS 7 64 Bit or CentOS 6 32 Bit, just replacing with these commands

For CentOS 7 64 Bit
Code:
wget http://dl.fedoraproject.org/pub/epel/7/x86_64/e/epel-release-7-6.noarch.rpm
rpm -ivh epel-release-7-6.noarch.rpm
For CentOS 6 32 Bit
Code:
wget http://dl.fedoraproject.org/pub/epel/6/i386/epel-release-6-8.noarch.rpm
rpm -ivh epel-release-6-8.noarch.rpm

Good luck to you!
 

TheCompWiz

Well-known member
Registered
Joined
Apr 20, 2016
Messages
130
Points
18
I have backup files with large sizes in rar format. After upload them to my VPS how can I unrar these files on my Centos. Please guide me!
Instead of using rar/unrar on your VPS, you can use zip and unzip commands to extract your files which is more easier and convenient without installing extra rar/unrar package.
 

Mujkanovic

Well-known member
Collaborate
Registered
Joined
Apr 24, 2016
Messages
424
Points
18
Mujkanovic
Exactly, Zip format will suitable and compatible with any platforms that you are running on hence you can easily unzip files without requiring to install extra software like Winrar.
 
Recommended Threads
Replies
2
Views
2,948
Replies
7
Views
1,729
fwh
Replies
7
Views
2,490
Replies
1
Views
1,694

Latest Hosting OffersNew Reviews

Sponsors

Tag Cloud

You are using an out of date browser. It may not display this or other websites correctly.
You should upgrade or use an alternative browser.

Top