Hello o/
First thanks for all your stuff. It’s amazing.
My goal is to calculate route between 2 or more points.
Optimize how to chain some routes.
End render an these things with leaflet.
I have deployed my own server (mac studio m1 32go) with docker :
And everythings works well.
Then, for adding france-latest.osm.pbf (4.6go) :
- i stop the server
- i put france-latest.osm.pbf in the file directory
- i delete the graph folder
- i edit the ors-config with that source_file: /home/ors/files/france-latest.osm.pbf
- i re-start the server and i have this issue : ors-app exited with code 137
I tried many things during hours.
I tried to set this in the docker-compose.yml
XMS: 10g
XMX: 20g
Without succes…
docker-compose.yml
# Docker Compose file for the openrouteservice (ORS) application
# Documentation and examples can be found on https://giscience.github.io/openrouteservice/run-instance/running-with-docker
version: '3.8'
services:
# ----------------- ORS application configuration ------------------- #
ors-app:
# Activate the following lines to build the container from the repository
# You have to add --build to the docker compose command to do so
build:
context: ./
container_name: ors-app
ports:
- "8080:8082" # Expose the ORS API on port 8080
- "9001:9001" # Expose additional port for monitoring (optional)
image: openrouteservice/openrouteservice:v8.0.0
# Advanced option! If you different ids to 0:0 and 1000:1000, you have to rebuild the container with the build args UID,GID.
# The user command is useful if you want easier bind mount access or better security.
#user: "1000:1000" # Run "mkdir -p ors-docker/config ors-docker/elevation_cache ors-docker/files ors-docker/graphs ors-docker/logs && sudo chown -R 1000:1000 ors" before starting the container!
volumes: # Mount relative directories. ONLY for local container runtime. To switch to docker managed volumes see 'Docker Volumes configuration' section below.
- ./ors-docker:/home/ors # Mount the ORS application directory (for logs, graphs, elevation_cache, etc.) into its own directory
#- ./graphs:/home/ors/graphs # Mount graphs directory individually
#- ./elevation_cache:/home/ors/elevation_cache # Mount elevation cache directory individually
#- ./config:/home/ors/config # Mount configuration directory individually
#- ./logs:/home/ors/logs # Mount logs directory individually
#- ./files:/home/ors/files # Mount files directory individually
environment:
REBUILD_GRAPHS: False # Set to True to rebuild graphs on container start.
CONTAINER_LOG_LEVEL: INFO # Log level for the container. Possible values: DEBUG, INFO, WARNING, ERROR, CRITICAL
# If you don't want the default ors-config.yml you can specify a custom file name, that should match the file in
# your 'config' volume mount.
#ORS_CONFIG_LOCATION: /home/ors/config/my-ors-config.yml # Location of your ORS configuration file in the docker container
# ------------------ JAVA OPTS ------------------ #
# Configure the memory settings for JAVA or pass additional opts
# Fore more available ENV properties see Prepare CATALINA_OPTS and JAVA_OPTS
# in https://github.com/GIScience/openrouteservice/blob/main/docker-entrypoint.sh
XMS: 10g # start RAM assigned to java
XMX: 20g # max RAM assigned to java. Rule of Thumb: <PBF-size> * <profiles> * 2
# Example: 1.5 GB pbf size, two profiles (car and foot-walking)
# -> 1.5 * 2 * 2 = 6. Set xmx to be AT LEAST `-Xmx6g`
ADDITIONAL_JAVA_OPTS: "" # further options you want to pass to the java command
# ----------------- Properties configuration ------------------- #
# Configure your whole container with only property ENVs.
# These can be set alternatively or additionally to the yml configuration file.
# Note, that any values set will override the corresponding values from the yml configuration file.
# See the ors-config.env file for more options.
# To have a configuration file-less container, uncomment at least the following properties.
# The values are examples and provide the default configuration.
#ors.engine.source_file: /home/ors/files/example-heidelberg.osm.gz
#ors.engine.graphs_root_path: /home/ors/graphs
#ors.engine.elevation.cache_path: /home/ors/elevation_cache
#ors.engine.profiles.car.enabled: true
# ----------------- ENV file configuration ------------------- #
# Too many variables for your 'environment:' section?
# Use an env_file with the ENV properties instead and define everything in there:
# Values will be overwritten if set in the 'environment' section.
#env_file: ors-config.env
# ----------------- Healthcheck configuration ------------------- #
# The healthcheck is disabled by default. Uncomment the following lines to enable it.
# The healthcheck allows you to monitor the status of the ORS application.
# Be careful with long graph builds, as the healthcheck will fail and show 'unhealthy' during this time.
# This is especially useful if you run your ORS container in a production environment.
#healthcheck:
# test: wget --no-verbose --tries=1 --spider http://localhost:8082/ors/v2/health || exit 1
# start_period: 1m
# interval: 10s
# timeout: 2s
# retries: 3
# disable: false
# ----------------- Docker Volumes configuration ------------------- #
# Define the Docker managed volumes for the ORS application. For more info on Docker Volumes see https://docs.docker.com/compose/compose-file/07-volumes/
# Volumes are used to persist the data and configuration of the ORS application.
# If you want to use volumes, uncomment the following lines and remove the ./ prefix from the volume paths in 'services.ors-app.volumes'.
#volumes:
# graphs:
# elevation_cache:
# config:
# logs:
# files:
ors-config.yml
##### openrouteservice settings file #####
# This file contains parameters for openrouteservice.
# For a full list of possible parameters see https://giscience.github.io/openrouteservice/run-instance/configuration/
##### General server settings #####
#server:
# port: 8082
# error:
# whitelabel:
# enabled: false
# # Keep the context-path at / else the war file run with tomcat will have the context-path of /ors/v2 as well.
# servlet:
# context-path: /ors
#spring:
# profiles:
# active: default
# mvc:
# servlet:
# path: /
##### Settings related to springdoc #####
#springdoc:
# swagger-ui:
# enabled: true
# path: /swagger-ui
# tryItOutEnabled: true
# filter: false
# syntaxHighlight:
# activated: true
# showExtensions: true
# api-docs:
# path: /v2/api-docs
# version: OPENAPI_3_0
# packages-to-scan: org.heigit.ors
# pathsToMatch: /v2/**
##### Logging settings #####
#logging:
# file:
# name: ./logs/ors.log
# pattern:
# console: "%d{yyyy-MM-dd HH:mm:ss} %highlight{%-7p} %style{%50t}{Cyan} %style{[ %-40.40c{1.} ]}{Bright Cyan} %m%n"
# file: "%d{yyyy-MM-dd HH:mm:ss} %p [%-40.40c{1.}] - %m%n"
# level:
# root: WARN
# org.heigit: INFO
##### openrouteservice specific settings #####
ors:
# cors:
# allowed_origins: "*"
# allowed_headers: Content-Type, X-Requested-With, accept, Origin, Access-Control-Request-Method, Access-Control-Request-Headers, Authorization
# preflight_max_age: 600
# messages:
# ##### ORS endpoints settings #####
# endpoints:
# routing:
# enabled: true
# attribution: openrouteservice.org, OpenStreetMap contributors, tmc - BASt
# gpx_name: ORSRouting
# gpx_description: This is a directions instructions file as GPX, generated from openrouteservice
# gpx_base_url: https://openrouteservice.org/
# gpx_support_mail: support@openrouteservice.org
# gpx_author: openrouteservice
# gpx_content_licence: LGPL 3.0
# maximum_avoid_polygon_area: 200000000
# maximum_avoid_polygon_extent: 20000
# maximum_alternative_routes: 3
# matrix:
# enabled: true
# attribution: openrouteservice.org, OpenStreetMap contributors
# maximum_routes: 2500
# maximum_routes_flexible: 25
# maximum_visited_nodes: 100000
# maximum_search_radius: 2000
# u_turn_costs: -1
# isochrones:
# enabled: true
# attribution: openrouteservice.org, OpenStreetMap contributors
# maximum_locations: 2
# maximum_intervals: 1
# allow_compute_area: true
# maximum_range_distance_default: 50000
# maximum_range_distance:
# - profiles: driving-car, driving-hgv
# value: 100000
# maximum_range_time_default: 18000
# maximum_range_time:
# - profiles: driving-car, driving-hgv
# value: 3600
# fastisochrones:
# maximum_range_distance_default: 50000
# maximum_range_distance:
# - profiles: driving-car, driving-hgv
# value: 500000
# maximum_range_time_default: 18000
# maximum_range_time:
# - profiles: driving-car, driving-hgv
# value: 10800
# Snap:
# enabled: true
# attribution: openrouteservice.org, OpenStreetMap contributors
# ##### ORS engine settings #####
engine:
source_file: /home/ors/files/france-latest.osm.pbf
# init_threads: 1
# preparation_mode: false
# graphs_root_path: ./graphs
# graphs_data_access: RAM_STORE
# elevation:
# preprocessed: false
# data_access: MMAP
# cache_clear: false
# provider: multi
# cache_path: ./elevation_cache
# profile_default:
# enabled: false
# elevation: false
# elevation_smoothing: false
# encoder_flags_size: 8
# instructions: true
# optimize: false
# traffic: false
# maximum_distance: 100000
# maximum_distance_dynamic_weights: 100000
# maximum_distance_avoid_areas: 100000
# maximum_waypoints: 50
# maximum_snapping_radius: 400
# maximum_distance_alternative_routes: 100000
# maximum_distance_round_trip_routes: 100000
# maximum_speed_lower_bound: 80
# maximum_visited_nodes: 1000000
# location_index_resolution: 500
# location_index_search_iterations: 4
# force_turn_costs: false
# interpolate_bridges_and_tunnels: true
# preparation:
# min_network_size: 200
# methods:
# lm:
# enabled: true
# threads: 1
# weightings: recommended,shortest
# landmarks: 16
# execution:
# methods:
# lm:
# active_landmarks: 8
profiles:
car:
enabled: true
# profile: driving-car
# elevation: true
# encoder_options:
# turn_costs: true
# block_fords: false
# use_acceleration: true
# preparation:
# min_network_size: 200
# methods:
# ch:
# enabled: true
# threads: 1
# weightings: fastest
# lm:
# enabled: false
# threads: 1
# weightings: fastest,shortest
# landmarks: 16
# core:
# enabled: true
# threads: 1
# weightings: fastest,shortest
# landmarks: 64
# lmsets: highways;allow_all
# execution:
# methods:
# lm:
# active_landmarks: 6
# core:
# active_landmarks: 6
# ext_storages:
# WayCategory:
# HeavyVehicle:
# WaySurfaceType:
# RoadAccessRestrictions:
# use_for_warnings: true
# hgv:
# enabled: false
# profile: driving-hgv
# encoder_flags_size: 8
# encoder_options:
# turn_costs: true
# block_fords: false
# use_acceleration: true
# maximum_distance: 100000
# elevation: true
# preparation:
# min_network_size: 200
# methods:
# ch:
# enabled: true
# threads: 1
# weightings: recommended
# core:
# enabled: true
# threads: 1
# weightings: recommended,shortest
# landmarks: 64
# lmsets: highways;allow_all
# execution:
# methods:
# core:
# active_landmarks: 6
# ext_storages:
# WayCategory:
# HeavyVehicle:
# restrictions: true
# WaySurfaceType:
# bike-regular:
# enabled: false
# profile: cycling-regular
# encoder_options:
# consider_elevation: true
# turn_costs: true
# block_fords: false
# elevation: true
# ext_storages:
# WayCategory:
# WaySurfaceType:
# HillIndex:
# TrailDifficulty:
# bike-mountain:
# enabled: false
# profile: cycling-mountain
# encoder_options:
# consider_elevation: true
# turn_costs: true
# block_fords: false
# elevation: true
# ext_storages:
# WayCategory:
# WaySurfaceType:
# HillIndex:
# TrailDifficulty:
# bike-road:
# enabled: false
# profile: cycling-road
# encoder_options:
# consider_elevation: true
# turn_costs: true
# block_fords: false
# elevation: true
# ext_storages:
# WayCategory:
# WaySurfaceType:
# HillIndex:
# TrailDifficulty:
# bike-electric:
# enabled: false
# profile: cycling-electric
# encoder_options:
# consider_elevation: true
# turn_costs: true
# block_fords: false
# elevation: true
# ext_storages:
# WayCategory:
# WaySurfaceType:
# HillIndex:
# TrailDifficulty:
# walking:
# enabled: false
# profile: foot-walking
# encoder_options:
# block_fords: false
# elevation: true
# ext_storages:
# WayCategory:
# WaySurfaceType:
# HillIndex:
# TrailDifficulty:
# hiking:
# enabled: false
# profile: foot-hiking
# encoder_options:
# block_fords: false
# elevation: true
# ext_storages:
# WayCategory:
# WaySurfaceType:
# HillIndex:
# TrailDifficulty:
# wheelchair:
# enabled: false
# profile: wheelchair
# encoder_options:
# block_fords: true
# elevation: true
# maximum_snapping_radius: 50
# ext_storages:
# WayCategory:
# WaySurfaceType:
# Wheelchair:
# KerbsOnCrossings: true
# OsmId:
# public-transport:
# enabled: false
# profile: public-transport
# encoder_options:
# block_fords: false
# elevation: true
# maximum_visited_nodes: 1000000
# gtfs_file: ./src/test/files/vrn_gtfs_cut.zip
Thanks for all