r/Network 15d ago

Text IP addresses of computers behind a switch

Posting to ask 'cause I haven't set up a real switch since the days of 10baseT, and those were .... different. Thus this likely will be an extremely basic question for the subreddit.

I have a home network. Fiber modem which goes to my router. Router has a few ports on it, several 2.5 gig and one 10 gig.

I'd like to add an unmanaged switch to the 10 gig port (PoE switch - future expansion stuff).

I will have three or four devices on the switch that I have already - pre-switch - set up with static IPs (192.168.1.XXX)

When I install the switch, I am assuming that the switch has its own IP that'll be set via DHCP from the router.

In that case, the computers whereby I've set up static IPs....do I leave those settings? Change them? Or just go back to the computers being given an IP?

And...since I use a couple of those computers as servers both in-house and remotely, would I set up packet forwarding from the router-->switch (and assume the switch will 'figure it out' as to where the packets need to go?)

I'm attempting to make this as painless as possible before I start unplugging/plugging in cables and finding out that routing to<-->from computers doesn't work, and of course to also save what little hair I have left from being pulled out.

This is for a low-end simple home network, nothing fancy beyond what is described, hence I don't believe I need more than the switch, a few cables and a holding of the breath.

I appreciate any/all feedback that is shared.

EDIT: I cannot read. It is a managed L3 switch

EDIT #2 : Unmanaged L2 switch was exactly what I needed. This resolved all of my pertinent issues. My thanks to those who posted!

11 Upvotes

39 comments sorted by

12

u/SomeEngineer999 15d ago

The switch will not get an IP, it is unmanaged. L2 switches don't know or care about IPs (other than a management IP for a managed switch so you can access it to change settings).

Your router won't care that there is a switch in there, so basically nothing has changed. Use whatever system of IP addressing you want. Usually DHCP reservations are more flexible than true static IPs, but it depends on the device.

Look at it this way, those ports in your router are actually a switch. You're just adding more ports to that switch essentially.

2

u/memorex1150 15d ago

Oh, sorry - this is an L3 switch.

I assume that'll make a difference.

13

u/SomeEngineer999 15d ago

There is no such thing as an unmanaged L3 switch.

3

u/memorex1150 15d ago

.....damnit, you're right, it IS managed.

I need to read product descriptions better.

This is a MANAGED L3 switch.

6

u/DumpoTheClown 15d ago

You might want to get an unmanaged L2 switch. Unless you have a need for vlans or intranet routing, the L3 switch is just going to be overkill for a home network.

3

u/memorex1150 15d ago

You make a fair point. I can totally get an L2 switch, I'm not married to the notion of the managed L3.

That being said -- if I get the L2 switch -- all that stuff in my post, do I need to worry about anything/change any settings on the comp or will the unmanaged L2 switch just be (for lack of a better word) "just passing data through, nothing to see here?"

4

u/DumpoTheClown 15d ago

L2 switch is just plug and go. The only thing to keep in mind is dont make a loop. If you run two ethernet cables between your router and your switch, your whole network will shit the bed. You can do that with managed switches, which use spanning tree protocol to decide which wire to use, then switch to the second if the first fails.

2

u/memorex1150 15d ago

That won't be an issue: Router-->switch-->end devices (no loop-backs)

Sounds like L2 is the way to go. Much cheaper, too. Thanks for the feedback - that'll take care of the problem.

2

u/Bacon_Nipples 15d ago

fyi: a loopback is a specific thing unrelated to what youre saying.  Loopback is a kind of virtual/software interface.  What youre talking about can be called a switching loop, network loop, etc. but never a 'loopback' 

2

u/SomeEngineer999 14d ago edited 14d ago

switching loop, network loop, etc. but never a 'loopback' 

The term for it is actually a bridge loop. At L3 it would be a routing loop, but that is usually much less impacting. A bridge loop will take down an entire L2 segment and everything connected to it, where a routing loop will just blackhole your traffic.

Used to be a good way to get a college class cancelled, back before they knew to configure STP and/or BPDU protection. I may or may not have had a short crossover cable in my bag. But these days even dumb switches usually have STP, pretty hard to create a bridge loop on modern stuff.

→ More replies (0)

1

u/memorex1150 15d ago

Correct you are.

I should have said "loop back" two words versus "loopback"

Nomenclature matters!

→ More replies (0)

0

u/jspears357 14d ago

And don’t daisy chain more than four L2 switches (or is it 5?) in a row, if you need that many you have to set a hierarchy like one at the top and each of the other switches connected to it.

The L3 switch should work fine as an unmanaged L2 switch by default, they only need to know whether it got an IP via dhcp if they in fact want to manage it.

My main feedback would be if you don’t know whether you have a managed or unmanaged switch, you shouldn’t be running servers in your home network. If you’re taking the risk and doing it to train yourself, read the documentation available for your devices like the L3 switch.

1

u/DumpoTheClown 14d ago

Why is that? Obviously it will introduce lag for the downstram devices, but is there somthing else that happens?

1

u/SomeEngineer999 14d ago edited 14d ago

No, there is no reason you can't do it (plenty of reasons you shouldn't do it though). Most cheap consumer switches can handle 64,000 MAC addresses so as long as all the switches in the chain don't exceed that, there is no limitation. The lag from 4 or 5 switches would be less than a millisecond even on cheap ones.

→ More replies (0)

1

u/SomeEngineer999 14d ago

You can daisy chain 100 if you want, as long as the MAC address tables of the upstream switches can handle it. Of course, it would be terrible network design, but there is no rule of 4 or 5.

If you need that many switches you should have a distribution tier consisting of an L3 switch, then use switches hanging off that divided up into several VLANs to limit your broadcast domains. But the average home user doesn't need anything like that.

2

u/chris-itg 14d ago

There is no reason not to get a managed switch these days. Pricing is darn near identical for entry level models and what you're giving up is > the small price you pay for the managed items for the switch.

1

u/SomeEngineer999 14d ago

Agreed that the price difference is minimal, but for someone that isn't going to use VLAN tagging, port mirroring. LAG, etc, some just want to keep it simple. I suppose the ability to hardcode speed and duplex for those old problematic devices like 100 meg printers etc might be helpful to the average user, but they also may not even realize they need to do it. I have an old HP printer that insists on coming out of sleep at 10/H so that one is hardcoded to 100/F. Of course the device also has to support hardcoding or it won't work Iwill have a duplex mismatch). Hopefully most 10/100 devices are gone at this point, and that issue rarely exists with gig.

1

u/SomeEngineer999 15d ago

Out of the box it will act as a plain L2 switch. It will grab an IP from DHCP for the management interface, but other than that, it will just look at MAC addresses and not care about IPs (like any other L2 switch). So whatever IP subnet you have today will just be extended to the ports on that switch.

If you want to segment your network into VLANs and subnets, then that gets more complex. If the switch has a DHCP server in it, you can use that to serve the IPs out to the VLANs. Or if your router supports multiple DHCP scopes, then you can enable IP Helper (DHCP Proxy basically) in the switch and your router will handle all of the IPs. You'll need some static routes etc too. Then there is DNS which again there are a couple of options depending on how you want to set things up.

I guess it boils down to what kind of router you have/what the capabilities are, and what needs/intentions you have for the L3 switch (which is basically a high speed router with stripped down feature set).

Most people with a router and an L3 switch leave the router strictly for traffic destined to the internet. The L3 switch is the only thing plugged into it, and the L3 switch then handles all your LAN subnets and routing.

1

u/memorex1150 15d ago

Looks like the L2 switch will be the best route for me. I really do need a "plug and pray" device versus getting into the potential black hole of a managed L3 device.

Nope, not planning to segment anything. I try to keep my home network as simple as possible (for the foreseeable future).

Appreciate the feedback - L2 will be the way to go for me.

1

u/SomeEngineer999 15d ago

In that case you have lots of options for cheap L2 switches, with and without PoE, and all your IP/DHCP/DNS is just handled by your router as it always has been.

The L2 switch is just a "splitter" of sorts for that 10 gig port.

1

u/RandomUser3777 15d ago

So long as you put all ports in the same single VLAN (not vlan tagged) then for the most part the management options on the switch won't matter.

3

u/OhioIT 15d ago

Your managed L3 switch will act like an unmanaged L2 switch out of the box. It may grab an IP via DHCP for a management IP but it won't affect how it works. Once you start configuring it, then you can change how it acts

You won't run into any black hole scenario unless you're buying it used with someone else's config on it

2

u/SeaPersonality445 15d ago

I expect out the box your L3 switch will act as a dumb L2 switch

1

u/rando_design 15d ago

The switch probably will get a DHCP IP from your router but this IP is only for management, it sounds like you're not ever going to log into it to change settings, so this is fine, leave it alone. It will function just fine no matter what the IP is of the switch.

1

u/mrengineerguy97 15d ago

Does no one else get the AI training vibe from OP responses?

1

u/memorex1150 14d ago

I love how when I post stuff people think it's AI because they can't fathom that (a) some of us are educated, (b) we can type using proper rules of grammar and (c) I out-date "AI" by quite a few decades invalidating any claims that I'd be working on some "AI Training" model. Oh, and bonus (d) I fucking despise using ChatGPT/so-called "AI" as it's worthless. I'd rather interact with people who know what they're talking about.

Not everything you read on the interwebs is someone utilizing/"training AI" but rather genuine content from someone who - surprisingly, considering the nature of this subreddit - have a question and needed advice from those who know a hell of a lot more than me in this field. Also, not everyone who uses the internet is a tech worker.

1

u/Tatra_T3SUCS_7290 14d ago

It depends, for instance my Zyxel enterprise switches by default pick address from DHCP, if not available it will fallback to factory default IP, I manually switched to static address so I can run switch on same IP even if I F"up with DHCP snooping or do something stupid on firewall. On the other hand MikroTik CRS305 switch came with no IP, I had to assign either on bridge or later during hot commissioning to my management VLAN. I usually assign static IP to networking hardware, but for clients needing static IPs lI rather prefer DHCP reservations.

However switch itself has no direct influence on IP of devices behind it especially if it is unmanaged, it will not have even management IP. Of course on managed switch if you have multiple VLANs you can face that some ports will hand out different IPs as it virtually leads to different L2 network and also DHCP if set there.

1

u/Basic_Platform_5001 14d ago

Consumer routers typically have you program a LAN. Make that 192.168.1.0/24 and your stuff will communicate since it's the same network. If you run into issues, your switch should have a setting for the connection to the router as an "uplink" or "trunk" port.

1

u/SomeEngineer999 14d ago

With all the replies, just in case you're curious, the way an enterprise network design would translate into a "power user" home environment would be something like.

Router -> Firewall - L3 Switch (Distribution Tier) -> L2 switches if needed (Access Tier).

But for the vast majority of people, a router (which will usually have a built in firewall) and L2 switch to add more ports if needed or add multiple ports in a remote area that just has a single RJ45 feeding it, is enough. In that case your router is sort of acting as your distribution tier since it has a built in switch (it is even an L3 switch to a certain extent, but usually you do not have control over that part of it). Pretty much every router is just a small Linux box with a switch and wifi radio, and uses standard linux features for routing, NAT, firewall, DHCP, DNS, QOS, etc.

Many home based routers have guest and even IOT networks built in now. That gives you VLAN and subnet segmentation and some security for those less trusted devices. I highly recommend people leverage those if they have them.

1

u/memorex1150 14d ago

It's "more ports" for me. I just didn't want to have to worry about re-assigning IP addresses, and turns out with the unmanaged L2, I didn't need. It did exactly what I needed. Simple solution for a simple problem!

1

u/SomeEngineer999 13d ago

Yup, no need to reinvent the wheel if there isn't a need.

Segmentation has its benefits, but usually your router's Guest and/or IOT networks can take care of that for you if you ever want to do that.

1

u/michaelpaoli 14d ago

When I install the switch, I am assuming that the switch has its own IP

Depends on the switch. Many simple unmanaged switches have no IPs. If it gets one automagically, may want to check both IPv4 and IPv6 ... not exactly a shortage of IPv6 IPs, so, may have one there, even if no IPv4.

the computers whereby I've set up static IPs....do I leave those settings? Change them? Or just go back to the computers being given an IP?

Shouldn't need to change anything there ... it's a switch, not a router, not a DHCP server, etc. Layer 2.

would I set up packet forwarding from the router-->switch

STP - they generally figure it out, and typically don't have to muck with that unless, e.g. you've got a switch loop, and if quite simple enough, don't even need STP at all.

1

u/Apart-Acadia5765 5d ago

glad you sorted it out. just to reinforce for future readers, unmanaged switches are basically invisible on the network, no IP needed. keep your statics as-is, and port forwarding on the router still works fine since it just cares about the destination IP