Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

install apt-get on linux Red Hat server

Tags:

linux

apt-get

I'm setting up a Linux Red Hat web server. apt-get isn't installed, but yum is. However, yum cannot find the apt package.

When I run apt-get, I get a message from the shell saying that the command apt-get couldn't be found. When I try yum install apt or yum install apt-get I get a message saying yum couldn't find the package and there was nothing to do

I suspect that it's probably a case of editing a sources list (as with apt) to add the source that apt is available from, but I a) don't know where this source list would be, and b) don't know what source would provide apt...

If anyone could enlighten me, it would be greatly appreciated

like image 877
Philip Mais Avatar asked Mar 18 '11 21:03

Philip Mais


People also ask

How do you install apt-get in RHEL Linux?

Grab the apt and apt-devel packages (you don't need the source [. src. rpm] rpm) and save them to your machine. Then open a terminal, switch to root user, and install the packages with: rpm -ivh apt* Once that's done: cat /etc/apt/sources.

Can I use apt-get in RHEL?

No, apt is Debian specific.


3 Answers

If you have a Red Hat server use yum. apt-get is only for Debian, Ubuntu and some other related linux.

Why would you want to use apt-get anyway? (It seems like you know what yum is.)

like image 125
Michael Avatar answered Sep 18 '22 15:09

Michael


If you insist on using yum, try yum install apt. As read on this site: Link

like image 30
Yuri Avatar answered Sep 20 '22 15:09

Yuri


I think you're running into problems because RedHat uses RPM for managing packages. Debian based systems use DEBs, which are managed with tools like apt.

like image 44
PPC-Coder Avatar answered Sep 19 '22 15:09

PPC-Coder