LoginSignup
0
1

More than 3 years have passed since last update.

AWSのDNS障害でDebianパッケージがインストールできなかった話

Last updated at Posted at 2019-10-23

やろうとしたこと

Dockerファイルをビルドしようとしていました。

FROM php:7.1.11-fpm

WORKDIR /var/local

RUN apt-get update && apt-get install -y \
    apt-transport-https \
    lsb-release \
    ca-certificates \
    wget
...

エラー発生

Step 3/13 : RUN apt-get update && apt-get install -y     apt-transport-https     lsb-release     ca-certificates     wget
 ---> Running in 50a658d96e1f
Get:1 http://security.debian.org jessie/updates InRelease [44.9 kB]
Err http://deb.debian.org jessie InRelease
Err http://deb.debian.org jessie-updates InRelease
Err http://deb.debian.org jessie Release.gpg
  Could not resolve 'cdn-fastly.deb.debian.org'
Err http://deb.debian.org jessie-updates Release.gpg
  Could not resolve 'cdn-fastly.deb.debian.org'
Get:2 http://security.debian.org jessie/updates/main amd64 Packages [893 kB]
Fetched 938 kB in 4s (192 kB/s)
Reading package lists...
W: Failed to fetch http://deb.debian.org/debian/dists/jessie/InRelease
W: Failed to fetch http://deb.debian.org/debian/dists/jessie-updates/InRelease
W: Failed to fetch http://deb.debian.org/debian/dists/jessie/Release.gpg  Could not resolve 'cdn-fastly.deb.debian.org'
W: Failed to fetch http://deb.debian.org/debian/dists/jessie-updates/Release.gpg  Could not resolve 'cdn-fastly.deb.debian.org'
W: Some index files failed to download. They have been ignored, or old ones used instead.
Reading package lists...
Building dependency tree...
Reading state information...
Package lsb-release 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
E: Package 'lsb-release' has no installation candidate
The command '/bin/sh -c apt-get update && apt-get install -y     apt-transport-https     lsb-release     ca-certificates     wget' returned a non-zero code: 100
make: *** [build] Error 100

原因調査

deb.debian.orgのサーバーが死んだのかな?と思いきや、エラーメッセージに下記を発見。

Could not resolve 'deb.debian.org'

ネームサーバー変わったのかなと思っていたら、社内のエンジニアからSlackが飛んできました。
AWSでDNS周りの障害が起きていたみたいです。

その障害によって、deb.debian.orgの名前解決ができず、パッケージのダウンロードができなくなっていたんですね。

障害復旧後

下記のステータスを、AWSで確認しました。

[RESOLVED] Intermittent DNS Resolution Errors
Between 10:30 AM and 6:30 PM PDT, we experienced intermittent errors with resolution of some AWS DNS names.
Beginning at 5:16 PM, a very small number of specific DNS names experienced a higher error rate. These issues have been resolved.

その後再ビルドすると、無事にdebianパッケージもインストールされ、ビルドできました!

考察

おそらくdeb.debian.orgはRoute53あたりを使っているんでしょうか。
今後debianパッケージ取得の際に名前解決関係のエラーが出たら、AWSの障害を疑ってみることも一つの手ですね。

0
1
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
1