[Lizmap-de] QGIS and Postgis

G. Wagner, Wagner-IT info at wagner-it.de
Di Feb 15 13:00:57 PST 2022


Hallo Wolfgang,

 

ich bin die Woche nicht im Büro und mir deshalb nicht sicher, ob es das ausführliche Protokoll vom QGIS-Server oder vom Apache war, in dem die gesetzten Variablen angezeigt werden. Das könnte doch helfen – oder?

 

Viele Grüße

 

Günter

 

 

Von: Lizmap-de <lizmap-de-bounces at lists.osgeo.org> Im Auftrag von Wolfgang Meinolf
Gesendet: Dienstag, 15. Februar 2022 17:25
An: Etienne Trimaille <etienne.trimaille at gmail.com>
Cc: lizmap-de at lists.osgeo.org
Betreff: Re: [Lizmap-de] QGIS and Postgis

 

Hm, on my machine I have /home/gisuserhome and /home/qgis. My Portals are located in separate folders under /home/gisuserhome, e.g. /home/gisuserhome/portal1, /home/gisuserhome/portal2 and so on. Owner of these folders is gisuserhome.

 

In /home/qgis I just see 2 folders called qgisserverdb and projects. Owner of these folders is www-data. I installed the entire server about 18 months ago, so it’s difficult to remember. 

 

So I tried to place the „.pg_service.conf“ in both home dirs, gisuserhome and qgis, but without success. I also ran pg_config –sysconfdir, which lead me to /etc/postgresql-common and placed the „.pg_service.conf“ there without success.

 

How can I check the user, used for QGIS Server?

 

 

Von: Etienne Trimaille <etienne.trimaille at gmail.com <mailto:etienne.trimaille at gmail.com> > 
Gesendet: Dienstag, 15. Februar 2022 16:33
An: Wolfgang Meinolf <wmeinolf at bbv-deutschland.de <mailto:wmeinolf at bbv-deutschland.de> >
Cc: lizmap-de at lists.osgeo.org <mailto:lizmap-de at lists.osgeo.org> 
Betreff: Re: [Lizmap-de] QGIS and Postgis

 

Hi,

 

You need to check the user used for QGIS Server.

Does it use /home/gisuserhome ?

 

Try to set explicitly the path to the service file with PGSERVICEFILE when launching QGIS Server.

 

QGIS_SERVER_IGNORE_BAD_LAYERS is very convenient.

https://docs.qgis.org/3.22/en/docs/server_manual/config.html#environment-variables

 

Le mar. 15 févr. 2022 à 16:25, Wolfgang Meinolf <wmeinolf at bbv-deutschland.de <mailto:wmeinolf at bbv-deutschland.de> > a écrit :

Hallo zusammen,

auf meinem Web Server (UBUNTU) läuft Lizmap mit QGIS Server unter Apache und Postgres mit Postgis Erweiterung. Die Postgis credentials habe ich auf meinem Windows PC in pg_service.conf. Darin auf dem PC die URL des Webservers. Die gleiche pg_service.conf ist auf dem Webserver unter /home/gisuserhome, also meinem Home Verzeichnis dort, nur natürlich mit punkt davor, also „.pg_service.conf“. Ausserdem ist die host adresse dort „localhost“.

 

Ein QGS Projekt auf meinem PC enthält ausschließlich einen Postgis Layer. In Qgis funktioniert das Ganze einwandfrei, die credentials kommen offensichtlich aus der pg_service.conf. Lade ich das QGS und Lizmap cfg file auf meinen Server zeigt Lizmap Service non disponible. Offensichtlich kann der POSTGIS Layer nicht geöffnet werden. Ist ja sonst kein Layer im Projekt.

 

Was mache ich falsch?

 

Gruß

Wolfgang

-- 
Lizmap-de mailing list
Lizmap-de at lists.osgeo.org <mailto:Lizmap-de at lists.osgeo.org> 
https://lists.osgeo.org/mailman/listinfo/lizmap-de

-------------- nächster Teil --------------
Ein Dateianhang mit HTML-Daten wurde abgetrennt...
URL: <http://lists.osgeo.org/pipermail/lizmap-de/attachments/20220215/c8dd1864/attachment.html>


Mehr Informationen über die Mailingliste Lizmap-de