0

Rosanswers logo

Hi everyone, I have just installed ROS noetic on Ubuntu 20.04 LTS using multimass (so I am in a virtual enviroment in windows).

I am folowing the ROS tutorial step by step and after the installation there is the creation of a Workspace using catkin, but the first command to do that ("mkdir -p /catkin_ws/src") doesn't work.

The response is:

mkdir: cannot create directory ‘/catkin_ws’: Permission denied

How can I fix that?


Originally posted by andreatesta on ROS Answers with karma: 3 on 2021-02-10

Post score: 0

1 Answers1

0

Rosanswers logo

mkdir -p /catkin_ws/src

you're missing the ~ (or tilde), which refers to your home directory on Linux.

Right now you're trying to create a directory in the root of your filesystem, which is typically not something you can do as an ordinary user.

You'll want to run something like this:

mkdir -p ~/catkin_ws/src

or (equivalent):

mkdir -p $HOME/catkin_ws/src

Originally posted by gvdhoorn with karma: 86574 on 2021-02-10

This answer was ACCEPTED on the original site

Post score: 4


Original comments

Comment by andreatesta on 2021-02-10:
Thanks a lot! Actually in the tutorial the ~ was present but I cannot write it in Windows powershell (even copying and pasting it doesn't appear). With $HOME instead it works!!!

Comment by gvdhoorn on 2021-02-10:
The tutorials will assume you're using Bash, so I'm not surprised the commands don't work for you in PowerShell.

I'm also slightly confused how you're using PowerShell on Ubuntu.

Comment by andreatesta on 2021-02-10:
I am not on Ubuntu, but on Windows 10. To create the virtual machine needed to generate an Ubuntu enviroment I used Multipass. So Windows Powershell is available.

Comment by gvdhoorn on 2021-02-10:
Multipass creates VMs afaict. So it's still Ubuntu that's eventually running.

You state so yourself as well.

Comment by andreatesta on 2021-02-11:
Yes but the terminal where I am writing remains the same, the tops rows are still:

    Windows PowerShell
    Copyright (C) Microsoft Corporation. Tutti i diritti riservati.
Prova la nuova PowerShell multipiattaforma https://aka.ms/pscore6

PS C:\Users\Utente>

gvdhoorn-rse
  • 39,013
  • 1
  • 1
  • 4