OPNsense Forum

Archive => 17.7 Legacy Series => Topic started by: yogo on December 12, 2017, 12:16:22 pm

Title: [SOLVED] Captive Portal isn't working after Upgrade to 17.7.9
Post by: yogo on December 12, 2017, 12:16:22 pm
Hi,

after upgrading from 17.7.8 to 17.7.9_8 and/or 17.7.9_9 my Captive Portal isn't working anymore.
Behavior: User connects to CP, after a while connection timed out. No Authentication Window. Setup was fully working for month. Used this Guide: https://wiki.opnsense.org/manual/how-tos/guestnet.html

It seems to me like lighttpd doesn't work correctly.

I can't see any errors in System-Log.

Greets, Yogo.
Title: Re: Captive Portal isn't working after Upgrade to 17.7.9
Post by: franco on December 12, 2017, 05:13:23 pm
Hi there,

Known issue, try this for now:

# opnsense-revert -r 17.7.8 lighttpd

And restart your CP services.


Cheers,
Franco
Title: Re: Captive Portal isn't working after Upgrade to 17.7.9
Post by: gothbert on December 12, 2017, 08:26:29 pm
Well, there is the answer before I asked the question  ;D

Downgrade works for me.
Title: Re: Captive Portal isn't working after Upgrade to 17.7.9
Post by: yogo on December 12, 2017, 09:03:17 pm
Downgrade helped me too.
I just read the Issue #1990: https://github.com/opnsense/core/issues/1990

I can confirm this error:

Code: [Select]
/usr/local/sbin/lighttpd  -f /var/etc/lighttpd-cp-zone-0.conf
daemonized server failed to start; check error log for details


Thanks for your fast help.
Title: Re: Captive Portal isn't working after Upgrade to 17.7.9
Post by: franco on December 12, 2017, 11:21:16 pm
Thanks for the report!

The bottom of this is: lighttpd 1.4.45 was used until 17.7.8, then FreeBSD updated to 1.4.48 which shows this odd behaviour. The behaviour, however, dates back as far as 1.4.46 and seems to be caused by devfs not being mounted properly inside the chroot directory, where lighttpd tries to find /dev/null but fails, which wasn't the case on versions lower than 1.4.46.

Very hard to debug within the code as logging is apparently off and the daemon uses a pipe to pass information up and down the (grand)child running in the chroot directory...  :o

We'll have this fixed in 17.7.10 for sure.


Cheers,
Franco
Title: Re: Captive Portal isn't working after Upgrade to 17.7.9
Post by: jon.alf on December 13, 2017, 03:19:19 am
This is good to know. I was beginning to wonder if it was caused, in my case, by a witches' brew of MultiWAN, VLANs, VMs, and a dash of proxmox
Title: Re: Captive Portal isn't working after Upgrade to 17.7.9
Post by: franco on December 13, 2017, 08:24:20 am
Sorry, it was quite late...  :)
Title: Re: Captive Portal isn't working after Upgrade to 17.7.9
Post by: franco on December 13, 2017, 11:52:12 am
So here is the commit and all help to confirm this for swift 17.7.10 inclusion this week is appreciated! :)

https://github.com/opnsense/core/commit/ac6a1ef8c

# opnsense-revert lighttpd
# opnsense-patch ac6a1ef

And apply from the captive portal page.


Cheers,
Franco
Title: Re: Captive Portal isn't working after Upgrade to 17.7.9
Post by: gothbert on December 13, 2017, 01:32:33 pm
Hi,

I found it is working after executing the commands and button click you listed. I found that it keeps functioning after a reboot.

Thank you for making it work again!

Kind regards
Boris
Title: Re: Captive Portal isn't working after Upgrade to 17.7.9
Post by: franco on December 13, 2017, 01:42:41 pm
Hi Boris,

Splendid, many thanks for the quick feedback!


Cheers,
Franco
Title: Re: Captive Portal isn't working after Upgrade to 17.7.9
Post by: yogo on December 13, 2017, 03:07:50 pm
Hi Franco,

# opnsense-revert lighttpd
# opnsense-patch ac6a1ef

And apply from the captive portal page.
Reboot (like Boris wrote)

=> Clean Start of lighttpd!

Works!

Kind regards
Jörg
Title: Re: [SOLVED] Captive Portal isn't working after Upgrade to 17.7.9
Post by: franco on December 13, 2017, 04:51:08 pm
Hi Jörg et al,

Thanks again, we've added this fix for 17.7.10 tomorrow. :)


Cheers,
Franco