环境:
rk3399pro + ubuntu18.04.
问题:
修改ubuntu根文件系统时,不能apt-get update。
错误信息:
root@sams-desktop:/# apt-get update
Get:1 https://repo.huaweicloud.com/ubuntu-ports bionic InRelease [242 kB]
Get:2 https://repo.huaweicloud.com/ubuntu-ports bionic-security InRelease [88.7 kB]
Get:3 https://repo.huaweicloud.com/ubuntu-ports bionic-updates InRelease [88.7 kB]
Get:4 https://repo.huaweicloud.com/ubuntu-ports bionic-backports InRelease [74.6 kB]
Err:1 https://repo.huaweicloud.com/ubuntu-ports bionic InRelease
Couldn't create temporary file /tmp/apt.conf.cBC7Lj for passing config to apt-key
Err:2 https://repo.huaweicloud.com/ubuntu-ports bionic-security InRelease
Couldn't create temporary file /tmp/apt.conf.9QXhoc for passing config to apt-key
Err:3 https://repo.huaweicloud.com/ubuntu-ports bionic-updates InRelease
Couldn't create temporary file /tmp/apt.conf.36WDOa for passing config to apt-key
Err:4 https://repo.huaweicloud.com/ubuntu-ports bionic-backports InRelease
Couldn't create temporary file /tmp/apt.conf.DeFxma for passing config to apt-key
Reading package lists... Done
W: GPG error: https://repo.huaweicloud.com/ubuntu-ports bionic InRelease: Couldn't create temporary file /tmp/apt.conf.cBC7Lj for passing config to apt-key
E: The repository 'https://repo.huaweicloud.com/ubuntu-ports bionic 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.
W: GPG error: https://repo.huaweicloud.com/ubuntu-ports bionic-security InRelease: Couldn't create temporary file /tmp/apt.conf.9QXhoc for passing config to apt-key
E: The repository 'https://repo.huaweicloud.com/ubuntu-ports bionic-security 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.
W: GPG error: https://repo.huaweicloud.com/ubuntu-ports bionic-updates InRelease: Couldn't create temporary file /tmp/apt.conf.36WDOa for passing config to apt-key
E: The repository 'https://repo.huaweicloud.com/ubuntu-ports bionic-updates 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.
W: GPG error: https://repo.huaweicloud.com/ubuntu-ports bionic-backports InRelease: Couldn't create temporary file /tmp/apt.conf.DeFxma for passing config to apt-key
E: The repository 'https://repo.huaweicloud.com/ubuntu-ports bionic-backports 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.
错误原因:
根文件系统中没有 tmp 目录。创建目录并分配权限,即可解决问题。
处理方法:
/# mkdir tmp
/# chmod 777 /tmp
ARM64 UBUNTU 更新源设置:
参考:
https://blog.csdn.net/c417469898/article/details/106412687/
使用华为源。
本文参考:
https://xie.infoq.cn/article/b81ac033bbe40fca501828302
完毕。
版权声明:本文为qs521原创文章,遵循 CC 4.0 BY-SA 版权协议,转载请附上原文出处链接和本声明。