0

Hello everyone, i have this problem with Osm2pgsql, i use linux mint 18.4 32bit with 3GB RAM, Processeur intel Centrino,

osm2pgsql -d gis --create --slim -G -hstore --tag-transform -script ~/src/openstreetmap-carto/openstreetmap-carto.lua -S ~/src/openstreetmap-carto/openstreetmap-carto.style ~/data/madagascar-latest.osm.pbf

osm2pgsql SVN version 0.88.1 (64bit id space)

osm2pgsql: invalid option -- 't' Osm2pgsql failed due to ERROR: Usage error. For further information see: osm2pgsql -h|--help

how can i do? thanks,

asked 07 Dec '19, 11:00

Jacquinot's gravatar image

Jacquinot
11114
accept rate: 0%

edited 07 Dec '19, 11:00


6 Answers:
2

Do you have a space between "--tag-transform" and "-script" in your call? It should be "--tag-transform-script" without a space.

I also see that you are using a really old version and I'm not sure about the options offered in version 0.88.

I would advise to use a newer version from https://www.github.com/openstreetmap/osm2pgsql

permanent link

answered 07 Dec '19, 11:44

Spiekerooger's gravatar image

Spiekerooger
696816
accept rate: 16%

edited 07 Dec '19, 13:41

1

So it does look as if you are using options that are not provided in this old version of osm2pgsql. If you would do a "osm2pgsql -h" you would see the options available for version 0.88.

I strongly recommend to use a newer version (see my answer above) to have lua scripting included as well as hstore options.

permanent link

answered 07 Dec '19, 14:10

Spiekerooger's gravatar image

Spiekerooger
696816
accept rate: 16%

so i remove the old version of osm2pgsql and i install the new version !!

(07 Dec '19, 14:17) Jacquinot
0

it haven't space in this script

permanent link

answered 07 Dec '19, 13:50

Jacquinot's gravatar image

Jacquinot
11114
accept rate: 0%

edited 07 Dec '19, 13:57

0

i have i new problem after installation:

osm2pgsql -d gis --create --slim -G -hstore --tag-transform-script ~/src/openstreetmap-carto/openstreetmap-carto.lua -S ~/src/openstreetmap-carto/openstreetmap-carto.style ~/data/madagascar-latest.osm.pbf bash: /usr/bin/osm2pgsql: No such file or directory

permanent link

answered 07 Dec '19, 15:16

Jacquinot's gravatar image

Jacquinot
11114
accept rate: 0%

1

Sounds like osm2pgsql is not installed where they are expected. You do need some Linux knowledge to get this working.

(07 Dec '19, 21:11) Spiekerooger
0

now i have this:

# osm2pgsql -d gis --create --slim -G --hstore --tag-transform-script ~/src/openstreetmap-carto/openstreetmap-carto.lua -C 2500 --number-processes 1 -S ~/src/openstreetmap-carto/openstreetmap-carto.style ~/data/madagascar-latest.osm.pbf osm2pgsql version 1.2.0 (64 bit id space)

Allocating memory for sparse node cache Node-cache: cache=2500MB, maxblocks=40000*65536, allocation method=9 Mid: pgsql, cache=2500 Connection to database failed: could not connect to server: No such file or directory Is the server running locally and accepting connections on Unix domain socket "/var/run/postgresql/.s.PGSQL.5432"?

Connection to database failed: could not connect to server: No such file or directory Is the server running locally and accepting connections on Unix domain socket "/var/run/postgresql/.s.PGSQL.5432"?

DB writer thread failed due to ERROR: Connecting to database.

permanent link

answered 10 Dec '19, 16:29

Jacquinot's gravatar image

Jacquinot
11114
accept rate: 0%

0

Run this command to see what version(s) of PostgreSQL are running as well as their ports, statuses & data directories:

$ pg_lsclusters

If you are running PostgreSQL on a port other than 5432, many of the commands you use require the option '-p <port number="">'.

permanent link

answered 27 May, 12:35

TimothyOnline's gravatar image

TimothyOnline
1
accept rate: 0%

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:

×224

question asked: 07 Dec '19, 11:00

question was seen: 504 times

last updated: 27 May, 14:21

powered by OSQA