Community discussions

MikroTik App
 
mguzy
just joined
Topic Author
Posts: 7
Joined: Fri Jan 24, 2025 3:50 pm

Setting crs304-4xg-in as layer 2 switch

Fri Jan 24, 2025 4:10 pm

I recently bought crs304-4xg-in as I upgraded my internet connection to 8Gbs and needed to replace my 1Gbe switch. I actually wanted unmanaged switch as I have no experience in networking but assumed that I can easily make it a 'dumb switch' (and got great price for the switch ;) )
As I understand it should work as such out-of-the box but it doesn't for me.
I also tried:
1. System > Reset Configuration
- No Default Configuration
- Do Not Backup
2.
[admin@MikroTik] > /interface bridge add name=bridge1
[admin@MikroTik] > /interface bridge port add bridge=bridge1 interface=ether2
[admin@MikroTik] > /interface bridge port add bridge=bridge1 interface=ether1
[admin@MikroTik] > /interface bridge port add bridge=bridge1 interface=ether3
[admin@MikroTik] > /interface bridge port add bridge=bridge1 interface=ether4
[admin@MikroTik] > /interface bridge port add bridge=bridge1 interface=ether5

Am I missing something?
current firmware: 7.15.3
Image
 
jaclaz
Forum Guru
Forum Guru
Posts: 2350
Joined: Tue Oct 03, 2023 4:21 pm

Re: Setting crs304-4xg-in as layer 2 switch

Fri Jan 24, 2025 7:15 pm

Your crs304-4xg-in is defective :shock: it has two ether4 ports :wink: :lol:

Now, seriously, how are you managing the Mikrotik? (I presume with Winbox via MAC).

A good idea is (unless you really-really need it) is to keep a port outside the bridge, for emergency access (it is not a problem in a "dumb" bridge but when/if you will want to make it more secure or play with some advanced feature it is easy to lock oneself out).
As a matter of fact if you look at the device layout:
https://cdn.mikrotik.com/web-assets/pro ... 240945.png
you will see that ether5 is designed to be not part of a bridge.

I would take port 5 out of the bridge, a 1 Gb port in a bridge with 4 10 Gb bridge may slow down everything (or worse), even if not used/not connected to anything.

Describe what/how it doesn't work.
 
mguzy
just joined
Topic Author
Posts: 7
Joined: Fri Jan 24, 2025 3:50 pm

Re: Setting crs304-4xg-in as layer 2 switch

Fri Jan 24, 2025 7:45 pm

I thought I will need to return it :D
And thanks for the reply!

Yes, Winbox via MAC.

Make sense to keep it out of the bridge, looking how it is internally wired :)

1. I reseted the configuration (no default).
2. I've run
[admin@MikroTik] > /interface bridge add name=bridge1
[admin@MikroTik] > /interface bridge port add bridge=bridge1 interface=ether1
[admin@MikroTik] > /interface bridge port add bridge=bridge1 interface=ether2
[admin@MikroTik] > /interface bridge port add bridge=bridge1 interface=ether3
[admin@MikroTik] > /interface bridge port add bridge=bridge1 interface=ether4

as a result I have
Image
Image

after such setup and router connected to ether 1 and pc to ether 4, my problem is best described by I don't have access to internet on PC.
Also
Image
Any ideas how can I debug/investigate?
 
jaclaz
Forum Guru
Forum Guru
Posts: 2350
Joined: Tue Oct 03, 2023 4:21 pm

Re: Setting crs304-4xg-in as layer 2 switch

Fri Jan 24, 2025 8:29 pm

Well, the "dumb" bridge should have an IP (L3) assigned to be able to ping a destination.
A "dumb" bridge is L2 and knows nothing of L3, while not becoming "smart"; it will become a "disadvantaged" switch if you give it a L3 address.

Once an address is assigned to the interface, a dynamic route for the whole subnet (192.168.1.0/24) will be automatically added to the "main" route table.

You could add a dhcp client to the bridge.
/ip dhcp-client
add interface=bridge
But from the PC, can you ping 192.168.1.1?
 
mguzy
just joined
Topic Author
Posts: 7
Joined: Fri Jan 24, 2025 3:50 pm

Re: Setting crs304-4xg-in as layer 2 switch

Fri Jan 24, 2025 8:51 pm

As I understand adding DHCP client should allow my DHCP server (router/modem) to assign IP address to the switch (Do I understand that correctly?)

I've run the commands you've posted (except bridge1 instead of bridge as it is the name of the interface) and result is the same unfortunately :(

Image
Image

There are also this quick set where address acquisition is set to automatic
Image

But in IP > Addresses I see nothing (maybe it is ok when it is automatic (?)
Image
 
jaclaz
Forum Guru
Forum Guru
Posts: 2350
Joined: Tue Oct 03, 2023 4:21 pm

Re: Setting crs304-4xg-in as layer 2 switch

Fri Jan 24, 2025 9:09 pm

The status of "searching" means that the DHCP server is not found. Otherwise it would be "bound", and you would see the assigned IP.
Better leave quick set alone.
You can add manually an IP address to the bridge to see if pinging to 192.168.1.1 works, let's say 192.168.1.9/24.
But do check that the DHCP server works.
 
mguzy
just joined
Topic Author
Posts: 7
Joined: Fri Jan 24, 2025 3:50 pm

Re: Setting crs304-4xg-in as layer 2 switch

Sat Jan 25, 2025 2:00 pm

I tried with statically assigned IP and it didn't work as well.

But I found the issue...
It was the cable. I did a sanity check and move with laptop and switch closer to router and connect new short cables and it worked like a charm :)
I still don't know why my old TP-LINK had no issues with old cable, but Mikrotik did, hmm.
But I have one to replace it ;)

Thanks for the support!
I did learn few things in the process!
 
User avatar
mkx
Forum Guru
Forum Guru
Posts: 13311
Joined: Thu Mar 03, 2016 10:23 pm

Re: Setting crs304-4xg-in as layer 2 switch

Sat Jan 25, 2025 2:13 pm

Your previous switch was 1Gbps (if I understand your opening post right) and your CRS304 is 10Gbps. Which is a huge difference when it comes to UTP cable. Even though you're using a cat7 cable (indicated on your chart), it might be of low quality, it might be improperly terminated, it might be (slightly) damaged (e.g. too tight curves). And if the cable is longer than around half of declared max length (which is 100m/328ft), anything not ideal can affect ability to operate connection at desired speed. Requirements regarding UTP cable for 10Gbps are much higher than for 1Gbps and minor problems might not break 1Gbps connection.
 
jaclaz
Forum Guru
Forum Guru
Posts: 2350
Joined: Tue Oct 03, 2023 4:21 pm

Re: Setting crs304-4xg-in as layer 2 switch

Sat Jan 25, 2025 2:48 pm

Still, if the ports are set to 10 Gb it should show "no link" (and not "running" status), this kind of "almost connected" (interface running, but not a real communication on it) seems like a tricky issue.
In the (good?) ol' times there was a monthly column on Byte by Jerry Pournelle that had (at the time bordering science fiction) a lot of fast SCSI devices and the moral in every other article was "when something doesn't work in SCSI it is often always the cable".
Anyway, all is well that ends well :) .
 
User avatar
anav
Forum Guru
Forum Guru
Posts: 22453
Joined: Sun Feb 18, 2018 11:28 pm
Location: Nova Scotia, Canada
Contact:

Re: Setting crs304-4xg-in as layer 2 switch  [SOLVED]

Sat Jan 25, 2025 3:05 pm

/interface bridge
add ingress-filtering=no name=bridge 
/interface ethernet
set [ find default-name=ether5 ] name=OffBridge5
/interface list
add name=MAIN
/interface bridge port
add bridge=bridge interface=ether1
add bridge=bridge interface=ether2
add bridge=bridge interface=ether3
add bridge=bridge interface=ether4
/ip neighbor discovery-settings
set discover-interface-list=MAIN
/interface list member
add interface=bridge list=MAIN
add interface=OffBridge5 list=MAIN
/ip address
add address=192.168.1.99/24 interface=bridge network=192.168.1.0  
add address=192.168.55.1/30 interface=OffBridge5 network=192.168.55.0
/ip dns
set servers=192.168.1.1
/ip route
add disabled=no dst-address=0.0.0.0/0 gateway=192.168.1.1 routing-table=main 
/tool mac-server
set allowed-interface-list=none
/tool mac-server mac-winbox
set allowed-interface-list=MAIN
 
mguzy
just joined
Topic Author
Posts: 7
Joined: Fri Jan 24, 2025 3:50 pm

Re: Setting crs304-4xg-in as layer 2 switch

Sat Jan 25, 2025 8:21 pm

Just to provide full picture.
I might have lied with my diagram, but now it is new and fresh cat 7 cable 😂
The one that was installed was
cat. 6e 28AMG Network Flat Patch Cord CABLE ROHS MADE IN CHINA (30 meters) and it was indeed a bit damaged in one place.
 
jaclaz
Forum Guru
Forum Guru
Posts: 2350
Joined: Tue Oct 03, 2023 4:21 pm

Re: Setting crs304-4xg-in as layer 2 switch

Sun Jan 26, 2025 2:36 am

Even if not damaged "flat", "cat6a" and "30 meters" rarely can work at 10 Gb, personally I wouldn't use the 28 AWG ones for more than 15-20 meters, maybe the 26 AWG for 30 m, but 23 or 24 are the "normal" ones, good for 100 m.
If I recall correctly good manufacturers give max 60 or 65 m for those and the rule of thumb to be on the safe side Is to not exceed half of the theoretical max.
Still in theory a damaged (but not interrupted) cable should have the devices negotiate a slower connection rate or have a high error rate, but preventing a DHCP lease it is AFAIK unusual.
Maybe the cable was actually damaged with one wire among 4,5,7,8 interrupted i.e. in a way that your previous 1 GB hardware down negotiated to 100 Mb whilst your current 10 Gb hardware cannot negotiate lower than 1 GB (i.e. all 8 wires are needed).
But then It should cause "no link". :-?
Last edited by jaclaz on Sun Jan 26, 2025 7:06 pm, edited 1 time in total.
 
User avatar
anav
Forum Guru
Forum Guru
Posts: 22453
Joined: Sun Feb 18, 2018 11:28 pm
Location: Nova Scotia, Canada
Contact:

Re: Setting crs304-4xg-in as layer 2 switch

Sun Jan 26, 2025 3:10 am

Seems like 6,6a,7 are perfectly fine for 10gbps connections.
.......
Screenshot 2025-01-25 210955.jpg
You do not have the required permissions to view the files attached to this post.
 
 
User avatar
anav
Forum Guru
Forum Guru
Posts: 22453
Joined: Sun Feb 18, 2018 11:28 pm
Location: Nova Scotia, Canada
Contact:

Re: Setting crs304-4xg-in as layer 2 switch

Sun Jan 26, 2025 4:40 am

Good to know!!
 
jaclaz
Forum Guru
Forum Guru
Posts: 2350
Joined: Tue Oct 03, 2023 4:21 pm

Re: Setting crs304-4xg-in as layer 2 switch

Sun Jan 26, 2025 4:03 pm

Yep, besides there are two kinds of "flat" cables, let's call them "semi-flat" and "super-flat".

The "semi-flat" have anyway twisted pairs, but the "super-flat" may lack the twisting of pairs (hopefully only very short patch cables are made with this)

Twisting pairs, at different twist rates, is actually a very smart way to reduce crosstalk between pairs, still Cat 6+ round cables have anyway a cross-shaped insulator between the pairs (good) and the outer insulation is way thicker than what the flat cables have.

Even the newish "small round" (slim) cables (outer diameter 3/4 mm instead of 6/7)
https://www.fs.com/blog/slim-vs-regular ... -4746.html
have this cross shaped separator, but they are as well advised for (short) patch cables or anyway for runs of 50 feet/15 mt:
https://infinity-cable-products.com/col ... unshielded

Then, there are two schools of thoughts among electrical engineers:
1) a wire is a wire, no matter if it is solid core or stranded
2) a wire is a wire, BUT I use ONLY solid core over long distances and stranded ONLY for very short distance

JFYI:
https://www.flukenetworks.com/blog/cabl ... olid-cable

Finally, notwithstanding what manufacturers may say, it is better to avoid using flat cables for PoE:
https://app-community.fs.com/blog/will- ... d-how.html
 
mguzy
just joined
Topic Author
Posts: 7
Joined: Fri Jan 24, 2025 3:50 pm

Re: Setting crs304-4xg-in as layer 2 switch

Sun Jan 26, 2025 9:18 pm

Flat cables also have the benefit of your wife not asking, 'Why can't you just use Wi-Fi like a normal person?' :D As they can be hidden nicely, which was the whole reason with 'going flat'

Image
 
jaclaz
Forum Guru
Forum Guru
Posts: 2350
Joined: Tue Oct 03, 2023 4:21 pm

Re: Setting crs304-4xg-in as layer 2 switch

Sun Jan 26, 2025 10:43 pm

I think it depends on the exact model/version/release :shock: of wife, I don't believe most would consider a black cable on a whitish wall as "hiding", let alone "nicely". :lol:
 
mguzy
just joined
Topic Author
Posts: 7
Joined: Fri Jan 24, 2025 3:50 pm

Re: Setting crs304-4xg-in as layer 2 switch

Sun Jan 26, 2025 10:57 pm

Oh, that is the frame of the picture on the wall. Cable is white and running along door frame ;)
 
jaclaz
Forum Guru
Forum Guru
Posts: 2350
Joined: Tue Oct 03, 2023 4:21 pm

Re: Setting crs304-4xg-in as layer 2 switch

Sun Jan 26, 2025 11:07 pm

Oh, that is the frame of the picture on the wall. Cable is white and running along door frame ;)
Then, mission accomplished :) .