Skip to content

(Windows) Laverna Signal Server cannot connect to mongodb

taw00 edited this page Dec 4, 2018 · 2 revisions

Windows 10 (and probably other versions) prioritizes ipv6 when available over ipv4. Thus "localhost" resolves to ::1 instead of 127.0.0.1. The problem with this is that mongodb binds to the ipv4 address, but not the ipv6 one. The signal server, for whatever reason, does not attempt to connect to anything but the first address that localhost resolves to.

This could be fixed in configuration, or it can be fixed at an OS level. To change OS behavior, refer to the "Prefer IPv4 over IPv6 in prefix policies" option at https://support.microsoft.com/en-us/help/929852/guidance-for-configuring-ipv6-in-windows-for-advanced-users to solve the issue. Note that a reboot is required.