# Issue with default vhost

**URL:** <https://www.ruby-forum.com/t/issue-with-default-vhost/229795>\
**Category:** NGINX\
**Created:** [January 22, 2013, 3:19pm UTC](https://www.ruby-forum.com/t/issue-with-default-vhost/229795 "2013-01-22T15:19:51Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![automatix](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/f08c70/32.png) [@automatix](https://www.ruby-forum.com/u/automatix)\
**Post date:** [January 22, 2013, 3:19pm UTC](https://www.ruby-forum.com/t/issue-with-default-vhost/229795/1 "2013-01-22T15:19:51Z")

</div>

Hello!

There is an Nginx instance on one of my VMs (192.168.56.101) and three  
(enabled) vhosts: “default” and two further vhosts I created.

When I enter the IP in my host browser or “localhost” in my guest  
browser,  
in both cases the default page (/usr/share/nginx/html/index.html) is  
displayed:

It works!  
This is the default web page for this server.  
The web server software is running but no content has been added, yet.

OK. Now I’ve edited the default page /usr/share/nginx/html/index.html.  
But I  
only can see the chages in the guest browser. So, no changes are  
visible,  
when access the defalt vhost via IP from the host system.

Furthermore I created a simple PHP file index.php

\<?php phpinfo(); ?\>

and added it to the default vhost directory (/usr/share/nginx/html).  
When I  
access it from the guest (localhost/index.php), it works fine. But when  
I  
try it from the host, only a message

File not found.

is displayed.

I only have this issue with the default vhost. The oher two are working  
fine.

What can be the cause? What do I do wrong?

thx

Posted at Nginx Forum:

> **[issue with default vhost](https://forum.nginx.org/read.php?2,235411,235411#msg-235411)**
>
> Hello! There is an Nginx instance on one of my VMs (192.168.56.101) and three (enabled) vhosts: "default" and two further vhosts I created. When I enter the IP in my host browser or "localhost" in my guest browser, in both cases...

---

<div class="post-metadata">

**Author:** ![automatix](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/f08c70/32.png) [@automatix](https://www.ruby-forum.com/u/automatix)\
**Post date:** [January 22, 2013, 4:09pm UTC](https://www.ruby-forum.com/t/issue-with-default-vhost/229795/2 "2013-01-22T16:09:31Z")

</div>

EDIT:

The same issue occures, when I try to reach the server from the guest  
but  
over the domain of the machine (devvm.loc).

Posted at Nginx Forum:

> **[Re: issue with default vhost](https://forum.nginx.org/read.php?2,235411,235413#msg-235413)**
>
> Hello! There is an Nginx instance on one of my VMs (192.168.56.101) and three (enabled) vhosts: "default" and two further vhosts I created. When I enter the IP in my host browser or "localhost" in my guest browser, in both cases...

---

<div class="post-metadata">

**Author:** ![automatix](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/f08c70/32.png) [@automatix](https://www.ruby-forum.com/u/automatix)\
**Post date:** [January 23, 2013, 10:01pm UTC](https://www.ruby-forum.com/t/issue-with-default-vhost/229795/3 "2013-01-23T22:01:42Z")

</div>

This issue doesn’t appear anymore, since the problem I described in my  
thread “RegEx VHost name and the default VHost”  
([RegEx VHost name and the default VHost](http://forum.nginx.org/read.php?2,235490)) is resolved (solution:  
[Re: RegEx VHost name and the default VHost](http://forum.nginx.org/read.php?2,235490,235500#msg-235500)).

Posted at Nginx Forum:

> **[\[resolved\] Re: issue with default vhost](https://forum.nginx.org/read.php?2,235411,235506#msg-235506)**
>
> Hello! There is an Nginx instance on one of my VMs (192.168.56.101) and three (enabled) vhosts: "default" and two further vhosts I created. When I enter the IP in my host browser or "localhost" in my guest browser, in both cases...
