首页
学习
活动
专区
圈层
工具
发布
首页
学习
活动
专区
圈层
工具
MCP广场
社区首页 >问答首页 >Debian 10 buster apt更新失败-只读文件系统

Debian 10 buster apt更新失败-只读文件系统
EN

Unix & Linux用户
提问于 2021-05-19 10:46:12
回答 2查看 3.6K关注 0票数 0

在我的Debian 10 buster服务器上启用了自动更新。但是,我注意到在手动运行apt update命令时出现了许多错误:

代码语言:javascript
运行
复制
Err:2 http://security.debian.org/debian-security buster/updates Release
  Could not open file /var/lib/apt/lists/partial/security.debian.org_debian-security_dists_buster_updates_Release - open (30: Read-only file system) [IP:]
Hit:3 http://ftp.de.debian.org/debian stable InRelease
Err:3 http://ftp.de.debian.org/debian stable InRelease
  Couldn't create temporary file /tmp/apt.conf.eYF3oi for passing config to apt-key
Hit:4 https://deb.nodesource.com/node_12.x buster InRelease
Err:4 https://deb.nodesource.com/node_12.x buster InRelease
  Couldn't create temporary file /tmp/apt.conf.CraMte for passing config to apt-key
Hit:5 https://artifacts.elastic.co/packages/7.x/apt stable InRelease
Err:5 https://artifacts.elastic.co/packages/7.x/apt stable InRelease
  Couldn't create temporary file /tmp/apt.conf.PnxFvd for passing config to apt-key
Hit:6 https://packages.sury.org/php buster InRelease
Err:6 https://packages.sury.org/php buster InRelease
  Couldn't create temporary file /tmp/apt.conf.YH5tQi for passing config to apt-key
Hit:7 http://repo.mysql.com/apt/debian buster InRelease
Err:7 http://repo.mysql.com/apt/debian buster InRelease
  Couldn't create temporary file /tmp/apt.conf.nny8ap for passing config to apt-key
Reading package lists... Done
W: chown to _apt:root of directory /var/lib/apt/lists/partial failed - SetupAPTPartialDirectory (30: Read-only file system)
W: chmod 0700 of directory /var/lib/apt/lists/partial failed - SetupAPTPartialDirectory (30: Read-only file system)
W: chown to _apt:root of directory /var/lib/apt/lists/auxfiles failed - SetupAPTPartialDirectory (30: Read-only file system)
W: chmod 0700 of directory /var/lib/apt/lists/auxfiles failed - SetupAPTPartialDirectory (30: Read-only file system)
W: Not using locking for read only lock file /var/lib/apt/lists/lock
W: Problem unlinking the file /var/lib/apt/lists/partial/.apt-acquire-privs-test.AK6iXs - IsAccessibleBySandboxUser (30: Read-only file system)
W: Problem unlinking the file /var/lib/apt/lists/partial/.apt-acquire-privs-test.IWp7Gu - IsAccessibleBySandboxUser (30: Read-only file system)
W: Problem unlinking the file /var/lib/apt/lists/partial/.apt-acquire-privs-test.aIUVqw - IsAccessibleBySandboxUser (30: Read-only file system)
W: Problem unlinking the file /var/lib/apt/lists/partial/.apt-acquire-privs-test.qFwKay - IsAccessibleBySandboxUser (30: Read-only file system)
W: Problem unlinking the file /var/lib/apt/lists/partial/.apt-acquire-privs-test.a5kzUz - IsAccessibleBySandboxUser (30: Read-only file system)
W: Problem unlinking the file /var/lib/apt/lists/partial/.apt-acquire-privs-test.EGgoEB - IsAccessibleBySandboxUser (30: Read-only file system)
W: Problem unlinking the file /var/lib/apt/lists/partial/security.debian.org_debian-security_dists_buster_updates_InRelease - PrepareFiles (30: Read-only file system)
W: Problem unlinking the file /var/lib/apt/lists/partial/security.debian.org_debian-security_dists_buster_updates_Release - PrepareFiles (30: Read-only file system)
E: The repository 'http://security.debian.org/debian-security buster/updates Release' no longer has a Release file.
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.
W: Problem unlinking the file /var/lib/apt/lists/partial/ftp.de.debian.org_debian_dists_stable_InRelease - PrepareFiles (30: Read-only file system)
W: chown to _apt:root of file /var/lib/apt/lists/ftp.de.debian.org_debian_dists_stable_InRelease failed - Item::QueueURI (30: Read-only file system)
W: chmod 0600 of file /var/lib/apt/lists/ftp.de.debian.org_debian_dists_stable_InRelease failed - Item::QueueURI (30: Read-only file system)
W: chown to root:root of file /var/lib/apt/lists/ftp.de.debian.org_debian_dists_stable_InRelease failed - 400::URIFailure (30: Read-only file system)
W: chmod 0644 of file /var/lib/apt/lists/ftp.de.debian.org_debian_dists_stable_InRelease failed - 400::URIFailure (30: Read-only file system)
W: An error occurred during the signature verification. The repository is not updated and the previous index files will be used. GPG error: http://ftp.de.debian.org/debian stable InRelease: Couldn't create temporary file /tmp/apt.conf.eYF3oi for passing config to apt-key
W: Problem unlinking the file /var/lib/apt/lists/partial/deb.nodesource.com_node%5f12.x_dists_buster_InRelease - PrepareFiles (30: Read-only file system)
W: chown to _apt:root of file /var/lib/apt/lists/deb.nodesource.com_node%5f12.x_dists_buster_InRelease failed - Item::QueueURI (30: Read-only file system)
W: chmod 0600 of file /var/lib/apt/lists/deb.nodesource.com_node%5f12.x_dists_buster_InRelease failed - Item::QueueURI (30: Read-only file system)
W: chown to root:root of file /var/lib/apt/lists/deb.nodesource.com_node%5f12.x_dists_buster_InRelease failed - 400::URIFailure (30: Read-only file system)
W: chmod 0644 of file /var/lib/apt/lists/deb.nodesource.com_node%5f12.x_dists_buster_InRelease failed - 400::URIFailure (30: Read-only file system)
W: An error occurred during the signature verification. The repository is not updated and the previous index files will be used. GPG error: https://deb.nodesource.com/node_12.x buster InRelease: Couldn't create temporary file /tmp/apt.conf.CraMte for passing config to apt-key
W: Problem unlinking the file /var/lib/apt/lists/partial/artifacts.elastic.co_packages_7.x_apt_dists_stable_InRelease - PrepareFiles (30: Read-only file system)
W: chown to _apt:root of file /var/lib/apt/lists/artifacts.elastic.co_packages_7.x_apt_dists_stable_InRelease failed - Item::QueueURI (30: Read-only file system)
W: chmod 0600 of file /var/lib/apt/lists/artifacts.elastic.co_packages_7.x_apt_dists_stable_InRelease failed - Item::QueueURI (30: Read-only file system)
W: chown to root:root of file /var/lib/apt/lists/artifacts.elastic.co_packages_7.x_apt_dists_stable_InRelease failed - 400::URIFailure (30: Read-only file system)
W: chmod 0644 of file /var/lib/apt/lists/artifacts.elastic.co_packages_7.x_apt_dists_stable_InRelease failed - 400::URIFailure (30: Read-only file system)
W: An error occurred during the signature verification. The repository is not updated and the previous index files will be used. GPG error: https://artifacts.elastic.co/packages/7.x/apt stable InRelease: Couldn't create temporary file /tmp/apt.conf.PnxFvd for passing config to apt-key
W: Problem unlinking the file /var/lib/apt/lists/partial/packages.sury.org_php_dists_buster_InRelease - PrepareFiles (30: Read-only file system)
W: chown to _apt:root of file /var/lib/apt/lists/packages.sury.org_php_dists_buster_InRelease failed - Item::QueueURI (30: Read-only file system)
W: chmod 0600 of file /var/lib/apt/lists/packages.sury.org_php_dists_buster_InRelease failed - Item::QueueURI (30: Read-only file system)
W: chown to root:root of file /var/lib/apt/lists/packages.sury.org_php_dists_buster_InRelease failed - 400::URIFailure (30: Read-only file system)
W: chmod 0644 of file /var/lib/apt/lists/packages.sury.org_php_dists_buster_InRelease failed - 400::URIFailure (30: Read-only file system)
W: An error occurred during the signature verification. The repository is not updated and the previous index files will be used. GPG error: https://packages.sury.org/php buster InRelease: Couldn't create temporary file /tmp/apt.conf.YH5tQi for passing config to apt-key
W: Problem unlinking the file /var/lib/apt/lists/partial/repo.mysql.com_apt_debian_dists_buster_InRelease - PrepareFiles (30: Read-only file system)
W: chown to _apt:root of file /var/lib/apt/lists/repo.mysql.com_apt_debian_dists_buster_InRelease failed - Item::QueueURI (30: Read-only file system)
W: chmod 0600 of file /var/lib/apt/lists/repo.mysql.com_apt_debian_dists_buster_InRelease failed - Item::QueueURI (30: Read-only file system)
W: chown to root:root of file /var/lib/apt/lists/repo.mysql.com_apt_debian_dists_buster_InRelease failed - 400::URIFailure (30: Read-only file system)
W: chmod 0644 of file /var/lib/apt/lists/repo.mysql.com_apt_debian_dists_buster_InRelease failed - 400::URIFailure (30: Read-only file system)
W: An error occurred during the signature verification. The repository is not updated and the previous index files will be used. GPG error: http://repo.mysql.com/apt/debian buster InRelease: Couldn't create temporary file /tmp/apt.conf.nny8ap for passing config to apt-key
W: Problem unlinking the file /var/cache/apt/pkgcache.bin - RemoveCaches (30: Read-only file system)
W: Problem unlinking the file /var/cache/apt/srcpkgcache.bin - RemoveCaches (30: Read-only file system)

我认为错误是由于服务器没有正确关闭而造成的。

你能帮我解决这个问题吗?谢谢!

EN

回答 2

Unix & Linux用户

发布于 2021-05-19 11:41:49

我认为错误是由于服务器没有正确关闭而造成的。

这实际上是我在这里读到的主要问题

我的其他Ubuntu实例也受到相同问题的影响。为了解决问题,我重新启动了服务器!

票数 1
EN

Unix & Linux用户

发布于 2021-05-19 23:41:42

可以将文件系统重装为读/写,但不要这样做。我建议在文件系统上运行fsck,这将需要重新启动,因为它必须有写访问权才能修复任何错误。

如何在重新启动时强制fsck:

代码语言:javascript
运行
复制
sudo shutdown -rF now

或者(如果你可以写信给/)

代码语言:javascript
运行
复制
sudo touch /forcefsck
sudo reboot now
票数 0
EN
页面原文内容由Unix & Linux提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://unix.stackexchange.com/questions/650393

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档