オブジェクト指向とかデザインパターンとか開発プロセスとかツールとか

satoshi's ソフトウェア開発

js






当サイトはアフィリエイト広告を利用してます。

apache Ubuntu

Ubuntuのapache2をアップデートする方法

投稿日:



 apache2で脆弱性が見つかったために、修正版が公開されました。

 詳しくはこちらを参照してください。

 新しいバージョンは 2.4.51 です。

 まずはリポジトリを追加します。


# add-apt-repository ppa:ondrej/apache2
This branch follows latest Apache2 packages as maintained by the Debian Apache2 team with couple of compatibility patches on top.

It also includes some widely used Apache 2 modules (if you need some other feel free to send me a request).

IMPORTANT: The -backports is now required on older Ubuntu releases.

BUGS&FEATURES: This PPA now has a issue tracker: https://deb.sury.org/#bug-reporting

PLEASE READ: If you like my work and want to give me a little motivation, please consider donating: https://deb.sury.org/#donate
More info: https://launchpad.net/~ondrej/+archive/ubuntu/apache2
Press [ENTER] to continue or Ctrl-c to cancel adding it.

 エンターキーを押すと、いろいろとメッセージが表示されます。

 念のため、apt-getもアップデートしておきます。


# apt-get update
Hit:1 http://jp.archive.ubuntu.com/ubuntu focal InRelease
Hit:2 http://jp.archive.ubuntu.com/ubuntu focal-updates InRelease
Hit:3 http://jp.archive.ubuntu.com/ubuntu focal-backports InRelease
Hit:4 http://jp.archive.ubuntu.com/ubuntu focal-security InRelease
Hit:5 http://ppa.launchpad.net/ondrej/apache2/ubuntu focal InRelease
Hit:6 http://ppa.launchpad.net/ondrej/php/ubuntu focal InRelease
Reading package lists... Done

 これでアップデートの準備ができました。

 apache2をインストールします。インストールでアップデートされるみたいです。


# apt-get install apache2
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following package was automatically installed and is no longer required:
liblua5.2-0
Use 'apt autoremove' to remove it.
The following additional packages will be installed:
apache2-bin apache2-data apache2-utils libapr1 liblua5.3-0
Suggested packages:
apache2-doc apache2-suexec-pristine | apache2-suexec-custom www-browser
The following NEW packages will be installed:
liblua5.3-0
The following packages will be upgraded:
apache2 apache2-bin apache2-data apache2-utils libapr1
5 upgraded, 1 newly installed, 0 to remove and 14 not upgraded.
Need to get 1,987 kB of archives.
After this operation, 640 kB of additional disk space will be used.
Do you want to continue? [Y/n]

 Yを入力してエンターを押して継続します。

 しばらく待つとインストールが終わります。

 バージョンを確認してみます。


# apache2 -v
Server version: Apache/2.4.51 (Ubuntu)
Server built: 2021-10-07T19:17:29

 新しいバージョンに変わっているので、apache2を再起動します。


# systemctl restart apache2

 Ubuntuだと10分程度でapache2のアップデートができました。

 簡単ですね。

 それに比べてCentOSはアンインストールしてからインストールしないといけないみたい(めんどくさー)。







-apache, Ubuntu
-, , ,

Copyright© satoshi's ソフトウェア開発 , 2024 All Rights Reserved Powered by STINGER.