
openssl, 1.0.1-4ubuntu5.12
ミラーで利用可能かどうかを問い合わせたいとします。例:
deb http://security.ubuntu.com/ubuntu precise-security main restricted
確認できる簡単なコマンドはありますか?
答え1
走れるapt-get install -s openssl -t precise-security
- この
-s
フラグはインストールをシミュレートするためのものです - フラグ
-t
はターゲットリリースを指定します
次のような結果が返されます:
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages will be upgraded:
openssl
1 upgraded, 0 newly installed, 0 to remove and 64 not upgraded.
Inst openssl [1.0.1-4ubuntu5.11] (1.0.1-4ubuntu5.12 Ubuntu:12.04/precise-security [amd64])
Conf openssl (1.0.1-4ubuntu5.12 Ubuntu:12.04/precise-security [amd64])
ここで、openssl 1.0.1-4ubuntu5.12
このリポジトリでバージョンが利用可能であることがわかります。
ただし、これは、システムにインストールされているバージョンよりも新しいバージョンがリポジトリに含まれている場合にのみ報告されます。
apt-cache policy openssl
は、sources.list ファイルで定義した各リポジトリで利用可能なバージョンを報告します (システムがすでに最新の場合でも、私の場合はそうではありません)。
openssl:
Installed: 1.0.1-4ubuntu5.11
Candidate: 1.0.1-4ubuntu5.12
Version table:
1.0.1-4ubuntu5.12 0
500 http://security.ubuntu.com/ubuntu/ precise-security/main amd64 Packages
*** 1.0.1-4ubuntu5.11 0
500 http://fr.archive.ubuntu.com/ubuntu/ precise-updates/main amd64 Packages
100 /var/lib/dpkg/status
1.0.1-4ubuntu3 0
500 http://fr.archive.ubuntu.com/ubuntu/ precise/main amd64 Packages