Skip to content

PFSense machine disappears #127

@georgejung

Description

@georgejung

Hi all,

Thanks for this great work I have been using it to help secure my VPS and homelab and its been working great, with one exception. I don't think this is related to my vps but I have one using pangolin to communicate with my homelab.

At home i'm running pfsense on bare metal, no ram disk, v 2.8.2 community edition with the latest verion of crowdsec as i just installed it on pfsense a few weeks ago. I have my LAPI on this machine and have set lapi host to be the pfsense ip on my lan and a custom port.
Behind this is my server and i have crowdsec running in a ubuntu vm as a docker container, along with my traefik and authelia docker containers.

It seems like when things restart/reload, specifically the wan interface, the pfsense machine drops off crowdsec. The pfsense box itself stays powered on the entire time, it is not rebooting.
adding cscli machines add pfsense --auto --force fixes it right away.
As a result I setup a cron job to check and do the reload:
cscli machines list | grep -q pfsense || (cscli machines add pfsense --auto --force && service crowdsec onerestart) >> /var/log/crowdsec-cron.log 2>&1

The other machines (traefik agent and crowdsec-web-ui) are always there, its just the pfsense machine that drops off from crowdsec.

I did change ISPs recently and was using PPPoe and now DHCP (the WAN_PPPOE is just a legacy name, i deleted all pppoe and the vlan interfaces) and it seems to be happening more regularly, about once a day, though it happened before as well. I'll try to keep track of the logs of when cron is actually kicking in. here is an example of the system log around the time i think it happened. I typically this kind of thing in the log around the time that it seems to go down. Now with the cron i will be able to match to confirm the time it drops.

Apr 18 11:17:00 pfSense check_reload_status[486]: updating dyndns WAN_PPPOE
Apr 18 11:17:00 pfSense check_reload_status[486]: Restarting IPsec tunnels
Apr 18 11:17:00 pfSense check_reload_status[486]: Restarting OpenVPN tunnels/interfaces
Apr 18 11:17:00 pfSense check_reload_status[486]: Reloading filter
Apr 18 11:18:00 pfSense check_reload_status[486]: Linkup starting igb0

It seems similar to these issues though they are older
#84
#90

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions