stecklars
Posts: 27
Joined: Sat Mar 03, 2012 5:42 pm

Rar and unrar on Raspbian

Mon Jul 16, 2012 3:06 pm

Hi,

could someone help me getting rar and unrar working on Raspbian?
It doesn't seem to be included in the repositories but I'm pretty sure that there must be some way to get it working...?
I found this post: http://www.raspberrypi.org/phpBB3/viewt ... 176#p96176
In the meantime you should be able to build it yourself from the debian source package. Please post if you have problems and i'll try to help.
Well, could somebody roughly tell me how to do this?

Thanks!

plugwash
Forum Moderator
Forum Moderator
Posts: 3845
Joined: Wed Dec 28, 2011 11:45 pm

Re: Rar and unrar on Raspbian

Mon Jul 16, 2012 3:08 pm

apt-get build-dep unrar-nonfree
apt-get source -b unrar-nonfree

niko1986
Posts: 12
Joined: Thu Jun 28, 2012 10:21 am

Re: Rar and unrar on Raspbian

Mon Jul 16, 2012 3:18 pm

Without building from source you could use:

apt-get install unrar-free

stecklars
Posts: 27
Joined: Sat Mar 03, 2012 5:42 pm

Re: Rar and unrar on Raspbian

Mon Jul 16, 2012 3:23 pm

niko1986 wrote:Without building from source you could use:

apt-get install unrar-free
Thanks, but I was installing sabnzbd+ and it didn't "like" unrar-free. ;-)

stecklars
Posts: 27
Joined: Sat Mar 03, 2012 5:42 pm

Re: Rar and unrar on Raspbian

Mon Jul 16, 2012 3:24 pm

plugwash wrote:apt-get build-dep unrar-nonfree
apt-get source -b unrar-nonfree
Thank you. Trying this right now :-)

EDIT: It worked fine. For people coming from google:
After this you have to install the created .deb file by typing dpkg -i xxxxxxxxx.deb (<-- insert name of .deb)
:-)

niko1986
Posts: 12
Joined: Thu Jun 28, 2012 10:21 am

Re: Rar and unrar on Raspbian

Mon Jul 16, 2012 9:03 pm

stecklars wrote:
niko1986 wrote:Without building from source you could use:

apt-get install unrar-free
Thanks, but I was installing sabnzbd+ and it didn't "like" unrar-free. ;-)
Is that when you load up Sabnzbd in the browser? AFAIK it doesn't affect unraring.

stecklars
Posts: 27
Joined: Sat Mar 03, 2012 5:42 pm

Re: Rar and unrar on Raspbian

Mon Jul 16, 2012 9:42 pm

Yes, it said something like "It's not recommended to use this type of unrar tool".
Or something like that.
Anyway I've got the non-free version working now, so it's fine.

DonHugo
Posts: 2
Joined: Thu Aug 11, 2011 9:28 pm

Re: Rar and unrar on Raspbian

Fri Jul 20, 2012 7:05 am

Hi,

I tried the above method but got this message insted.

Code: Select all

sudo apt-get build-dep unrar-nonfree
 Reading package lists... Done
 Building dependency tree
 Reading state information... Done
 E: You must put some 'source' URIs in your sources.list

Code: Select all

sudo apt-get source -b unrar-nonfree
 Reading package lists... Done
 Building dependency tree
 Reading state information... Done
 E: You must put some 'source' URIs in your sources.list
my sources.list looks like this

Code: Select all

cat sources.list
 deb http://mirrordirector.raspbian.org/raspbian/ wheezy main contrib non-free rpi
what URI do i need to add??

plugwash
Forum Moderator
Forum Moderator
Posts: 3845
Joined: Wed Dec 28, 2011 11:45 pm

Re: Rar and unrar on Raspbian

Fri Jul 20, 2012 7:46 am

deb-src http://mirrordirector.raspbian.org/raspbian/ wheezy main contrib non-free rpi

Then once that is added you should be able to use apt-get build-dep and apt-get source

DonHugo
Posts: 2
Joined: Thu Aug 11, 2011 9:28 pm

Re: Rar and unrar on Raspbian

Fri Jul 20, 2012 8:34 am

thanx that worked! :)

stbp
Posts: 3
Joined: Tue Jul 24, 2012 4:21 am

Re: Rar and unrar on Raspbian

Tue Jul 24, 2012 4:28 am

I have added the suggested deb-src as well as archive.raspian.org as suggested in the other google hit for this problem, but I still get "You must put some 'source' URIs in your sources.list" when I go to build this. what am I doing wrong? sources.list looks like this:
deb http://archive.raspbian.org/raspbian wheezy main contrib non-free rpi
deb http://mirrordirector.raspbian.org/raspbian wheezy main contrib non-free rpi
deb-src http://archive.raspbian.org/raspbian wheezy testing main contrib non-free rpi
deb-src http://mirrordirector.raspbian.org/raspbian wheezy testing main contrib non-free rpi

help, what am I missing?

plugwash
Forum Moderator
Forum Moderator
Posts: 3845
Joined: Wed Dec 28, 2011 11:45 pm

Re: Rar and unrar on Raspbian

Tue Jul 24, 2012 8:07 am

Did you remember to run apt-get update?

stbp
Posts: 3
Joined: Tue Jul 24, 2012 4:21 am

Re: Rar and unrar on Raspbian

Wed Jul 25, 2012 3:16 am

plugwash wrote:Did you remember to run apt-get update?
nope, and I was able to install a working unrar-nonfree after updating it (and fixing some extraneous lines in sources.list). thank you!

joelbitar
Posts: 1
Joined: Fri Aug 03, 2012 7:46 am

Re: Rar and unrar on Raspbian

Fri Aug 03, 2012 7:50 am

What would the performance be with the Raspberry when unpacking rar archives. Roughly how long would it take to unrar a gigabyte of data for instance?

shalo
Posts: 74
Joined: Tue May 08, 2012 7:25 pm

Re: Rar and unrar on Raspbian

Fri Aug 03, 2012 12:39 pm

joelbitar wrote:What would the performance be with the Raspberry when unpacking rar archives. Roughly how long would it take to unrar a gigabyte of data for instance?
Let's see. Some samples from my 800mhz Pi. All these files are on a USB harddrive and unpacked to the same USB harddrive. I have not tested the speed of the harddrive, which I probably should do because that may be the limiting factor here with it reading and writing from the same drive and the suggestion that USB drivers are still....immature?

3.0GB file: Unpacked 1 files/folders in 6 minutes 48 seconds
1.3GB file: Unpacked 1 files/folders in 3 minutes 24 seconds
740MB file: Unpacked 1 files/folders in 1 minute 38 seconds

I'll throw in this mildly offtopic example too. While using sabnzbd to saturate my bandwidth and download at ~1.15MB/s to the same usb harddrive, it can unrar another file at the same time. In this scenario it takes about 7.5 minutes to unpack a 1.4GB file. (If there is no file unraring, it tends to download at the full 1.2MB/s)

james968
Posts: 29
Joined: Tue Jul 17, 2012 8:52 am

Re: Rar and unrar on Raspbian

Fri Aug 03, 2012 1:18 pm

Hi,

I downlloaded the source and SabNZB stopped complaing about the version.

Download and unpack
___ wget http://www.rarlab.com/rar/unrarsrc-4.2.4.tar.gz
___ gunzip -v unrarsrc-4.2.4.tar.gz
___ tar -xvf unrarsrc-4.2.4.tar
Compile
___ cd unrar/
___ make -f makefile.unix
Install
___ sudo cp unrar /usr/local/bin
Configure alternatives to point to my unrar instead of the unrar-free
___ sudo update-alternatives --install /usr/bin/unrar unrar /usr/local/bin/unrar 10
___ update-alternatives --display unrar
___ sudo update-alternatives --config unrar

stbp
Posts: 3
Joined: Tue Jul 24, 2012 4:21 am

Re: Rar and unrar on Raspbian

Fri Aug 03, 2012 6:17 pm

joelbitar wrote:What would the performance be with the Raspberry when unpacking rar archives. Roughly how long would it take to unrar a gigabyte of data for instance?
My stock Pi unrars 1GB in about 2m 45s on an SD card. (I halt downloads while post-processing as I saw recommended somewhere.)

User avatar
Sander
Posts: 174
Joined: Wed Aug 31, 2011 1:01 pm

Re: Rar and unrar on Raspbian

Thu Aug 16, 2012 12:48 pm

FWIW:

Based on the information above (thank you!), I had unrar-nonfree compiled and installed on my Raspbian with these lines of code:

Code: Select all

echo "deb-src http://mirrordirector.raspbian.org/raspbian/ wheezy main contrib non-free rpi" | sudo tee -a /etc/apt/sources.list
sudo apt-get update
sudo apt-get build-dep unrar-nonfree
sudo apt-get source -b unrar-nonfree
sudo dpkg -i unrar_4.1.4-1_armhf.deb
HTH

Sander

User avatar
bigdavethehorn
Posts: 56
Joined: Thu Jan 19, 2012 8:46 pm
Location: Scotland

Re: Rar and unrar on Raspbian

Thu Sep 13, 2012 11:43 am

Sander, I used this code last night on a fresh Raspbian install (2012-08-16) and it worked flawlessly. Thanks.

User avatar
bigdavethehorn
Posts: 56
Joined: Thu Jan 19, 2012 8:46 pm
Location: Scotland

Re: Rar and unrar on Raspbian

Mon Sep 17, 2012 11:18 am

shalo wrote:Let's see. Some samples from my 800mhz Pi. All these files are on a USB harddrive and unpacked to the same USB harddrive. I have not tested the speed of the harddrive, which I probably should do because that may be the limiting factor here with it reading and writing from the same drive and the suggestion that USB drivers are still....immature?

3.0GB file: Unpacked 1 files/folders in 6 minutes 48 seconds
1.3GB file: Unpacked 1 files/folders in 3 minutes 24 seconds
740MB file: Unpacked 1 files/folders in 1 minute 38 seconds

I'll throw in this mildly offtopic example too. While using sabnzbd to saturate my bandwidth and download at ~1.15MB/s to the same usb harddrive, it can unrar another file at the same time. In this scenario it takes about 7.5 minutes to unpack a 1.4GB file. (If there is no file unraring, it tends to download at the full 1.2MB/s)
Shalo, do you have any tips for stabilising SAB? I have it configured to start downloading to an external HDD on a schedule from midnight until 07:55. I've successfully managed a 123MB file and a 2.0GB file, however I'm not having much luck with a 10GB file.

I don't know what the error is, but the Pi seems to lose network connection sometime duing the evening and locks-up. The only way to wake the Pi is to power off and on.

User avatar
bigdavethehorn
Posts: 56
Joined: Thu Jan 19, 2012 8:46 pm
Location: Scotland

Re: Rar and unrar on Raspbian

Wed Sep 19, 2012 11:09 am

For anyone who found their way here from Google, I increased the following value from the default 8192 to 16384:

vm.min_free_kbytes=16384 in /etc/sysctl.conf

I also added this line to cmdline.txt

smsc95xx.turbo_mode=N in /boot/cmdline.txt

My Pi was still contactable this morning after downloading approximately 7GB during the evening. I'll post back in a few days to report stability.

T0bias
Posts: 1
Joined: Tue Jan 22, 2013 3:21 pm

Re: Rar and unrar on Raspbian

Mon Feb 18, 2013 5:11 pm

Here's a precompiled build:
http://files.tobiass.eu/unrar_4.1.4-1_armhf.deb
You can install it by running:

Code: Select all

wget http://files.tobiass.eu/unrar_4.1.4-1_armhf.deb
sudo dpkg -i unrar_4.1.4-1_armhf.deb

mike1946
Posts: 15
Joined: Wed Jun 05, 2013 1:22 pm

Re: Rar and unrar on Raspbian

Thu Oct 24, 2013 8:26 am

Hi is there a way to update unrar nonfree I am on 4.1

Robertus
Posts: 38
Joined: Tue Jul 14, 2015 8:24 am

Re: Rar and unrar on Raspbian

Wed Nov 25, 2015 11:35 pm

guys i have a little problem with raspbian

i needed to extract with archiver, winrar 5 files

can you help me to install it?

i use raspbian with jdownloader and some rar files (version 5) jdownloader won't extract, so i need to extract with archiver in raspbian

thanks for the support

Navyscourge
Posts: 258
Joined: Sat Oct 24, 2015 1:50 pm

Re: Rar and unrar on Raspbian

Thu Nov 26, 2015 11:04 am

This is an old thread... another thread was started here: viewtopic.php?f=91&t=125520&sid=c4731d0 ... 32a88d33ab

Return to “Raspberry Pi OS”