osm2pgrouting (#24) - Connection Failed. (#381) - Message List

Connection Failed.

Hi! I followed everything here: http://pgrouting.postlbs.org/wiki/OSMTutorial. Everything went smoothly until I try using osm2pgrouting. This is what happens:

root@niceroute:/opt/osm2pgrouting# ./osm2pgrouting -file ncr.osm -conf mapconfig.xml -dbname niceroute -user postgres -host localhost
host=localhost user=postgres dbname=niceroute port=5432
connection failed

What should I do? I don't have any idea how I will solve this. Please help me. Thanks!