質問をすることでしか得られない、回答やアドバイスがある。

15分調べてもわからないことは、質問しよう!

新規登録して質問してみよう
ただいま回答率
85.48%
CentOS

CentOSは、主にRed Hat Enterprise Linux(RHEL)をベースにした、フリーのソフトウェアオペレーティングシステムです。

Apache

Apacheは、Apache HTTP Serverの略で、最も人気の高いWebサーバソフトウェアの一つです。安定性が高いオープンソースソフトウェアとして商用サイトから自宅サーバまで、多くのプラットフォーム向けに開発・配布されています。サーバーソフトウェアの不具合(NCSA httpd)を修正するパッチ(a patch)を集積、一つ独立したソフトウェアとして開発されました。

SSL

SSL(Secure Sockets Layer)とは、暗号化されたプロトコルで、インターネット上での通信セキュリティを提供しています。

Q&A

0回答

2111閲覧

CentOS stream 9上のサイトのSSL化ができなくて困っています

taki-tech

総合スコア0

CentOS

CentOSは、主にRed Hat Enterprise Linux(RHEL)をベースにした、フリーのソフトウェアオペレーティングシステムです。

Apache

Apacheは、Apache HTTP Serverの略で、最も人気の高いWebサーバソフトウェアの一つです。安定性が高いオープンソースソフトウェアとして商用サイトから自宅サーバまで、多くのプラットフォーム向けに開発・配布されています。サーバーソフトウェアの不具合(NCSA httpd)を修正するパッチ(a patch)を集積、一つ独立したソフトウェアとして開発されました。

SSL

SSL(Secure Sockets Layer)とは、暗号化されたプロトコルで、インターネット上での通信セキュリティを提供しています。

0グッド

0クリップ

投稿2022/01/02 16:09

前提・実現したいこと

CentOS stream 9にApacheで立てたサイトをSSL化したいと思っています。
そのために、Let's Encrypt クライアントである「certbot」をインストールしようとして次のコマンドを入力しました。
yum -y install certbot python2-certbot-apache
しかし、下記のエラーが出てしまいインストールできずに困っています。

発生している問題・エラーメッセージ

# yum -y install certbot python2-certbot-apache Updating Subscription Management repositories. Unable to read consumer identity This system is not registered with an entitlement server. You can use subscription-manager to register. Last metadata expiration check: 2:27:43 ago on Sun 02 Jan 2022 10:09:44 PM JST. Error: Problem 1: conflicting requests - nothing provides python(abi) = 2.7 needed by python2-certbot-apache-1.11.0-1.el7.noarch Problem 2: package certbot-1.11.0-2.el7.noarch requires python2-certbot = 1.11.0-2.el7, but none of the providers can be installed - conflicting requests - nothing provides pytz needed by python2-certbot-1.11.0-2.el7.noarch - nothing provides /usr/bin/python2 needed by python2-certbot-1.11.0-2.el7.noarch - nothing provides python-zope-interface needed by python2-certbot-1.11.0-2.el7.noarch - nothing provides python(abi) = 2.7 needed by python2-certbot-1.11.0-2.el7.noarch - nothing provides python2-cryptography >= 1.2.3 needed by python2-certbot-1.11.0-2.el7.noarch (try to add '--skip-broken' to skip uninstallable packages or '--nobest' to use not only best candidate packages)

試したこと

python2系のインストールが必要なのかと思い、インストールしようとして下記のコマンドを入力したのですが、次のエラーが発生してしまいました。

sh

1# yum install python2 2Updating Subscription Management repositories. 3Unable to read consumer identity 4 5This system is not registered with an entitlement server. You can use subscription-manager to register. 6 7Last metadata expiration check: 2:55:08 ago on Sun 02 Jan 2022 10:09:44 PM JST. 8No match for argument: python2 9Error: Unable to find a match: python2 10

補足情報(FW/ツールのバージョンなど)

  • CentOSのバージョン:CentOS Stream release 9
  • apacheのバージョン: Apache/2.4.51 (CentOS Stream)

気になる質問をクリップする

クリップした質問は、後からいつでもMYページで確認できます。

またクリップした質問に回答があった際、通知やメールを受け取ることができます。

バッドをするには、ログインかつ

こちらの条件を満たす必要があります。

hoshi-takanori

2022/01/02 16:39

CentOS Stream 詳しくありませんが、yum は廃止されたと聞きましたが…。 また、python2 で書かれた古い certbot はもう動かない (Let’s Encrypt のサーバー側で拒否される) はずです。 新しい certbot は snap というパッケージマネージャーを使って入れるのが推奨されてると記憶してますが、CentOS Stream 9 に対応してるかは知りません。(もしかしたら dnf 版もあるのかも?)
yukky1201

2022/01/02 23:55

環境構成に誤りありませんか? メッセージに表示されているパッケージがel7となっており、centos7用のリポジトリがインストールされてしまっているのでは?
taki-tech

2022/01/03 07:06

みなさま、ありがとうございますm(__)m OSはCentOS Stream 9で間違いないのですが、ssl化を行う際にCentOS7用のサイトを参照していたためパッケージがel7となってしまったのだと思います。 centos9用のEPELリポジトリの追加を試みたのですが、下記のようにエラーになってしまいます。 ```sh dnf install https://dl.fedoraproject.org/pub/epel/epel-release-latest-9.noarch.rpm Updating Subscription Management repositories. Unable to read consumer identity This system is not registered with an entitlement server. You can use subscription-manager to register. CentOS Stream 9 - BaseOS 13 kB/s | 9.6 kB 00:00 CentOS Stream 9 - AppStream 41 kB/s | 9.7 kB 00:00 CentOS Stream 9 - CRB 820 kB/s | 2.9 MB 00:03 Extra Packages for Enterprise Linux 9 - x86_64 5.3 MB/s | 2.0 MB 00:00 Extra Packages for Enterprise Linux Modular 9 - x86_64 47 kB/s | 86 kB 00:01 Errors during downloading metadata for repository 'epel-modular': - Status code: 404 for https://mirrors.fedoraproject.org/metalink?repo=epel-modular-9&arch=x86_64&infra=$infra&content=$contentdir (IP: 2406:da18:39f:a01:35a2:d9e9:8164:a209) - Status code: 404 for https://mirrors.fedoraproject.org/metalink?repo=epel-modular-9&arch=x86_64&infra=$infra&content=$contentdir&countme=1 (IP: 2406:da18:39f:a01:35a2:d9e9:8164:a209) - Status code: 404 for https://mirrors.fedoraproject.org/metalink?repo=epel-modular-9&arch=x86_64&infra=$infra&content=$contentdir (IP: 2406:da12:0:c10:92a3:5a6e:221b:f9eb) Error: Failed to download metadata for repo 'epel-modular': Cannot prepare internal mirrorlist: Status code: 404 for https://mirrors.fedoraproject.org/metalink?repo=epel-modular-9&arch=x86_64&infra=$infra&content=$contentdir (IP: 2406:da12:0:c10:92a3:5a6e:221b:f9eb) ``` また、snapというパッケージマネージャーによるcertbotの導入を試みたのですが、下記のようなエラーが出てしまいます。 ```sh sudo yum install snapd Updating Subscription Management repositories. Unable to read consumer identity This system is not registered with an entitlement server. You can use subscription-manager to register. Extra Packages for Enterprise Linux Modular 9 - x86_64 36 kB/s | 86 kB 00:02 Errors during downloading metadata for repository 'epel-modular': - Status code: 404 for https://mirrors.fedoraproject.org/metalink?repo=epel-modular-9&arch=x86_64&infra=$infra&content=$contentdir (IP: 2406:da12:0:c10:92a3:5a6e:221b:f9eb) - Status code: 404 for https://mirrors.fedoraproject.org/metalink?repo=epel-modular-9&arch=x86_64&infra=$infra&content=$contentdir (IP: 2406:da1a:fcb:2f01:f381:af1a:f922:c519) - Status code: 404 for https://mirrors.fedoraproject.org/metalink?repo=epel-modular-9&arch=x86_64&infra=$infra&content=$contentdir (IP: 2406:da18:39f:a01:8c16:c226:1274:7098) Error: Failed to download metadata for repo 'epel-modular': Cannot prepare internal mirrorlist: Status code: 404 for https://mirrors.fedoraproject.org/metalink?repo=epel-modular-9&arch=x86_64&infra=$infra&content=$contentdir (IP: 2406:da12:0:c10:92a3:5a6e:221b:f9eb) ``` `Status code: 404` ということは、centos9用のモジュールはまだ用意されていないということになるのでしょうか。
guest

あなたの回答

tips

太字

斜体

打ち消し線

見出し

引用テキストの挿入

コードの挿入

リンクの挿入

リストの挿入

番号リストの挿入

表の挿入

水平線の挿入

プレビュー

まだ回答がついていません

会員登録して回答してみよう

アカウントをお持ちの方は

15分調べてもわからないことは
teratailで質問しよう!

ただいまの回答率
85.48%

質問をまとめることで
思考を整理して素早く解決

テンプレート機能で
簡単に質問をまとめる

質問する

関連した質問