Can You Purchase Switch Hardware Without an OS?
dhahn asks: "I have a project where I'm building a large Linux router (about 40 ports or so). At this point, my only hardware solution is to purchase a box with lots of PCI-ish slots and fill them multi-port ethernet cards. I've looked into currently available solutions and haven't found anything that gives me the control I want. Does anyone know of where I could purchase a 'naked switch?' I just want the switch hardware with enough guts to allow me to customize a Linux OS and load it up." If anyone else has been in this situation, what did you do?
Why not use any managable switch, configure each port into its own vlan, hook up the Linux box to a trunk port and use Linux's vlan support, like anyone else does?
if you would like i can buy a switch and flash it with nothing and sell it to you.. but money frist and no returns.
'...if only "Jumping to a Conclusion" was an event in the Olympics.'
I'm not sure if I'm familiar with the 'ish' variant of the PCI slot. Could you please elaborate?
This guy's the limit!
Limitations:
p lane/backplane.HTM
- PCI bus bandwidth is going to hurt you hard. 32-bit PCI @ 33Mhz = 127Mbyte/sec. 64-bit PCI-X @ 66Mhz = 508Mbyte/sec.
- 100Mbit ethernet = ~10Mbyte/sec (assume 10b8 encoding, easier numbers).
- 127Mbyte/sec / ~10Mbyte/sec = 12 100Mbit ports only.
If you aren't deterred by this:
1. Get a motherboard.
2. Get a decent PCI backplane. A quick Google search brings this company:
http://www.commell.com.tw/Product/Peripheral/Back
and they have a backplane with 17 PCI slots.
3. Buy 4-port PCI 100mbit network cards (http://www.americanpredator.com they don't list it on their site, but I'm certain they do custom quad port cards, or can point you to somebody that can, $500/card for industrial grade hardware).
4. 17*4 = 68x 100Mbit ethernet ports.
ICQ# : 30269588
"I used to be an idealist, but I got mugged by reality."
Even if you could buy just an "OS-less" switch, I don't think it would do you any good. Most switches have hardware fast-paths for switching packets. You'd have to completely disable the switching logic, and redirect all frames through the host CPU.
Some of the switch ASICs I'm familiar with [medium range broadcom, vitesse] are in fact slower at sending a packet through the host control interface, than at simply switching it to a port on which a host cpu might be connected. [Reference designs from the above have the host CPU connected to the host interface, and control packets, ssh, telnet, http, depending on the design captured and sent through it]. In that case, you'd need your host CPU to be connected to one of the ports of the switch, and then of course your routing speed is limited to the maximum speed that can be sent through a single port.
One of the posters above me mentioned buying a managed switch and using VLAN's, thats what I woulda suggested had he not beat me to it.
Good Luck!
Forget your hackish idea. Get a Cisco 3750-48 style switch and all will be well.
Trolling is a art,
The poster leaves a lot of stuff out - like what's the bandwidth per port? Are they routing analog dial-up lines or gigabit ethernet? What protocols are they routing? Do they need ACLs? How many? Other filtering? Proxying? And if the installation is really that big, just lay out the $jack for a layer-3 or higher switch or router or firewall or whatever.
Not to be a dick, but if the poster has to Ask Slashdot about this sort of configuration, he or she has no business messing with this and should leave the design and configuration to grown ups (unless it's a lab experiment or something).
Help save the critically endangered Blue Iguana
You want to build a router, but you are looking for switch hardware.
You are asking for independent ports. If you need to route through each port seperately and not 'switch' data between ports but 'route' it among them then you need router hardware not switch.
See the thing with switches is that chips are available with 4 ports or 8 ports and it automatically switches data in ASIC between ports. Usually these chips cannot be interfaced to a microcontroller and almost never have PCI interfaces.
You do need individual ports, not a switched collection of ports. So you need something with 7 PCI ports (7x4=28). There are plenty of 4-port PCI cards out there, but there must be 8-port cards too. I have seen plenty of 6-port motherboards. You will have to use PCI extension devices to get to 7 or 8 ports unless you find those 4+ port ethernet cards. Do keep in mind you cannot switch between all ports at wire speed. You'll need faster busses and powerful processors. At this point you're looking at highly specialized hardware like cisco juniper etc.
It is inefficient to route between that many ports on a single CPU. Its better to cascade entire routers if your design allows it or add switches to routers with fewer ports. Unless you are a telco providing high speed connections to ISPs or a central location breaking the bandwidth for many branches, I dont see why anyone will need a router with 30 ports. In any application when you need more processing power, you'd divide the algorithm and use multiple CPUs or multiple computers. In this case you can almost definitely use cascaded routers if you need that many ports in the first place.
I have a Cisco 4700M router with 12 10-mbit ethernet ports. Never needed more than 3.
"Give orange me give eat orange me eat orange give me eat orange give me you." -Nim Chimpsky
Are you routing or switching? What purpose do you have that requires linux specifically? Are you just anti-Cisco, anti-brand name?
:)
You specify that you are building a router then request a switch hardware. What level are you managing your network at? What kind of throughput are you trying to get (10/100, 100 full, gigabit?) Are you managing at the port level or at the IP level (switching vs routing)?
Elaborate and maybe then we can get you some answers
Browsing with classic discussion, noscript, at -1 and nested
no hidden comments and I only mod UP
Get a normal Linux box with 1 or maybe a few ethernet ports (you can bond them together, if you like), and then connect a 48-port switch that supports VLANing. Set up the ports to the Linux box to pass all 40+ VLANs tagged, and then set the ports that are not connected to the Linux box as untagged ports. You now have each of the switch ports effectively as an interface on the Linux machine.
I've done this for cases where I needed a small machine to run with more ethernet ports than it's actually got. Works great.
Sean
Depending on how adventurous you feel about getting linux running on strange hardware, you could buy a used cisco or foundry L2/L3 box for cheap. I know there are a lot of linux projects at cisco, there must be something you can google about how they went about compiling for the platform. The CPUs inside will be something non-mainstream, i.e. not a pentium, but chances are there is a linux distro for it. It shouldn't be that hard to find some archived info on how to bootstrap a linux distro onto one of those boxes.
Used cisco 3500s or 2950s with 24 or 48 ports are on the market for a few hundred (dollars or euros) each. Foundry workgroup switches are less than 100 euros right now. Cisco 7200s are just PCs inside, but their PCI buses are a different layout to allow hot swapping. Cisco Pix 515s are just commodity 1U intel pc motherboards, cisco didn't even bother doing a redesign to remove the superfluous connectors.
If you have enough money for a PCI-ish box and many quad ethernet NICs, then you probably could afford a used Juniper M5. It already runs BSD, and pretty much looks like standard PC hardware inside. A used M5 without any interface cards should be had for less than a new PC, its the interface cards that will cost you dearly.
If you follow my advice, then with any luck you will document everything you did along the way, and release a linux distro for some otherwise proprietary hardware. I'd like to see a cisco 2950 turned into a linux box with all kinds of extra linuxey features. What I'd love to see is openBSD's pf on a switch, so I could set per port ACLs and bandwidth shaping.
the AC
Hemos is like...sci-fi fans;he thinks technology is cool, but he hasn't bothered to understand the science it's based on
I would suggest investing time looking into something such as Cisco 3750 series switches.
I can't speak for the original poster, but in our case we needed VLAN's to be unique per port. That is, VLAN 100 on port 1 should be switched to VLAN 105 on port 2, and VLAN 100 on port 2 should be switched to VLAN 200 on port 3 and 4, and so on. Trivially easy to do in Linux, not so with a 3750. You can do it with VLAN mapping, but you can also buy quite a server for the price of a 3750 and the Advanced IP Services image. Oh and the 3750 supports only 24 VRF-lites, whereas you can run quite a few more OpenVZ instances with routing on a Linux box.
Finally! A year of moderation! Ready for 2019?
Hardware switches can look straight at layer 2 encapsulation and shuffle packets based on that information. The switch's main CPU never sees the packet. The "naked" version of the switch still has enough main CPU in it to program the switch controller chip(s). More "clothed" switches have the spanning tree protocol, SNMP bits, and any other cool features you might have.
Routers have to look at layer 3. Back when I was writing code for a major switch/router manufacturer, most switch chips didn't pass the (de-encapsulated) packet up to the main CPU (or back down). The chip only gave notification that a packet arrived (etc) in the form of an incremented register. This meant the chips were unsuitable for routing because the main CPU had no visibility into the packet whatsoever.
Either of these designs generally require a separate Ethernet NIC for the main CPU, as the switch ports are too busy with external connections. That NIC might be connected to the switch chip on the switch's main board, or it might appear externally as a "management interface port." You'll be programming this NIC, too-- but hopefully, just with ifconfig(1M)
Suggestion: Look for commercial switch chips that can pass the packet to and from the main CPU. Find a company which has a COTS switch with the combination of your favorite switch chip and a CPU that will run your Linux version (or uCLinux). Make sure the implementation hardware is wired properly to be able to get the packets to and from the main CPU-- your favorite chip might have a separate HW interface for communicating with the main CPU that could be unconnected in the implementation hardware. At this point, you essentially have the naked switch that can route. Learn how to boot Linux on the implementation hardware and build a flash filesystem that the switch's bootloader will read. Then start writing code to add the capability you require (to routed?).
Suggestion: Once it works, sell the thing. Or open the source up for others. You went through a lot of trouble to get that capability in the system, and it's got to be so cool because it isn't already in a commercial router. You might consider selling it on the open market yourself, or finding someone to sell it to. Or drop it on Sourceforge for others to upgrade.
Suggestion: Or, you can get your cool feature embodied as an RFC and get the main router vendors to build it in. Or contribute the code to routed(or whatever). You can probably skip the effort of building this one-off switch/router.
[Error 407: No signature found]
Many people have pointed out reasons why this kind of thing is probably a bad idea, but if you still want to do it, ImageStream sells hardware platforms that can include several multi-port ethernet boards. There are reasons why they are marketed as routers and not switches, but they might be useful as switches for some unusual purpose.
AFAIK Apple only sells their hardware with OS X. And if you bought it without an OS, you probably wouldn't be switching. Also, the "Switch" ad campaign has been replaced with the "Get a Mac" ad campaign:
http://www.apple.com/getamac/
Sent from my iPhone
If you go to www.linuxdevices.com and look around, there are several vendors who sell sbc's that have ethernet switches as backplanes, you can add as many as you want. The underlying cpu is either a strong arm, or x86 compat cpu, some have mini-pci slots, etc. And they all run linux!
A 40-port router or switch that has typical office workstations with typical "office" use doesn't require a HUGE amount of power. Most users will drive minimal traffic during office hours except when accessing network resources, which will probably be bursty and random in nature. Realisticly, an office like this would probably have a 48- or two 24-port switches costing a few hundred dollars each, with a router to manage external traffic.
Now, throw half a dozen servers on there along with a few machines that are accessing the outside world 24x7, and now you need some beef and the corresponding dollars.
If it's 40 servers in a server farm, then you are absolutely correct, the user should be prepared to spend big because a cheap router or switch or PC-based solution just won't do the job.
Knowledge is how to play a game, intelligence is how to win, wisdom is knowing what game to play.