Nominatim serve results in error

Hello everyone,

I am pretty new into a self-hosted nominatim server and worked myself through the docs.

After building and configuring the whole import process of Germany took round about 8 hours.

After that I tested nominatim through the command line - as stated in the docs - and continued with testing it through website. And here is my problem:

nginx is running but the website call results in a 502 Bad Gateway. Moreover I am getting the following error when trying to run nomatim serve:

2024-07-11 15:39:51: Using project directory: /srv/nominatim
Traceback (most recent call last):
File “/usr/local/bin/nominatim”, line 12, in
exit(cli.nominatim(module_dir=‘/usr/local/lib/nominatim/module’,
File “/usr/local/lib/nominatim/lib-python/nominatim/cli.py”, line 228, in nominatim
return get_set_parser().run(**kwargs)
File “/usr/local/lib/nominatim/lib-python/nominatim/cli.py”, line 121, in run
return args.command.run(args)
File “/usr/local/lib/nominatim/lib-python/nominatim/cli.py”, line 173, in run
import uvicorn # pylint: disable=import-outside-toplevel
ModuleNotFoundError: No module named ‘uvicorn’

Could anyone provide me any tips or help to get the system fully running?

Thanks in advance.

apt install python3-uvicorn
:thinking:

Well, that gives me another error after trying to serve it again:

2024-07-12 05:07:35: Using project directory: /srv/nominatim
Traceback (most recent call last):
File “/usr/local/bin/nominatim”, line 12, in
exit(cli.nominatim(module_dir=‘/usr/local/lib/nominatim/module’,
File “/usr/local/lib/nominatim/lib-python/nominatim/cli.py”, line 228, in nominatim
return get_set_parser().run(**kwargs)
File “/usr/local/lib/nominatim/lib-python/nominatim/cli.py”, line 121, in run
return args.command.run(args)
File “/usr/local/lib/nominatim/lib-python/nominatim/cli.py”, line 183, in run
server_module = importlib.import_module(f’nominatim.server.{args.engine}.server’)
File “/usr/lib/python3.10/importlib/init.py”, line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File “”, line 1050, in _gcd_import
File “”, line 1027, in _find_and_load
File “”, line 1006, in _find_and_load_unlocked
File “”, line 688, in _load_unlocked
File “”, line 883, in exec_module
File “”, line 241, in _call_with_frames_removed
File “/usr/local/lib/nominatim/lib-python/nominatim/server/falcon/server.py”, line 15, in
from falcon.asgi import App, Request, Response
ModuleNotFoundError: No module named ‘falcon’

It seems like that I did the trick. After researching a bit in the web I found out that I need to install falcon through pip.

apt install python3-falcon