Q: configuring server template, log paths

i’m going to rebuild my server using AlmaLinux, the latest Virtualmin, and CSF

i could use some help understanding how log file paths in the default server template correlate to those in csf.generic.conf (copied to /etc/csf/csf.conf upon CSF install)

the Virtualmin default server template contains…
ErrorLog /var/log/virtualmin/${DOM}_error_log

and csf.generic.conf contains…

HTACCESS_LOG = "/var/log/httpd/error_log"
MODSEC_LOG = "/var/log/httpd/error_log"
...

i want to alter the CSF log paths to jive with those in the default server template, but it seems it might not be as simple as changing /var/log/httpd/error_log to /var/log/virtualmin/example.com_error_log given that there’s more than one error_log ( /var/log/apache2/error_log (ubuntu), /var/log/virtualmin/<domain.tld>_error_log )

lastly, in the default server template there is …
CustomLog /var/log/virtualmin/${DOM}_access_log combined
and in the CSF conf file there are several …
CUSTOM1_LOG = "/var/log/customlog"

what needs to be done with this?

Although I am not familiar with CSF, in Fail2Ban I use the following paths and it works.

"/var/log/virtualmin/*_error_log"

"/var/log/virtualmin/*_access_log"
1 Like