Amazon Linux:apt-get:找不到命令 [英] Amazon Linux: apt-get: command not found

查看:76
本文介绍了Amazon Linux:apt-get:找不到命令的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试在我的 AWS 实例上安装 apache 服务器,但是,它似乎没有安装 apt 包.

I'm trying to install an apache server on my AWS instance, however, it seems that it doesn't have the apt package installed.

我用谷歌搜索,我发现的只是这个包的一些损坏的链接.如果该信息有帮助,我将在 Windows 机器上使用 Putty.

I googled and all I found was some broken links to this package. I am using Putty on a windows machine if that information helps.

我目前在 Linux 环境方面的经验很少甚至没有.

I currently have low to none experience in linux enviroments.

我正在运行以下版本的 Linux

I am running the following version of Linux

Linux ip-172-31-37-96 3.14.48-33.39.amzn1.x86_64 #1 SMP Tue Jul 14 23:43:07 UTC 2015 x86_64 x86_64 x86_64 GNU/Linux

有人可以帮忙吗?

推荐答案

如果您使用的是 Amazon Linux,它是基于 CentOS 的,也就是基于 RedHat 的.基于 RH 的安装使用 yum 而不是 apt-get.yum search httpd 之类的应该向您显示可用的 Apache 包 - 您可能想要 yum install httpd24.

If you're using Amazon Linux it's CentOS-based, which is RedHat-based. RH-based installs use yum not apt-get. Something like yum search httpd should show you the available Apache packages - you likely want yum install httpd24.

注意:Amazon Linux 2 与 CentOS 不同 自从写了这个答案,但仍然使用 yum.

Note: Amazon Linux 2 has diverged from CentOS since the writing of this answer, but still uses yum.

这篇关于Amazon Linux:apt-get:找不到命令的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆