rhockett94
Posts: 4
Joined: Wed Jul 11, 2012 7:53 pm

Crossover cable problem- cannot connect to network.

Wed Jul 11, 2012 8:06 pm

Hi, I keep trying to connect my RPi to my win7 computer through an ethernet cable (these are the same as crossover cables, right?) but despite my best efforts I cannot get the RPi to successfully connect.

I have tried http://elinux.org/RPi_Setting_up_a_static_IP_in_Debian and http://ubuntuforums.org/showthread.php?t=1576711 , and the only other person on troubleshooting I found with this problem got a replacement. I just got the pi today (along with the brand new ethernet cable) and tried connecting it to the network through my computer (which uses a wireless connection to router). Every time I tried to ping my router (192.168.0.1) or the computer (192.168.0.33) I get the following:

From 192.168.0.33 icmp_sec=1 Destination Host Unreachable

Could anyone tell me what this is? cat /etc/resolv.conf returns some obscure IPs irrelevant to my local network, despite how many times I try using /etc/init.d/networking restart.

Thanks!

aaa801
Posts: 428
Joined: Mon Jun 04, 2012 9:06 pm
Location: Berkshire

Re: Crossover cable problem- cannot connect to network.

Wed Jul 11, 2012 8:35 pm

Why are you using a crossover cable in the first place =/
Also no. normal cables are NOT crossovers, I advise that you pickup a cheap switch as it will be much easier

rhockett94
Posts: 4
Joined: Wed Jul 11, 2012 7:53 pm

Re: Crossover cable problem- cannot connect to network.

Wed Jul 11, 2012 8:48 pm

aaa801 wrote:Why are you using a crossover cable in the first place =/
Also no. normal cables are NOT crossovers, I advise that you pickup a cheap switch as it will be much easier
I don't have the money/room for a switch, and I've just confirmed that it's indeed a crossover cable that was bought from RS components with the raspberry Pi. I have read up that you can connect it through the PC, as connecting it to the router is infeasible as it's in a different room. The router cannot be moved, and neither can my computer.

aaa801
Posts: 428
Joined: Mon Jun 04, 2012 9:06 pm
Location: Berkshire

Re: Crossover cable problem- cannot connect to network.

Wed Jul 11, 2012 11:03 pm

rhockett94 wrote:
aaa801 wrote:Why are you using a crossover cable in the first place =/
Also no. normal cables are NOT crossovers, I advise that you pickup a cheap switch as it will be much easier
I don't have the money/room for a switch, and I've just confirmed that it's indeed a crossover cable that was bought from RS components with the raspberry Pi. I have read up that you can connect it through the PC, as connecting it to the router is infeasible as it's in a different room. The router cannot be moved, and neither can my computer.
Did you enable ics from your normal connection onto the crossover,
Also, I can confirm that this is a decent dumb switch for less then a tenner, http://www.ebay.co.uk/itm/5Port-RJ45-Et ... 4ab0b89d1d

Crossovers generaly use a link local address, Pm me if you want me to check it up for you

bredman
Posts: 1415
Joined: Tue Jan 17, 2012 2:38 pm

Re: Crossover cable problem- cannot connect to network.

Thu Jul 12, 2012 10:29 am

It looks as if you have succeded in connecting to your Windows PC, because you have received a response from it.

Have you enabled a network bridge on the Windows PC from WiFi to Ethernet? Search the internet for "Windows network bridge" if you need instructions.

You do not actually need a crossover cable. The RPi has auto-sensing ethernet, so you can use either a straight or crossover cable.

halfabiscuit
Posts: 26
Joined: Thu Jun 21, 2012 10:55 am

Re: Crossover cable problem- cannot connect to network.

Thu Jul 12, 2012 3:08 pm

Crossovers generaly use a link local address
Possibly the daftest thing I have ever heard.

There is no reason a crossover would not work - I am having the same problems as you - see http://www.raspberrypi.org/phpBB3/viewt ... 28&t=10011
No resolution as yet..

rhockett94
Posts: 4
Joined: Wed Jul 11, 2012 7:53 pm

Re: Crossover cable problem- cannot connect to network.

Thu Jul 12, 2012 5:18 pm

bredman wrote:It looks as if you have succeded in connecting to your Windows PC, because you have received a response from it.

Have you enabled a network bridge on the Windows PC from WiFi to Ethernet? Search the internet for "Windows network bridge" if you need instructions.

You do not actually need a crossover cable. The RPi has auto-sensing ethernet, so you can use either a straight or crossover cable.
Thanks mate! I set up a bridge according to this video, now it seems to be connecting to my network, and I can ping other devices (my PC it's connected to, the router, etc) without fail. However it still cannot connect to the internet- I've checked the routing table with route -n and it tells me that the destination for the second entry is 192.168.0.0 . My router is at 0.1, not 0.0 . The network I set in /etc/network/interfaces is still 0.1 however. Is this what's causing the issues? I've tried editing resolv.conf to include 192.168.0.1 as a nameserver, but it then tells me "cannot assign requested address" and "failed to bring up eth0".

W. H. Heydt
Posts: 13347
Joined: Fri Mar 09, 2012 7:36 pm
Location: Vallejo, CA (US)

Re: Crossover cable problem- cannot connect to network.

Thu Jul 12, 2012 6:18 pm

aaa801 wrote:
rhockett94 wrote:
aaa801 wrote:Why are you using a crossover cable in the first place =/
Also no. normal cables are NOT crossovers, I advise that you pickup a cheap switch as it will be much easier
I don't have the money/room for a switch, and I've just confirmed that it's indeed a crossover cable that was bought from RS components with the raspberry Pi. I have read up that you can connect it through the PC, as connecting it to the router is infeasible as it's in a different room. The router cannot be moved, and neither can my computer.
Did you enable ics from your normal connection onto the crossover,
Also, I can confirm that this is a decent dumb switch for less then a tenner, http://www.ebay.co.uk/itm/5Port-RJ45-Et ... 4ab0b89d1d

Crossovers generaly use a link local address, Pm me if you want me to check it up for you
From that link:
5Port RJ45 Ethernet LAN Network Hub Switch Power Adapter Cable For Xbox Ps3 Game
It is *probably* a hub and NOT a switch...why even *mention* "hub" if it is actually a switch?

While a hub will work as suggested in this instance, (a) one should not confuse the two devices, (b) you can connect switches in cascade, but you can't do that with hubs, and (c) if you have any choice at all, use a switch, not a hub.

If it weren't for the proliferation of single network facing single IP address connections (necessitating the use of NAT on LANs), we would probably be seeing similar confusion between bridges and routers. Just as a switch can do anything a hub can do...and do it better...a router can do anything a bridge can do, not only better, but a lot more besides.

halfabiscuit
Posts: 26
Joined: Thu Jun 21, 2012 10:55 am

Re: Crossover cable problem- cannot connect to network.

Fri Jul 13, 2012 12:37 pm

W. H. Heydt wrote:While a hub will work as suggested in this instance, (a) one should not confuse the two devices, (b) you can connect switches in cascade, but you can't do that with hubs
Another very dubious statement - there is no reason why you can't cascade a hub the same way you do with a switch. The only real difference between a switch and a hub is that a switch isolates each port into its own collision domain whereas a hub is one big collision domain. A switch will give much better performance and the more you interlink hubs the worse performance gets (because you are effectively increasing the collision domain) and if you make the mistake of forming a loop then your network will go into meltdown.
But you can cascade them...

rhockett94
Posts: 4
Joined: Wed Jul 11, 2012 7:53 pm

Re: Crossover cable problem- cannot connect to network.

Fri Jul 13, 2012 10:07 pm

I apologise to interrupt your conversation, but could you answer my question please?

Matt The Insane
Posts: 22
Joined: Thu Jul 12, 2012 7:23 pm

Re: Crossover cable problem- cannot connect to network.

Sat Jul 14, 2012 12:09 pm

You need to strip this back to basics.

Tell the Pi not to have a fixed IP - put it back to getting it via DHCP.
On your PC, click the network adapter that is connected to the Internet (Wifi) and in the options, set it to "allow other users to connect via this computers internet connection". When you do this, it will setup your other network adapter (your wired connection) to act as if it's a router, and it will start dishing out IP addresses.

In all probability, your Pi will be given IP address 192.168.0.2 and see your computer as 192.168.0.1 - it wont see the router at that address.

Your computer will probably stay as 192.168.0.33 on the network connected via WiFi, but it now has two IP addresses - one for the WiFi connection, and one for the wired.

That's how I had my Pi connected to the internet to do updates before I got the USB WiFi working on the Pi.

rocketero
Posts: 64
Joined: Wed Jul 11, 2012 5:45 pm

Re: Crossover cable problem- cannot connect to network.

Thu Jul 19, 2012 6:01 am

@rhockett94

Code: Select all

route -n and it tells me that the destination for the second entry is 192.168.0.0 . My router is at 0.1, not 0.0


Actually the route -n output you got is fine. As for a 192.168.0.X IP address with mask 255.255.255.0, the network address is 192.168.0.0

Return to “Troubleshooting”