<div dir="ltr">I got it.<div><br></div><div>It's the `map`parameter in the URL.</div><div><br></div><div>Thanks in any case everyone.</div><div><br></div><div>Writing this email helped me discover the answer ;)</div></div><div class="gmail_extra"><br><div class="gmail_quote">On Sat, Jul 23, 2016 at 6:46 PM, jenia mtl <span dir="ltr"><<a href="mailto:jenia.ivlev@gmail.com" target="_blank">jenia.ivlev@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><span style="font-size:12.8px">Hello.</span><br style="font-size:12.8px"><br style="font-size:12.8px"><br style="font-size:12.8px"><span style="font-size:12.8px">How can I specify the mapfile path to the mapserv fastcgi process?</span><br style="font-size:12.8px"><br style="font-size:12.8px"><span style="font-size:12.8px">My problem is that I get a 502 error when try to access</span><br style="font-size:12.8px"><a href="http://localhost/cgi-bin/mapserv?map=/ms4w/apps/tutorial/htdocs/example1-1.map&layer=states&mode=map" rel="noreferrer" style="font-size:12.8px" target="_blank">http://localhost/cgi-bin/mapserv?map=/ms4w/apps/tutorial/htdocs/example1-1.map&layer=states&mode=map</a><br style="font-size:12.8px"><br style="font-size:12.8px"><span style="font-size:12.8px">I get:</span><br style="font-size:12.8px"><br style="font-size:12.8px"><span style="font-size:12.8px">    2016/07/23 17:45:22 [error] 1768#1768: *7 upstream prematurely closed</span><br style="font-size:12.8px"><span style="font-size:12.8px">    FastCGI stdout while reading response header from upstream, client:</span><br style="font-size:12.8px"><span style="font-size:12.8px">    127.0.0.1, server: localhost, request: "GET</span><br style="font-size:12.8px"><span style="font-size:12.8px">    /cgi-bin/mapserv?map=/ms4w/</span><span style="font-size:12.8px">apps/tutorial/htdocs/example1-</span><span style="font-size:12.8px">1.map&layer=states&mode=map</span><br style="font-size:12.8px"><span style="font-size:12.8px">    HTTP/1.1", upstream: "fastcgi://</span><a href="http://127.0.0.1:8001/" rel="noreferrer" style="font-size:12.8px" target="_blank">127.0.0.1:8001</a><span style="font-size:12.8px">", host: "localhost"</span><br style="font-size:12.8px"><br style="font-size:12.8px"><br style="font-size:12.8px"><span style="font-size:12.8px">This is how I start mapserver:</span><br style="font-size:12.8px"><br style="font-size:12.8px"><span style="font-size:12.8px">    `spawn-fcgi   -a 127.0.0.1 -p 8001 /usr/bin/mapserv`</span><br style="font-size:12.8px"><br style="font-size:12.8px"><br style="font-size:12.8px"><span style="font-size:12.8px">I'm thinking it's because I didn't specify a `mapfile`. And in any case,</span><br style="font-size:12.8px"><span style="font-size:12.8px">I'd like to see the error logs from mapserver (error logs configs go to the mapfile apperently).</span><br style="font-size:12.8px"><br style="font-size:12.8px"><span style="font-size:12.8px">So again, where is the `mapfile` or how do I specify the `mapfile` path for the `mapserv`</span><span style="font-size:12.8px">instance?</span><br style="font-size:12.8px"><br style="font-size:12.8px"><br style="font-size:12.8px"><span style="font-size:12.8px">Thanks in advance for your kind help.</span><br style="font-size:12.8px"><span style="font-size:12.8px">Jenia</span><br style="font-size:12.8px"><br style="font-size:12.8px"><br style="font-size:12.8px"><span style="font-size:12.8px">P.S. This is my nginx config:</span><br style="font-size:12.8px"><br style="font-size:12.8px"><span style="font-size:12.8px">    server {</span><br style="font-size:12.8px"><br style="font-size:12.8px"><span style="font-size:12.8px">        listen       80;</span><br style="font-size:12.8px"><span style="font-size:12.8px">        server_name  localhost;</span><br style="font-size:12.8px"><span style="font-size:12.8px">        error_log /home/jenia/error.log;</span><br style="font-size:12.8px"><span style="font-size:12.8px">        access_log /home/jenia/access.log;</span><br style="font-size:12.8px"><br style="font-size:12.8px"><span style="font-size:12.8px">        location ~ / {</span><br style="font-size:12.8px"><span style="font-size:12.8px">            fastcgi_pass   </span><a href="http://127.0.0.1:8001/" rel="noreferrer" style="font-size:12.8px" target="_blank">127.0.0.1:8001</a><span style="font-size:12.8px">;</span><br style="font-size:12.8px"><span style="font-size:12.8px">            error_log /home/jenia/error.log;</span><br style="font-size:12.8px"><span style="font-size:12.8px">            access_log /home/jenia/access.log;</span><br style="font-size:12.8px"><span style="font-size:12.8px">        }</span><br style="font-size:12.8px"><span style="font-size:12.8px">    }</span><br></div>
</blockquote></div><br></div>