0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

Hyper-Vで立てたUbuntuのVMにDefault Switchを割り当てたらVMの中のdockerからDNSが解決できない

Posted at

事象

fatal: unable to access 'https://github.com/yumetodo/unofficial-windows-message-center-rss.git/': Could not resolve host: github.com

のようなログがCIに出てきた(実際には社内のgitlab ciのdomainがDNSが解決できなかった)

image.png

構成

Windows 11 24H2 ProのPCでHyper-Vを用いてUbuntu 24.04のVMを作ってある。

このVMにはDefault Switchを割り当ててある。

VMの中ではDockerがインストールされている。

また、gitlab-runnerがインストールされ稼働している

発見経緯

今回の事象はgitlab ciのjobの失敗という形で発見された。

脳死でapt upgrade→reboot: だめ

CIのよくわからんエラーはとりあえず脳死でapt upgradeしてrebootすると6割位は治る(体感)

というわけでそうしてみた。ちょうどgitlab-runnerの更新も来てたしね。

・・・が、だめっ!

CI関係なく再現するか試みる→再現

たまに意味わからんくらい古いdocekr volumeを掴まされて死ぬことがあるが

main@main-virtual-machine:~$ sudo ls -l /var/lib/docker/volumes
合計 88
brw------- 1 root root  8, 2  8月 15 11:12 backingFsBlockDev
-rw------- 1 root root 65536  8月 15 11:40 metadata.db
drwx-----x 3 root root  4096  8月 15 11:27 runner-lx6nffyja-project-67-concurrent-0-cache-3c3f060a0374fc8bc39395164f415a70
drwx-----x 3 root root  4096  8月 15 11:27 runner-lx6nffyja-project-67-concurrent-0-cache-c33bcaa1fd2c77edfc3893b41966cea8
drwx-----x 3 root root  4096  8月 15 11:27 runner-lx6nffyja-project-67-concurrent-1-cache-3c3f060a0374fc8bc39395164f415a70
drwx-----x 3 root root  4096  8月 15 11:27 runner-lx6nffyja-project-67-concurrent-1-cache-c33bcaa1fd2c77edfc3893b41966cea8
drwx-----x 3 root root  4096  8月 15 11:27 runner-lx6nffyja-project-67-concurrent-2-cache-3c3f060a0374fc8bc39395164f415a70
drwx-----x 3 root root  4096  8月 15 11:27 runner-lx6nffyja-project-67-concurrent-2-cache-c33bcaa1fd2c77edfc3893b41966cea8

作り立てホヤホヤそうなので違う。

main@main-virtual-machine:~$ git clone --depth=1 https://github.com/yumetodo/unofficial-windows-message-center-rss.git/
Cloning into 'unofficial-windows-message-center-rss'...
Username for 'https://github.com': ayame
Password for 'https://ayame@github.com':
remote: HTTP Basic: Access denied. If a password was provided for Git authentication, the password was incorrect or you're required to use a token instead of a password. If a token was provided, it was either incorrect, expired, or improperly scoped. See ...
fatal: Authentication failed for 'https://github.com/yumetodo/unofficial-windows-message-center-rss.git/'

hostでわざと偽の認証情報でcloneしようとしたが普通に認証が聞かれるってことは、DNSはできてる。まあというかさっきapt upgradeできた時点でそこはあんま疑ってないが・・・。

というわけで、CIで使ってたdocker imageを使って起動してみる。

main@main-virtual-machine:~$ sudo docker run --rm -it gitlab-registry.tokyo.optim.co.jp/bizweb/optimal_biz_web_admin/for_rspec:ruby3.1.6_with_launchable /bin/bash
root@e2c77646e3d6:/# git -v
git version 2.39.2
root@e2c77646e3d6:/# git clone --depth=1 https://github.com/yumetodo/unofficial-windows-message-center-rss.git
Cloning into 'unofficial-windows-message-center-rss'...
fatal: unable to access 'https://github.com/yumetodo/unofficial-windows-message-center-rss.git/': Could not resolve host: github.com
root@e2c77646e3d6:/# apt -v
apt 2.6.1 (amd64)
root@e2c77646e3d6:/# apt update
Ign:1 http://deb.debian.org/debian bookworm InRelease
Ign:2 http://deb.debian.org/debian bookworm-updates InRelease
Ign:3 http://deb.debian.org/debian-security bookworm-security InRelease
Ign:1 http://deb.debian.org/debian bookworm InRelease
Ign:2 http://deb.debian.org/debian bookworm-updates InRelease
Ign:3 http://deb.debian.org/debian-security bookworm-security InRelease
Ign:1 http://deb.debian.org/debian bookworm InRelease
Ign:2 http://deb.debian.org/debian bookworm-updates InRelease
Ign:3 http://deb.debian.org/debian-security bookworm-security InRelease
Err:1 http://deb.debian.org/debian bookworm InRelease
  Temporary failure resolving 'deb.debian.org'
Err:2 http://deb.debian.org/debian bookworm-updates InRelease
  Temporary failure resolving 'deb.debian.org'
Err:3 http://deb.debian.org/debian-security bookworm-security InRelease
  Temporary failure resolving 'deb.debian.org'
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
All packages are up to date.
W: Failed to fetch http://deb.debian.org/debian/dists/bookworm/InRelease  Temporary failure resolving 'deb.debian.org'
W: Failed to fetch http://deb.debian.org/debian/dists/bookworm-updates/InRelease  Temporary failure resolving 'deb.debian.org'
W: Failed to fetch http://deb.debian.org/debian-security/dists/bookworm-security/InRelease  Temporary failure resolving 'deb.debian.org'
W: Some index files failed to download. They have been ignored, or old ones used instead.

再現してしまった。

同一構成の別のPCと比較する

Microsoft Copilotくんと壁打ちしつつ、同じくHyper-VでUbuntuを立ててる環境と比べていった。

動かないPCだとこう

main@main-virtual-machine:~$ sudo resolvectl status
Global
         Protocols: -LLMNR -mDNS -DNSOverTLS DNSSEC=no/unsupported
  resolv.conf mode: stub

Link 2 (eth0)
    Current Scopes: DNS
         Protocols: +DefaultRoute -LLMNR -mDNS -DNSOverTLS DNSSEC=no/unsupported
Current DNS Server: 172.17.32.1
       DNS Servers: 172.17.32.1
        DNS Domain: mshome.net

Link 3 (docker0)
    Current Scopes: none
         Protocols: -DefaultRoute -LLMNR -mDNS -DNSOverTLS DNSSEC=no/unsupported
main@main-virtual-machine:~$ ip a
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
    inet 127.0.0.1/8 scope host lo
       valid_lft forever preferred_lft forever
    inet6 ::1/128 scope host noprefixroute
       valid_lft forever preferred_lft forever
2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP group default qlen 1000
    link/ether 00:15:5d:c8:80:02 brd ff:ff:ff:ff:ff:ff
    inet 172.17.35.24/20 brd 172.17.47.255 scope global dynamic noprefixroute eth0
       valid_lft 82999sec preferred_lft 82999sec
    inet6 fe80::3f3:901c:de44:b3b6/64 scope link noprefixroute
       valid_lft forever preferred_lft forever
3: docker0: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc noqueue state DOWN group default
    link/ether 46:a4:65:c5:97:59 brd ff:ff:ff:ff:ff:ff
    inet 172.17.0.1/16 brd 172.17.255.255 scope global docker0
       valid_lft forever preferred_lft forever
    inet6 fe80::44a4:65ff:fec5:9759/64 scope link
       valid_lft forever preferred_lft forever

うごくPCだとこう

yumetodo@yumetodo-vm-ubuntu2204-rbenv:~$ sudo resolvectl status
Global
       Protocols: -LLMNR -mDNS -DNSOverTLS DNSSEC=no/unsupported
resolv.conf mode: stub

Link 2 (eth0)
    Current Scopes: DNS
         Protocols: +DefaultRoute +LLMNR -mDNS -DNSOverTLS DNSSEC=no/unsupported
Current DNS Server: 192.168.144.1
       DNS Servers: 192.168.144.1
        DNS Domain: mshome.net

Link 3 (docker0)
Current Scopes: none
     Protocols: -DefaultRoute +LLMNR -mDNS -DNSOverTLS DNSSEC=no/unsupported

Link 4 (br-26b59e196b7c)
Current Scopes: none
     Protocols: -DefaultRoute +LLMNR -mDNS -DNSOverTLS DNSSEC=no/unsupported

Link 5 (br-65a026fa56e7)
Current Scopes: none
     Protocols: -DefaultRoute +LLMNR -mDNS -DNSOverTLS DNSSEC=no/unsupported

Link 6 (br-bf8cf7caade1)
Current Scopes: none
     Protocols: -DefaultRoute +LLMNR -mDNS -DNSOverTLS DNSSEC=no/unsupported

Link 7 (br-2bbd880f5b0e)
Current Scopes: none
     Protocols: -DefaultRoute +LLMNR -mDNS -DNSOverTLS DNSSEC=no/unsupported

Link 8 (br-d2d94279e21a)
Current Scopes: none
     Protocols: -DefaultRoute +LLMNR -mDNS -DNSOverTLS DNSSEC=no/unsupported

Link 9 (br-d31a46cda10a)
Current Scopes: none
     Protocols: -DefaultRoute +LLMNR -mDNS -DNSOverTLS DNSSEC=no/unsupported

Link 10 (br-df3b3c8f19b8)
Current Scopes: none
     Protocols: -DefaultRoute +LLMNR -mDNS -DNSOverTLS DNSSEC=no/unsupported

Link 11 (br-e77d1327799f)
Current Scopes: none
     Protocols: -DefaultRoute +LLMNR -mDNS -DNSOverTLS DNSSEC=no/unsupported

Link 12 (veth87066f5)
Current Scopes: none
     Protocols: -DefaultRoute +LLMNR -mDNS -DNSOverTLS DNSSEC=no/unsupported
yumetodo@yumetodo-vm-ubuntu2204-rbenv:~$ ip a
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
    inet 127.0.0.1/8 scope host lo
       valid_lft forever preferred_lft forever
    inet6 ::1/128 scope host
       valid_lft forever preferred_lft forever
2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP group default qlen 1000
    link/ether 00:15:5d:65:e7:02 brd ff:ff:ff:ff:ff:ff
    inet 192.168.148.207/20 metric 100 brd 192.168.159.255 scope global dynamic eth0
       valid_lft 44471sec preferred_lft 44471sec
    inet6 fe80::215:5dff:fe65:e702/64 scope link
       valid_lft forever preferred_lft forever
3: docker0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UP group default
    link/ether 9e:ff:35:3b:3f:06 brd ff:ff:ff:ff:ff:ff
    inet 172.17.0.1/16 brd 172.17.255.255 scope global docker0
       valid_lft forever preferred_lft forever
    inet6 fe80::9cff:35ff:fe3b:3f06/64 scope link
       valid_lft forever preferred_lft forever
4: br-26b59e196b7c: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc noqueue state DOWN group default
    link/ether 42:9d:a6:f7:de:d1 brd ff:ff:ff:ff:ff:ff
    inet 172.18.0.1/16 brd 172.18.255.255 scope global br-26b59e196b7c
       valid_lft forever preferred_lft forever
5: br-65a026fa56e7: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc noqueue state DOWN group default
    link/ether 42:6b:bf:d0:eb:d5 brd ff:ff:ff:ff:ff:ff
    inet 172.20.0.1/16 brd 172.20.255.255 scope global br-65a026fa56e7
       valid_lft forever preferred_lft forever
6: br-bf8cf7caade1: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc noqueue state DOWN group default
    link/ether 8e:67:57:6b:4d:dd brd ff:ff:ff:ff:ff:ff
    inet 172.23.0.1/16 brd 172.23.255.255 scope global br-bf8cf7caade1
       valid_lft forever preferred_lft forever
7: br-2bbd880f5b0e: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc noqueue state DOWN group default
    link/ether 62:53:42:70:61:dc brd ff:ff:ff:ff:ff:ff
    inet 172.22.0.1/16 brd 172.22.255.255 scope global br-2bbd880f5b0e
       valid_lft forever preferred_lft forever
8: br-d2d94279e21a: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc noqueue state DOWN group default
    link/ether 5e:c9:80:20:30:bc brd ff:ff:ff:ff:ff:ff
    inet 172.25.0.1/16 brd 172.25.255.255 scope global br-d2d94279e21a
       valid_lft forever preferred_lft forever
9: br-d31a46cda10a: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc noqueue state DOWN group default
    link/ether d6:df:08:e7:3d:58 brd ff:ff:ff:ff:ff:ff
    inet 172.26.0.1/16 brd 172.26.255.255 scope global br-d31a46cda10a
       valid_lft forever preferred_lft forever
10: br-df3b3c8f19b8: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc noqueue state DOWN group default
    link/ether ee:af:71:d3:04:a6 brd ff:ff:ff:ff:ff:ff
    inet 172.21.0.1/16 brd 172.21.255.255 scope global br-df3b3c8f19b8
       valid_lft forever preferred_lft forever
11: br-e77d1327799f: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc noqueue state DOWN group default
    link/ether 52:96:04:d5:97:02 brd ff:ff:ff:ff:ff:ff
    inet 172.19.0.1/16 brd 172.19.255.255 scope global br-e77d1327799f
       valid_lft forever preferred_lft forever
12: veth87066f5@if2: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue master docker0 state UP group default
    link/ether 92:ca:3b:a7:81:a9 brd ff:ff:ff:ff:ff:ff link-netnsid 0
    inet6 fe80::90ca:3bff:fea7:81a9/64 scope link
       valid_lft forever preferred_lft forever

copilotくんはしきりに/etc/docker/daemon.jsondnsを書けと言ってくるが、そんな訳はない。

ありがとうございます!この比較は非常に有益です。


🔍 比較から見える違い

項目 動かないVM(172.17.32.1) 動くVM(192.168.144.1)
DNSサーバー 172.17.32.1 192.168.144.1
IPアドレス 172.17.35.24/20 192.168.148.207/20
Dockerネットワーク docker0 が DOWN docker0 が UP
systemd-resolved stub resolver (127.0.0.53) 同じく stub resolver
Dockerコンテナ内の名前解決 失敗 成功

🧠 考察

✅ 成功しているVMの特徴

  • docker0UP 状態で、Dockerネットワークが正常に動作
  • DNSサーバーが 192.168.x.x 系 → Hyper-V Default Switchが割り当てた NAT ゲートウェイが安定している
  • Dockerコンテナが 127.0.0.53 を経由せず、正しく名前解決できている

❌ 失敗しているVMの特徴

  • docker0DOWN → Dockerネットワークが不安定
  • DNSが 172.17.x.x 系 → Dockerの内部ネットワークと競合している可能性あり
  • コンテナが 127.0.0.53 を参照してしまい、名前解決できない

解決の糸口

だが、ちょっと示唆深いことを言ってくれた。

Dockerの内部ネットワークと競合している可能性あり

なるほど?

あいにく私はネットワークのサブネット計算を暗算できる系人類ではないのでcopilotくんに調べさせよう。

私: 172.17.35.24/20と172.17.0.1/16ってぶつかるんだっけ・・・?


はい、ぶつかる可能性があります


🔍 IPアドレスの範囲を比較

  • 172.17.35.24/20 のネットワーク範囲は:

    • ネットワークアドレス:172.17.32.0
    • ブロードキャストアドレス:172.17.47.255
    • 使用可能なホスト範囲:172.17.32.1172.17.47.254
  • 172.17.0.1/16 のネットワーク範囲は:

    • ネットワークアドレス:172.17.0.0
    • ブロードキャストアドレス:172.17.255.255
    • 使用可能なホスト範囲:172.17.0.1172.17.255.254

✅ 結論

172.17.35.24172.17.0.0/16含まれるため、ネットワーク的には完全に重複しています

つまり、ホスト側の eth0172.17.35.24/20 を使っていて、Dockerが 172.17.0.0/16 を内部ネットワークとして使っている場合、ルーティングの競合や名前解決の失敗が起こる可能性が高いです。


🛠 対処方法

1. Dockerのデフォルトネットワークを変更する

Dockerの bridge ネットワークを別の範囲に変更することで競合を避けられます。

手順:

  1. /etc/docker/daemon.json に以下を追加:
{
 "bip": "172.30.0.1/16"
}

bip は Bridge IP の略。ここでは Docker の内部ネットワークを 172.30.0.0/16 に変更しています。

  1. Dockerを再起動:
sudo systemctl restart docker
  1. ip adocker0 の IP が 172.30.0.1 になっていることを確認

2. CIやコンテナでの名前解決が改善されるか確認

sudo docker run --rm curlimages/curl curl https://google.com

default switchとdockerのネットワークがぶつかってるのでDNSが解決できないという説が出てきた。

対処

とりあえず言われた通り対処してみる。というのも、Hyper-VのDefault Switchというのは融通が利かない子で、IPの範囲指定をする機能を持っていないからだ。かといってスイッチを作り直すのは面倒極まるし弊害がでかいので嫌だ。

main@main-virtual-machine:~$ cat /etc/docker/daemon.json
 {
    "registry-mirrors": ["https://my-mirror.example.com"]
 }
main@main-virtual-machine:~$ sudo nano /etc/docker/daemon.json
main@main-virtual-machine:~$ cat /etc/docker/daemon.json
 {
    "registry-mirrors": ["https://my-mirror.example.com"],
    "bip": "172.30.0.1/16"
 }
main@main-virtual-machine:~$ sudo systemctl restart docker
main@main-virtual-machine:~$ sudo systemctl status docker
● docker.service - Docker Application Container Engine
     Loaded: loaded (/usr/lib/systemd/system/docker.service; enabled; preset: enabled)
     Active: active (running) since Fri 2025-08-15 12:21:56 JST; 4s ago
TriggeredBy: ● docker.socket
       Docs: https://docs.docker.com
   Main PID: 48933 (dockerd)
      Tasks: 11
     Memory: 22.5M (peak: 24.6M)
        CPU: 211ms
     CGroup: /system.slice/docker.service
             └─48933 /usr/bin/dockerd -H fd:// --containerd=/run/containerd/containerd.sock

 8月 15 12:21:55 main-virtual-machine dockerd[48933]: time="2025-08-15T12:21:55.906020866+09:00" level=info msg="[graphdriver] using prior storage driver: overlay2"
 8月 15 12:21:55 main-virtual-machine dockerd[48933]: time="2025-08-15T12:21:55.929840132+09:00" level=info msg="Loading containers: start."
 8月 15 12:21:56 main-virtual-machine dockerd[48933]: time="2025-08-15T12:21:56.421482098+09:00" level=warning msg="Error (Unable to complete atomic operation, key modified) deleting object [endpoint_count 31cc1554df8662c016044c820f41a>
 8月 15 12:21:56 main-virtual-machine dockerd[48933]: time="2025-08-15T12:21:56.449905131+09:00" level=info msg="Loading containers: done."
 8月 15 12:21:56 main-virtual-machine dockerd[48933]: time="2025-08-15T12:21:56.478792958+09:00" level=info msg="Docker daemon" commit=bea959c containerd-snapshotter=false storage-driver=overlay2 version=28.3.3
 8月 15 12:21:56 main-virtual-machine dockerd[48933]: time="2025-08-15T12:21:56.479446119+09:00" level=info msg="Initializing buildkit"
 8月 15 12:21:56 main-virtual-machine dockerd[48933]: time="2025-08-15T12:21:56.492357800+09:00" level=info msg="Completed buildkit initialization"
 8月 15 12:21:56 main-virtual-machine dockerd[48933]: time="2025-08-15T12:21:56.495774527+09:00" level=info msg="Daemon has completed initialization"
 8月 15 12:21:56 main-virtual-machine dockerd[48933]: time="2025-08-15T12:21:56.495841531+09:00" level=info msg="API listen on /run/docker.sock"
 8月 15 12:21:56 main-virtual-machine systemd[1]: Started docker.service - Docker Application Container Engine.
main@main-virtual-machine:~$ ip a
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
    inet 127.0.0.1/8 scope host lo
       valid_lft forever preferred_lft forever
    inet6 ::1/128 scope host noprefixroute
       valid_lft forever preferred_lft forever
2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP group default qlen 1000
    link/ether 00:15:5d:c8:80:02 brd ff:ff:ff:ff:ff:ff
    inet 172.17.35.24/20 brd 172.17.47.255 scope global dynamic noprefixroute eth0
       valid_lft 82248sec preferred_lft 82248sec
    inet6 fe80::3f3:901c:de44:b3b6/64 scope link noprefixroute
       valid_lft forever preferred_lft forever
3: docker0: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc noqueue state DOWN group default
    link/ether 46:a4:65:c5:97:59 brd ff:ff:ff:ff:ff:ff
    inet 172.30.0.1/16 brd 172.30.255.255 scope global docker0
       valid_lft forever preferred_lft forever
    inet6 fe80::44a4:65ff:fec5:9759/64 scope link
       valid_lft forever preferred_lft forever
main@main-virtual-machine:~$ sudo docker run --rm -it docker.io/curlimages/curl:latest -v https://google.com
* Host google.com:443 was resolved.
* IPv6: 2404:6800:4004:801::200e
* IPv4: 142.250.207.46
*   Trying [2404:6800:4004:801::200e]:443...
* Immediate connect fail for 2404:6800:4004:801::200e: Network unreachable
*   Trying 142.250.207.46:443...
* ALPN: curl offers h2,http/1.1
* TLSv1.3 (OUT), TLS handshake, Client hello (1):
*  CAfile: /cacert.pem
*  CApath: none
* TLSv1.3 (IN), TLS handshake, Server hello (2):
* TLSv1.3 (IN), TLS change cipher, Change cipher spec (1):
* TLSv1.3 (IN), TLS handshake, Encrypted Extensions (8):
* TLSv1.3 (IN), TLS handshake, Certificate (11):
* TLSv1.3 (IN), TLS handshake, CERT verify (15):
* TLSv1.3 (IN), TLS handshake, Finished (20):
* TLSv1.3 (OUT), TLS change cipher, Change cipher spec (1):
* TLSv1.3 (OUT), TLS handshake, Finished (20):
* SSL connection using TLSv1.3 / TLS_AES_256_GCM_SHA384 / X25519MLKEM768 / id-ecPublicKey
* ALPN: server accepted h2
* Server certificate:
*  subject: CN=*.google.com
*  start date: Jul  7 08:34:03 2025 GMT
*  expire date: Sep 29 08:34:02 2025 GMT
*  subjectAltName: host "google.com" matched cert's "google.com"
*  issuer: C=US; O=Google Trust Services; CN=WR2
*  SSL certificate verify ok.
*   Certificate level 0: Public key type EC/prime256v1 (256/128 Bits/secBits), signed using sha256WithRSAEncryption
*   Certificate level 1: Public key type RSA (2048/112 Bits/secBits), signed using sha256WithRSAEncryption
*   Certificate level 2: Public key type RSA (4096/152 Bits/secBits), signed using sha384WithRSAEncryption
* Connected to google.com (142.250.207.46) port 443
* using HTTP/2
* [HTTP/2] [1] OPENED stream for https://google.com/
* [HTTP/2] [1] [:method: GET]
* [HTTP/2] [1] [:scheme: https]
* [HTTP/2] [1] [:authority: google.com]
* [HTTP/2] [1] [:path: /]
* [HTTP/2] [1] [user-agent: curl/8.15.0]
* [HTTP/2] [1] [accept: */*]
> GET / HTTP/2
> Host: google.com
> User-Agent: curl/8.15.0
> Accept: */*
>
* Request completely sent off
* TLSv1.3 (IN), TLS handshake, Newsession Ticket (4):
* TLSv1.3 (IN), TLS handshake, Newsession Ticket (4):
< HTTP/2 301
< location: https://www.google.com/
< content-type: text/html; charset=UTF-8
< content-security-policy-report-only: object-src 'none';base-uri 'self';script-src 'nonce-H0VYpdlaIFhKjZRJlHuGvA' 'strict-dynamic' 'report-sample' 'unsafe-eval' 'unsafe-inline' https: http:;report-uri https://csp.withgoogle.com/csp/gws/other-hp
< date: Fri, 15 Aug 2025 03:22:29 GMT
< expires: Sun, 14 Sep 2025 03:22:29 GMT
< cache-control: public, max-age=2592000
< server: gws
< content-length: 220
< x-xss-protection: 0
< x-frame-options: SAMEORIGIN
< alt-svc: h3=":443"; ma=2592000,h3-29=":443"; ma=2592000
<
<HTML><HEAD><meta http-equiv="content-type" content="text/html;charset=utf-8">
<TITLE>301 Moved</TITLE></HEAD><BODY>
<H1>301 Moved</H1>
The document has moved
<A HREF="https://www.google.com/">here</A>.
</BODY></HTML>
* Connection #0 to host google.com left intact

なおったぽい!

0
0
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
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?