I am upgrade GeoServer to 2.20 version, but when specifying the data directory I get the error Found Java environment variable GEOSERVER_DATA_DIR set to /var/lib/geoserver_data/ , which is not writeable. I am check the owner of directory geoserver_data and is Tomcat. I am using Tomcat9

1 Answer 1


Newer Tomcat 9 versions are more "secure" than previous versions and control where tomcat can read and write outside $CATALINA_HOME. You need to find the file /lib/systemd/system/tomcat9.service or equivalent which has the lines:


and add a new line with your data directory.

Then run systemctl daemon-reload.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.