logging

All posts tagged logging

Modifications to the SWAT setup are as follows:

Install OpenSSL.

Generate certificate and private key.

root# /usr/bin/openssl req -new -x509 -days 365 -nodes -config \
/usr/share/doc/packages/stunnel/stunnel.cnf \
-out /etc/stunnel/stunnel.pem -keyout /etc/stunnel/stunnel.pem

Remove SWAT entry from [x]inetd.

Start stunnel.

root# stunnel -p /etc/stunnel/stunnel.pem -d 901 \
-l /usr/local/samba/bin/swat swat

Afterward, simply connect to SWAT by using the URL https://myhost:901, accept the certificate, and the SSL connection is up.

dnscache ang logwatch

There are no translations available.

 

This page is written to explain how to integrate logwatch and dnscache, a component of djbdns.

First, download the logwatch script to your server:

cd /usr/share/logwatch/scripts/services/
wget http://www.cypress-systems.net/scripts/dnscache
chmod 755 dnscache

Second, edit the script to tell logwatch where the logfile is looking for

vim /usr/share/logwatch/default.conf/services/dnscache.conf

Title = “dnscache”
LogFile = dnscache
# vi: shiftwidth=3 tabstop=3 et

 

Third, tell logwatch where the logs are exactly stored

vim /usr/share/logwatch/default.conf/logfiles/dnscache.conf

LogFile = /service/dnscache/log/main/@*.s
LogFile = /service/dnscache/log/main/current
# Keep only the lines in the proper date range…
*applytaidate
# vi: shiftwidth=3 tabstop=3 et

 

Four, run a test to see if there is any output

logwatch –service dnscache –range today –detail 10 –output stdout