PDA

View Full Version : Can't connect to internet through router



archimedes1981
12-23-2007, 12:55 PM
SO, i had given up trying to use linux because i couldn't get connected through pppoe. Now I had the need of installing a router and since with this there should be no pppoe configurations through Knoppix and only through the router I am trying again. I setup the router myself and although it works perfectly on Win XP i might have done something wrong. What I did and supposedly works as i want it is this, I connected my PC using ethernet to the router while another PC is connected through wireless. The PC directly connected to the router works fine on XP (internet). The router should be set up using static IP to the PCs and DHCP to ISP. One question I have is this:
If the Inet is the IP address from eth0 to router and the gateway and mask are the same as on XP, what exactly is the Bcast IP??
I set it as blank in netcardconfig and it showed up 192.168.2.255. With this configuration i could browse the router GUI but unless there is something else to setup on KNOPPIX the internet connection is not working(on the PC connected with ethernet card). Also question 2 is this:
what is 'lo'? is it the LAN in winXP?
Do i have to set it up in some way? And also:
If i can browse the router , what is wrong with the internet connection? It shows up on the router! So i presume that it is eth0 that in fact i should have set up(and i did).
Thanks and regards.

hedgehog
12-23-2007, 02:23 PM
Hi, I don't know much other than what I've found out going through the same process as you, but I can tell you that the broadcast address is (according to Wikipedia) an IP address that can transmit information to all machines on a subnet. I asked about it on another forum and was told that it is worked out from the first three number blocks of the IP address and the first of the subnet (eg if the IP address is 192.168.1.1 with a subnet of 255.255.255.0 the broadcast address is 192.168.1.255).
"lo" is the loopback - 127.0.0.1 is your own computer.
I've had no trouble accessing the internet through my router with the eth0 IP address, subnet and gateway all exactly the same as in XP and I did nothing to the "lo" connection information. Not sure if that is helpful, but good luck with it.

kirol
12-23-2007, 03:54 PM
192.168.2.x looks good for a private IP range, and the fact that you can connect to your router seems to indicate that your address is OK. You haven't mentioned if you had configured DNS. Without it, you won't be able to do much. I suggest you try DHCP first, which should take care of providing your linux client with all the necessary parameters (IP, netmask, DNS servers...). Once that works and if you really need a static IP, make sure you provide all the parameters when asked by the knoppix "netcardconfig" script. If you've installed to HD, look into /etc/network/interfaces and /etc/resolv.conf

BTW PPPoE is perfectly supported on linux, by the "roaring penguin" SW, included with knoppix. Connecting through USB can be problematic, though, and purchasing a router is a smart move.

Harry Kuhman
12-23-2007, 06:11 PM
Knoppix generally gets the setup by dhcp from the router and works fine. It might be helpful if you define what isn't working; as we have seen some reports of DNS server problems with firefoxc/iceweasel when the ISP is trying to support IPv6 (disabling IPv6 in the browser usually resolves this). There have also been reports of IPv4/IPv6 issues when the ISP assigned DNS servers are improperly configured (in this case you can ping an Internet address by IP address but not by URL).

Giving the output of ifconfig may help. In general the broadcast address will be 192.168.x.255, but this really is interdependent on the net mask (and, of course, the assigned local IP address).

And I'm assuming you are trying to get a wired connection working, not wireless, although I found that part of your post somewhat confusing.

archimedes1981
12-24-2007, 12:20 PM
I finally managed to fix it...by mistake!
All my IPs start with 192.168.2.xxx
I set my Bcast address to 192.168.0.255 and it worked !
I'm happy with this but for future problems if anyone can give me an answer on why this happened it would be very helpful. Probably when I used to try without the router and using roaringpenguin that was the same problem i had!
Thanks to all , regards and best wishes.

Harry Kuhman
12-24-2007, 05:34 PM
...All my IPs start with 192.168.2.xxx
I set my Bcast address to 192.168.0.255 and it worked !....
There is something very wrong here. While you may perceive this as working now, network activities that depend on broadcasts will fail under this condition. I suggest that you dig deeper into what is going wrong and correct it. It would be best to determine not only why this apparently out-of-range broadcast address seems to work, but also why you need to do any manual configuration at all rather than just letting DHCP configure the network for you.

I would be interested in seeing ifconfig output, both before and after you set the broadcast address to 192.168.0.255. Also, why this particular address? Is there something on your system that makes this address seem special, or is it just that you bypassed the normal (for your system) 192.168.2.255 broadcast address? I suggest an experiment where you try 192.168.50.255 and see what happens (or pretty much any address outside the 102.168.2.xxx and 192.168.0.xxx ranges). My guess is that your new broadcast address isn't really working, but it's preventing you from getting some information from the normal broadcast address that was leading to the problem.

If you choose to not track this down now, at the very least remember that you have done this and make it clear again that your broadcast address is not right when you come back later and make your next post about a networking problem that you are having. Because with addresses like this you will have future problems.

archimedes1981
12-27-2007, 04:17 PM
So I reconfigured the (this is the first time i'm using knoppix to write on this site, i don't know why some words are being written in red ! anyway....) eth0 broadcast to 192.168.2.255 and it works too . I also think that this is better because although i had internet with the last IP (192.168.0.255) Knoppix always ended up in hanging while browsing but i'm not sure if it had anything to do with this. Also I forgot that as nameserver i used the Gateway IP and it must have been that which maked everything work and not the old broadcast).
I also did SWAP file configuration, which if i understood correctly seems to be something like the microsoft "virtual memory" , so it should run better like this too i think.
I will try browsing some heavier sites to check if it hangs again later.
(now all the words in this post turned back to black....I'm quite confused ! anyway...)
This is my ifconfig:

eth0 Link encap:Ethernet HWaddr 00:0B:6A:D1:F7:30
inet addr:192.168.2.101 Bcast:192.168.2.255 Mask:255.255.255.0
inet6 addr: fe80::20b:6aff:fed1:f730/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:996 errors:0 dropped:0 overruns:0 frame:0
TX packets:997 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:599725 (585.6 KiB) TX bytes:169568 (165.5 KiB)
Interrupt:21 Base address:0xd800

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:22 errors:0 dropped:0 overruns:0 frame:0
TX packets:22 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:1100 (1.0 KiB) TX bytes:1100 (1.0 KiB)

1) I don't need IPv6. How do I get rid of it?
2) Could it be the IPv6 or the bad broadcast that made knoppix hang ?
3) Does the "SWAP file configuration" help running?
4) When I "Save KNOPPIX configuration"and choose all the fields in it, do they include the SWAP file and any programs i 'install'?
5) Since this is a live cd, can I install anything which will come up again after i restart? I was going to look for an anti-virus and spam/adware protection....will these remain available after restart? Also some Divx drivers and flash players etc.
Thanks a lot for your precious help,

archimedes1981
12-27-2007, 04:20 PM
Btw sorry forgot about the IP before configuring i will try restarting and post them. I am using this IP because I am on a wireless router(although this particular PC is hardwired) and I wish to setup every machine with static IP and MAC address so that no one steals broadband from me.

Harry Kuhman
12-27-2007, 05:30 PM
...... and I wish to setup every machine with static IP and MAC address so that no one steals broadband from me.
I'm not quite sure the reason fpr the static IP addresses here, although different routers deal with this in different ways. You might want to spell out your understanding of what your router does in this area. As for MAC addresses, this will stop accidental access but will not even slow down a hard core hacker. The MAC can be spoofed, and if you are depending on it for security you may suffer the loss of a lot more than a little bandwidth. The proper approach for wireless security is to use WPA encryption (and absolutely not use WEP) with a long non-guessable, safe from dictionary attack key. If you do this you are secure, if you don't you are not. And even without using MAC spoofing a hacker may find it more useful to just passively monitor your wireless traffic and steal things like e-mail addresses and passwords (which often lead to other saved accounts and passwords, as well as bank accounts and more) than bothering to steal bandwidth. If you feel better about using a MAC table after setting up WPA, that's fine although it really isn't needed. But depending on a MAC table for any form of security is idiotic.

archimedes1981
12-27-2007, 06:41 PM
well i didn't know that, i'll try to set everything to WPA. And as long as i'm asking for assistance and willing to learn i guess i'm not entitled to be called an idiot.
however can you answer any of my questions please?
I couldn't send you the ifconfig because i couldn't paste it on the web browser like i did before since i had no connection.
the idea was to save it on a txt file but knoppix does not always recognise my harddisks and sometimes it also shows icons of hardware which doesn't exist.
Then after trying a couple of things it always hangs.
I don't even know where to find any error logs if they exist.

Harry Kuhman
12-27-2007, 07:10 PM
.... as long as i'm asking for assistance and willing to learn i guess i'm not entitled to be called an idiot.
I didn't try to call you an idiot, rather to call the often suggested but completely insecure technique of counting on MAC addresses for any form of wireless security as idiotic and unsafe. More than unsafe really, as it is completely bogus advice. And I assumed that you would be receptive to the knowledge, or I would not have bothered to post it.


however can you answer any of my questions please?
I couldn't send you the ifconfig because i couldn't paste it on the web browser....
I'm trying to answer your questions, but don't have needed information. While cut and paste makes life simple, there is technology based n a graphite rod bound inside a wooden cylinder that would allow you to accurately record the data from ifconfig and then type it back in to a browser on a different OS. Sure, it's a bit more effort, but if saving to a USB drive or a floppy isn't working for you then the older approach may be the best.

archimedes1981
12-27-2007, 10:52 PM
ok that was fun :)
well for the time being, what i can tell you is that the eth0 is not detected at all before i do netcardconfig. It just gives me 'lo' IPs and settings, but i think that has nothing to do with my problem right?
Btw my hard drives (as probably you may have assumed) are formatted as NTFS, which as advised by most linux distros i have, is not fully compatible with linux but just experimental.

Harry Kuhman
12-27-2007, 11:41 PM
well for the time being, what i can tell you is that the eth0 is not detected at all before i do netcardconfig. It just gives me 'lo' IPs and settings, but i think that has nothing to do with my problem right?
I really don't know what is going on here. You haven't told us what NIC you have. But I would expect that Knoppix must have a driver for it, or else you would not have gotten it to work at all, even after a Netcardconfig. So I would normally expect that it would be properly configured BY DHCP. And in fact you seem to have said that it was being configured by DHCP, but the gateway address was, for some very mysterious reason, incorrect. If that it not what happened then please restate how that bad gateway address got there; if it was configured by DHCP then I don't know why you are now saying that eth0 was not detected before the netcardconfig. I have seen one router that didn't properly do a DHCP configuration with Knoppix even though it did DHCP handshake with Windows (an old 802-11b Belkin), so it certainly can happen that a router doesn't DHCP handshake properly and cause a problem, but so far I don't have enough information to say if that is happening in this case, or even if you equipment is trying to do a DHCP handshake.



....Btw my hard drives (as probably you may have assumed) are formatted as NTFS, which as advised by most linux distros i have, is not fully compatible with linux but just experimental.
Knoppix can read NTFS partitions just fine and can work fine on systems with them or even on systems with no hard disk at all. Writing data to NTFS partitions has been a problem for Linux that has had many bad results. Frequently when someone managed to do it at all the partition would become corrupted. Sometimes this was immidately evident, sometimes it would fester for a while and come back to haunt you later. Some previous attempts to write to NTFS were removed from Knoppix because they had been abandoned. The claim was made with version 5.x that in some cases you could now write to NTFS. That "in some cases" qualification scarred the heck out of me, and I decided not to risk my hard disk to it. And I don't think there is a good reason for others to risk it either. I've seen a few people post that they were able to get it to work, but never with any detailed technical data or history of use of the drive that would convince me that it presented long term safety for the partition. And even then I'm not convinced that Microsoft, sworn emeny of Linux, might not do something in a "security update" that might deliberately destroy the partition if they detect that it was written to by Linux in the future. Heck, we see plenty of reports that NTFS has been corrupted by XP itself, that's what brings many people tio Knoppix looking for data recovery, and now there are reports that Microsoft acknowledges it's own software can't write to NTFS safely (http://www.computerworld.com/action/article.do?command=viewArticleBasic&articleId=9054178), so why expect Knoppix to be able to do so? If you want to risk your data to NTFS partitions and Knoppix, be my guest, but I'll not do it nor advise others to risk their data.

archimedes1981
12-28-2007, 12:31 AM
I think there was a misunderstanding.
I am using static IPs (if i'm correct that's exactly the opposite of DHCP).
So that is why i have to configure my
IP address to 192.168.2.101
Netmask 255.255.255.0
Broadcast 192.168.2.255 - works now
Gateway 192.168.2.1
always. i.e. I need them to stay like that .
I think once i had found a command to display all the hardware configuration - if you can tell it to me it's better but i might find it again.
I didn't quite understand what you meant by NIC but i'm using ASRock motherboard 939A8X-M with
Ali/Uli M5263 ethernet .
I will try checking if knoppix is configuring the right driver for it.
The problem you mentioned about the gateway was in fact about the broadcast. I didn't know what to put there and while doing netcardconfig i mistyped and put 192.168.0.255 instead of 192.168.2.255. I think that 192.168.2.255 is good, right?
About NTFS : is there any safe way to share data between linux and windows (until i get everything running ok)?
Please confirm that my IP settings look fine now.
And also if you can, give me some commands that will give you the answers you need.

archimedes1981
12-28-2007, 01:35 AM
I hope this gives you enough info.

knoppix@Knoppix:~$ ifconfig
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:14 errors:0 dropped:0 overruns:0 frame:0
TX packets:14 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:700 (700.0 b) TX bytes:700 (700.0 b)

knoppix@Knoppix:~$ netcardconfig
ifconfig eth0 192.168.2.101 netmask 255.255.255.0 broadcast 192.168.2.255 up
route add default gw 192.168.2.1
Setting Nameserver in /etc/resolv.conf to 192.168.2.1
Done.
knoppix@Knoppix:~$ ifconfig
eth0 Link encap:Ethernet HWaddr 00:0B:6A:D1:F7:30
inet addr:192.168.2.101 Bcast:192.168.2.255 Mask:255.255.255.0
inet6 addr: fe80::20b:6aff:fed1:f730/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:37 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:0 (0.0 b) TX bytes:2758 (2.6 KiB)
Interrupt:21 Base address:0xd800

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:14 errors:0 dropped:0 overruns:0 frame:0
TX packets:14 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:700 (700.0 b) TX bytes:700 (700.0 b)

knoppix@Knoppix:~$ lspci
00:00.0 Host bridge: ALi Corporation M1689 K8 Northbridge [Super K8 Single Chip]
00:01.0 PCI bridge: ALi Corporation AGP8X Controller
00:02.0 PCI bridge: ALi Corporation M5249 HTT to PCI Bridge
00:03.0 ISA bridge: ALi Corporation M1563 HyperTransport South Bridge (rev 70)
00:03.1 Bridge: ALi Corporation M7101 Power Management Controller [PMU]
00:04.0 Multimedia audio controller: ALi Corporation M5455 PCI AC-Link Controller Audio Device (rev 20)
00:0d.0 Ethernet controller: ALi Corporation ULi 1689,1573 integrated ethernet. (rev 40)
00:0e.0 IDE interface: ALi Corporation M5229 IDE (rev c7)
00:0e.1 Mass storage controller: ALi Corporation ULi 5289 SATA (rev 10)
00:0f.0 USB Controller: ALi Corporation USB 1.1 Controller (rev 03)
00:0f.1 USB Controller: ALi Corporation USB 1.1 Controller (rev 03)
00:0f.2 USB Controller: ALi Corporation USB 1.1 Controller (rev 03)
00:0f.3 USB Controller: ALi Corporation USB 2.0 Controller (rev 01)
00:18.0 Host bridge: Advanced Micro Devices [AMD] K8 [Athlon64/Opteron] HyperTransport Technology Configuration
00:18.1 Host bridge: Advanced Micro Devices [AMD] K8 [Athlon64/Opteron] Address Map
00:18.2 Host bridge: Advanced Micro Devices [AMD] K8 [Athlon64/Opteron] DRAM Controller
00:18.3 Host bridge: Advanced Micro Devices [AMD] K8 [Athlon64/Opteron] Miscellaneous Control
01:00.0 VGA compatible controller: ATI Technologies Inc RV350 AR [Radeon 9600]
01:00.1 Display controller: ATI Technologies Inc RV350 AR [Radeon 9600] (Secondary)
knoppix@Knoppix:~$

According to windows XP the ethernet card should show Uli 5263.
I tried finding a driver for it but the only one i found needs something called tulip which i don't have in knoppix.
Any ideas?

Harry Kuhman
12-28-2007, 02:35 AM
I'm not even clear what the current problem is. You wrote:

I finally managed to fix it...by mistake! All my IPs start with 192.168.2.xxx
I set my Bcast address to 192.168.0.255 and it worked ! I'm happy with this but for future .....
So the Broadcast address made no sense, but at least you seemed to think it was working. So you clearly have the NIC (network Interface) drivers in Knoppix. Then you wrote:

So I reconfigured the (this is the first time i'm using knoppix to write on this site, i don't know why some words are being written in red ! anyway....) eth0 broadcast to 192.168.2.255 and it works too . I also think that this is better.....
Even better. You connected with a meaningful broadcast address (which should help your local network work better). Things are clearly working, you said that you posted the above from within Knoppix.

I'm not sure why you need to use a static IP address, but it's certainly a valid thing to do. There can be some reasons to do this, such as running a server that needs to always be on the same IP address. Some routers are very good about letting you lock a MAC address to an IP address, but others often give out different IP addresses every time that the computer connects, making DHCP a problem for servers. But you seem to be able to configure the system adequately by netcardconfig by bypassing DHCP and setting a static IP address (I wouldn't exactly use the term opposites, but these are two different ways to assign IP addresses, DHCP lets the router hand out available IP addresses and related information like the name server, network mask, gateway and DNS server, while bypassing DHCP lets you set these parameters manually).

So what is the current problem?

archimedes1981
12-28-2007, 06:18 PM
the current problem is that it hangs whenever it feels like i.e. erratically :- without me doing the same things at the time that it hangs.
i figured out that the ethernet driver is incorrect and maybe that's why it's hanging.
I found a driver for it but it needs something called tulip which i don't think i have and besides that it tells me to look for folders which i don't definitely have.
Can it be the ethernet card driver that hangs the complete system, it's Ali/Uli M5263.
If yes how can i install the driver ?
Or if it's NOT the incorrect ethernet card driver that hangs the system, how can i find what it is?