我搞砸了。如何清理仓库?无法正常更新

我搞砸了。如何清理仓库?无法正常更新

我是 Ubuntu 服务器的新手。我完成了这些,现在,当我运行 时sudo apt update,收到以下消息:

E: Failed to fetch http://download.onlyoffice.com/repo/d.../dists/squeeze/InRelease  403  Forbidden [IP: 108.157.214.62 80]
E: The repository 'http://download.onlyoffice.com/repo/d... squeeze InRelease' is not signed.
N: Updating from such a repository can't be done securely, and is therefore disabled by default.
N: See apt-secure(8) manpage for repository creation and user configuration details.

如何清洁?谢谢帮助!

答案1

下次,请添加更多上下文,而不是“,做了这个做了那个,现在”。我确实设法追踪了你运行的命令,从https://helpcenter.onlyoffice.com/installation/docs-developer-install-ubuntu.aspx这个在这里:

echo "deb https://download.onlyoffice.com/repo/debian squeeze main" | sudo tee /etc/apt/sources.list.d/onlyoffice.list

如果你想要继续 OnlyOffice 教程,让我们删除 repo。运行此命令:

sudo rm /etc/apt/sources.list.d/onlyoffice.list

Ubuntu 现在不会尝试从该存储库中提取。让我们使用 apt 更新存储库:

sudo apt update

如果你想要继续安装,让我们回到您跳过的步骤:

mkdir -p ~/.gnupg
chmod 700 ~/.gnupg
gpg --no-default-keyring --keyring gnupg-ring:/tmp/onlyoffice.gpg --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys CB2DE8E5
chmod 644 /tmp/onlyoffice.gpg
sudo chown root:root /tmp/onlyoffice.gpg
sudo mv /tmp/onlyoffice.gpg /etc/apt/trusted.gpg.d/

如果您在此步骤中遇到问题,则可能是缺少软件包。运行:

sudo apt install gnupg gpg ca-certificates

最后,使用 apt 更新 repos:

sudo apt update

成功的响应将包括以下内容:

Get:5 https://download.onlyoffice.com/repo/debian squeeze InRelease [10.7 kB]
Get:6 https://download.onlyoffice.com/repo/debian squeeze/main amd64 Packages [14.6 kB]

相关内容