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.
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.
I have two routers, 3com and dlink 624. The purpose to have two routers which is there are two broadband connections in our office. So, there are two network segments which are 192.168.0.1 and 192.168.1.1.
When I am in 192.168.0.1 network, I couldn't use the share printer which is connecting to 192.168.1.1 network.
Can you recommend the method to hook up this two network?
You have to add a gateway connecting both the networks... It may be a dedicated router or a PC running linux for instance... Your default gateways on each network must also be configured to forward packets, destined to the other local net, to that new gateway...
You might wanna build up tunneling, e.g. VPN(with bridging) in order to make those shared printers appear in the same logical segment. But i'm sure those routers won't support bridging with their ipsec capabilities. The other way around is to use a WINS server which would hold the NETBIOS machine/share list on both those networks and route them between of course. I wouldn't write iptables/route/ip cause i'm damn lazy. You should've gotten the idea.
...Yes, it could be a PC running any flavor of Linux or a dedicated router...
In the case of a Linux PC it would have two ethernet nics and ip forwarding turned on.
i think that there should be no problem as a friend of mine had two routers on his lan and he had a printer shared and everything worked well i dont know whats your problem
You have two distinct subnets, and you want packets to travel from one to the other and vice-versa. It's called routing and I don't think it can become any easier than that... :P
I suspect he either had a switch and a router, or had one router just acting like a switch(referring to post #8). Sometimes you can pick up a used router cheaper than a switch. We had four routers in use at one point (3 as switches and one actually as a router).
I solved it in a quick way. As I turn off the second router DHCP, and I used just one subnet. So, if I want to use the second network, I just specify the fix IP with the second gateway IP address. So, if the client PC in DHCP, it will go to the first network.
However, I still feel interesting to find out to connect to different subnet.
Here are two suggestions. A) "ifconfig" will change the subnet. Possibly tiresome. B) Use two separate Distros and boot into the option from Boot Menu in Boot Loader.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.