Linux - NetworkingThis forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.
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.
Introduction to Linux - A Hands on Guide
This guide was created as an overview of the Linux Operating System, geared toward new users as an exploration tour and getting started guide, with exercises at the end of each chapter.
For more advanced trainees it can be a desktop reference, and a collection of the base knowledge needed to proceed with system and network administration. This book contains many real life examples derived from the author's experience as a Linux system and network administrator, trainer and consultant. They hope these examples will help you to get a better understanding of the Linux system and that you feel encouraged to try out things on your own.
Click Here to receive this Complete Guide absolutely free.
I have to develop a project for the university. It has to do with complex routing.
I have one linux box with one Ethernet interface, a Layer 2 switch with 801.1q (VLAN) support and four routers. Each router has four Ethernet ports. The Linux box and the routers are connected to the switch.
Is it possible to route traffic from the linux box interface to a specific router interface and vice-versa only by configuring the linux box and the switch? What is the best way to achieve this purpose?
I thought about using VLANs (one for each router interface) but I have some doubts...
Ok, so, correct me if I'm wrong, I enable different aliases on the interface and then I configure the switch to route the traffic based on the source IP address (in case of packets coming from the linux box) or the port (in case of packets coming from one of the routers' interfaces).
Switches do not perform routing as they operate at layer 2 (apart from layer3 switches) in your case the linux box will be able to get to all the routers as it will have an ip address in all of the router ranges.
The routers are the question mark: the project is somewhat generic about the router specs. The whitepaper only says it has an integrated 4-port switch (not VLAN-aware) and a WAN Ethernet port. All four ports are connected to the main switch (VLAN-aware).
I was thinking about pros and cons of the two approaches and the subtle questions I may be facing during the exam... something like this: "suppose all four routers are of the same subnet: how can I route packets?"
I guess the best way is to create sixteen VLANs, one for each router interface (4 routers, 4 ports each). Both the linux box and the main switch are VLAN-aware so I can send traffic over the unique interface I have available on the linux box. I should statically bind sixteen ports on the switch to the router interfaces so that each router interface gets bounded to a specific VLAN. Packets routing between VLANs should be managed on the routers' switches. Unfortunately this way I can route traffic only for groups of four interfaces...