PDA

View Full Version : [ubuntu] cannot connect to the internet



strnad
May 19th, 2008, 05:08 PM
I am using ubuntu 8.04


I have a problem with my internet connection. I use D-Link DES-1005D Fast ethernet desktop switch. When I plug the ethernet cable into the Notebook with Windows, the connection is made up automatically.

However this is not valid for Ubuntu. When I do it, Ubuntu tries to connect, but without any success. I called to my internet provider (telenet.be) and they told me, that they cannot give me any IP adresses or so, since all these information is passed on by the modem - D-Link.

When I put the command cat /etc/resolv.conf, I get only this response:

cat: /etc/resolv.conf No such file or directory

I do not understand it, because I have downloaded a fresh copy from the internet just a few hours ago.

Nevertheless, if it helps. When I was installing Ubuntu, I tried to configure the network as it is possible during the installation. However Ubuntu told me, that automatic configuration is not possible, because my network does not use DHCP. But when I checked my settings in Windows, I get some DHCP IP address. Also I had to enter a name for my network - I used "user". I do not know, what that exactly means, but I want to provide you with as much (useful) information as possible.

kestrel1
May 19th, 2008, 05:14 PM
Can you post the result of:

ifconfig
This may help us.

kestrel1
May 19th, 2008, 05:14 PM
Double Post......

strnad
May 19th, 2008, 07:30 PM
Hello,

the output of the ifconfig is as follows:

user@ubuntu:~$ ifconfig

eth0 Link encap:Ethernet HWaddr 00:1d:92:53:d3:81
inet6 addr: fe80::21d:92ff:fe53:d381/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:4 errors:0 dropped:0 overruns:0 frame:0
TX packets:12 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:240 (240.0 B) TX bytes:2520 (2.4 KB)
Interrupt:252 Base address:0x6000

lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
inet6 addr: ::1/128 Scope:Host
UP LOOPBACK RUNNING MTU:16436 Metric:1
RX packets:154 errors:0 dropped:0 overruns:0 frame:0
TX packets:154 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:7700 (7.5 KB) TX bytes:7700 (7.5 KB)

user@ubuntu:~$

I do apologize for the double post, but the original one has been forgotten and I would really like to solve this problem.

Thanks for understanding

Peter.

kestrel1
May 19th, 2008, 10:24 PM
I wasn't saying you had double posted, for some reason my machine decided to post my reply twice, so I edited it. Sorry for confusion there.

Go to System> Administration> Network.
You may need to unlock this.
What do you have under the DNS tab?
Is your Wired connection set to Roaming Mode?

mapes12
May 19th, 2008, 11:58 PM
This is not good:


When I put the command cat /etc/resolv.conf, I get only this response:

cat: /etc/resolv.conf No such file or directory

I do not understand it, because I have downloaded a fresh copy from the internet just a few hours ago.

Also, the file is generated by your system, not downloaded off the web.

Likewise, your ifconfig output is not registering your private IP address which means you are not connecting to your router.

Have you tried resetting the router i.e turning it off and on again. Sounds crude but will restart DHCP to assign an IP address to your machine?!

superprash2003
May 20th, 2008, 01:56 AM
you dont seem to be getting an ip address in eth0. try this go to system->administration->network and choose eth0 properties and select DHCP.. and then post an ifconfig output

kestrel1
May 20th, 2008, 09:29 AM
After selecting DHCP you would need to reboot the machine. However having eth0 set to roaming mode you should get an IP address via DHCP.
You could type:

ping 'router ip'
where 'router ip' = the IP address of your router, to see if you are getting a response from your router.

strnad
May 20th, 2008, 06:15 PM
Hello,

mapes12 - the restart of the router did not help. I still cannot connect to the internet.

kestrel1:

- under DNS tab in Administration - Network I have no IP addresses at all.
- in administration - network, I have no eth0 option. I have only two options: Wired connection and Pont to point connection. When I have set the Wired connection to DCHP I had to turn the Roaming off and it did not work either.

I have somehow managed to get some IP addresses from Administrator - Networ Tools from the tab Devices. There is an address of 127.0.0.1. When I put this number into command ping '127.0.0.1' I get this response:

user@ubuntu:~$ ping 127.0.0.1

PING 127.0.0.1 (127.0.0.1) 56(84) bytes of data.
64 bytes from 127.0.0.1: icmp_seq=1 ttl=64 time=0.038 ms
64 bytes from 127.0.0.1: icmp_seq=2 ttl=64 time=0.033 ms
64 bytes from 127.0.0.1: icmp_seq=3 ttl=64 time=0.035 ms
64 bytes from 127.0.0.1: icmp_seq=4 ttl=64 time=0.034 ms
64 bytes from 127.0.0.1: icmp_seq=5 ttl=64 time=0.015 ms
64 bytes from 127.0.0.1: icmp_seq=6 ttl=64 time=0.030 ms
64 bytes from 127.0.0.1: icmp_seq=7 ttl=64 time=0.035 ms
64 bytes from 127.0.0.1: icmp_seq=8 ttl=64 time=0.034 ms
64 bytes from 127.0.0.1: icmp_seq=9 ttl=64 time=0.036 ms
64 bytes from 127.0.0.1: icmp_seq=10 ttl=64 time=0.034 ms
64 bytes from 127.0.0.1: icmp_seq=11 ttl=64 time=0.034 ms
64 bytes from 127.0.0.1: icmp_seq=12 ttl=64 time=0.035 ms
64 bytes from 127.0.0.1: icmp_seq=13 ttl=64 time=0.034 ms
64 bytes from 127.0.0.1: icmp_seq=14 ttl=64 time=0.033 ms
64 bytes from 127.0.0.1: icmp_seq=15 ttl=64 time=0.034 ms
64 bytes from 127.0.0.1: icmp_seq=16 ttl=64 time=0.035 ms

--- 127.0.0.1 ping statistics ---

16 packets transmitted, 16 received, 0% packet loss, time 15043ms
rtt min/avg/max/mdev = 0.015/0.033/0.038/0.005 ms
user@ubuntu:~$

The problem is, that I get this only on network device "Loopback interface (lo),I can also choose Ethernet interface (eth0) but when I push configure button, I get an information, that such device does not exist and cannot be configured.

So what now?

Thanks for help

Peter

kestrel1
May 20th, 2008, 06:39 PM
127.0.0.1 is a loop back address & will not help you.
It sounds like the drivers for your network card are either corrupt or not installed correctly. What network card do you have?

mapes12
May 20th, 2008, 07:20 PM
Nevertheless, if it helps. When I was installing Ubuntu, I tried to configure the network as it is possible during the installation. However Ubuntu told me, that automatic configuration is not possible, because my network does not use DHCP.

This is the problem and Ubuntu is correct. Your network is a switch (which you did say but we all missed it!) See here:

http://www.dlink.co.uk/?go=gNTyP9CgrdFOIC4AStFCF834mptYKO9ZTdvhLPG3yV3oV4 58kP98f8p8M6tj5jkkBSrgzy9B/IsIAw==

Switches manage traffic. They do not have DHCP capability to assign private IP addresses across a LAN.

XP must be getting its DHCP service from somewhere else on your network that Ubuntu can't find.

In XP:

Start>Run>cmd - enter
At the prompt type:


ipconfig
Post the output into this thread.

And try and explain in more detail your network physical configuration including any other devices between your client machine and the internet.

strnad
May 20th, 2008, 09:30 PM
Hello,

this is the output of the Windows XP if I type ipconfig. I do not have the Windows in english, so this is a translation from my language so it does not have exactly match to what you are used to:

Configuration of the IP protocol of the Windows system

Ethernet network adapter for the Local connection 2:

Specific DNS suffix for the connection: telenet.be
IP address. 84.193.194.88
Mask of the subnetwork: 255.255.240.0
Preset gate: 84.193.192.1

Considering my physical connection:

I am using D-Link switch, that is directly pluged into my computer via ethernet cable into ethernet port. My computer is a standard type - NOTEBOOK MSI VR610X-099SK 15.4 TK55 160G 2G WEBCAM.

Considering to networking, it has an Express card - Realtek Semiconductor Co. Ltd. RTL8101E PCI Express Fast Ethernet Controller (rev 01.

There is also a Wireless PCI Express adapter from Atheros Communications, but that is I think not important.

Peter

kestrel1
May 21st, 2008, 10:27 AM
Thanks for pointing out that it is a switch, I missed that as well.
What is the switch plugged into, apart from the computer? You must have a physical connection to the Internet via a router unless this is on a large network & you are a small part of the network.

mapes12
May 21st, 2008, 10:39 AM
Peter


IP address. 84.193.194.88
Mask of the subnetwork: 255.255.240.0
Preset gate: 84.193.192.1

Your IP address is a public address straight though to your ISP. In other words you do not have a DHCP service between you and your ISP. That's why the Ubuntu install couldn't find it.

Therefore, you will need to configure Network Manager manually. I'm hoping your ISP assigns you a static IP address and not a new leased public address at each login. Ask them the question.

Anyhow, try this:

System>Administration>Networking

Highlight your connection then click properties. If roaming mode is checked then uncheck it.

Then,

configuration = Static IP address

IP address = 84.193.194.88

Subnetmask = 255.255.240.0

Gateway = 84.193.192.1

Click OK and close the window.

Can you connect?

You may have to restart your machine.

kestrel1
May 21st, 2008, 10:59 AM
Not a good idea to use the public address as a static if your ISP assigns your address via DHCP though, if you are assigned a static though, go with it.

mapes12
May 21st, 2008, 11:05 AM
By the way, you may want to consider installing a router between you and your ISP.

This is because if you surf the net broadcasting a public address then it is very easy for hackers and malware to sniff out your system and create untold damage. A router has Network Address Translation (NAT) capabilty which cloaks your internal network address from the public address your ISP assigns to you.

It does this by using DHCP which assigns your internal network (i.e. client machines behind the router - this is what Ubuntu was trying to find) with Private Addresses. The private address is different to the public address thus hiding your machines from the outside world.

In Linux you are pretty well protected because of the inbuilt iptable configuration but if you surf the web using windoze and broadcasting a public address then you are braver than me.....


EDIT: If you don't want to go to the expense of buying a router then it's fairly easy to build a firewall server which does exactly the same job out of an old base unit, a couple of NIC cards and Linux. Get back to me if you want more info.

strnad
May 21st, 2008, 07:33 PM
Hello,

I have tried manual configuration and it did not work either. The problem is, that I have got assigned a new IP address. Despite I have filled in a new one, the computer did not even try to connect.

Just to make my physical connection more precise. The D-Link switch is connected to the Motorola Cable modem (SB51001E-CN). This modem serves to the D-Link switch as well as to the digibox for the digital TV.

Peter

mapes12
May 21st, 2008, 08:39 PM
Hi

I was able to connect to your previous IP address


mark@ubuntu-laptop:~$ ping -c4 84.193.194.88
PING 84.193.194.88 (84.193.194.88) 56(84) bytes of data.
64 bytes from 84.193.194.88: icmp_seq=1 ttl=109 time=67.7 ms
64 bytes from 84.193.194.88: icmp_seq=2 ttl=109 time=63.6 ms
64 bytes from 84.193.194.88: icmp_seq=3 ttl=109 time=63.4 ms
64 bytes from 84.193.194.88: icmp_seq=4 ttl=109 time=64.3 ms

--- 84.193.194.88 ping statistics ---
4 packets transmitted, 4 received, 0% packet loss, time 3000ms
rtt min/avg/max/mdev = 63.449/64.786/67.790/1.790 ms


although this maybe assigned to someone else now. It appears your ISP is leasing public addresses from a range they have registered to them.

Please could you let me have the weblink to your ISP?

strnad
May 21st, 2008, 08:48 PM
hello,

the web is

http://telenet.be/5/0/1/en/residential.html

it is their english version

Peter

kestrel1
May 22nd, 2008, 12:12 PM
Is the machine that has Ubuntu installed the same machine as Windows XP? (Dual boot) or are they seperate machines?
If they are seperate machines you shouldn't use the same IP address on both unless one machine is switched off. Also if they are seperate machines, are you sure that you are using a normal ethernet cable & not a cross over ethernet cable.

kestrel1
May 22nd, 2008, 12:13 PM
Is the machine that has Ubuntu installed the same machine as Windows XP? (Dual boot) or are they separate machines?
If they are separate machines you shouldn't use the same IP address on both unless one machine is switched off. Also if they are separate machines, are you sure that you are using a normal Ethernet cable & not a cross over Ethernet cable.

strnad
May 22nd, 2008, 12:56 PM
It is two separate machines. I am sure, I am using an ethernet cable. I do not use them at once - I have only one cable, so when I am trying to connect with one machine, the other one is unplugged.

Peter

kestrel1
May 22nd, 2008, 01:23 PM
If you only have the one cable & you transfer it between machines, then it blew my theory.
I still wonder if the Ethernet cards drivers are installed correctly or corrupt in some way in Ubuntu. If the settings are being entered in to Ubuntu & the cable is connected, I would have thought you should get somewhere. With the settings entered in Ubuntu, what is the output of:

ifconfig eth0
We should be getting the ip Address & everything else in there.

strnad
May 22nd, 2008, 02:41 PM
well,

the problem is, that when I enter the settings, the computer does not even want to connect.

Considering ethernet cards I think, they are OK, because at the HW test, Ubuntu recognizes them correcly.

When I have roaming mode, then it is trying to connect - I can see the icon - but the connection is not established.

nevertheless, I will put the output of the ifconfig eth0. But the problem is that I cannot even choose eth0 in Network tools, only lo.

mapes12
May 22nd, 2008, 05:18 PM
OK.

I had a look around the ISP's site but it didn't tell me what I was looking for. Which was the recommended physical installation and how IP's are assigned.

I think the NIC is Ok:


user@ubuntu:~$ ifconfig

eth0 Link encap:Ethernet HWaddr 00:1d:92:53:d3:81
inet6 addr: fe80::21d:92ff:fe53:d381/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:4 errors:0 dropped:0 overruns:0 frame:0
TX packets:12 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:240 (240.0 B) TX bytes:2520 (2.4 KB)
Interrupt:252 Base address:0x6000

lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
inet6 addr: ::1/128 Scope:Host
UP LOOPBACK RUNNING MTU:16436 Metric:1
RX packets:154 errors:0 dropped:0 overruns:0 frame:0
TX packets:154 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:7700 (7.5 KB) TX bytes:7700 (7.5 KB)

127.0.0.1 is registering.

If it were my configuration I would either replace the switch with an ethernet router or install a router between the PC's and the switch. That would introduce a local DHCP service which Ubuntu is trying to find. Once I had the router in my local network I would then reinstall Ubuntu so that the setup routine would initialise and hook up with DHCP.

DHCP could than handle the NAT translation between the ISP assigned IP address and allocate private addresses to clients behind the router.

It would also introduce a much more secure environment to the local machines.

mapes12
May 22nd, 2008, 05:21 PM
Peter

Forgot to mention that you can check if your NIC is OK by entering this in a Terminal window:


ping -c4 127.0.0.1

If you get 4 responses with no packets lost then it's OK.

mapes12
May 22nd, 2008, 05:26 PM
We should be getting the ip Address & everything else in there

The Ubuntu box can't negotiate itself an IP address. That's the problem. See the output Peter posted earlier in the thread.

kestrel1
May 22nd, 2008, 07:09 PM
I mean when the IP address is set manually, as it is clear that the Ubuntu box is not getting an address via DHCP.

strnad
May 22nd, 2008, 07:37 PM
Hello guys,

thanks for your help and advice. I will try to accomodate myself according to your advice.

I must say, that despite telenet told me, that the internet should work with Linux, it is not as easy, as they say. Nevertheless I have learned, that Linux is much more pleasant working environment than any other OS so definitelly will stick with it.

Moreover there is a great community here that is really responsive and willing to help, so what more can one need :-)

Thanks again and you were great help and support for me.

Peter

W6LQR
June 6th, 2008, 04:55 AM
Just installed v8.04 and the tab for activating the modem, that was there in v6.06 is gone (Admin/Network with the icon of a telephone). Also how can I make that easier to connect/disconnect from the Internet?

Thanks, Jerry