Netgate SG-1000 microFirewall

Author Topic: apu2 led control?  (Read 2338 times)

0 Members and 1 Guest are viewing this topic.

Offline xbipin

  • Hero Member
  • *****
  • Posts: 1631
  • Karma: +6/-0
    • View Profile
apu2 led control?
« on: May 06, 2017, 10:44:20 am »
on older alix i could turn off the front leds, is there any way to do the same for apu2?

Offline doktornotor

  • Hero Member
  • *****
  • Posts: 8553
  • Karma: +962/-278
  • Not a pfSense employee, they cannot fire me...
    • View Profile
Re: apu2 led control?
« Reply #1 on: May 06, 2017, 12:57:55 pm »
Do NOT PM for help!

Offline xbipin

  • Hero Member
  • *****
  • Posts: 1631
  • Karma: +6/-0
    • View Profile
Re: apu2 led control?
« Reply #2 on: May 06, 2017, 02:56:47 pm »
Ok so it seems it's going to take a while to end up in pfsense, btw is it ever possible to turn off the led on the nics, not that I have seen any system do that so far but just curious.

The other issue I'm having is I installed the full 2.4 on the apu2 and the bios is set to 115200 as well as pfsense but just the part when pfsense boots and gives option for single user mode etc, it comes all messed up so can't figure out a way to enable trim on the ssd as it needs going to single user mode.

Offline doktornotor

  • Hero Member
  • *****
  • Posts: 8553
  • Karma: +962/-278
  • Not a pfSense employee, they cannot fire me...
    • View Profile
Re: apu2 led control?
« Reply #3 on: May 07, 2017, 03:41:45 am »
That's a BIOS bug. Try with 4.0.7 (or the experimental 4.5.5).

P.S. Trim in enabled by default on ZFS, so not really sure whether the messing is worth the time.
Do NOT PM for help!

Offline xbipin

  • Hero Member
  • *****
  • Posts: 1631
  • Karma: +6/-0
    • View Profile
Re: apu2 led control?
« Reply #4 on: May 07, 2017, 03:58:31 am »
im on the 4.0.7 already and its happening there only.

well during install i selected UFS so is it recommended to use UFS or ZFS, i read that UFS has a bunch of issues. Im currently using RAM disk for /var and /tmp on UFS currently

Offline doktornotor

  • Hero Member
  • *****
  • Posts: 8553
  • Karma: +962/-278
  • Not a pfSense employee, they cannot fire me...
    • View Profile
Re: apu2 led control?
« Reply #5 on: May 07, 2017, 08:32:47 am »
Definitely ZFS for me. Way too many boxes already bricked with UFS filesystem corruption that's unfixable with the broken fsck tool.

P.S. For sure cannot confirm that the console corruption is 4.0.7-only issue. Reported pretty much since the very beginning on PC Engines forums with various coreboot versions.
Do NOT PM for help!

Offline xbipin

  • Hero Member
  • *****
  • Posts: 1631
  • Karma: +6/-0
    • View Profile
Re: apu2 led control?
« Reply #6 on: May 07, 2017, 11:00:48 am »
but does zfs need 2 storage devices, i just have the msata inside it and no plans to add a second

Offline Jailer

  • Sr. Member
  • ****
  • Posts: 413
  • Karma: +54/-2
    • View Profile
    • Bored Guy Blog
Re: apu2 led control?
« Reply #7 on: May 07, 2017, 12:56:38 pm »
Nope.

Offline xbipin

  • Hero Member
  • *****
  • Posts: 1631
  • Karma: +6/-0
    • View Profile
Re: apu2 led control?
« Reply #8 on: May 07, 2017, 02:40:37 pm »
Well I don't run any package other than cron and I have the var and tmp in ram disk so what difference does it anyways make using ufs or zfs coz on power failure it isn't going to corrupt anyways right?

For ppl using squid etc they would definitely benefit coz I had just one instance of a full install corrupting due to power failure

Offline doktornotor

  • Hero Member
  • *****
  • Posts: 8553
  • Karma: +962/-278
  • Not a pfSense employee, they cannot fire me...
    • View Profile
Re: apu2 led control?
« Reply #9 on: May 07, 2017, 06:03:01 pm »
Well I don't run any package other than cron and I have the var and tmp in ram disk so what difference does it anyways make using ufs or zfs coz on power failure it isn't going to corrupt anyways right?

Actually, yes, it is going to corrupt. Most often corruption happens with /etc. UFS == junk.
Do NOT PM for help!

Offline xbipin

  • Hero Member
  • *****
  • Posts: 1631
  • Karma: +6/-0
    • View Profile
Re: apu2 led control?
« Reply #10 on: May 08, 2017, 01:29:12 am »
ok i formatted to ZFS now, i have the /tmp and /var in RAM disk, how do i check TRIM status? (/tmp /var shows using UFS when in RAM disk, and isnt SWAP supposed to be disabled, is this fine?)

Offline steve_v

  • Newbie
  • *
  • Posts: 7
  • Karma: +1/-1
    • View Profile
Re: apu2 led control?
« Reply #11 on: May 11, 2017, 04:39:53 am »
2.4 running pretty smoothly on my APU2C4, with some (presumably benign) complaints from the bootloader:
Code: [Select]
gptzfsboot: error 12 lba 32
gptzfsboot: error 12 lba 7710712
gptzfsboot: error 12 lba 1

ZFS working nicely (bonus, a use for the  4GB of ECC RAM on this board), hopefully no more hosed filesystems...


To return to the OT,  the led driver mentioned above works just fine in 2.4, as does gwled. Here's a precompiled .ko for the lazy.

However...

The current blinkled binary segfaults, at least for me. Anyone else getting this?

Offline xbipin

  • Hero Member
  • *****
  • Posts: 1631
  • Karma: +6/-0
    • View Profile
Re: apu2 led control?
« Reply #12 on: May 11, 2017, 05:08:33 am »
thanks for the info, could u kindly mention how to install this ko file or how to compile the one mentioned on https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=189772 as it seems perfect for the job?

Offline steve_v

  • Newbie
  • *
  • Posts: 7
  • Karma: +1/-1
    • View Profile
Re: apu2 led control?
« Reply #13 on: May 11, 2017, 06:05:49 am »
thanks for the info, could u kindly mention how to install this ko file or how to compile the one mentioned on https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=189772 as it seems perfect for the job?
Download the attached apuled.ko.gz (compiled for FreeBSD 11) and put it somewhere on your pfsense box (e.g. /root/), then:
Decompress
Code: [Select]
gunzip apuled.ko.gzLoad
Code: [Select]
kldload /root/apuled.koYou can then set the kldload command to run at startup.

There's probably a better way to include it in pfsense, but this lazy method works just fine. ;)

To compile it yourself:
Install FreeBSD (10 for pfsense 2.3.x, 11 for 2.4) in a VM.
Install the matching kernel sources.
Download and unpack apuled.tgz from the bug report (and optionally the updated apuled.c for APU3 support).
Run 'make' in the directory containing apuled.c and Makefile.
Rename produced 'apuled.o' to 'apuled.ko'.
Copy to pfsense and load as above.
« Last Edit: May 11, 2017, 06:11:44 am by steve_v »

Offline xbipin

  • Hero Member
  • *****
  • Posts: 1631
  • Karma: +6/-0
    • View Profile
Re: apu2 led control?
« Reply #14 on: May 11, 2017, 07:03:54 am »
for testing i copied the ko file to /boot/modules and then load it using loader.conf and it works fine.

i noticed the /dev/led folder has igb0-1, are those to disable the nic leds or something else?