0

enter image description hereI am trying to launch the osm2pgrouting thru the command below and load data (file) into it, but i get the following message:

$ osm2pgrouting --f osnabrueck.osm --conf mapconfig.xml --dbname routing --username postgres Execution starts at: Tue Jul 14 14:14:01 2020


       COMMAND LINE CONFIGURATION             *

Filename = osnabrueck.osm Configuration file = mapconfig.xml host = localhost port = 5432 dbname = routing username = postgres schema=
prefix = suffix =
Don't drop tables Don't create indexes Don't add OSM nodes


Testing database connection: routing fe_sendauth: no password supplied

What does the last line mean? How do I supply password to it?

1

This usually means that you are trying to connect to Postgres/PostGIS with your default user name and it is not a trusted user. You can usually, solve it by specifying the actual user you want to run this command (postgres) by using the --username postgres commandline argument. You will then be prompted for the password.

6
  • Thank you! Could you show me exactly how the command line should look like? – Set Jul 14 '20 at 13:03
  • I tried: sudo osm2pgrouting --f osnabrueck.osm --conf mapconfig.xml --dbname routing --username postgres and it showed me: [sudo] password for postgres: postgres is not in the sudoers file. This incident will be reported. – Set Jul 14 '20 at 13:09
  • are you already logged in as postgres? - can you edit your question with more details – Ian Turton Jul 14 '20 at 13:19
  • Yes, I logged-in using: sudo su postgres. Then it asks to enter password. Then I add the sudo command line above and I get the incident message. If not using sudo, I receive message which I already posted: fe_sendauth: no password supplied – Set Jul 14 '20 at 13:23
  • do it as a regular user with the --username or as postgres then no sudo or --username – Ian Turton Jul 14 '20 at 13:27
0

Password command needed to be added:

osm2pgrouting --f your-OSM-XML-File.osm --conf mapconfig.xml --dbname routing --username postgres -W yourpassword --clean

Password needs to be simple with letter characters. Otherwise, if you have these symbols: !1,234, it will show: event not recognized.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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