0
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 1 year has passed since last update.

WSL2環境でapt-get updateに失敗する

Posted at

問題

WSL2環境にてapt-get updateに失敗する

原因

セキュリティソフトが原因()
image.png

エラー内容

Some index files failed to download. They have been ignored, or old ones used instead.

~$ sudo apt-get update
Ign:1 http://security.ubuntu.com/ubuntu jammy-security InRelease
Ign:2 http://archive.ubuntu.com/ubuntu jammy InRelease
Ign:3 http://archive.ubuntu.com/ubuntu jammy-updates InRelease
Ign:4 http://archive.ubuntu.com/ubuntu jammy-backports InRelease
Ign:1 http://security.ubuntu.com/ubuntu jammy-security InRelease
Ign:2 http://archive.ubuntu.com/ubuntu jammy InRelease
Ign:3 http://archive.ubuntu.com/ubuntu jammy-updates InRelease
Ign:4 http://archive.ubuntu.com/ubuntu jammy-backports InRelease
Ign:1 http://security.ubuntu.com/ubuntu jammy-security InRelease
Ign:2 http://archive.ubuntu.com/ubuntu jammy InRelease
Ign:3 http://archive.ubuntu.com/ubuntu jammy-updates InRelease
Ign:4 http://archive.ubuntu.com/ubuntu jammy-backports InRelease
Err:1 http://security.ubuntu.com/ubuntu jammy-security InRelease
<!-- 省略 -->
W: Some index files failed to download. They have been ignored, or old ones used instead.

解決方法

解決方法は2つあります。

1.Symantecくんを消す

  • 消すことができる環境であれば、最も手軽で楽な方法です。
    (学校・企業などでは消せないことも...)

2.Proxyを経由させる

  1. Proxyのインストール
    https://squid.diladele.com/

  2. bashrcを編集してProxyを経由させる

    nano ~/.bashrc

    export http_proxy="http://<windows host ip address>:3128"
    export https_proxy="http://<windows host ip address>:3128"
    
  3. リソースの再読み込み

    source ~/.bashrc

  4. 再度アップデートを実行する

    sudo apt update

心の声

Symantecくん...私の時間を返して...

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

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?