-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Good to know
This page documents some user experiences on how to solve problems
https://docs.google.com/document/d/1yaO-fKXbMNTtWXbcit2wPAht0zNuFd8XYN6k4JXzk6E/edit (Author Bruno Voisin)
https://docs.google.com/document/d/1JnS6bYteVrznWcN-_czswqDlhqubVNb6yg0TuNR5Bd0/edit (Author Toni Schönbuchner)
https://docs.google.com/document/d/1wzdndnfYMTtbinEMbD-KEUHPD4RliYXYWaZxIqmcx2M/edit?usp=sharing (Author Alex Gacon)
If your geonode instance is working perfectly with the localhost but when you try to add the domain if it throws the error like below then you need to delete the repetitive host from the monitoring_host
table in Postgres.
Traceback (most recent call last):
File "./geonode/wsgi.py", line 30, in <module>
application = get_wsgi_application()
File "/home/geonode/.virtualenvs/geonode/lib/python3.6/site-packages/django/core/wsgi.py", line 13, in get_wsgi_application
return WSGIHandler()
File "/home/geonode/.virtualenvs/geonode/lib/python3.6/site-packages/django/core/handlers/wsgi.py", line 135, in __init__
self.load_middleware()
File "/home/geonode/.virtualenvs/geonode/lib/python3.6/site-packages/django/core/handlers/base.py", line 37, in load_middleware
mw_instance = middleware(handler)
File "./geonode/monitoring/middleware.py", line 48, in __init__
self.setup_logging()
File "./geonode/monitoring/middleware.py", line 55, in setup_logging
self.service = self.get_service()
File "./geonode/monitoring/middleware.py", line 64, in get_service
host = Host.objects.filter(name=hname)[0]
File "/home/geonode/.virtualenvs/geonode/lib/python3.6/site-packages/django/db/models/query.py", line 309, in __getitem__
return qs._result_cache[0]
IndexError: list index out of range
Tue Aug 3 09:26:27 2021 - unable to load app 0 (mountpoint='') (callable not found or import error)
Tue Aug 3 09:26:27 2021 - *** no app loaded. going in full dynamic mode ***
Tue Aug 3 09:26:27 2021 - dropping root privileges after application loading
Tue Aug 3 09:26:27 2021 - *** uWSGI is running in multiple interpreter mode ***
Tue Aug 3 09:26:27 2021 - spawned uWSGI master process (pid: 16745)
Tue Aug 3 09:26:27 2021 - spawned uWSGI worker 1 (pid: 16765, cores: 2)
Tue Aug 3 09:26:27 2021 - spawned uWSGI worker 2 (pid: 16767, cores: 2)
Tue Aug 3 09:26:27 2021 - spawned uWSGI worker 3 (pid: 16769, cores: 2)
Tue Aug 3 09:26:27 2021 - spawned uWSGI worker 4 (pid: 16771, cores: 2)
When I tried to debug the system, I found that the error was due to two hosts in the monitoring_host
table. For solving this issue, you have to follow the following steps,
- access the Postgres database:
psql -h localhost -d geonode -U geonode
- See the data inside the
monitoring_host
table:SELECT * FROM monitoring_host;
- It should contain one hostname. If it contains the two repetitive hosts, delete one:
DROP FROM monitoring_host WHERE id=0;
- Now reload the UWSGI server:
sudo service uwsgi restart
- Now your domain will be mapped to your geonode.
A few various symptoms have been tracked to the inclusion of the daemonize
line in the uwsgi.ini file. If you encounter any of the following, try removing that line and reloading the uwsgi service.
- Running
sudo systemctl status uwsgi
returns a status ofdeactivating
instead ofactive
- uWSGI completely restarting every 1.5-2 minutes: try
grep "Starting uWSGI" /path/to/your/uwsgi.log
to check for evidence of this - Frequent 502 Gateway errors while navigating the GeoNode installation
To display new vector formats in the download window:
- You have to change the
wfs_link
function in thegeonode/geoserver/ows.py
file (https://github.com/GeoNode/geonode/blob/3.2.x/geonode/geoserver/ows.py#L108) to add the parameters for your new format - You have to check the
DOWNLOAD_FORMATS_VECTOR
setting (https://github.com/GeoNode/geonode/blob/3.2.x/geonode/settings.py#L1293) : it must contain the name of the object you add in the Python code
docker compose exec db bash
su - postgres
psql -d daard_geonode_data
ALTER TABLE test ADD COLUMN svgid character varying(120) NULL;
then: refresh geoserver attributes via geoserver gui reload attributes on side of geonode (layer detail refresh statistics ...) (author: toni schönbuchner)
https://docs.google.com/document/d/1nd45ZZQhuuuCot2gm5tkMifYmWwdYDJqubth3DuUI7k/edit?usp=sharing