OPNsense Forum

Archive => 17.1 Legacy Series => Topic started by: minimike on March 16, 2016, 07:24:07 pm

Title: Helping with ARM support + recommended ARM hardware
Post by: minimike on March 16, 2016, 07:24:07 pm
Hi

I've read that support about ARM will come in this summer. Thats something what I think is very interesting. Are they some recommendations about hardware available? I would like to buy a device for testing and share the results.

cheers Darko
Title: Re: recommended ARM Hardware
Post by: franco on March 17, 2016, 08:33:30 am
Hi Darko,

The plan is to get things running for a Raspberry Pi 1 Model B, which kind of outlines the lowest possible requirements. The experiment could fail for various reasons and/or time limitations, but there will be a test build as a proof of concept. Everything else will need to be assessed when we've reached that point and gotten a little feedback from users. :)


Cheers,
Franco
Title: Re: recommended ARM Hardware
Post by: interfaSys on March 17, 2016, 08:28:36 pm
Hi

I've read that support about ARM will come in this summer. Thats something what I think is very interesting. Are they some recommendations about hardware available? I would like to buy a device for testing and share the results.

cheers Darko

Projects like Turris Omnia are interesting even if x86 hardware brings better value for the money. Without support for netmap in the network driver, you will also burn a lot of CPU cycles running Suricata in IPS mode.
Title: Re: recommended ARM Hardware
Post by: minimike on March 17, 2016, 09:41:53 pm
Hey guys what you are thinking about a banana pi? The BPi-R1 looks very nice. Only two relevant things are not perfect. I've readed about the network-chip that it's a little bit slow. And the case is transparent and fits not the WAF of your wife :) But Hardware for 100,- € with 2 GB memory and you could attach an SSD...
Title: Re: recommended ARM Hardware
Post by: Σουπεργιούζερ on March 26, 2016, 11:21:53 am
Hello minimike!

Hey guys what you are thinking about a banana pi? The BPi-R1 looks very nice.

When I had first spotted the BPI-R1 I was enthusiastic about it since it seemed like the perfect solution for a firewall with its 5 NICs + WLAN. Unfortunately then I learned that it is not 6 physical interfaces but only a WLAN chip and a switch chip with 5 ports attached, check e.g. http://forum.lemaker.org/thread-12942-1-1.html. So it seems that someone could only create network zones by VLAN tagging which for security reasons I do consider to be inadequate, isn't it?

If that is true there seems not to be any significant advantage of the BPI-R1 over a Raspberry 1b, other than having e.g. SATA and a 5 port switch for a network zone, and of course more CPU power, etc...

Specs & images: http://www.banana-pi.com/eacp_view.asp?id=64

Regards
Title: Re: recommended ARM Hardware
Post by: Σουπεργιούζερ on March 27, 2016, 02:50:35 pm
In any case, when it comes to chose a SoC-device to support, I strongly recommend to study the list of flaws that the FSF outlines here https://www.fsf.org/resources/hw/single-board-computers and make a coice with as few flaws as possible.
The Raspberry Pi is not a good choice IMHO, as long as they stick to their blob strategy.

Here is a list with information about OS support and if BLOBs are needed or not: https://en.wikipedia.org/wiki/Comparison_of_single-board_computers#Operating_system

The topic on:

Cheers
Title: Re: recommended ARM Hardware
Post by: faisalusuf on April 30, 2016, 03:21:33 pm
Cubieboard is an opensource hardware and it supports FreeBSD, OpenBSD, Android. This can be a best choice for embedded deployment.

Thanks
Faisal.
Title: Re: recommended ARM Hardware
Post by: chemlud on May 16, 2016, 08:53:23 am
Hi!

a small (wifi, 3g/4g) router for traveling based on raspi 3 would be a cool project, is the ARM version of OPNsense anywhere near or will it come later? :-)

kind regards

chemlud
Title: Re: recommended ARM Hardware
Post by: franco on May 18, 2016, 07:42:45 pm
Hi chemlud,

A proof of concept is still pending, although I'm worried about

(a) computing power and other bottlenecks like RAM for small / old devices, also important for timely builds
(b) portability of builds across different hardware, we can't really handle more than one or two additional images with ease

The proof of concept is for Raspberry Pi 1 Model B, which will bring:

1. Updates to the tools.git to build an arm version without much effort other than setting up a build system and running the scripts
2. A few test builds for the above platform to try out.

Anything beyond that will have to be re-evaluated afterwards.


Cheers,
Franco
Title: Re: recommended ARM Hardware
Post by: fraenki on June 08, 2016, 01:14:40 pm
The proof of concept is for Raspberry Pi 1 Model B, which will bring:

Does an GH issue already exist to keep track of the open tasks and/or problems/solutions? I couldn't find one. It could help to point out what was already done and needs to be done. :)

I'd like to help testing and maybe more if it proves to be useful.


Regards
- Frank
Title: Re: recommended ARM Hardware
Post by: franco on June 10, 2016, 06:46:05 pm
We should create one in tools, that would be no problem.

Due to workload in my day job, however, I'm not going to be able to work on ARM for the moment. The roadmap has been adjusted accordingly.

If someone is interested in picking this up, there's an RPI that was sponsored that belongs to this task. :)

https://github.com/opnsense/tools/issues/33
Title: Re: recommended ARM Hardware
Post by: chemlud on June 11, 2016, 01:52:24 pm
... I would sponsor a Raspi 3 (bare metal :-) ), if someone starts working on that.

With the built-in wifi and the better CPU I guess the hardware is more appropriate the the reeeeeaaalllllyyyy slow Raspi 1.

 
Title: Re: recommended ARM Hardware
Post by: franco on June 13, 2016, 07:28:12 am
Chemlud, that would be very kind, thanks. I'll sticky this thread for more visibility. :)
Title: Re: Helping with ARM support + recommended ARM hardware
Post by: chemlud on June 14, 2016, 06:20:59 pm
Update:

Found this here:

https://www.raspberrypi.org/forums/viewtopic.php?f=85&t=149398

...and downloaded the FreeBSD 10.3 for Raspi (ARM 6 support):

https://www.freebsd.org/where.html

...burning SD card, Raspi 1B boots fine to boot prompt, whle Raspi 2B+/3B will only show rainbow screen, i.e. detect no bootable OS...

So apparently the Raspi 1 is the only bet at this time. Can anybody guide my how to get somefink like a nano image of opnsense with this special BSD for ARM? Or no way? :-D

Title: Re: Helping with ARM support + recommended ARM hardware
Post by: franco on July 17, 2016, 09:39:13 pm
Some attempts have been made to make the tools.git more cross-compile friendly. I have successfully built a RPI base and kernel set, just a little more work needs to be done to bring in a viable RaspberryPi kernel config.

Work that is still needed:

(a) The ports cross-build is probably something that can only be solved with QEMU or a native system.

(b) Prune ports.conf, help build failing but required ports.

(c) Modify core.git to cope with ports that are not available on arm.

(d) Proper nano image builds for the RPI with their magic boot blobs.

It looks like the PRI images will be compatible with model 1 and 2:

https://wiki.freebsd.org/FreeBSD/arm/Raspberry%20Pi

Some more docs on cross-building:

https://wiki.freebsd.org/FreeBSD/arm/crossbuild
https://wiki.freebsd.org/FreeBSD/arm/Raspberry%20Pi%202%20image
https://www.raspberrypi.org/forums/viewtopic.php?f=85&t=90613
http://allskyee.blogspot.ch/2014/02/freebsd-10-ports-cross-compile-amd64-to.html
http://kernelnomicon.org/?p=229
https://www.dvatp.com/tech/armv6_freebsd_poudriere
https://wiki.freebsd.org/QemuUserModeHowTo


Cheers,
Franco
Title: Re: Helping with ARM support + recommended ARM hardware
Post by: franco on July 18, 2016, 09:14:21 am
FWIW, I've completed (a), ports build works, but now needs to avoid building any unwanted ports and see if some have problems in arm.
Title: Re: Helping with ARM support + recommended ARM hardware
Post by: franco on July 18, 2016, 09:33:48 pm
https://twitter.com/fitchitis/status/755121098740604928 ;)
Title: Re: Helping with ARM support + recommended ARM hardware
Post by: bobbythomas on July 28, 2016, 08:05:36 pm
Hi Franco,

I have a Raspberry Pi 2 and Banana Pi 1 lying around (upgraded to Intel NUC)? Is there any opnsense test images available for those?

Thank you,
Regards,
Bobby Thomas.
Title: Re: Helping with ARM support + recommended ARM hardware
Post by: franco on July 28, 2016, 08:54:23 pm
Hi Bobby,

Only the RPI B works on FreeBSD 10.3, so 16.7. I will put up packages and instructions on how to install one of those next week. But there won't be frequent updates... this is going to be an experimental item as the RPI B is rather slow. But its fun to see it working. :)

The RPI2 can be possible with FreeBSD 11, but the roadmap for 17.1 hasn't been decided on, although it could be a likely candidate for adoption of FreeBSD 11 and its enhanced ARM support. We'll see over the course of the next month or two.


Cheers,
Franco
Title: Re: Helping with ARM support + recommended ARM hardware
Post by: bobbythomas on August 01, 2016, 02:27:28 pm
Hi Franco,

Sorry for the late reply. Thank you for your prompt response, I am eagerly waiting for 17.1 build. I believe freebsd also supports banana pi from 11.0 so that means we can use the same build for both RPi2 and Banana Pi (since BPi is better I wish I could see a build for that)?

Thank you,
Regards,
Bobby Thomas.
Title: Re: Helping with ARM support + recommended ARM hardware
Post by: lattera on August 01, 2016, 02:50:33 pm
Once FreeBSD 12-CURRENT supports the RPI3, and OPNsense solidifies its ARM support, I'll try doing a build for ARM64.
Title: Re: Helping with ARM support + recommended ARM hardware
Post by: franco on August 02, 2016, 07:35:31 am
Hi Bobby,

The way we will publicly test ARM will likely be without images so that one starts with a working FreeBSD image and then just installs OPNsense on top. That way we can make sure that all the ARMv6 devices that work with FreeBSD can be supported.

There is a caveat in the kernel build, which we'll have to see whether it's compatible between the RPi, PRi2 and BPi, but we'll get to see / solve this. :)


Cheers,
Franco
Title: Re: Helping with ARM support + recommended ARM hardware
Post by: bobbythomas on August 03, 2016, 01:22:47 am
Hi Franco,

Thanks for your time. I will try to install opnsense over the freebsd build on my rpi2 and bpi. I will update the results here.

Thank you,
Regards,
Bobby Thomas
Title: Re: Helping with ARM support + recommended ARM hardware
Post by: macafee on August 04, 2016, 07:36:18 am
You can test the Nvidia Tegra platform with INTEL 4-PORT NIC.
http://www.nvidia.com/object/jetson-tx1-dev-kit.html
Title: Re: Helping with ARM support + recommended ARM hardware
Post by: franco on October 14, 2016, 10:24:51 am
https://forum.opnsense.org/index.php?topic=3793.0 :)
Title: Re: Helping with ARM support + recommended ARM hardware
Post by: echo6 on October 30, 2016, 02:39:45 pm
https://lists.freebsd.org/pipermail/freebsd-arm/2016-October/014831.html (https://lists.freebsd.org/pipermail/freebsd-arm/2016-October/014831.html)

Looking for to RPI3 support!
Title: Re: Helping with ARM support + recommended ARM hardware
Post by: franco on October 30, 2016, 05:22:45 pm
Hi echo6,

We're going to try the RPI2 on top of our full 17.1 code early next year. RPI3 is a possibility afterwards.

We're still not sure whether we should add support for a single platform or simply help people build software for their ARM devices.

https://twitter.com/g0mb0/status/792612100011065344


Cheers,
Franco
Title: Re: Helping with ARM support + recommended ARM hardware
Post by: lattera on October 30, 2016, 05:45:05 pm
I'm helping FreeBSD a bit with the RPI3 support. In order to support the RPI3, FreeBSD first needs a working clang 3.9.0 with lld on it. I'm in the process of researching why building FreeBSD/aarch64 with clang 3.9.0 and lld breaks boot1.efi, loader.efi, and the kernel. The process behind the research is slow, especially given only a single core being enabled on the RPI3. Diane Bruce is researching enabling all four cores.

There's likely a locking issue in the aarch64-specific code in FreeBSD as the thread cache in jemalloc has to be disabled via malloc.conf in order to successfully compile and install ports-mgmt/pkg natively on the device itself. There's also an improper linking issue. Some applications, like pkg, get mislinked. I've sent out a few emails on the relevant FreeBSD mailing lists under Ed Maste's direction. I'm hoping we can get the clang 3.9.0/lld issues resolved soon.

So, it'll likely be a while before FreeBSD on the RPI3 is actually functional beyond the utilities provided in base. Naturally, it'll take downstream projects like OPNsense to follow in support.

Note that you won't get the best throughput on the Raspberry Pi devices as they're not really built for network performance. They use a USB-backed NIC. I would think something more like the Odroid-C2 would perform better. But I'm not a performance engineer, so take that with a grain of salt.

So, for now, stick with 32-bit ARM devices as 64-bit ARM support is still very much a work-in-progress.
Title: Re: Helping with ARM support + recommended ARM hardware
Post by: chemlud on October 30, 2016, 06:04:01 pm
Support for Raspi! Great! Will have a look soon... Going to try out some USB-RJ45 adapters I recently bought for a raspberry-Wireshark machine I'm planning currently.

Fun!
Title: Re: Helping with ARM support + recommended ARM hardware
Post by: chemlud on November 12, 2016, 05:12:52 pm
Hi again!

Did this here:

https://forum.opnsense.org/index.php?PHPSESSID=904p9h0bq3h7vttcejijdn4n30&topic=3793.msg13161#msg13161 (https://forum.opnsense.org/index.php?PHPSESSID=904p9h0bq3h7vttcejijdn4n30&topic=3793.msg13161#msg13161)

Very cool! First sense on raspi feeling!

Notes:

- FreeBSD has ssh enabled out of the box, but no root-login, log in as freebsd/freebsd and do a 'su'.

- Could not get the serial console (115200?) get running on the standard pins of raspi. PS: Error messages appear on serial, but not the usual menu?!? (smsc0: warning MII is busy etc)

- Used a cheap USB-RJ45 as WAN interface, get's an IP and internet is ready to go! CPU loves to "100%" feeling at the Dashboard... :-D

This is absolutely cool!

Keep on! Is there any way to make that work on a Raspi 2 at that time with FreeBSD 11 and the dev version of 17.1?
Title: Re: Helping with ARM support + recommended ARM hardware
Post by: franco on November 15, 2016, 05:10:16 pm
We'll definitely opt for RPI2 with 17.1 (100% CPU is a point...), not sure if there will be a build before 17.1 is out though.

Haven't played with the console yet, used HDMI+keyboard all the time.

Also, this:

https://twitter.com/g0mb0/status/792612100011065344
https://twitter.com/g0mb0/status/796203293269757952

all the way up to 12-CURRENT ;)
Title: Re: Helping with ARM support + recommended ARM hardware
Post by: chemlud on November 15, 2016, 06:19:36 pm
This might be fun, tooo:

http://www.banana-pi.org/r1.html

;-)

PS: For serial console try one of these:

https://www.amazon.de/gp/product/B00AFRXKFU/ref=oh_aui_detailpage_o06_s00?ie=UTF8&psc=1

https://www.amazon.de/gp/product/B00R76SCJ6/ref=oh_aui_detailpage_o06_s00?ie=UTF8&psc=1

Title: Re: Helping with ARM support + recommended ARM hardware
Post by: franco on November 15, 2016, 10:38:39 pm
Yes, nice! Eventually we will see convergence for armv6. It's nice that packages and base builds will be (hopefully) compatible. The blockers here are the multitude of ways to treat the release images and the problem of a device-specific kernel, especially during bootstraps. It can be solved. And it will take more time to get there. :)
Title: Re: Helping with ARM support + recommended ARM hardware
Post by: chemlud on November 24, 2016, 10:42:02 am
Bad news!

Raspi 2B has recently changed hardware from ARM7 to ARM8 (aarch64), same CPU as in Raspi 3

http://raspi.tv/2016/new-raspberry-pi-2b-1-2-with-pi3-bcm2837-processor (http://raspi.tv/2016/new-raspberry-pi-2b-1-2-with-pi3-bcm2837-processor)

So the planned 17.1 ARM release will only work on "older" Raspi 2 (not available to buy anymore...)

Very sad! We will have to wait for full support of BSD for ARM8, preferably as 64 bit. That should give a HUGH boost to performance, though, will give a very good an handy firewall for IO(shitty)T and for traveling.

I should switch to IT, it's so exciting to see the developments there, compared to my boring "daytime" job! :-D

Title: Re: Helping with ARM support + recommended ARM hardware
Post by: franco on November 24, 2016, 04:11:52 pm
This is a weird decision, especially with the highly acclaimed decision of RPI-1 being binary-compatible with RPI-2.

Of course, until it's not. :D
Title: Re: Helping with ARM support + recommended ARM hardware
Post by: chemlud on November 24, 2016, 04:17:08 pm
... with the standard Raspian not really a problem. All 32 bit. You can run the same SDcard on a Raspi zero, Rapsi 1, Raspi 2 and  Raspi 3. Only ONE image for the complete range of hardware. ;-)
Title: Re: Helping with ARM support + recommended ARM hardware
Post by: franco on November 24, 2016, 04:24:06 pm
Yet this differs from how FreeBSD approaches this, or did I miss something?
Title: Re: Helping with ARM support + recommended ARM hardware
Post by: chemlud on November 24, 2016, 05:27:36 pm
If you treat the whole range as one device (raspian style) you give away a whole lot of potential of the hardware, I guess.

Apparently BSD has a different approach, tailored for each hardware-release of the rasp-foundation.

http://www.raspbsd.org/ (http://www.raspbsd.org/)
https://wiki.freebsd.org/FreeBSD/arm/Raspberry%20Pi (https://wiki.freebsd.org/FreeBSD/arm/Raspberry%20Pi)

Brand new support for Raspi 3:

https://www.raspberrypi.org/forums/viewtopic.php?f=85&t=164863&sid=17e1a3d1e3df2f142ae2421b38a37c4b (https://www.raspberrypi.org/forums/viewtopic.php?f=85&t=164863&sid=17e1a3d1e3df2f142ae2421b38a37c4b)

(In fact, the change in hardware of Raspi 2B will kill the support of BSD for this model)

As has openSUSE, SUSE, with releases for 64bit only (SLES) or for each individual device (openSUSE)...


Would it be possible to bootstrap opnsense on a raspi 3 with the raspiBSD image?
Title: Re: Helping with ARM support + recommended ARM hardware
Post by: depekavienna on November 26, 2016, 04:23:34 am
Hi!

I just registered an account here, because I was hoping to get more information on the BPI (M1). I have such a unit from Lemaker and found franco's posting about the RPI 1B https://forum.opnsense.org/index.php?topic=3793.0#msg13161.

Is that setup method just the same for the BPI? I.E. get an image from FreeBSD for via https://github.com/freebsd/crochet, or ftp://ftp.freebsd.org/pub/FreeBSD/releases/arm/armv6/ISO-IMAGES/11.0/FreeBSD-11.0-RELEASE-arm-armv6-BANANAPI.img.xz respectively, then download and run the OPNsense install script?

Should it really be that simple?

Thanks!

Title: Re: Helping with ARM support + recommended ARM hardware
Post by: franco on November 26, 2016, 03:18:22 pm
Yes and no. The kernel part is currently a problem. You can try these instructions, but make sure to boot kernel.old from the boot menu, the one we ship is specifically for the RPI-1B.

Luckily, our kernel diverges little from FreeBSD these days, so that's not a fatal issue.

We have someone trying different ARM boards with OPNsense on FreeBSD 12-CURRENT, but he's done the same: skipping using the default kernels for now.

Once we can support a kernel per device, we could potentially offer support for the whole armv6 Architecture scope including the old PRIs, BPI and others.


Cheers,
Franco
Title: Re: Helping with ARM support + recommended ARM hardware
Post by: depekavienna on November 27, 2016, 01:49:07 am
Hi franco!

Can you please explain to me, what OPNsense's changes to the kernel are, compared to the FreeBSD mainline kernel?
How deep are the modifications to the base system, especially on ARM?

I'll now try to set up the Banana PI, as you suggested. If there is anything special I should report back or log while doing so, please let me know. Would it be advisable to use FreeBSD 11 with 16.7, or rather FreeBSD 12-Current with 17.1?

Thank you!
Title: Re: Helping with ARM support + recommended ARM hardware
Post by: franco on November 27, 2016, 10:55:35 am
Hi depekavienna,

ARM is pretty fragmented. We've put out a build for "armv6" Architecture based on a 16.7.x release based on FreeBSD 10.3.

For all other architectures or things that require FreeBSD 11.x or higher the ecosystem has to be built from scratch.

If Banana Pi M1 is armv6, then you can use the same instructions as RPI1-B, but need to switch the kernel back before final reboot:

# mv /boot/kernel /boot/kernel.opnsense
# mv /boot/kernel.old /boot/kernel

As far as changes go, I went through all the commits for the upcoming 17.1:

1. A significant patch that we have is for symmetric traffic shaping, something that doesn't work on FreeBSD in conjunction with pf+ipfw at the moment. The patch actually dates back to m0n0wall. Not having this patch in the kernel may cause traffic shaping to not fully adhere to its setup, but the scope is really small and causes no other service interruption.

https://github.com/opnsense/src/commit/4036f873755a3ceeb73c9292065c3530ebfd08e0

2. We have several imported features from HardenedBSD: ASLR, PIE and SEGVGUARD. All of those are optional.

https://github.com/opnsense/src/commit/2d787654c799ace1e033ee69a9fe7e7156eccff4
https://github.com/opnsense/src/commit/885c2e557f71a67020c72c5997fa3c9280e1e9a4
https://github.com/opnsense/src/commit/132c9174a61dbfac2cdc8081fed65382f42373c8

3. We build a slightly different kernel config than GENERIC and src.conf for base.

https://github.com/opnsense/tools/blob/master/config/17.1/SMP
https://github.com/opnsense/tools/blob/master/config/17.1/src.conf

That's it for 17.1. For 16.7 the list is still a little longer due to inherited patches, but compatible too as far as I have seen.

EDIT: BANANAPI is for 11.0 only, so no prebuilt packages yet.

ftp://ftp.freebsd.org/pub/FreeBSD/releases/arm/armv6/ISO-IMAGES/11.0/


Cheers,
Franco
Title: Re: Helping with ARM support + recommended ARM hardware
Post by: depekavienna on November 27, 2016, 02:47:42 pm
FYI: Banana PI specs: http://www.bananapi.org/p/product.html and http://www.banana-pi.org/m1.html
In short: Allwinner A20* (ARM Cortex-A7 dual-core, 1GHz), 1 GB DDR3 SDRAM, GE internally connected through USB. The OS gets loaded through U-Boot via SD-Card. (It's quite easy to repair wrong kernel issues that way.)

The fact, that FreeBSD lists it under the armv6 directory made me wonder. AFAIK, there is no armv6 banana.

For symetric traffic shaping - will this patch be included in FreeBSD's upcoming mainline kernels?

Ok, let me repeat the procedure:
I'll get the FreeBSD 11.0 image first and put it on sdcard. Then I boot to FreeBSD and get the OPNsense bootstrap script from https://raw.githubusercontent.com/opnsense/update/master/bootstrap/opnsense-bootstrap.sh and execute it. Is that script the correct one (for 11.0?) or will it rather break things? In the end I put the mainline kernel back in place.
Title: Re: Helping with ARM support + recommended ARM hardware
Post by: franco on November 28, 2016, 08:07:15 am
opnsense-bootstrap only works for prebuilt packages, which we do not have for 11.0 ARM at this moment.

Strictly armv6 or not, if FreeBSD lists it there the chances for binary compatibility is high. I don't have a BPI to test though.
Title: Re: Helping with ARM support + recommended ARM hardware
Post by: freebee on December 02, 2016, 01:58:30 am
http://www.raspbsd.org/raspberrypi.html

I think this page can help.
Packages from 11x can work.

Glad to see this effort.
I can help with vms and hardware test.
Title: Re: Helping with ARM support + recommended ARM hardware
Post by: chemlud on December 02, 2016, 09:04:02 am
@franco

Which "BPI" would you need?

Do you mean a raspi 3? Currently available raspi 2 would be the same CPU w/o bluetooth and wifi, see above.
Title: Re: Helping with ARM support + recommended ARM hardware
Post by: franco on December 02, 2016, 06:33:06 pm
I have a PRI-B and a RPI2, but no BananaPi. The latter looks like a good target for us as it offers multiple devices and even has more network cards for the cool use cases.
Title: Re: Helping with ARM support + recommended ARM hardware
Post by: chemlud on December 02, 2016, 09:58:08 pm
BPI = Banana Pi, got it! :-D
Title: Re: Helping with ARM support + recommended ARM hardware
Post by: lattera on December 19, 2016, 08:22:40 pm
Great news: I've now fixed the arm64-specific code in the RTLD to work with clang/lld 3.9.1, opening the door for us to be able to investigate OPNsense on arm64.

Here's the commit: https://github.com/HardenedBSD/hardenedBSD/commit/8754ed86fff3f2f793d37fb71725630f720bbfb7

I'm working on getting this upstreamed: https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=214971

Within the next month or two, I'll start investigating running OPNsense on arm64 (starting with the RPI3) with HardenedBSD 12-CURRENT as the base source code.
Title: Re: Helping with ARM support + recommended ARM hardware
Post by: chemlud on December 19, 2016, 08:25:33 pm
...I don't understand a word what you're doing but this is great news! Merry Christmas! :-)
Title: Re: Helping with ARM support + recommended ARM hardware
Post by: tango38317 on December 20, 2016, 04:02:54 pm
Hi,
maybe its an alternative to rpi:

https://www.amazon.de/AllNet-BPI-R1-banana-Router-board/dp/B00O4F9NHS/ref=sr_1_1?ie=UTF8&qid=1482245489&sr=8-1&keywords=banana+pi+router

br
Title: Re: Helping with ARM support + recommended ARM hardware
Post by: lattera on December 20, 2016, 05:25:31 pm
Another update: Looks like lld is having issues with symbol versioning. I'm working with Ed Schouten and Ed Maste of the FreeBSD project to figure out a fix. Once this bug is fixed, then there should be no stopping someone from deploying OPNsense based on FreeBSD 12-CURRENT on an arm64 system.
Title: Re: Helping with ARM support + recommended ARM hardware
Post by: tsgan on December 26, 2016, 02:43:26 pm
Finally I was able to build OPNsense 17.1 for NanoPI NEO using FreeBSD stock head with some patches to core, ports and tools.
NanoPI NEO is small and very cheap ($8-$10) armv6 (Allwinner H3 SoC based) board which has quad core Cortex-A7 CPU and 256MB/512MB RAM, 1Gb ethernet and 3 USB host ports. I'm using USB ethernet as second, LAN interface.
I couldn't cross build, had several problems with building ports so I gave up.
Instead, I tried to build it natively on slow BananaPI M1 and Cubieboard2 board and succeeded after long trials and failures.
If someone wants to grab the image and try please let me know.
Title: Re: Helping with ARM support + recommended ARM hardware
Post by: franco on December 28, 2016, 03:15:34 pm
This is really cool! Providing the image/sets would be great. We can mirror them through the official channels marked "snapshots". :)
Title: Re: Helping with ARM support + recommended ARM hardware
Post by: tsgan on December 29, 2016, 05:08:11 pm
And it works on OrangePI Zero too :)
Where do you want me to upload/put the image?
Title: Re: Helping with ARM support + recommended ARM hardware
Post by: franco on December 29, 2016, 10:20:35 pm
Can you give me a location to pull from once? Any location that is convenient for you.
Title: Re: Helping with ARM support + recommended ARM hardware
Post by: tsgan on December 30, 2016, 06:48:48 am
It is here:

https://people.freebsd.org/~ganbold/opnsense/
Title: Re: Helping with ARM support + recommended ARM hardware
Post by: franco on December 30, 2016, 05:11:29 pm
It's on our mirrors now, e.g. https://pkg.opnsense.org/snapshots/OPNsense-201612260924-OpenSSL-nanopineo-armv6.img.bz2

Many thanks for providing this image! :)
Title: Re: Helping with ARM support + recommended ARM hardware
Post by: lattera on January 12, 2017, 02:55:05 am
I'll just leave this here:

(https://hardenedbsd.org/~shawn/2017-01-11%20rpi3%20clang%20400%2001.png)
Title: Re: Helping with ARM support + recommended ARM hardware
Post by: chemlud on October 30, 2017, 04:59:22 pm
...any advice on this? Would like to try somethink with raspi and a wifi WAN interface, tried it on the raspi 1 image of 16.x provided by Franco, but get a lot of

ieee80211_load module: load the wlan_ccmp module by hand for now

in the console and the wifi interface never get's the IP reserved in DHCP of the wifi access point it should contact...
Title: Re: Helping with ARM support + recommended ARM hardware
Post by: franco on October 30, 2017, 05:09:03 pm
I have two BPI devices now, so shifting over from RPI2, but not before end of November. I have a few days off for better or worse.


Cheers,
Franco
Title: Re: Helping with ARM support + recommended ARM hardware
Post by: chemlud on October 30, 2017, 05:22:28 pm
OK, but I don't have any Bananas on my little farm here... ;-)

Any news on OPNsense on Raspi 3?
Title: Re: Helping with ARM support + recommended ARM hardware
Post by: orangana on January 15, 2018, 11:46:57 am
Leave the bananas where they are... go with the orange!

recommended hardware: orange pi r1

(https://ae01.alicdn.com/kf/HTB10vanXlUSMeJjy1zkq6yWmpXaP/Orange-Pi-R1-H2-256MB-Quad-Core-Cortex-A7-Open-source-development-board-beyond-Raspberry-Pi.jpg_640x640.jpg)

(http://www.orangepi.org/images/Pi_R1_en.jpg)

but be aware! It costs $13,90 and there is no official opnsense available  :'(
Title: Re: Helping with ARM support + recommended ARM hardware
Post by: franco on January 15, 2018, 12:41:11 pm
But does it run FreeBSD? ;)
Title: Re: Helping with ARM support + recommended ARM hardware
Post by: orangana on January 15, 2018, 01:44:38 pm
But does it run FreeBSD? ;)

It should. The SoC used is a Allwinner H2+ (tecnically a H3 without video) and one page before someone released an image for a H3 SoC.

Quote
FreeBSD supports the following Allwinner SoCs:

    Allwinner A10 (sun4i), a single core Cortex-A8
    Allwinner A13/R8 (sun5i), a single core Cortex-A8
    Allwinner A20 (sun7i), a dual-core Cortex-A7
    Allwinner A31 and A31s (sun6i), a quad-core Cortex-A7
    Allwinner A64 (sun50i), a quad-core Cortex-A53
    Allwinner A83T (sun8i), an octa-core Cortex-A7
    Allwinner H3 (sun8i), a quad-core Cortex-A7

From: https://wiki.freebsd.org/FreeBSD/arm/Allwinner

And someone who builded FreeBSD: https://framkant.org/2017/07/running-freebsd-on-nanopi-neo-or-orangepi-zero/

It would be more than awesome to see these damn cheap and powerful devices supported by opnsense!  8)

Meanwhile there is a no go solution called zeroshell (Warning! Outdated kernel! Don't use this anywhere! And don't visit www.zeroshell.org)
Title: Re: Helping with ARM support + recommended ARM hardware
Post by: orangana on January 15, 2018, 02:42:32 pm
Maybe we should directly forward this to 18.1  ;D

...and do the tick for:

Quote
Future development*

The development team and users have some wishes
they'd like to see in one of the future releases.

  • ARM support
https://opnsense.org/about/road-map/ *slightly modified ::)
Title: Re: Helping with ARM support + recommended ARM hardware
Post by: monstermania on January 17, 2018, 08:37:33 am
Orange Pi
- the 2'nd Ethernet Port seems to be an USB2LAN-port (RTL8152B)
- only 256 MB RAM
- only 32 Bit CPU

Title: Re: Helping with ARM support + recommended ARM hardware
Post by: chemlud on January 17, 2018, 09:52:44 am
For the use of as a "personal firewall" (i.e. with your notebook/tablet while travelling) that would not be a show stopper for me. What counts as an opnsense for this purpose is a supported wifi device, openVPN, DNS (IDS/IPS would be nice, but not necessary, would not be feasible, I guess). Power supply from a USB-port or from a larger power bank.
Title: Re: Helping with ARM support + recommended ARM hardware
Post by: orangana on January 17, 2018, 11:34:44 am
Orange Pi
- the 2'nd Ethernet Port seems to be an USB2LAN-port (RTL8152B)
- only 256 MB RAM
- only 32 Bit CPU

This is what you get for $13,90. What do you offer for that price? Anything?

For the use of as a "personal firewall" (i.e. with your notebook/tablet while travelling) that would not be a show stopper for me. What counts as an opnsense for this purpose is a supported wifi device, openVPN, DNS (IDS/IPS would be nice, but not necessary, would not be feasible, I guess). Power supply from a USB-port or from a larger power bank.

Exactly the case. This device is has a typical power usage around 1W and is therefore the perfect device for travel and road warrior scenarios. But also the use at home should be more than fine. For Enterprise you should maybe invest a little more.. Maybe 10 to 100 times more....
Title: Re: Helping with ARM support + recommended ARM hardware
Post by: orangana on January 17, 2018, 02:58:52 pm
But does it run FreeBSD? ;)

It should. The SoC used is a Allwinner H2+ (tecnically a H3 without video) and one page before someone released an image for a H3 SoC.

Quote
FreeBSD supports the following Allwinner SoCs:

    Allwinner A10 (sun4i), a single core Cortex-A8
    Allwinner A13/R8 (sun5i), a single core Cortex-A8
    Allwinner A20 (sun7i), a dual-core Cortex-A7
    Allwinner A31 and A31s (sun6i), a quad-core Cortex-A7
    Allwinner A64 (sun50i), a quad-core Cortex-A53
    Allwinner A83T (sun8i), an octa-core Cortex-A7
    Allwinner H3 (sun8i), a quad-core Cortex-A7

From: https://wiki.freebsd.org/FreeBSD/arm/Allwinner

And someone who builded FreeBSD: https://framkant.org/2017/07/running-freebsd-on-nanopi-neo-or-orangepi-zero/

It would be more than awesome to see these damn cheap and powerful devices supported by opnsense!  8)
[...]

So the SoC is natively supported by FreeBSD. Is there any change to see a (beta) build of opnsense for the H3/H2+ SoC Family? Or is there any guide how to do this?

Thank'S & Greetings