4

I am installing a tile server from this link on my Ubuntu Machine 14.04. The problem I am facing is in this line :

./make.py
cd ../OSMBright/
carto project.mml > OSMBright.xml

Whenever I enter 'carto project.mml > OSMBright.xml' it is giving me permission denied error. I have also tried with sudo carto project.mml > OSMBright.xml but still it is giving me permission denied. I am stuck here at this stage and I need to install this server. See I have tried all combination to execute this commandenter image description here. Could anyone help with this?

I tried to post this question on Ubuntu forum but they don't have the proper tags that I am looking for.

4 Answers 4

5

The problem you ran into has nothing to do with carto, it's an issue with your shell command, when you run sudo carto project.mml > OSMBright.xml carto runs as root, but the file write happens as your normal permission level, to do what your looking for you can sudo sh -c "carto project.mml > OSMBright.xml"

1
  • 1
    My reputation is too low to give you thumbs up but I have accepted your answer. I resolved it earlier though, see my answer.
    – python
    Commented Aug 11, 2015 at 17:37
1

I resolved the error by following these steps:

Step 1- Create a new file OSMBright.xml in the same folder.

Step 2- Type 'ls -l' and see the read and write permission of OSMBright.xml file.

Step 3- sudo Chmod 777 OSMBright.xml and it will change the read/write permission of the file.

Step 4 - Now do sudo carto project.mml > OSMBright.xml and output will be saved in OSMBright.xml file :)

0

Have a look ath these instructions from a mapbox article:

osm-bright-ubuntu-quickstart

There is a section with hints for setting right permissions for database access.

Maybe the issue is hidden there?

1
  • @I resolved it by creating a new file then changed its permission and redirected my output. It worked for me.
    – python
    Commented Aug 11, 2015 at 17:06
-1

Correct. Its the issue with your shell command which can easily be resolved with sudo sh -c "carto project.mml > OSMBright.xml"

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.