PDA

View Full Version : How to I network two PCs together with Ethernet



transistordude
08-19-2004, 09:33 PM
Hi,
I would like to transfer files between my PC and laptop via ethernet. I have a cross cat 5e yellow cable and ethernet on both computers.

I clicked on Knoppix->Network Internet-> Network card configuration on both computers and I saw nothing except the mouse icon change for a few seconds.

Please advise on the command to learn what is my IP address so I could ping the computers and how do I specify in Konqueror the netwroked computer's directories.
Thanks,
Frank

Harry Kuhman
08-19-2004, 11:21 PM
Hi,
I would like to transfer files between my PC and laptop via ethernet. I have a cross cat 5e yellow cable and ethernet on both computers.

I clicked on Knoppix->Network Internet-> Network card configuration on both computers and I saw nothing except the mouse icon change for a few seconds.

Please advise on the command to learn what is my IP address so I could ping the computers and how do I specify in Konqueror the netwroked computer's directories.
Thanks,
Frank

If you are just connecting 2 computers by a cross-over cable and have no other network connections, then the 2 computers don't "have" IP addresses; you would have to assign one to each of them. If this network is completely cut off from anything else then you could use any IP addresses; but you would be wise to use private unroutable addreses like 192.168.1.2 and 192.168.1.3.

Although 2 computers can be networked this way and it might server you well, I really recommend the use of an inexpensive router. If you have high speed internet this becomes almost a must. In this case that would take care of all set-up and IP assignment for you. But it cartainly can be done with a cross over cable; I have one myself and have done just that with it.

By the way, you do know that the color of the cross-over cable is a non-issue, don't you?

j.drake
08-20-2004, 12:37 AM
By the way, you do know that the color of the cross-over cable is a non-issue, don't you?

Wondering the same thing myself, although I have noticed that some manufacturers tend to color code within their own brands. I bought a Belkin cross-over (before I learned how to make my own), and it appeared that they were all colored orange. At Home Depot, it seems that Blue Cat5 is plenum-rated. Problem is that I don't think their competitors are jumping on the bandwagon.

jd

mzilikazi
08-20-2004, 02:34 AM
It might be easiest to simply run the Knoppix terminal server on one box and configure the network on eth0 then set up the other box so that it gets an i.p. via dchp. The dhcpd running on the terminal server will hand your other box an i.p.

BTW the comand to check your i.p. under Linux is ifconfig

shah
08-20-2004, 02:35 AM
Might work and might not

I would suggest you boot with only one pc/notebook first using knoppix cd.
Try netcardconfig again, don't use DHCP, assign ip manually.
Then run Start Knoppix terminal server (on Penguin icon at the bottom).Click okay on every question ask. This will make this pc act as a "DHCP server" and will assign ip to your second pc.

Depends on OS of the other pc (client), if it's Windows, you need to run samba. To run samba, click the Start Samba Server (on Penguin icon). The samba user/password must be same as user/password used to login into your windows.

Then boot the second pc (client).

On "server" pc, open linneighborhood (under internet submenu), click on icon "ADD", you client pc should appear and will list all shared folder. Right click on your preferred folder and mount.

Now you can start working from konquerer. On konquerer, cick devices icon
and you will see Remote Share folder. You will see all your shared folder there which you can manipulate.




:D :D

Harry Kuhman
08-20-2004, 03:52 AM
...
Depends on OS of the other pc (client), if it's Windows, you need to run samba. ...
I thought about the OS issue, but he made it pretty clear he was running Knoppix on each system when he said
I clicked on Knoppix->Network Internet-> Network card configuration on both computers . Don't know if he's running Knoppix from CD or hard disk, which is always something good to say when asking for help, but I deleted the stuff I was going to say on OSs when I noted that the original post was clear on that.

transistordude
08-20-2004, 06:31 AM
You guys are right, I omitted to say that it is a hard disk Knoppix install.

I typed netcardconfig and got the dialogs. I assigned the IP addresses manually. The tower PC got 192.168.1.2. I left all the other parameters at their default values.

For the color code I am aware that makers put pretty much any color. I know for sure that my cable is a cross because I bought it specifically for this purpose at a store and I already networked two Windows-Windows PCs together with it.

Harry: I have a question about the private unroutable address. Exactly what in the 192.168.1.2 numbers guarantees it doesn't match some IP address somewhere on the net if I have a dialup modem online with the ethernet between the two PCs on?

PROBLEM: I ping the laptop with "ping 192.168.4" but ping gives no response at all. There is no timeout or unreachable. When I press control-C it says 100% packet loss with many packets that were sent.

Another detail I didn't mention Knoppix seems to think the laptop has two ethernet ports. I am using a PCMCIA card and assume that it's eth1.

I ran the Knoppix terminal server on the laptop. After, I went to linneighborhood, clicked on ADD, but the client was not written. So, I typed the Ip address, put nothing in the group, wrote the tower PC name and clicked OK. (I got an error when I did Querry.)

I did not find the devices icon in konqueror. Where is it?

I suspect something might be wrong because if I run netcardconfig on the client tower PC, with the DHCP, DHCP doesn't work.

Harry Kuhman
08-20-2004, 07:09 AM
Harry: I have a question about the private unroutable address. Exactly what in the 192.168.1.2 numbers guarantees it doesn't match some IP address somewhere on the net if I have a dialup modem online with the ethernet between the two PCs on?

The Internet TCP/IP spec defines some unroutable IP address ranges for just this purpose (sorry, I can't give you the exact RFC #). Off the top of my head, 10.xxx.xxx.xxx and 192.168.xxx.xxx are defined to be unroutable, there may be others but 192.168.xxx.xxx is the most common used for home networks. I don't know what logic, if any, was used to select these ranges.

Other people may certainly be using those numbers as well, but since they will not route on the 'net they can't see yours and you can't see them, so there is no conflict. That you are connecting via dial-up brings up another issue; that connection will end up with it's own IP address and your system will figure out what to send to the local lan and what to send to the dial-up, but as long as you use these addresses things will be safe even when you are directly connected to the Internet through the same NIC.


Another detail I didn't mention Knoppix seems to think the laptop has two ethernet ports. I am using a PCMCIA card and assume that it's eth1.

Actually I would expect it to be eth0, but I'm not clear why Knoppix thinks you have multiple NICs unless you have a motherboard with a built-in NIC. You don't , do you? (many recent laptops do). And you don't have built-in wireless in that laptop, do you? Try either and/or both of the connections Knoppix thinks it sees.


I suspect something might be wrong because if I run netcardconfig on the client tower PC, with the DHCP, DHCP doesn't work.

I'm not clear here where you think the DHCP server is that would supply an IP address when you do this, unless you already have DHCP services running on the laptop. If you had a home DSL/Cable router it would server as a DHCP server and assign you a DHCP address (even if it was not connected to the Internet, and, in fact, even if it never connected to the Internet (although the DHCP setup might make your computer keep trying to get to the Internet through that router, even if you did make a dial-up connection, unless you reset a few things)).

I'm not an expert on hard disk install (nor on many other things), so I'm going to back out and hope others can give you more help than I, but at least I hope I answered some of your first questions.

shah
08-20-2004, 07:57 AM
You didn't mention , are you using knoppix hdd installation on both computer?

If both computer are using knoppix, samba won't work, so did linneighborhood.

If both are using knoppix, I guest you could just share files directly ( I might be wrong. Never done this before.)after running terminal server.
Try right click on the folder to share -->properties and set that folder to be shared. I guest you need to run Lisa daemon to able to browse your shared files.

Correct me if I'm wrong :D

transistordude
08-20-2004, 03:56 PM
It's Knoppix hdinstall on both computers.

The laptop is built with two versions one with one without internal NIC. This is the one without an ethernet jack. When I do lspci -vv and compare with and without the PCMCIA card, I get two and one ethernet ports respectively. Maybe a portion of the internal ethernet is present.

I thought that running Knoppix terminal server will also start a DHCP server too.

What does lisa provide? Do I run it just on the server laptop?

Also, where is the devices icon in Konqueror?

Can I specify something like "/fmobile" to refer to a machine in the Konqueror URL assuming the laptop has the fmobile name?

Thanks a lot guys, you are really helpfull.
Frank

user unknown
08-21-2004, 02:31 AM
hi transistordude.
Ask 3 linuxer, and you get 4 opinions.
Here is mine :)

For two machines, dhcp is overkill.
It needs setup too, and will consume resources.
I use static IPs and it's fine and easy.

To make the servername usable, edit /etc/hosts on both machines, and insert

192.168.1.3 fmobile.transistordude.net fmobile
192.168.1.2 tower.transistordude.net tower

And I don't need a router - just a switch to connect two computers.

Samba:
A lot of people integrate linux into their windows net.
They use samba as a fileserver. Hm.
Why don't they throw away their windows? Don't know.
For a linux-net, there is no need for samba.
Use nfs to share directories.
Start a ftp-server.
Use ssh, sshd, scp and all that jazz.
Unix is a networking system for decades with appropriate solutions for different tasks.

Lisa:
When windows-users join linux, they often ask, why things are so complicated in linux.
Lisa shall solve this problem: Make linux windows-alike.
I don't like lisa.
It's windows-alike.

Btw.: I have a blue x-link cable and 3 grey ones.
For the blue one, I needn't follow the route, to see where it ends.
Having different colors makes it more easy to follow.
Having all x-link-cables yellow, and the normal ones blue helps error-prevention.
And colored cables are much nicer to look at.
:)

CrashedAgain
08-26-2004, 03:33 PM
I really recommend you use fish protocol to connect your computers. It uses secure shell server (ssh) & once set up all you have to do is type 'fish://<username>@192.168.<whatever the ip for the other computer is>'
in konqueror address box & you will be rewarded with the root dir of the other system in the browser. Much easier then samba (usually used only for connecting to windows systems although you can samba linux boxes together) or NFS (generally limited to file sharing from home directory only).

See the "I need help networking my two computers" in this forum post for ssh setup help.

As for connecting the two computers together, I use a router but then I'm on broadband internet.