What is the necessary hardware to connect two computers in a LAN configuration?
Linux - HardwareThis forum is for Hardware issues.
Having trouble installing a piece of hardware? Want to know if that peripheral is compatible with Linux?
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
What is the necessary hardware to connect two computers in a LAN configuration?
Hi: The scenario:
(a) No knowledge whatsoever about LAN.
(b) Two desktops at home, one of them connected to the internet by only using a cable modem.
(c) The other one stands alone, up to now.
(d) Each machine has only one LAN chip.
I aim at:
(d) Having communications between both computers.
(e) At least one computer must have internet.
Some questions: What is the minimum hardware I need to make the connection? Do I need a router? And the cables? Are they commercially available?
OK. I see in the internet that from each computer a cable goes to the hub or switch. I guess from the hub a cable goes to the cable modem. But then these are three cables. I'm afraid I did not get you.
You may have to get an additional network card for the computer that is already connected to network so as to use crossover cable. Or you can get another router with atleast 2 ports.
A switch is normally used on an internal network. You could connect both computers and a modem via a switch, but you would have to setup internet access on both desktops. A typical NAT setup is to use a router, connect the modem to its WAN port and the desktop computers to its LAN ports. The computers are configured with DHCP, and the router connects to the internet.
Most modern cable modems act already as router, not as modem. You can easily check that with checking how your machine gets the network interface set up. If the network interface is using DHCP to get its settings the modem acts as router. In that case you need nothing but a switch (hubs are outdated and should not be used) and three cables (Cat5-E). All of these are commercially available.
A switch is normally used on an internal network. You could connect both computers and a modem via a switch, but you would have to setup internet access on both desktops. A typical NAT setup is to use a router, connect the modem to its WAN port and the desktop computers to its LAN ports. The computers are configured with DHCP, and the router connects to the internet.
So the connection via a switch and the connection via router are two different approaches, or is the router scenario a particular case of the switch connection?
So the connection via a switch and the connection via router are two different approaches, or is the router scenario a particular case of the switch connection?
You can see the router as a device that connects different networks, for example the Internet and your local network, while a switch is used to extent an existing network. If your cable modem acts as router you already have a separate home netwrok and just need to extend it with a switch.
Most modern cable modems act already as router, not as modem. You can easily check that with checking how your machine gets the network interface set up. If the network interface is using DHCP to get its settings the modem acts as router. In that case you need nothing but a switch (hubs are outdated and should not be used) and three cables (Cat5-E). All of these are commercially available.
Alright. Then:
Street cable goes to MODEM which goes to SWITCH which goes to both computers A and B. Cat5-E is needed for all connections except street to modem, which is a coaxial cable provided by the company.
This, provided I use DHCP, and I have done so up to the present. I can get the Cat5-E cables and, about the switch: they offer me for 10/100Mbits/s. My ISP is presently giving me 1Mbit/s. Does this mean that switch is 100 times faster than I need?
Depends on your ISP but typically in the US basic home cable setup only provides one DHCP IP address. If this is true and your MODEM is not also a router then a switch will not work.
A physical inspection of the modem reveals it has one I/O connector for the coaxial cable, and two I/O connectors, one labeled USB, the other, Ethernet. I guess this is not enough to know if it is also a router.
I certainly have the model. It's a Motorola Surfboard SB5101i. If I look in google or go to the motorola.com site, what should I look for to know it is also a router?
Distribution: Ubuntu 11.4,DD-WRT micro plus ssh,lfs-6.6,Fedora 15,Fedora 16
Posts: 3,233
Rep:
it depends, if your modem has only one ethernet plug on the back (which is the likely situation), then you need a router
typical home routers (I would recommend a Linksys router) have a built in 4 port switch
(actually it's a 5 port switch, but to all intents and purposes it's a 4 since port 5 is separated by the router's firmware used as the WAN port, but that's neither here nor there)
thus your network diagram would look something like this
If either end is GigE then the above statement is not true. GigE will automatically handle doing this without using a crossover cable.
however passing internet packets between the 2 pc's will require the op to know about iptables rules: http://www.linuxquestions.org/questi...6/#post3804866
(probably easier for them to buy an off-the-shelf router for like 40 bucks).
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.