Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I need the package rar. But I get this error whenever I try to install it:

Reading package Lists... Done
Building dependency tree
Reading state information... Done
Package rar ist not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or is only available form another source
E: package 'rar' has no installation candidate.

What must I do to get rar?

share|improve this question
    
Have you tried an apt-cache search rar and see the results? –  Ander2 Jan 17 '13 at 11:03
2  
@Ander2 apt-cache policy rar is better ;) –  Rinzwind Jan 17 '13 at 11:13

3 Answers 3

rar is provided in the multiverse component, so you must enable that repository. To do this, open up the Software Sources window in any of three ways:

  • Press Alt+F2 and run software-properties-gtk. (Use software-properties-kde instead if this is a Kubuntu system.)
  • Open the Software Updater (or Update Manager, in older releases) and click Settings... at the lower-left corner of the window.
  • Open the Software Center and go to Edit > Software Sources....

Software Sources window showing Ubuntu Software tab with mouse pointer hovering over checkbox label for multiverse repository component

In the Ubuntu Software tab of the Software Sources window, under *Downloadable from the Internet, one of the checkboxes is:

  • Software restricted by copyright or legal issues (multiverse)

Check that box. You may be prompted for your password, to make the change. After you've done so and the box has a check in it, click Close to close the Software Sources window. Now try installing again.

(If it still doesn't work and you're installing from the Terminal with apt-get, try running apt-get update then attempting the installation again.)

How to find software with "no installation candidate"?

To find out why you might not have been able to install rar, the first thing I did was to go to packages.ubuntu.com and search for it.

Searching for the rar package, in all currently supported releases.
Searching for rar in all supported releases (can also search one specific release).

The results revealed it to be in the multiverse component.

Search results for rar (searching in all non-EoL releases).

share|improve this answer
    
add in the apt-cache policy rar and I can remove my answer ;) –  Rinzwind Jan 17 '13 at 11:13
    
@Rinzwind I think your answer is also good; in my opinion, they should both exist. (I was going to upvote it, when I get more votes.) Anyway, it's your call. Feel free to edit that into my answer if you like. (If nothing happens for a while I'll probably edit it to include at least a mention of that command.) –  Eliah Kagan Jan 17 '13 at 11:14

Package rar exists in multiverse: http://packages.ubuntu.com/quantal/rar

Multiverse is a non-free repositorie so... make sure you enable it/have it enabled.

apt-cache policy rar tells you where to find it:

$ apt-cache policy rar
rar:
  Installed: (none)
  Candidate: 1:3.7.1-1
  Version table:
     1:3.7.1-1 0
        500 http://nl.archive.ubuntu.com hardy/multiverse Packages
share|improve this answer
    
apt-cache policy packagename reports the software sources that are already configured to provide the package. Can it be used to tell someone where to find a package that it's provided by any currently enabled repository? –  Eliah Kagan Jan 18 '13 at 0:11

Everyone keeps telling folks who want WinRar to apt-get unrar...it's not the same. did it ever occure to any of you out there that perhaps those asking for WinRar want all the features that they are used to? The amazing compression abilities, adding recovery records, ability to archive an entire drive for backup purposes, adding their authentication info, etc. So here's the real deal...1) WinRar works perfectly in WINE but if you want more support RarLabs has an extras page with both a command line version and additional support for WINE here http://www.rarlab.com/rar_add.htm

share|improve this answer
    
The question specifically says that he needs the package rar. There is no indication why he needs this package or what he is going to do with it. Also I don't see any indication that he wants a full blown GUI to manage rar-files. –  MadMike Oct 16 '13 at 7:54

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.