[Solved] Can't connect to the internet

Discussions related to using VirtualBox on Linux hosts.
kris2peyu
Posts: 7
Joined: 2. Aug 2008, 16:03

Post by kris2peyu »

TerryE wrote: Since DCHP normally overwrites resolv.conf, you need to put your override search list in resolv.conf.tail. However you should always include your router IP as the first node in the list, so that if your router's DNS cache is working, then your don't go to the internet unnecessarily.
how do I configure this "resolv.conf" & "resolv.conf.tail" ?
I tried disabling my dns and still doesn't connect!
TerryE
Volunteer
Posts: 3572
Joined: 28. May 2008, 08:40
Primary OS: Ubuntu other
VBox Version: PUEL
Guest OSses: Ubuntu 10.04 & 11.10, both Svr&Wstn, Debian, CentOS
Contact:

Post by TerryE »

I was about to reply, but then I googled "configure reslv.conf" and guess what: there are a lot better explanations out there. As it says below ...
Read the Forum Posting Guide
Google your Q site:VirtualBox.org or search for the answer before posting.
kris2peyu
Posts: 7
Joined: 2. Aug 2008, 16:03

Post by kris2peyu »

TerryE wrote:I was about to reply, but then I googled "configure reslv.conf" and guess what: there are a lot better explanations out there. As it says below ...
Ok I got it! But I tried using my dsl modem and remove my router. Just so I can find out if this is a router problem. But I still can't access the net with just my modem!
Is there a way we can do diagnostic on vb is there's something wrong with it?

I also found this http://backports.ubuntuforums.com/showt ... 7&t=346185
but I don't know where to find my eth0 or tap0
TerryE
Volunteer
Posts: 3572
Joined: 28. May 2008, 08:40
Primary OS: Ubuntu other
VBox Version: PUEL
Guest OSses: Ubuntu 10.04 & 11.10, both Svr&Wstn, Debian, CentOS
Contact:

Post by TerryE »

OK, normally in the UK most users buy a combined router / ADSL modem, so there are not two separate devices since you can get a 4 port + Wireless + router/firewall + ADSL modem for about $100, there's not much point in doing otherwise. If you have a separate router and modem then this makes things a little more complicated, but point is that you don't need to work out whether it's your router or your modem and you don't need to start removing things, you only need to give your VM the correct search list.

I'll talk you through what I did in my case. First my JeOS build didn't have the dnsutils installed so I had to do a sudo apt-get install dnsutls. I then catted /etc/resolv.conf which gave my name server as 10.0.2.3 which is what you would expect with NAT. I then googled my ISP to find the page which tells me what my ISPs DNS servers are. This took me to a page which told me that the servers are indnscN.ukcore.bt.net where N are various 2 digit numbers. Pinging these often fails because NS are often configured not to respond to IRCP, however you can just first from the host and then the same from the guest to find out which were working, though you may need to use the resolved IP address of the DNS server in this second case. I decided to use indnsc41.ukcore.bt.net (194.74.65.69), so I added to my /etc/resolv.conf.tail
  • nameserver 194.74.65.69
Now my guest will first use the VBox DNS function, but if this fails it will fall back to resolve using a specific BT DNS server. Clearly you don't want to pick a BT DNS server but use one in your ISPs infrastructure since this is going to be a lot nearer hop-wise.
Read the Forum Posting Guide
Google your Q site:VirtualBox.org or search for the answer before posting.
kris2peyu
Posts: 7
Joined: 2. Aug 2008, 16:03

Post by kris2peyu »

When i bought my router which is a wrt54g I never though there would be an all in one device. And since I already bought this one I can't just throw it away.
BTW ubuntu doesn't have "sudo apt-get install dnsutls"!
It just gives me the warnng "E: Couldn't find package dnsutls"!
Sorry but I do not know how to perform what you suggested to me!
I'm new to ubuntu and virtualization helps me to easily access programs that I have used and programs that are way better than open source programs out there.
Can you do a step by step process?
runbei
Posts: 46
Joined: 12. Nov 2007, 20:33
Primary OS: Linux other
VBox Version: PUEL
Guest OSses: WinXP Pro SP3
Location: Mountain View, CA
Contact:

Re: [Solved] Can't connect to the internet

Post by runbei »

I solved a problem getting my Internet connection working. This is in VB 3.0 with Linux Mint 7 host and WinXP Pro SP2 guest. In Windows, I simply went to TC/IP configuration and set both IP and DNS to automatic. Network connection seems to be working fine now.
Post Reply