osrm-backend icon indicating copy to clipboard operation
osrm-backend copied to clipboard

Server pausing?

Open etiennecha opened this issue 12 years ago • 10 comments

Hi,

When running viaroute queries on my local OSRM server (Ubuntu 14.04 on a VM, osrm extract of France), it seems that after roughly 1,500 requests, the server freezes for a while before resuming its activity. Are there any built-in restrictions that could account for that?

Thanks a lot,

Etienne

etiennecha avatar Oct 28 '14 07:10 etiennecha

lack of ram mean osrm is using disk instead?

emiltin avatar Oct 28 '14 10:10 emiltin

I'll have a look once I am back home. I'm not sure why this would happen though. Queries are not related to each other so I don't expect the server to keep smth/much in memory. Pause do not appear to be triggered by specific queries, and once a pause ends queries run smoothly again (could possibly be that ram has been cleaned then...?)

etiennecha avatar Oct 28 '14 10:10 etiennecha

it could maybe be something else on your system?

emiltin avatar Oct 28 '14 10:10 emiltin

I only had the script running on the system (on top of the osrm server). I guess it's possible that the script takes "too much" ram to store results... but I'm not sure if it would be reasonable to expect things to come back to normal after a while? (or queries would run at a slower pace due to osrm using disk instead of ram without me having noticed?). I'll definitely check that.

etiennecha avatar Oct 28 '14 10:10 etiennecha

probably not the server but the script. there is no memory allocation at the server that could build up. If there was, that would be an obvious bug.

DennisOSRM avatar Oct 28 '14 13:10 DennisOSRM

Neither the server nor the script use a significant amount of memory (14Go Ram dedicated to my VM, not even 3 are used). I really have a hard time figuring what could be the issue.

etiennecha avatar Oct 30 '14 07:10 etiennecha

maybe try to see if any processes have significant i/o access or waits http://unix.stackexchange.com/questions/55212/how-can-i-monitor-disk-io

emiltin avatar Oct 30 '14 08:10 emiltin

For the record, queries are run sequentially (I wait for the answer before launching a new one). Running 10k queries I really get that every roughly 1,5k-1,6k queries the server does not answer to roughly 20 queries.CPU activity falls down during fails. Ok I'm going to have a closer look at i/o

etiennecha avatar Oct 30 '14 08:10 etiennecha

It could also be network related. The network tuning part of this article might be helpful: https://engineering.gosquared.com/optimising-nginx-node-js-and-networking-for-heavy-workloads

dymo avatar Oct 30 '14 08:10 dymo

Not sure if it applies as I'm running queries locally ( basically http://server:5000/viaroute?loc=lat1,lon1&loc=lat2,lon2 )

etiennecha avatar Oct 30 '14 08:10 etiennecha