LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 12-13-2003, 01:40 PM   #1
stanley_shilov
LQ Newbie
 
Registered: Oct 2003
Distribution: Knoppix
Posts: 14

Rep: Reputation: 0
crossover cable for linux and winxp


i have two computers. they both have 2 network cards inside. they're both hooked up to a hub and the hub then runs to a dsl modem

what I wanted to do, was to hook up the computers through the crossover cable so i can transfer files back and forth

one computer runs winXP, the other one runs RedHat 9

I know it sounds simple, but I'm really not sure what to do. I tired to get a crossover cable, and connect it between the two computers. but i didnt work


( I really don't want for one PC to be dependent on the other for the connection )


thanks in advance..

Last edited by stanley_shilov; 12-15-2003 at 06:51 AM.
 
Old 12-13-2003, 01:45 PM   #2
chort
Senior Member
 
Registered: Jul 2003
Location: Silicon Valley, USA
Distribution: OpenBSD 4.6, OS X 10.6.2, CentOS 4 & 5
Posts: 3,660

Rep: Reputation: 76
If they're both plugged into the same hub already, then they can already connect to each other through the hub. You just need to make sure they both have an IP on the same network (such as 196.168.0.0/16, so you would give computer1 192.168.0.2 and computer2 192.168.0.3).
 
Old 12-13-2003, 01:57 PM   #3
stanley_shilov
LQ Newbie
 
Registered: Oct 2003
Distribution: Knoppix
Posts: 14

Original Poster
Rep: Reputation: 0
two questions..

would this make either one dependent on the other to access the internet?

question 2: there is no router anywhere. and the IP address is dynamic. so it would change from time to time. would this mean I have to change the Ip every time?
 
Old 12-13-2003, 02:02 PM   #4
chort
Senior Member
 
Registered: Jul 2003
Location: Silicon Valley, USA
Distribution: OpenBSD 4.6, OS X 10.6.2, CentOS 4 & 5
Posts: 3,660

Rep: Reputation: 76
So only one of your computers gets an IP at a time, the DSL modem doesn't have NAT? i.e. can both your computers be connected to the Internet at once, or only one at a time?

If only one at a time, then it would still be possible to connect through the hub, but since you already have two network cards you could do it with cross-over and not interfere with the Internet connection.

Plug the cross-over into the second NIC of each computer. On the Linux box do:
ifconfig eth1 172.16.0.2 netmask 255.255.255.0

On WinXP setup a new Local Area Network connection and choose to manually assign the IP rather than automatic. Give it the IP 172.16.0.3 and netmask 255.255.255.0. The default gateway should be empty.
 
Old 12-14-2003, 08:24 PM   #5
stanley_shilov
LQ Newbie
 
Registered: Oct 2003
Distribution: Knoppix
Posts: 14

Original Poster
Rep: Reputation: 0
I did as you said and assigned the IPs and netmasks to both systems.

But when I tried pinging one system from the other it didnt work


everything looks okay, I have no idea what could be wrong
 
Old 12-14-2003, 08:42 PM   #6
2damncommon
Senior Member
 
Registered: Feb 2003
Location: Calif, USA
Distribution: PCLINUXOS
Posts: 2,918

Rep: Reputation: 103Reputation: 103
Does:
cat /var/log/messages | grep Ethernet
show that your card is seen at boot up?
Firewalls can also be a problem.
 
Old 12-14-2003, 10:44 PM   #7
stanley_shilov
LQ Newbie
 
Registered: Oct 2003
Distribution: Knoppix
Posts: 14

Original Poster
Rep: Reputation: 0
network card is detected fine so that cant be the problem..

I think i configured something wrong
if not on the linux, then probably on the windows side =/

Last edited by stanley_shilov; 12-14-2003 at 10:53 PM.
 
Old 12-14-2003, 10:57 PM   #8
2damncommon
Senior Member
 
Registered: Feb 2003
Location: Calif, USA
Distribution: PCLINUXOS
Posts: 2,918

Rep: Reputation: 103Reputation: 103
Quote:
they're both hooked up to a hub and the hub then runs to a dsl modem
With my setup I have all PCs connected VIA a hub, but the modem is connected to my firewall PC.
Unless your modem is more than a modem, that may be the problem. Have you had it working that way before?
Both Pcs connected to the hub and assigned address on the same network should be able to communicate.
The DSL modem should be connected to one of the PCs and that PC should be a gateway for the other.
I think...
 
Old 12-15-2003, 03:57 AM   #9
chort
Senior Member
 
Registered: Jul 2003
Location: Silicon Valley, USA
Distribution: OpenBSD 4.6, OS X 10.6.2, CentOS 4 & 5
Posts: 3,660

Rep: Reputation: 76
But are you sure you hooked the right cards up?

In WinXP, unplug the cable from the hub and only leave one cable plugged in. In your system tray you should see one set of little computers with a red X, this is the unplugged NIC. The other set of computers should be flashing occasionally. That's the one you want to right click on and go into properties (might have to go to status first, then properties).

On your Linux box unplug the cable that goes into the hub and only leave the crossover plugged in. If you do ifconfig -a|grep -i carrier it should show you one of the NICs says "NO CARRIER" (I'm pretty sure that's what Linux says when it's not plugged in). That's the NIC for the hub. You want to ifconfig the other one for the same subnet as WinXP.

Now the last thing is, you may have a firewall on either side that prevents ICMP echo requests (or replies). There's some iptables command you can run on Linux to check your rules (man iptables) and on Windows, if you go into advanced on the properties for your NIC there is a check box for Internet Connection Firewall. If the box is checked, go into settings and see if the allow ICMP echo request box is checked. Note that you do NOT need ICMP packets to go between your computers in order to share files and the like, you only need TCP and that only on the service ports you require (such as 139 for SMB).
 
Old 12-15-2003, 05:07 AM   #10
fotoguy
Senior Member
 
Registered: Mar 2003
Location: Brisbane Queensland Australia
Distribution: Custom Debian Live ISO's
Posts: 1,291

Rep: Reputation: 62
Try a straight through cable instead of a crossover.
 
Old 12-15-2003, 05:13 AM   #11
fotoguy
Senior Member
 
Registered: Mar 2003
Location: Brisbane Queensland Australia
Distribution: Custom Debian Live ISO's
Posts: 1,291

Rep: Reputation: 62
Some times having to nics of the same chipset may not work properly, you could try useing 1 nic in each and run throught the hub.
 
Old 12-15-2003, 06:49 AM   #12
stanley_shilov
LQ Newbie
 
Registered: Oct 2003
Distribution: Knoppix
Posts: 14

Original Poster
Rep: Reputation: 0
ok I read each and one of your every posts and thank you all for trying to help.

It is my fault that I forgot to leave out some details.

- I don't have a firewall installed on either side.

- I do not wish to touch the current connection.

I installed an extra NIC card into each PC specifically for the purpose of having a crossover connection.

All I really want, is to establish the crossover connection.

- I really don't want for one PC to be dependent on the other for the connection.


once again, thank you all for trying to help
 
Old 12-15-2003, 10:54 AM   #13
chort
Senior Member
 
Registered: Jul 2003
Location: Silicon Valley, USA
Distribution: OpenBSD 4.6, OS X 10.6.2, CentOS 4 & 5
Posts: 3,660

Rep: Reputation: 76
So does it work, or not? Did you try my suggestions?

By the way, a straight-through between two NICs is not going to work, that's the whole point of cross-over cables!
 
Old 12-15-2003, 03:30 PM   #14
stanley_shilov
LQ Newbie
 
Registered: Oct 2003
Distribution: Knoppix
Posts: 14

Original Poster
Rep: Reputation: 0
I know lol

On the linux box I did exactly as you said.

On the windows box everything seems to be configured okay too, but if I ping one system from the other it doesnt work
 
Old 12-15-2003, 04:49 PM   #15
fotoguy
Senior Member
 
Registered: Mar 2003
Location: Brisbane Queensland Australia
Distribution: Custom Debian Live ISO's
Posts: 1,291

Rep: Reputation: 62
Sorry i know a straight through wont work between 2 nics, i was tired and didn't read the thread properly, didn't see haveing 2 nics on the 1 machine
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Crossover cable WolfCub Linux - Hardware 20 09-05-2009 01:20 PM
connect 2 Linux boxes via crossover cable forbuto Linux - Networking 1 10-21-2004 06:38 PM
How to: linux<---->linux with crossover cable? tredegar Linux - Networking 2 10-09-2004 11:29 AM
Trouble networking two Linux computers (via crossover cable) lrt2003 Linux - Networking 3 06-29-2004 09:06 AM
Crossover cable eggoz Linux - Networking 4 03-14-2004 12:49 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 12:59 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration