GraphHopper freezes at "pass2 - start reading OSM ways" on VM but works locally

Hi everyone,

I’m experiencing an issue when running GraphHopper 11.0 on a Windows-based VM.

When I try to import italy-latest.osm.pbf, the process consistently stops at this log line:

“com.graphhopper.reader.osm.WaySegmentParser - pass2 - start reading OSM ways”

No errors are thrown, it just freezes there indefinitely. What’s strange is:

  • On my local PC, the graph is created successfully in ~13 minutes.
  • On the VM, it stops at that exact log line after just a couple of minutes, and doesn’t continue.
  • The .pbf file is the exact same file (SHA256 verified).
  • Java version, GraphHopper version, and configuration are identical.
  • I tried limiting RAM (e.g. -Xmx1024m) and even corrupting the .pbf for testing, but those scenarios behave differently. They don’t match the specific freeze behavior.

I’ve also verified:

  • It’s not a file permission issue.
  • The .pbf is not served via network or HTTP in this test; it’s on the local file system.
  • I even tried creating the graph locally and moving the graph-cache folder to the VM, which works fine.

So, I have a working workaround, but I’d like to understand what’s happening and whether there’s something in WaySegmentParser or the VM environment that could explain this.

Any insight would be much appreciated—especially from anyone who’s seen a similar freeze at this stage.

Thanks!

My best guess is that there is not enough memory when you use the VM. Maybe try a smaller map first.