Score:0

Cannot install YUM on WSL

lc flag

I am trying to install yum to install another app on my WSL but keep getting the error cannot find the package. I am using the following command:

sudo apt install -y yum

It is returning this:

Reading package lists... Done

Building dependency tree

Reading state information... Done

E: Unable to locate package yum

Search the net I keep seeing to update the apt so I am using this:

 sudo apt update

Returns the following:

Get:1 http://security.ubuntu.com/ubuntu focal-security InRelease [114 kB]

Hit:2 http://archive.ubuntu.com/ubuntu focal InRelease

Get:3 http://archive.ubuntu.com/ubuntu focal-updates InRelease [114 kB]

Get:4 http://archive.ubuntu.com/ubuntu focal-backports InRelease [101 kB]

Get:5 http://archive.ubuntu.com/ubuntu focal-updates/main amd64 Packages [1129 kB]

Get:6 http://archive.ubuntu.com/ubuntu focal-updates/universe amd64 Packages [843 kB]

Fetched 2300 kB in 6s (405 kB/s)

Reading package lists... Done

Building dependency tree

Reading state information... Done

All packages are up to date.

What am I doing wrong?

ChanganAuto avatar
us flag
Yum isn't available for Debian/Ubuntu. It's a wrong assumption that you need "yum to install another app" probably stemming from some tutorial/guide/instructions for RH based desktop Linux distros.
Xaphann avatar
lc flag
ok, that explains alot. So then what is the recommended way to install an RPM?
ChanganAuto avatar
us flag
The recommended way is NOT INSTALL RPMs as they weren't package for Debian/Ubuntu. You need DEB, not RPM so try to find the software you want properly packaged for Debian derivatives. This is an X-Y problem.
NotTheDr01ds avatar
vn flag
Agreed, better to rephrase the question "How do I install (whatever app you were trying to install via yum) on WSL Ubuntu?" But first search for *<that_app_name> ubuntu 20.04* or *<that_app_name> focal*, and you are almost certain to find instructions. First give the "normal" Ubuntu directions a try -- They almost always work on WSL. If you still have problems, let us know what you run into (in a new question).
N0rbert avatar
zw flag
Does this answer your question? [How do I install applications in Ubuntu?](https://askubuntu.com/questions/307280/how-do-i-install-applications-in-ubuntu) Also consult about actual package names with https://packages.ubuntu.com/ . RPM on Debian are aliens.
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.