ubuntu24.04 apt更新源后出现architecture错误信息[Resolved]

2024/06/14 Development

修复新版apt更新源报错

问题描述

升级到ubuntu24.04后,之前装的msedge,chrome的apt源在update的时候总会报如下错误:

N: Skipping acquire of configured file 'main/binary-i386/Packages' as repository 'https://dl.google.com/linux/chrome/deb stable InRelease' doesn't support architecture 'i386'
N: Skipping acquire of configured file 'main/binary-i386/Packages' as repository 'https://packages.microsoft.com/repos/edge stable InRelease' doesn't support architecture 'i386'

看样子是没有指定架构,之前的sources文件应该是这样的

deb [arch=amd64] https://dl.google.com/linux/chrome/deb/ stable main

现在好像把PGP也合进来了,类似这样

Types: deb
URIs: https://dl.google.com/linux/chrome/deb/
Suites: stable
Components: main
Signed-By:
 -----BEGIN PGP PUBLIC KEY BLOCK-----
 -----END PGP PUBLIC KEY BLOCK-----

看样子没有加入之前的arch属性

问题解决

sources直接手动加入Architectures: amd64即可

Types: deb
Architectures: amd64
URIs: https://dl.google.com/linux/chrome/deb/
Suites: stable
Components: main
Signed-By:
 -----BEGIN PGP PUBLIC KEY BLOCK-----
 -----END PGP PUBLIC KEY BLOCK-----

如果需要批量修改,可以参考这个脚本

Search

    Table of Contents