Ubuntu 系统上 apt 源列表中的条目格式错误

Ubuntu 系统上 apt 源列表中的条目格式错误

在此输入图像描述

每次我尝试安装某些东西时都会显示此错误,请帮助我,因为我对 /etc/apt/sources.list 中基于 Linux 的操作系统内容不熟悉

# deb cdrom:[Ubuntu 20.04.3 LTS _Focal Fossa_ - Release amd64 (20210819)]/ focal main restricted

# See http://help.ubuntu.com/community/UpgradeNotes for how to upgrade to
# newer versions of the distribution.
deb http://in.archive.ubuntu.com/ubuntu/ focal main restricted
# deb-src http://in.archive.ubuntu.com/ubuntu/ focal main restricted

## Major bug fix updates produced after the final release of the
## distribution.
deb http://in.archive.ubuntu.com/ubuntu/ focal-updates main restricted
# deb-src http://in.archive.ubuntu.com/ubuntu/ focal-updates main restricted

## N.B. software from this repository is ENTIRELY UNSUPPORTED by the Ubuntu
## team. Also, please note that software in universe WILL NOT receive any
## review or updates from the Ubuntu security team.
deb http://in.archive.ubuntu.com/ubuntu/ focal universe
# deb-src http://in.archive.ubuntu.com/ubuntu/ focal universe
deb http://in.archive.ubuntu.com/ubuntu/ focal-updates universe
# deb-src http://in.archive.ubuntu.com/ubuntu/ focal-updates universe

## N.B. software from this repository is ENTIRELY UNSUPPORTED by the Ubuntu 
## team, and may not be under a free licence. Please satisfy yourself as to 
## your rights to use the software. Also, please note that software in 
## multiverse WILL NOT receive any review or updates from the Ubuntu
## security team.
deb http://in.archive.ubuntu.com/ubuntu/ focal multiverse
# deb-src http://in.archive.ubuntu.com/ubuntu/ focal multiverse
deb http://in.archive.ubuntu.com/ubuntu/ focal-updates multiverse
# deb-src http://in.archive.ubuntu.com/ubuntu/ focal-updates multiverse

## N.B. software from this repository may not have been tested as
## extensively as that contained in the main release, although it includes
## newer versions of some applications which may provide useful features.
## Also, please note that software in backports WILL NOT receive any review
## or updates from the Ubuntu security team.
deb http://in.archive.ubuntu.com/ubuntu/ focal-backports main restricted universe multiverse
# deb-src http://in.archive.ubuntu.com/ubuntu/ focal-backports main restricted universe multiverse

## Uncomment the following two lines to add software from Canonical's
## 'partner' repository.
## This software is not part of Ubuntu, but is offered by Canonical and the
## respective vendors as a service to Ubuntu users.
# deb http://archive.canonical.com/ubuntu focal partner
# deb-src http://archive.canonical.com/ubuntu focal partner

deb http://security.ubuntu.com/ubuntu focal-security main restricted
# deb-src http://security.ubuntu.com/ubuntu focal-security main restricted
deb http://security.ubuntu.com/ubuntu focal-security universe
# deb-src http://security.ubuntu.com/ubuntu focal-security universe
deb http://security.ubuntu.com/ubuntu focal-security multiverse
# deb-src http://security.ubuntu.com/ubuntu focal-security multiverse

# This system was installed using small removable media
# (e.g. netinst, live or single CD). The matching "deb cdrom"
# entries were disabled at the end of the installation process.
# For information about how to configure apt package sources,
# see the sources.list(5) manual.
deb http://www.geogebra.net/linux/stable main
# deb-src http://www.geogebra.net/linux/stable main
deb http://www.geogebra.net/linux/pool/main/g/geogebra-classic/ focal
# deb-src http://www.geogebra.net/linux/pool/main/g/geogebra-classic/ focal

答案1

正确的存储库是:

deb http://www.geogebra.net/linux/ stable main

要修复您的sources.list

sudo sed -i '/geogebra/d' /etc/apt/sources.list

干净地添加geogebra存储库:

sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys C072A32983A736CF
sudo add-apt-repository "deb http://www.geogebra.net/linux/ stable main"
sudo apt update

答案2

我同意评论说你不应该发布文字图片,以及建议你合并帐户的评论。

这是一个非常简单的问题,错误消息基本上说明了错误所在,第 58 行sources.list,即

deb http://www.geogebra.net/linux/stable main

我还没有尝试安装 geogebra,所以我不确定正确的线应该是什么样子,但我的猜测是你应该用空格替换最后一个(即和/之间的线)。linuxstable

第 60 行也sources.list有同样的问题,我的直觉是删除该行(但正如我所说,我没有尝试安装gegebra)。

相关内容