Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Unable to install ROS Melodic on Ubuntu 20.04

Tags:

ubuntu

ros

I am trying to install ROS Melodic on Ubuntu 20.04 using these commands

sudo sh -c 'echo "deb http://packages.ros.org/ros/ubuntu $(lsb_release -sc) main" > /etc/apt/sources.list.d/ros-latest.list'
sudo apt-key adv --keyserver 'hkp://keyserver.ubuntu.com:80' --recv-key C1CF6E31E6BADE8868B172B4F42ED6FBAB17C654
sudo apt update
sudo apt install ros-melodic-desktop-full

But I get this error

E: Unable to locate package ros-melodic-desktop-full

I have tried to install the different versions and Kinetic Kame but they all give me the same error.

like image 760
Jimmy202020 Avatar asked Dec 07 '22 10:12

Jimmy202020


1 Answers

In your case, this won't work. There is no ROS version for Ubuntu 20, and Melodic is only found on Ubuntu 18. I recommend installing Ubuntu 18 if you have the choice.

ROS has a strict versioning scheme that aligns with different versions of Ubuntu. Ex:

  • Ubuntu 14 (aka Trusty) == ROS Indigo
  • Ubuntu 16 (aka Xenial) == ROS Kinetic
  • Ubuntu 18 (aka Bionic) == ROS Melodic
  • Ubuntu 20 (aka Focal) == ROS Noetic
  • Ubuntu 22 (N/A)

(You can still, like, manually compile ROS, but I'd recommend against it for sanity's sake. Less things to go wrong)

EDIT!

I originally wrote this on May 22, 2020, not realizing that ROS Noetic was going to be released on May 23, 2020. It should have full official apt support, just like the rest of the ROS versions. If you're set on using Ubuntu 20 vs 18, Noetic installed via apt is now the official way to go!

like image 157
JWCS Avatar answered Dec 09 '22 22:12

JWCS