Skip to content

GeoNode backup creates empty files in GeoServer data directory #611

@slefrancois

Description

@slefrancois

When running a full GeoNode backup on 5.0.1, empty files are created in the GeoServer data directory where directories should be. This happens if the directories were not yet created by uploads to GeoServer before the backup. Geoserver uploads to the expected directories then fail.

 # ls -lh /geoserver_data/data/workspaces/geonode/
 -rw-r----- 1 root root   0 Mar 30 17:08 csw
 -rw-r----- 1 root root   0 Mar 30 17:08 demo
 -rw-r----- 1 root root   0 Mar 30 17:08 gwc-layers
 ...
 # ls -lh /geoserver_data/data/
 -rw-r----- 1 root root    0 Mar 30 17:08 csw
 -rw-r----- 1 root root    0 Mar 30 17:08 gwc-layers
 ...

This happens on Geonode 4.4.2 using backup.sh and 5.0.1 using python manage.py backup.

A workaround is to manually create the directories before running the first backup:

docker exec geoserver4my_geonode sh -c "cd /geoserver_data/data; mkdir -m 755 csw gwc-layers layergroups validation www"
docker exec geoserver4my_geonode sh -c "cd /geoserver_data/data/workspaces/geonode; mkdir -m 750 csw demo gwc-layers images layergroups logs palettes plugIns styles user_projections validation www"

Metadata

Metadata

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions