Hi Janet,<div><br>Can you show us the content of your nginx.conf?</div><div><br></div><div>Do you have the 'include' directive in your nginx.conf to point to your sites-available?</div><div><br></div><div>For example:</div>
<div>http {</div><div><blockquote style="margin:0 0 0 40px;border:none;padding:0px"><div>...</div><div>include /etc/nginx/sites-available/*;</div><div>...</div></blockquote>}</div><div><br></div><div><div>Best regards,<br>
Wong Kee Wee</div>
<br><br><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi Sajan<br>
<br>
Yes I did restart nginx. I've tried several times.<br>
<br>
Just tried nginx -t and all seems to be fine.<br>
<br>
nginx -t<br>
nginx: the configuration file /etc/nginx/nginx.conf syntax is ok<br>
nginx: configuration file /etc/nginx/nginx.conf test is successful<br>
<br>
<br>
JV<br>
<br>
<br>
On 17 June 2013 15:48, Sajan Parikh <<a href="mailto:sajan@noppix.com">sajan@noppix.com</a>> wrote:<br>
<br>
>  Did you restart nginx for the new configuration to take effect?  Run<br>
> 'sudo service nginx restart' to do this.  Also run 'nginx -t' to test your<br>
> configuration.<br>
><br>
> Sajan Parikh<br>
> *Owner, Noppix LLC*<br>
><br>
> e: <a href="mailto:sajan@noppix.com">sajan@noppix.com</a><br>
> p: <a href="tel:%28563%29%20726-0371" value="+15637260371">(563) 726-0371</a><br>
><br>
> [image: Noppix LLC Logo]<br>
> On 06/17/2013 09:36 AM, Janet Valbuena wrote:<br>
><br>
>  Hi<br>
><br>
> I'm new to nginx. I'm trying to configure a virtual server.<br>
><br>
>  I've created a new server file under sites-enabled like this:<br>
><br>
>  server {<br>
>     listen  80; ## listen for ipv4; this line is default and implied<br>
><br>
>     server_name blogtest;<br>
><br>
>     root /usr/share/nginx/cakephptest/app/webroot;<br>
>     index index.php;<br>
><br>
>     location / {<br>
>             # First attempt to serve request as file, then<br>
>             # as directory, then fall back to 404<br>
>             try_files $uri $uri/ =404;<br>
>     }<br>
>     # PHP FPM<br>
>     location ~ \.php$ {<br>
>             fastcgi_pass <a href="http://127.0.0.1:9000" target="_blank">127.0.0.1:9000</a>;<br>
>             fastcgi_index index.php;<br>
>             include fastcgi_params;<br>
>             fastcgi_intercept_errors on;<br>
>             fastcgi_buffers 8 16k;<br>
>             fastcgi_buffer_size 32k;<br>
>             fastcgi_split_path_info ^(.+\.php)(/.+)$;<br>
>             fastcgi_param PATH_INFO $fastcgi_path_info;<br>
>             fastcgi_param PATH_TRANSLATED $document_root$fastcgi_path_info;<br>
>             fastcgi_param SCRIPT_FILENAME<br>
> $document_root$fastcgi_script_name;<br>
>     }<br>
> }<br>
><br>
><br>
>  Is there anything wrong with that?<br>
>  When I type in blogtest/index.php on the browser I get the default<br>
> config, which points to /usr/share/nginx/www/, even though I deleted the<br>
> symbolic link to sites-available/default from sites-enabled.<br>
><br>
>  Note: /usr/share/nginx/cakephptest/app/webroot/index.php does exist.<br>
><br>
>  Could anyone please help.<br>
><br>
>  Thanks<br>
><br>
>  JV<br></blockquote></div></div>