Linux - NetworkingThis forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.
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.
I've got a DLink ADSL Modem. The modem wants to have the 192.168.0.1 address and lends dynamically an ip to the computer, the external ip (it lends the same ip if it's not connected to the internet). And this is my first network. Then i have to set up another one: the pc with the modem has to share the connection to another computer. I read that i can't have the same ip classes (like 192.168.0.3 and 192.168.0.4) for the other network.
Now let's say that PC1 has two network cards, eth0 connected to the modem and with a dynamic ip, and eth1 connected to PC2 using a static ip. PC2 will have just eth0 connected to PC1 with a static ip. I've already configured the internet connection for PC1, i just need help sharing it with PC2. That would be merging two networks right? How do i do that?
Why dont you put a hub facing your private network side on your dlink ... with 4 ports you could attach 3 pc's... direcly to the hub ... no need to leave the pc1 on for pc2 to acces the net ...
Yes you could do it.. You would need two ethernet cards in PC1, and a cross-over ethernet cable to connect it to PC2. However getting a hub or switch would be a much better solution.
i've already got two eth cards on PC1, you don't need to be a guru to figure out i needed two eth cards... i mean, where would i plug the 2nd cable? (no jokes about this one )
The os is linux of course
I already have all the hardware i need and it's properly configured on each PC. The configuration of PC2 should be simple as
ifconfig eth0 some-ip up
route add default gw PC1-eth1-ip
with some-ip and PC1-eth1-ip being two static ips i have yet to decide (not very difficult, but they must be on a ip class than 192.168.0.x right?)
but the configuration of PC1 requires some skills i do not have.
an ethernet card costs 5 €, the cheapest hub i found online is 30€.
And since it CAN be done without a hub i'd like to do that without a hub.
Windows can do that without a hub, so i'd expect linux could do that even without the eth cable
Are you talking to connect PC2 with Internet or to connect PC1 to PC2 and vice?
In the 2nd case you need to install nfs to see one to another
If the 2 r linux box u need client and server nfs
nfs? i tought nfs was used to share files... i plan to share files too, but i'm not going that far yet
anyway, PC1 is connect to a modem and to PC2 with two different eth cards, while PC2 is connected to PC1 and should "leech" the connection from PC1 (i don't need NAT, firewalling or something like that, just be able to browse web pages from PC2)
ok now the modem-PC1 net is 192.168.0.x and the PC1-PC2 net is 192.168.1.x
they actually see each other and i can ping the modem from the pc2. Still i can't browse web pages (not even providing an ip, so it's not dns fault), what does "make nic 1 and nic 2 on pc 1 as a proxy ..." mean?
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.