inverse-inc / packetfence

PacketFence is a fully supported, trusted, Free and Open Source network access control (NAC) solution. Boasting an impressive feature set including a captive-portal for registration and remediation, centralized wired and wireless management, powerful BYOD management options, 802.1X support, layer-2 isolation of problematic devices; PacketFence can be used to effectively secure networks small to very large heterogeneous networks.
https://packetfence.org
GNU General Public License v2.0
1.39k stars 291 forks source link

PF 14.0 Cluster pfcmd fixpermissions file, Warnings when syncing files #8308

Open PeriklisZisis opened 2 months ago

PeriklisZisis commented 2 months ago

Describe the bug Cluster with 3 nodes. When running the command /usr/local/pf/bin/cluster/sync --as-master on the "master" node , the command finishes with no error. However on the other 2 nodes there are warnings like :

pf2 httpd.webservices-docker-wrapper[1050842]: httpd.webservices(4954) WARN: [mac:unknown] Problem trying to run command: sudo PF_GID=995 PF_UID=996 /usr/local/pf/bin/pfcmd fixpermissions file /usr/local/pf/conf/security_events.conf called from fix_file_permissions. Child exited with non-zero value 1 (pf::util::safe_pf_run)

pf2 httpd.webservices-docker-wrapper[1050842]: httpd.webservices(4954) INFO: [mac:unknown] Successfully downloaded configuration /usr/local/pf/conf/security_events.conf from pf1 (pf::api::notify_configfile_changed)

The files are getting synced eventually, however there is this warning for each of the files that getting synced.

When running the command manually : sudo PF_GID=995 PF_UID=996 /usr/local/pf/bin/pfcmd fixpermissions file /usr/local/pf/conf/security_events.conf The output is the expected one : Fixed permissions on file /usr/local/pf/conf/security_events.conf

To Reproduce Steps to reproduce the behavior:

  1. Go to master node and run /usr/local/pf/bin/cluster/sync --as-master
  2. Check packetfence.log on the other 2 nodes

Expected behavior No warnings