LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Server (https://www.linuxquestions.org/questions/linux-server-73/)
-   -   Pings but doesn't go to web site. (https://www.linuxquestions.org/questions/linux-server-73/pings-but-doesnt-go-to-web-site-723563/)

RavenLX 05-04-2009 09:41 AM

Pings but doesn't go to web site.
 
I'm at a loss here. I have Ubuntu 8.04 server running in VMWare Server 2.0 running in Windows Vista Home Premium.

I have it set up for virtual hosts, and I have it set up in /etc/network/interfaces for Static IP (I'm not on a static IP service, but just want to use it inside my wireless home network with Linksys wireless router):

/etc/network/interfaces:

Code:

# This file describes the network interfaces available on your system
# and how to activate them. For more information, see interfaces(5).

# The loopback network interface
auto lo
iface lo inet loopback

# The primary network interface
auto eth0
#iface eth0 inet dhcp
iface eth0 inet static
address 192.168.100.135
netmask 255.255.255.0
network 192.168.100.0
broadcast 192.168.100.255
gateway 192.168.100.2

My /etc/hosts file looks something like this:

Code:

127.0.0.1      localhost
#127.0.1.1      myserver.localdomain      myserver
192.168.100.135 myserver.localdomain      myserver

Then some IPV6 stuffs.

My /etc/resolv.conf looks like this:
Code:

search localdomain
nameserver 192.168.100.2

Ok, I can ping it in a DOS window in Windows:

Code:

Pinging myserver.localdomain [208.69.36.132] with 32 bytes of data:
Reply from 208.69.36.132: bytes=32 time=38ms TTL=57
Reply from 208.69.36.132: bytes=32 time=151ms TTL=57
Reply from 208.69.36.132: bytes=32 time=35ms TTL=57
Reply from 208.69.36.132: bytes=32 time=37ms TTL=57

Ping statistics for 208.69.36.132:
    Packets: Sent = 4, Received = 4, Lost = 0 (0% loss),
Approximate round trip times in milli-seconds:
    Minimum = 35ms, Maximum = 151ms, Average = 65ms

I have my router set up to use OpenDNS so it looks like it's using that in Windows. However, if I ping it from the Ubuntu Server I get this:

Code:

PING myserver.localdomain (192.168.100.135) 56(84) bytes of data.
64 bytes from myserver.localdomain (192.168.100.135): icmp_seq=1 ttl=64 time=3.88 ms
64 bytes from myserver.localdomain (192.168.100.135): icmp_seq=2 ttl=64 time=0.076 ms
64 bytes from myserver.localdomain (192.168.100.135): icmp_seq=3 ttl=64 time=0.046 ms
64 bytes from myserver.localdomain (192.168.100.135): icmp_seq=4 ttl=64 time=0.073 ms
64 bytes from myserver.localdomain (192.168.100.135): icmp_seq=5 ttl=64 time=0.077 ms
64 bytes from myserver.localdomain (192.168.100.135): icmp_seq=6 ttl=64 time=0.041 ms

So it works from only within the Ubuntu Server.

If I go in Firefox in Windows to try to access the info on the web server in Ubuntu, I get a search page on OpenDNS.com instead!

I tried http://myserver.localdomain and http://myserver but I just get the OpenDNS.com search page.

What do I do to fix it so I can get to the server on Ubuntu Guest OS from the Windows host OS?

paulsm4 05-04-2009 09:47 AM

Hi -

For starters, you need to make sure the web page is accessable by IP address:

EXAMPLE http://192.xxx.yy.zzz

Once you've confirmed that, you need to:
1. Determine which DNS and/or WINS server(s) your Windows host is using (it's probably DHCP)
2. Make sure your LAN's DNS and/or DHCP is correctly configured for VMWare/Ubuntu
3. Make sure your Ubuntu is correctly configured for your LAN's DNS and/or DHCP

The easiest way to do this is (at least for a private, internal LAN) to simply use DHCP across the board.

RavenLX 05-04-2009 04:38 PM

Quote:

Originally Posted by paulsm4 (Post 3529591)
Hi -

For starters, you need to make sure the web page is accessable by IP address:

EXAMPLE http://192.xxx.yy.zzz

I can access the page using just the IP, yes. But I rather access it by myserver.localdomain.domain-on-my-server.com instead.

Quote:

Originally Posted by paulsm4 (Post 3529591)
Once you've confirmed that, you need to:
1. Determine which DNS and/or WINS server(s) your Windows host is using (it's probably DHCP)

It's set to DHCP, true.

Quote:

Originally Posted by paulsm4 (Post 3529591)
2. Make sure your LAN's DNS and/or DHCP is correctly configured for VMWare/Ubuntu

I am not sure how to do that. VMWare does it automatically. I've even tried the Bridged connection in setting up the Virtual Machine network adaptor and also tried NAT.

Quote:

Originally Posted by paulsm4 (Post 3529591)
3. Make sure your Ubuntu is correctly configured for your LAN's DNS and/or DHCP

The easiest way to do this is (at least for a private, internal LAN) to simply use DHCP across the board.

Ok, this is all where I don't know what to look for or what to do. All the network adaptors (wifi and wired on the host/Windows side and the two VMWare network 'adaptors') are set for DHCP.

But in Ubuntu Server itself, I wanted to use a static IP. Is that right? Or should I still be using DHCP in my /etc/network/interfaces?


All times are GMT -5. The time now is 10:52 AM.