Networking [SOLVED]: Assigning switch as gateway address

Networking [SOLVED]: Assigning switch as gateway address

Home Forums Networking Networking [SOLVED]: Assigning switch as gateway address

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #35843

    Anonymous

    QuestionQuestion

    I’ve tried researching a solution for this but I keep missing the connecting dots. This is my first question and if I mess up the formatting of my question, forgive me.

    There is a switch that I am trying to connect to 10 other switches and devices connected to those switches. Is it possible to set the address of the main switch as the gateway address of the secondary switches, so that I can have devices communicating to other devices on different subnets?

    Is there a more efficient approach? The devices and secondary switches are on different subnets. The secondary switches are not connected to each other. Only the main switch is connected to the secondary switches.

    #35844

    Anonymous

    Accepted AnswerAnswer

    If you are using layer-2 switches, they are transparent devices, and they do not look at the layer-3 (IP) addresses on the layer-3 packets. They only look at the layer-2 (MAC) addresses on the frames, so they cannot send traffic from one VLAN to a different VLAN.

    A layer-2 switch uses the source address on a frame to populate its MAC address table with the source MAC address and the interface on which it entered the switch. It uses the MAC address table to try to find the destination MAC address interface, and sends the frame to the indicated interface. If it fails to find the destination MAC address in its MAC address table, it floods the frame to all other interfaces.

    You must use a layer-3 device (router or layer-3 switch with routing enabled) to forward packets from one VLAN to another VLAN. The router will strip off the layer-2 frame, exposing the layer-3 packet, inspect the destination layer-3 address, look up the layer-3 address in its routing table, create a new layer-2 frame for the new interface to encapsulate the layer-3 packet to which it forwards the layer-3 packet (new layer-2 frame). If it finds no match in its routing table, it drops the layer-3 packet.

    Hosts will compare the layer-3 destination address to its own layer-3 address and mask to determine if the destination is on the same network. If it is, the host will use ARP to create a layer-2 frame to directly send the frame to the destination host. If the destination layer-3 address is on a different network, it will use ARP to get the layer-2 address of its configured gateway to build the layer-2 frame, and the frame will be delivered directly to its configured gateway. The layer-2 switches will switch the layer-2 frames using the layer-2 address.

    Source: https://serverfault.com/questions/887546/assigning-switch-as-gateway-address
    Author: Ron Maupin
    Creative Commons License
    This work is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License.

Viewing 2 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic.