# Stretch robot installation error \[Ubuntu 20.04\]

**URL:** <https://forum.hello-robot.com/t/stretch-robot-installation-error-ubuntu-20-04/594>\
**Category:** Ask\
**Created:** [February 14, 2023, 9:08pm UTC](https://forum.hello-robot.com/t/stretch-robot-installation-error-ubuntu-20-04/594 "2023-02-14T21:08:55Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![srama2512](https://yyz2.discourse-cdn.com/flex030/user_avatar/forum.hello-robot.com/srama2512/32/354_2.png) [@srama2512](https://forum.hello-robot.com/u/srama2512)\
**Post date:** [February 14, 2023, 9:08pm UTC](https://forum.hello-robot.com/t/stretch-robot-installation-error-ubuntu-20-04/594/1 "2023-02-14T21:08:55Z")

</div>

I installed ubuntu 20.04 today and performed the robot installation steps following [this](https://github.com/hello-robot/stretch_install/blob/master/docs/robot_install.md#run-the-new-robot-installation-script). The installation failed at `CREATE GALACTIC AMENT WORKSPACE at /home/hello-robot/ament_ws`. It seems to fail at the `stretch_navigation` package:

```auto
--- stderr: stretch_navigation
CMake Error at cmake_install.cmake:49 (file):
  file INSTALL cannot find
  "/home/hello-robot/ament_ws/src/stretch_ros2/stretch_navigation/map": No
  such file or directory.

```

I have attached the detailed logs [here](https://drive.google.com/file/d/1LT-rkSjaQzPiw1lC3arzuebJ1De3xRks/view?usp=share_link).

---

<div class="post-metadata">

**Author:** ![chintujaguar](https://yyz2.discourse-cdn.com/flex030/user_avatar/forum.hello-robot.com/chintujaguar/32/260_2.png) [@chintujaguar](https://forum.hello-robot.com/u/chintujaguar)\
**Post date:** [February 14, 2023, 9:54pm UTC](https://forum.hello-robot.com/t/stretch-robot-installation-error-ubuntu-20-04/594/2 "2023-02-14T21:54:42Z")

</div>

Hey @srama2512, thank you for reporting this issue. It was a result of an erroneous addition of the map directory to the [CMakelists.txt file](https://github.com/hello-robot/stretch_ros2/commit/32d804f60fbd084e63cb417b58bcc43c0b664a0b) of the stretch\_navigation package. This has now been corrected.

Seeing as you were performing a new robot install, please run the following steps to create a fresh ament\_ws:

```bash
cd ~/stretch_install
./factory/20.04/stretch_create_ament_workspace.sh

```

Have a look at the [creating a new workspace guide](https://github.com/hello-robot/stretch_install/blob/master/docs/ros_workspace.md#ubuntu-2004) to know more.

Best,  
Chintan

---

<div class="post-metadata">

**Author:** ![srama2512](https://yyz2.discourse-cdn.com/flex030/user_avatar/forum.hello-robot.com/srama2512/32/354_2.png) [@srama2512](https://forum.hello-robot.com/u/srama2512)\
**Post date:** [February 14, 2023, 10:46pm UTC](https://forum.hello-robot.com/t/stretch-robot-installation-error-ubuntu-20-04/594/3 "2023-02-14T22:46:27Z")

</div>

Thanks, @chintujaguar ! This did the trick. I got the “conflicting ROS version sourced” error as mentioned in the troubleshooting section. I successfully installed after commenting out the setup.bash commands in bashrc. Should I uncomment them now?

---

<div class="post-metadata">

**Author:** ![chintujaguar](https://yyz2.discourse-cdn.com/flex030/user_avatar/forum.hello-robot.com/chintujaguar/32/260_2.png) [@chintujaguar](https://forum.hello-robot.com/u/chintujaguar)\
**Post date:** [February 14, 2023, 11:32pm UTC](https://forum.hello-robot.com/t/stretch-robot-installation-error-ubuntu-20-04/594/4 "2023-02-14T23:32:34Z")

</div>

@srama2512, glad to know that the installation was successful.

You should only uncomment the source commands for the ROS distro you want to use. For example, if you want to use ROS Noetic, your .bashrc setup would look like this:

```bash
source /opt/ros/noetic/setup.bash
# source /opt/ros/galactic/setup.bash
source ~/catkin_ws/devel/setup.bash
# source ~/ament_ws/install/setup.bash

```

Conversely, if you want to work with ROS 2 Galactic, your .bashrc setup would look like this:

```bash
# source /opt/ros/noetic/setup.bash
source /opt/ros/galactic/setup.bash
# source ~/catkin_ws/devel/setup.bash
source ~/ament_ws/install/setup.bash

```

Best,  
Chintan
