目的のiptablesバージョンが見つからないのはなぜですか?

目的のiptablesバージョンが見つからないのはなぜですか?

Ubuntu 22.04にiptablesバージョン1.6.2をインストールしようとしています。 (注:これはiptables 1.6.2に関するものです。問題なくiptables 1.8.7をインストールしましたが、1.6.2が必要です。)

root@924516f76c4c:/var/www# apt install iptables=1.6.2
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
Package iptables is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source
However the following packages replace it:
  libxtables12

E: Version '1.6.2' for 'iptables' was not found

libxtables12への参照を理解できません。 iptables 1.6.2をインストールする動機は、ufwを使用しようとしたときにこの問題を解決することでした。

root@924516f76c4c:/var/www# ufw status
ERROR: problem running iptables: iptables v1.8.7 (nf_tables): Could not fetch rule set generation id: Permission denied (you must be root)

このエラーは、おそらくiptables 1.6.2を使用する必要があることを意味しました。

インストールする前にapt updateを実行してみましたが、役に立ちませんでした。

ベストアンサー1

iptables1.6.2 はaptリポジトリで使用できないため、Ubuntu 22.04 にはインストールできません。それにもかかわらず、以前のバージョンをインストールしてもiptables問題が解決する可能性は低いです。

さて、あなたはパック1.8.7 以降のバージョンを含め、次のように話す必要があります。

sudo apt install iptables=1.8.7-1ubuntu5

現在のバージョンは22.04です。 1.6.2が利用可能な場合は、パッケージバージョンも指定する必要があります。

おすすめ記事