rosdep update - smithgithub/RPi GitHub Wiki

rosdep update
reading in sources list data from /etc/ros/rosdep/sources.list.d ERROR: unable to process source [https://raw.githubusercontent.com/ros/rosdistro/master/rosdep/osx-homebrew.yaml]: <urlopen error [Errno 111] Connection refused> (https://raw.githubusercontent.com/ros/rosdistro/master/rosdep/osx-homebrew.yaml) ERROR: unable to process source [https://raw.githubusercontent.com/ros/rosdistro/master/rosdep/base.yaml]: <urlopen error [Errno 111] Connection refused> (https://raw.githubusercontent.com/ros/rosdistro/master/rosdep/base.yaml) ERROR: unable to process source [https://raw.githubusercontent.com/ros/rosdistro/master/rosdep/python.yaml]: <urlopen error [Errno 111] Connection refused> (https://raw.githubusercontent.com/ros/rosdistro/master/rosdep/python.yaml) ERROR: unable to process source [https://raw.githubusercontent.com/ros/rosdistro/master/rosdep/ruby.yaml]: <urlopen error [Errno 111] Connection refused> (https://raw.githubusercontent.com/ros/rosdistro/master/rosdep/ruby.yaml) ERROR: unable to process source [https://raw.githubusercontent.com/ros/rosdistro/master/releases/fuerte.yaml]: Failed to download target platform data for gbpdistro: <urlopen error [Errno 111] Connection refused> Query rosdistro index https://raw.githubusercontent.com/ros/rosdistro/master/index-v4.yaml ERROR: error loading sources list: <urlopen error <urlopen error [Errno 111] Connection refused> (https://raw.githubusercontent.com/ros/rosdistro/master/index-v4.yaml)> ubuntu@ubuntu:~/source/catkin_ws$ rosdep install --from-paths src --ignore-src --rosdistro=noetic -y --os=ubuntu:focal

ERROR: your rosdep installation has not been initialized yet. Please run:

rosdep update

ubuntu@ubuntu:~/source/catkin_ws$

解决办法:

sudo gedit /etc/resolv.conf

将原有的nameserver这一行注释,并添加以下两行:

nameserver 8.8.8.8 #google域名服务器

nameserver 8.8.4.4 #google域名服务器

保存退出,执行

sudo  apt-get update

再执行

rosdep update