Another successful OpenBSD setup

3 years ago by Oliver Lowe to c/selfhosted

Another successful OpenBSD setup

I've been buying these little boxes from AliExpress for years to use as firewalls and routers. My oldest one is almost 9 years old now! OpenBSD installs just fine. Just a BIOS tweak to always boot up after power is restored.

@selfhosted #selfhosting #selfhosted #openbsd #runbsd

shyguyblue 34 points 3 years ago

Throw some hard drives on it and baby, you got a stew home media server goin!

path: 0 7866579, hotness: undefined, score: 34, children: 3
LiveLM 3 points 3 years ago

How?
I've been thinking about setting up one of these cheap boxes as a NAS but I cannot ever find one with 4 Sata ports. Is there a solution for this?
I could use external USB Hard drives but that just feels so janky...

path: 0 7866579 7909952, hotness: undefined, score: 3, children: 2
shyguyblue 1 point 3 years ago

Can't speak to cheap boxes, so usb might be the way, but I use a Zimaboard. Two built in SATA ports, and a pci-e daughter card gives me two more ports. Full disclosure, i don't do anything more than 1080p, bad eyesight...

path: 0 7866579 7909952 7913620, hotness: undefined, score: 1, children: 1
LiveLM 1 point 3 years ago

I'd love to use a Zimaboard too but they're not available were I live.
I could import one but the currency conversion + import taxes make it very not worth it.

path: 0 7866579 7909952 7913620 7921883, hotness: undefined, score: 1, children: 0
possiblylinux127 19 points 3 years ago

I personally never understood the desire for BSD. BSD was good back in the day but we now have Linux which is better supported and protected under the GPL.

path: 0 7887497, hotness: undefined, score: 19, children: 8
Violet_McQuasional 23 points 3 years ago

PfSense and OPNsense are both killer router "out of the box" distros built on BSD. I say this as a Linux user, with little interest in running BSD for my applications, but... Respect to BSD. ✊

path: 0 7887497 7890602, hotness: undefined, score: 23, children: 5
possiblylinux127 4 points 3 years ago

I run OpenWRT and it works pretty well. The only potential issue is the updates but if you have a plan it isn't a problem.

Maybe I'm missing out but from my perspective it is way cheaper to buy a off the shelf router with OpenWRT that can handle gigabit speeds than it is is to build/buy a entire computer that pulls way more power and is several times the cost.

path: 0 7887497 7890602 7890917, hotness: undefined, score: 4, children: 2
winky9827b 3 points 3 years ago

I recently installed OPNsense specifically because I had to buy a mini PC with 2.5 gig ports. There simply isn't anything reasonable on the market for the prosumer above the 1 gig threshold. Running splendidly on a Beelink EQ12.

Also, OPNsense has things OpenWRT doesn't offer (plugins, IPS, etc.)

path: 0 7887497 7890602 7890917 7894694, hotness: undefined, score: 3, children: 0
Ajen 1 point 3 years ago

Openwrt works great for gigabit networks with simple firewall rules and no IPS. But used 10-56gbps enterprise equipment is getting pretty cheap, and more complicated firewall configurations need more powerful hardware than the typical openwrt router.

And 56gbps on a home LAN might be overkill, but that's not important.

path: 0 7887497 7890602 7890917 8166378, hotness: undefined, score: 1, children: 0
jjlinux 2 points 3 years ago

I couldn't agree more. I've been running PFsense for about 5 years, great little toy, not 1 single issue. BSD has been paramount in my life for my firewall needs. And I only run Linux on everything else (desktops and servers), but there is not a single FOSS firewall distro out there that can match, much less surpass, a BSD based firewall.

path: 0 7887497 7890602 7919424, hotness: undefined, score: 2, children: 1
Violet_McQuasional 2 points 3 years ago

Yeah. I've no need to change to anything else. pf/OPNsense 4life.

path: 0 7887497 7890602 7919424 8567307, hotness: undefined, score: 2, children: 0
Crashumbc 1 point 3 years ago

A lot of people stick with what they know and are familiar with.

path: 0 7887497 7921101, hotness: undefined, score: 1, children: 0
Bleach7297 1 point 3 years ago

I one heard ast describe Linux's code quality as 'marginal' (presumably speaking of the kernel)

Of course, it was ast talking at BSDCan but still, harsh words from a master.

path: 0 7887497 7913843, hotness: undefined, score: 1, children: 0
SuperSynthia 17 points 3 years ago

So these noname boxes are good for making a hardware firewall/network?

path: 0 7871255, hotness: undefined, score: 17, children: 7
Cornelius_Wangenheim 12 points 3 years ago
path: 0 7871255 7877937, hotness: undefined, score: 12, children: 0
floofloof 9 points 3 years ago

I use one with 6 LAN ports and a fanless 10th gen i5 running OPNsense, and it has worked well for years. It runs many services including Unbound DNS and Suricata with capacity to spare. It's much better than any consumer router, though I run WiFi separately with an Asus AI Mesh set to AP mode.

The only concerns are that you don't get BIOS updates, and you don't know for sure that there's nothing nasty in the firmware. But then you don't really know that on consumer routers either.

path: 0 7871255 7882810, hotness: undefined, score: 9, children: 0
fuckwit_mcbumcrumble 7 points 3 years ago

I've been running one for the past 6+ months with no issues.

path: 0 7871255 7873021, hotness: undefined, score: 7, children: 0
towerful 4 points 3 years ago

Mine died after 2 years after a power cut.
I havent tried to debug it yet. At the time, it would power on but a monitor didnt see anything from the video port, and it didnt seem to actually boot.
I presume it is toast.

If you dont need compact, a rebfurbed SFF with a 4 port network card is gonna be cheaper

path: 0 7871255 7882693, hotness: undefined, score: 4, children: 0
const_void 2 points 3 years ago

Sure as long as security isn't a concern

path: 0 7871255 7885181, hotness: undefined, score: 2, children: 2
emptiestplace 3 points 3 years ago

Ok, cool - do we have astroturfing on lemmy now?

pfSense has a very good record, but OpenBSD's record and code quality are literally unparalleled.

Conversely, I spend a fair bit of time working on devices made by SonicWall, Fortinet, etc. and it's all fucking garbage.

Are you concerned about it being designed in China in addition to the conventional and thoroughly ubiquitous "manufactured in China"? Please explain your concerns in detail.

path: 0 7871255 7885181 7907462, hotness: undefined, score: 3, children: 1
const_void 3 points 3 years ago

As @floofloof@lemmy.ca stated:

The only concerns are that you don’t get BIOS updates, and you don’t know for sure that there’s nothing nasty in the firmware.

path: 0 7871255 7885181 7907462 7918829, hotness: undefined, score: 3, children: 0
madcaesar 17 points 3 years ago

Sorry for my ignorance I tried googling but what is this exactly? A server for files or? A media server?

path: 0 7883132, hotness: undefined, score: 17, children: 2
rhys 13 points 3 years ago
path: 0 7883132 7887370, hotness: undefined, score: 13, children: 0
Jerry1098 -4 points 3 years ago

An operating system

path: 0 7883132 7887293, hotness: undefined, score: -4, children: 0
Da_Boom 15 points 3 years ago

I recognise that internet router on the right. That looks like the "smart router" Telstra gives their customers - we have one we used to use back when we had Telstra cable. It's currently playing the duty of an Ethernet switch for dad's office.

path: 0 7869176, hotness: undefined, score: 15, children: 2
otl 5 points 3 years ago

Good eyes! Yes this is one we got from Telstra on a VDSL NBN connection. Now it’s just a modem in bridge mode with Aussie Broadband

@selfhosted @Da_Boom

path: 0 7869176 7881187, hotness: undefined, score: 5, children: 0
ryannathans 3 points 3 years ago

Smg2?

path: 0 7869176 7873266, hotness: undefined, score: 3, children: 0
cmnybo 15 points 3 years ago

Do any of those cheap Chinese computers ever get any firmware or bios updates?

path: 0 7867116, hotness: undefined, score: 15, children: 21
const_void 31 points 3 years ago

No and they don't provide the source either. Makes you wonder what's running in there.

path: 0 7867116 7869119, hotness: undefined, score: 31, children: 4
StopSpazzing 23 points 3 years ago

While i agree, no one provides full source blobs for firmware and bios that i am aware of. Please correct me if I am wrong, however.

path: 0 7867116 7869119 7873617, hotness: undefined, score: 23, children: 3
const_void 3 points 3 years ago path: 0 7867116 7869119 7873617 7885010, hotness: undefined, score: 3, children: 2
StopSpazzing 11 points 3 years ago

Open source bios yes, but you still have close source firmware blobs for amd/intel used on those systems. The only way to do this is to make 100% of the hardware.

Also please note, I am using coreboot already on my pcengines router.

path: 0 7867116 7869119 7873617 7885010 7889014, hotness: undefined, score: 11, children: 0
areyouevenreal 1 point 3 years ago

Few computers use CoreBoot, and CoreBoot still uses proprietary blobs typically. Normally only libreboot has zero blobs, and they are very rare indeed.

path: 0 7867116 7869119 7873617 7885010 8135939, hotness: undefined, score: 1, children: 0
Bitflip 15 points 3 years ago

I'd be surprised if it wasn't just based off the UEFI sdk examples containing 30+ CVEs over the last couple of years. If anything, it won't get patched for logofail and all the others UEFI exploits we'll definitely see in the coming years.

path: 0 7867116 7870758, hotness: undefined, score: 15, children: 0
otl 7 points 3 years ago path: 0 7867116 7881279, hotness: undefined, score: 7, children: 1
benjja 3 points 3 years ago

@otl @cmnybo @selfhosted

Protectli ported coreboot for their hardware, and with a little research you can find this hardware on aliexpress, of course under a different name.

path: 0 7867116 7881279 7881509, hotness: undefined, score: 3, children: 0
scrion 7 points 3 years ago

I was wondering... that tp-link probably negates anything remotely resembling security on its own. But yeah, you can update some of these noname boxes easily, others, not so much.

I have dealt with (in a professional capacity) Chinese manufacturers that are under the impression they do not have to provide a working build tree for the kernel, let alone firmware, so its a gamble if you're not talking to a major Chinese name brand. Mind you, I was ordering hundreds of those boxes, so there was some leverage.

path: 0 7867116 7868334, hotness: undefined, score: 7, children: 11
MigratingtoLemmy 15 points 3 years ago

That TP-link is a dumb switch. Unless you're telling me that someone is going to find an opening in the firmware and hack their way into the ARP table or something (in which case the threat model here just became state actors and I don't think the OP is safe with this equipment), I don't think it affects much, if anything.

Now, if I'm mistaken and that is actually a managed switch; god help them with network security.

path: 0 7867116 7868334 7868533, hotness: undefined, score: 15, children: 10
Link 8 points 3 years ago

It is a managed switch. What’s wrong with TP-Link managed switches?

I have a basic Netgear managed switch for VLANs.

path: 0 7867116 7868334 7868533 7872605, hotness: undefined, score: 8, children: 6
MigratingtoLemmy 0 points 3 years ago

The problem is that their Web interface and firmware in general are not updated (at all). I think it's even possible for script kiddies to hack into such managed switches, which forms the reasoning behind my comment.

Does your switch produce its Web interface over TLS?

path: 0 7867116 7868334 7868533 7872605 7885818, hotness: undefined, score: 0, children: 5
scrion 6 points 3 years ago

They do make managed switches, but just to be completely clear, my comment was mostly hyperbole. I just found the general combination of security - mindedness and cheap Chinese hardware curious / amusing.

path: 0 7867116 7868334 7868533 7869530, hotness: undefined, score: 6, children: 2
MigratingtoLemmy 3 points 3 years ago

I did realise that, and apologies for my tone earlier.

With that said, this seems to be a slight bias - unless the PCB has some nefarious spy-chip built inside, hardware is hardware, regardless of where it comes from.

path: 0 7867116 7868334 7868533 7869530 7885766, hotness: undefined, score: 3, children: 0
floofloof 2 points 3 years ago

I just found the general combination of security - mindedness and cheap Chinese hardware curious / amusing.

I think it can make sense, since there are so often vulnerabilities in consumer router firmware, and because those devices are so common the vulnerabilities are profitable to exploit. Running a BSD-based router on a cheap Chinese PC is likely to be better security for the router's OS and software itself, even if you don't know for sure about the firmware on the board (which you don't with consumer routers either, really). Overall you could still have reduced your attack surface compared to a popular consumer router.

path: 0 7867116 7868334 7868533 7869530 7898801, hotness: undefined, score: 2, children: 0
possiblylinux127 3 points 3 years ago

Does any board ever get firmware updates? I don't understand your logic.

path: 0 7867116 7887523, hotness: undefined, score: 3, children: 0
StopSpazzing 11 points 3 years ago

Any cheap 2x 2.5gb n100 ones yet?

path: 0 7867100, hotness: undefined, score: 11, children: 2
Daughter3546 14 points 3 years ago

There are a few 5x 2.5g N100 for $120-130 USD range on AliExpress. I grabbed one a while back for my own network.

path: 0 7867100 7869639, hotness: undefined, score: 14, children: 0
possiblylinux127 0 points 3 years ago path: 0 7867100 7887541, hotness: undefined, score: 0, children: 0
Decronym 11 points 3 years ago

Acronyms, initialisms, abbreviations, contractions, and other phrases which expand to something larger, that I've seen in this thread:

Fewer Letters More Letters
AP WiFi Access Point
DNS Domain Name Service/System
NAS Network-Attached Storage
SATA Serial AT Attachment interface for mass storage
SSL Secure Sockets Layer, for transparent encryption
TLS Transport Layer Security, supersedes SSL

5 acronyms in this thread; the most compressed thread commented on today has 9 acronyms.

[Thread #543 for this sub, first seen 25th Feb 2024, 15:45] [FAQ] [Full list] [Contact] [Source code]

path: 0 7885822, hotness: undefined, score: 11, children: 1
else 2 points 3 years ago

Good bot 🤖

path: 0 7885822 7910718, hotness: undefined, score: 2, children: 0
wernsting 7 points 3 years ago

What bios tweak do you apply? That’s the one thing I still need to do.

These things are awesome!

path: 0 7867114, hotness: undefined, score: 7, children: 2
ryannathans 6 points 3 years ago

Restore power status after AC loss

path: 0 7867114 7873284, hotness: undefined, score: 6, children: 0
Landless2029 4 points 3 years ago

Basically auto power on after restore power.

Meaning if you get unplugged (or power outage) turn back on like any other networking gear.

path: 0 7867114 7873817, hotness: undefined, score: 4, children: 0
tk 6 points 3 years ago

@otl What CPU does it have?

path: 0 7867081, hotness: undefined, score: 6, children: 1
otl 4 points 3 years ago path: 0 7867081 7881411, hotness: undefined, score: 4, children: 0
Smc87 6 points 3 years ago

Why

path: 0 7867815, hotness: undefined, score: 6, children: 3
otl 5 points 3 years ago path: 0 7867815 7881652, hotness: undefined, score: 5, children: 0
vext01 5 points 3 years ago

Why what?

path: 0 7867815 7874896, hotness: undefined, score: 5, children: 0
ugh 3 points 3 years ago

I'm glad to see that we're not all addicts here

path: 0 7867815 7880634, hotness: undefined, score: 3, children: 0
alvaro 5 points 3 years ago path: 0 7868709, hotness: undefined, score: 5, children: 2
otl 5 points 3 years ago path: 0 7868709 7881518, hotness: undefined, score: 5, children: 1
alvaro 1 point 3 years ago path: 0 7868709 7881518 7885245, hotness: undefined, score: 1, children: 0
fmstrat 5 points 3 years ago

I have one of these with PFSense on it. Works great, but when I had it in a hot room I had to zip tie a 120mm fan to it 😀

path: 0 7883737, hotness: undefined, score: 5, children: 2
winky9827b 3 points 3 years ago

I bought some half-inch silicone feet to separate mine from the shelf it sits on. The added airflow underneath seems to do just fine.

path: 0 7883737 7894778, hotness: undefined, score: 3, children: 1
fmstrat 2 points 3 years ago

Yea mine was hung on the wall with an air gap, still needed the fan hah

path: 0 7883737 7894778 7897348, hotness: undefined, score: 2, children: 0
sandwich 3 points 3 years ago

@otl @selfhosted

Got a simmilar one, and once a time i get an IO error.
Im sacred to leave my country and find out my router is dead

path: 0 7882057, hotness: undefined, score: 3, children: 0
jjlinux 3 points 3 years ago

6 VLANs, 2 ISPs on load Balancing and FailOver, 6 switches, 7 APs.

The sky's the limit

path: 0 7919472, hotness: undefined, score: 3, children: 4
otl 2 points 3 years ago path: 0 7919472 7933847, hotness: undefined, score: 2, children: 3
jjlinux 1 point 3 years ago

I'm bent on getting as many people as I know to self-host everything possible and to guard their home networks. The garbage out there today is too much.

path: 0 7919472 7933847 7952248, hotness: undefined, score: 1, children: 2
otl 2 points 3 years ago

> The garbage out there today is too much.

For sure. I'm hoping that with much cheaper and more reliable hardware
that we have now, it makes it easier for indivduals and small groups
to run services that could only be run by big dysfunctional companies.
Fingers crossed!
@jjlinux @selfhosted

path: 0 7919472 7933847 7952248 7956799, hotness: undefined, score: 2, children: 1
jjlinux 1 point 3 years ago

It's not much, but I got a friend from church (die-hard Apple user) to love away from all that crap. He now owns a Pixel 6 Pro running Graphene and is running PopOS on an Intel Mac. Sold his IPhone too.

He says that I am the only person he knows that preaches 2 Gospels 🤣🤣

path: 0 7919472 7933847 7952248 7956799 7981403, hotness: undefined, score: 1, children: 0
7Sea_Sailor 2 points 3 years ago

Ive wanted one of these for a while to replace my ISPs modem+router+switch+wifi-AP. But apparently these devices can be funky to get a good wifi going, and I don't feel like adding three (mini pc, switch, AP) new devices to my "we don't talk about it" corner where all the IT is stored. Do you know anything about wifi on these?

path: 0 7907979, hotness: undefined, score: 2, children: 3
droans 1 point 3 years ago

It's usually considered a poor idea to use it also as an AP.

The location usually isn't great for your WiFi and there are better tools for the job.

path: 0 7907979 7926790, hotness: undefined, score: 1, children: 2
7Sea_Sailor 1 point 3 years ago

Is location the only reason to not use it as the AP? If I had a larger house I'd agree, but as I live in a small apartment, the current router location can easily serve the entire flat, so that is no concern right now.

path: 0 7907979 7926790 7940199, hotness: undefined, score: 1, children: 1
Lifebandit666 1 point 3 years ago

I picked up a 7 year old Netgear modem/router on eBay that has replaced my ISP modem/router. The WiFi is better, and I can port forward without taking all the cables out of the back (yeah that's a thing with the ISP one) and forward traffic through my Adguard DNS. Well worth the £25 I bought it for.

Also if it starts annoying me I can throw OPENWRT on it and play with that instead.

path: 0 7907979 7926790 7940199 7980247, hotness: undefined, score: 1, children: 0
Hiro8811 1 point 3 years ago

How would one go building a router? I was planning on getting wired networks for a NAS build but most providers seem to ship their own router which probably is a nightmare for privacy, can I just pay for internet and use whatever router I want?

path: 0 7920426, hotness: undefined, score: 1, children: 1
droans 1 point 3 years ago

OpnSense would be the easiest way if you wanted to go. It's still not easy, but the articles online should help you out.

First you'd need a machine. I've got an m920q I bought off eBay for $135 after shipping.

The computer will likely only have one Ethernet port. And it's likely the port is Realtek which isn't supported well.

So, you'll need to get yourself a NIC (a fancy term for a network card). There are good forum posts and articles online about the best NICs to buy for your needs. Intel is a must. However, you can find many of their NICs online labeled as another brand - usually HP, Lenovo, or Dell. Again, the forum posts will tell you what to look for.

If you bought the same computer I mentioned above, you'll also need a riser and a bezel. Amazon and eBay will have a good selection.

Now assemble it. Flash the computer with OpnSense. Don't plug it in as your router yet. Follow along with some basic setup guides online to figure out how you want it configured.

Once you're happy, plug it in as your router and test that it works. If not, you'll need to put your old router back in place until you can figure out what you need to change.

path: 0 7920426 7926766, hotness: undefined, score: 1, children: 0
selfhosted
selfhosted

@lemmy.world

login for more options
62941
6793
5617

A place to share alternatives to popular online services that can be self-hosted without giving up privacy or locking you into a service you don't control.

Rules:

Detailed Rules Post

  1. Be civil.

  2. No spam.

  3. Posts are to be related to self-hosting.

  4. Don't duplicate the full text of your blog or readme if you're providing a link.

  5. Submission headline should match the article title.

  6. No trolling.

  7. Promotion posts require active participation, with an account that is at least 30 days old. F/LOSS without a paywall has exceptions, with requirements. See the rules link for details. Tags [CBH] or [AIP] are required, see the links in Rule 8 for details.

  8. AI-related discussions and AI-involved promotional posts have additional requirements for tagging, as noted in Rule 7 and the AI & Promotional Post Expanded Rules post, and find example disclosures here.

Resources:

Any issues on the community? Report it using the report flag.

Questions? DM the mods!

go to feed...