summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--templates/syslog-ng.conf_lenny.erb6
-rw-r--r--templates/syslog-ng.conf_squeeze.erb10
2 files changed, 10 insertions, 6 deletions
diff --git a/templates/syslog-ng.conf_lenny.erb b/templates/syslog-ng.conf_lenny.erb
index 0e5a91d..9393e68 100644
--- a/templates/syslog-ng.conf_lenny.erb
+++ b/templates/syslog-ng.conf_lenny.erb
@@ -47,7 +47,9 @@ destination df_facility_dot_crit { file("/var/log/$FACILITY.crit"); };
############################################################
## generic filters
+# strip IP addresses
filter f_strip { strip(ips); };
+
filter f_at_least_info { level(info..emerg); };
filter f_at_least_notice { level(notice..emerg); };
filter f_at_least_warn { level(warn..emerg); };
@@ -221,7 +223,7 @@ destination df_errors { file("/var/log/errors.log"); };
log {
source(s_all);
filter(f_errors);
- filter(f_strip);
+ filter(f_strip);
destination(df_errors);
};
@@ -233,7 +235,7 @@ destination du_all { usertty("*"); };
log {
source(s_all);
filter(f_emerg);
- filter(f_strip);
+ filter(f_strip);
destination(du_all);
};
diff --git a/templates/syslog-ng.conf_squeeze.erb b/templates/syslog-ng.conf_squeeze.erb
index 0576ea1..39cec76 100644
--- a/templates/syslog-ng.conf_squeeze.erb
+++ b/templates/syslog-ng.conf_squeeze.erb
@@ -48,7 +48,9 @@ destination df_facility_dot_crit { file("/var/log/$FACILITY.crit"); };
############################################################
## generic filters and rewrites
+# strip IP addresses
rewrite r_strip {subst("(25[0-5]|2[0-4][0-9]|[0-1]?[0-9]?[0-9])([\\.\\-](25[0-5]|2[0-4][0-9]|[0-1]?[0-9]?[0-9])){3}", "0.0.0.0", value("MESSAGE"), flags("global"));};
+
filter f_at_least_info { level(info..emerg); };
filter f_at_least_notice { level(notice..emerg); };
filter f_at_least_warn { level(warn..emerg); };
@@ -111,7 +113,7 @@ destination d_sympa { file("/var/log/sympa.log"); };
log {
source(s_all);
filter(f_sympa);
- rewrite(r_strip);
+ rewrite(r_strip);
destination(d_sympa);
flags(final);
};
@@ -137,7 +139,7 @@ destination d_ldap { file("/var/log/ldap.log"); };
log {
source(s_all);
filter(f_ldap);
- rewrite(r_strip);
+ rewrite(r_strip);
destination(d_ldap);
flags(final);
};
@@ -222,7 +224,7 @@ destination df_errors { file("/var/log/errors.log"); };
log {
source(s_all);
filter(f_errors);
- rewrite(r_strip);
+ rewrite(r_strip);
destination(df_errors);
};
@@ -234,7 +236,7 @@ destination du_all { usertty("*"); };
log {
source(s_all);
filter(f_emerg);
- rewrite(r_strip);
+ rewrite(r_strip);
destination(du_all);
};