Ubuntu18.04 下载和安装package/library时报错及解决方法汇总 (不定时更新)

在Ubuntu系统里面下载和安装一些库和包总是报各种各样的错误,记录一下:

  1. apt-get install安装包时报错
E: Could not get lock /var/lib/dpkg/lock-frontend - open (11: Resource temporarily unavailable)
E: Unable to acquire the dpkg frontend lock (/var/lib/dpkg/lock-frontend), is another process using it?

删除锁定文件,然后重新run一次指令就好

sudo rm /var/lib/dpkg/lock-frontend

sudo rm /var/lib/dpkg/lock
  1. rosdep install --from-paths src --ignore-src -r -y安装依赖项时报错
After this operation, 652 kB of additional disk space will be used.
Err:1 http://packages.ros.org/ros/ubuntu bionic/main amd64 ros-melodic-rosserial-client amd64 0.8.0-0bionic.20210921.215203
  404  Not Found [IP: 64.50.236.52 80]
Err:2 http://packages.ros.org/ros/ubuntu bionic/main amd64 ros-melodic-rosserial-python amd64 0.8.0-0bionic.20210921.203044
  404  Not Found [IP: 64.50.236.52 80]
Err:3 http://packages.ros.org/ros/ubuntu bionic/main amd64 ros-melodic-rosserial amd64 0.8.0-0bionic.20210921.220548
  404  Not Found [IP: 64.50.236.52 80]
E: Failed to fetch http://packages.ros.org/ros/ubuntu/pool/main/r/ros-melodic-rosserial-client/ros-melodic-rosserial-client_0.8.0-0bionic.20210921.215203_amd64.deb  404  Not Found [IP: 64.50.236.52 80]
E: Failed to fetch http://packages.ros.org/ros/ubuntu/pool/main/r/ros-melodic-rosserial-python/ros-melodic-rosserial-python_0.8.0-0bionic.20210921.203044_amd64.deb  404  Not Found [IP: 64.50.236.52 80]
E: Failed to fetch http://packages.ros.org/ros/ubuntu/pool/main/r/ros-melodic-rosserial/ros-melodic-rosserial_0.8.0-0bionic.20210921.220548_amd64.deb  404  Not Found [IP: 64.50.236.52 80]
E: Unable to fetch some archives, maybe run apt-get update or try with --fix-missing?
ERROR: the following rosdeps failed to install
  apt: command [sudo -H apt-get install -y ros-melodic-apriltag] failed
  apt: command [sudo -H apt-get install -y ros-melodic-joint-state-publisher-gui] failed
  apt: command [sudo -H apt-get install -y ros-melodic-robot-localization] failed
  apt: command [sudo -H apt-get install -y ros-melodic-teleop-twist-keyboard] failed
  apt: command [sudo -H apt-get install -y ros-melodic-imu-transformer] failed
  apt: command [sudo -H apt-get install -y ros-melodic-rosserial] failed
  apt: Failed to detect successful installation of [ros-melodic-apriltag]
  apt: Failed to detect successful installation of [ros-melodic-joint-state-publisher-gui]
  apt: Failed to detect successful installation of [ros-melodic-robot-localization]
  apt: Failed to detect successful installation of [ros-melodic-teleop-twist-keyboard]
  apt: Failed to detect successful installation of [ros-melodic-imu-transformer]
  apt: Failed to detect successful installation of [ros-melodic-rosserial]

这个只需要更新一下apt-get就行了

sudo apt-get update
  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 1
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值