【问题标题】:Can not install semanage tool on RedHat virtual machine无法在 RedHat 虚拟机上安装 semanage 工具
【发布时间】:2020-11-10 17:58:36
【问题描述】:

我正在尝试在我的 AWS 虚拟机上 change the MongoDB default port,但在服务器上找不到 semanage

semanage port -a -t mongod_port_t -p tcp 27042

-bash: semanage: 找不到命令

试图找到提供semanage 的包失败。

dnf whatprovides semanage

下载存储库“rhui-client-config-server-8”的元数据时出错: 卷曲错误(58):https://rhui3.eu-west-3.aws.ce.redhat.com/pulp/mirror/protected/rhui-client-config/rhel/server/8/x86_64/os 的本地 SSL 证书有问题 [无法加载 PEM 客户端证书,OpenSSL 错误错误:0200100D:系统库:fopen:权限被拒绝,(未找到密钥,密码错误或文件错误格式?)]

错误:无法下载 repo 'rhui-client-config-server-8' 的元数据:无法准备内部镜像列表:Curl 错误 (58):https://rhui3.eu-west-3.aws.ce.redhat.com/pulp/mirror/protected/rhui-client-config/rhel/server/8/x86_64/os 的本地 SSL 证书有问题 [无法加载 PEM 客户端证书,OpenSSL 错误 error:0200100D:system library:fopen:Permission denied, (no key found, wrong pass phrase, or wrong file format?)]

dnf update 有效,系统是最新的

上次元数据过期检查:UTC 时间 2020 年 7 月 21 日星期二上午 0:42:00。 依赖关系已解决。 没事做。 完成!

其他信息:

cat /etc/redhat-release

红帽企业 Linux 8.2 版 (Ootpa)

dnf repolist

repo id/repo 名称

mongodb-org-4.2 / MongoDB 存储库

rhel-8-appstream-rhui-rpms / Red Hat Enterprise Linux 8 for x86_64 - 来自 RHUI 的 AppStream (RPM)

rhel-8-baseos-rhui-rpms / Red Hat Enterprise Linux 8 for x86_64 - 来自 RHUI (RPM) 的 BaseOS

rhui-client-config-server-8 / Red Hat Update Infrastructure 3 客户端配置服务器 8

你能帮我安装 semanage 吗?谢谢。

【问题讨论】:

  • 这个问题更有可能在Super User得到答案。
  • 谢谢克里斯·威廉姆斯。两天前我在超级用户上问了同样的问题,但我还没有得到答案。

标签: mongodb port redhat


【解决方案1】:

1.dnf 安装 policycoreutils-python-utils 2. dnf 提供semanage (这显示与上面相同的结果-路径) 3. yum 提供 /usr/sbin/semanage 4. yum install policycoreutils-python

我用这个解决了我的问题。

你也可以参考这个链接: https://www.ostechnix.com/linux-troubleshooting-semanage-command-not-found-in-centos-7rhel-7/

【讨论】:

  • 感谢 Divyani Singh。您的解决方案适用于 semanage,但现在我需要安装 screen,我遇到了同样的问题。
  • Screen 在 RHEL 8 以后已被弃用,您可以尝试使用 tmux 代替 screen。您可以在这里查看相同的内容access.redhat.com/solutions/4136481
猜你喜欢
  • 1970-01-01
  • 1970-01-01
  • 2014-01-30
  • 1970-01-01
  • 1970-01-01
  • 2023-04-01
  • 1970-01-01
  • 2017-03-24
  • 1970-01-01
相关资源
最近更新 更多