Feature request #21692
XYZ Tiles base map not working on QGIS Server with GetMap wms request
Status: | Open | ||
---|---|---|---|
Priority: | Normal | ||
Assignee: | - | ||
Category: | Documentation and Help | ||
Pull Request or Patch supplied: | No | Resolution: | |
Easy fix?: | No | Copied to github as #: | 29508 |
Description
I have a project in QGIS desktop with some XYZ Tiles base maps. Everything works fine on desktop version, that is all maps are displayed.
I use the same .qgs project on QGIS server and only some base maps work with GetMap request.
The following are my requests to the server, divided by maps that work and maps that don't work:
These maps work:
These maps don't work:
On desktop (MacOS) I have installed QGIS 3.4.5-Madeira
On the server (Debian) I have installed 3.4.5+14stretch
Please find in attachment the Qgis project file.
History
#1 Updated by Giovanni Manghi over 5 years ago
- Category changed from Web Services clients/XYZ to QGIS Server
#2 Updated by Paolo Cavallini over 5 years ago
- File template_xyz_tiles.zip added
I confirm the issue, see attached project.
#3 Updated by René-Luc ReLuc over 5 years ago
In the example provided by Paolo, the working layers are in HTTP the others are in HTTPS.
To fix it, you have to update QGIS2.ini or QGIS3.ini to configure the proxy section.
[proxy]
proxyEnabled=true
proxyHost=
proxyPort=8080
proxyUser=
proxyPassword=
proxyType=HttpProxy
proxyExcludedUrls=
And to add QGIS_OPTIONS_PATH in the server configuration to provide the directory in which QGIS Server wil find QGIS2.ini or QGIS3.ini
I think the QGIS docs could be updated.
#4 Updated by Giovanni Manghi over 5 years ago
René-Luc ReLuc wrote:
In the example provided by Paolo, the working layers are in HTTP the others are in HTTPS.
To fix it, you have to update QGIS2.ini or QGIS3.ini to configure the proxy section.
[proxy]
proxyEnabled=true
proxyHost=
proxyPort=8080
proxyUser=
proxyPassword=
proxyType=HttpProxy
proxyExcludedUrls=And to add QGIS_OPTIONS_PATH in the server configuration to provide the directory in which QGIS Server wil find QGIS2.ini or QGIS3.ini
I think the QGIS docs could be updated.
this is an important "tip", we should file a ticket in the documentation repository to not forget about adding it.
#5 Updated by Paolo Cavallini over 5 years ago
Unfortunately, it still does not work; from apache2 error log:
QSqlDatabasePrivate::database: unable to open database: "unable to open database file Error opening database" ERROR: Opening of authentication db FAILED QSqlQuery::prepare: database not open WARNING: Auth db query exec() FAILED
#6 Updated by Paolo Cavallini over 5 years ago
- Category changed from QGIS Server to Documentation and Help
- Tracker changed from Bug report to Feature request
Solved:
mkdir /var/www/authdb chown www-data /var/www/authdb /etc/apache2/mods-enabled/fcgid.conf FcgidInitialEnv QGIS_AUTH_DB_DIR_PATH /var/www/authdb/ service apache2 restart
Documentation should be updated.