mirror of
https://gitlab.com/shorewall/code.git
synced 2024-11-23 08:03:11 +01:00
Another tweak to LOG_BACKEND
Signed-off-by: Tom Eastep <teastep@shorewall.net>
This commit is contained in:
parent
540eff24aa
commit
520d21c056
@ -352,13 +352,12 @@ sub setup_interface_proc( $ ) {
|
||||
sub setup_log_backend($) {
|
||||
if ( my $setting = $config{LOG_BACKEND} ) {
|
||||
my $family = shift;
|
||||
my $file = '/proc/net/netfilter/nf_log';
|
||||
my $ctl = 'net.netfilter.nf_log.' . ( $family == F_IPV4 ? '2' : '10' );
|
||||
my $file = '/proc/sys/net/netfilter/nf_log/' . ( $family == F_IPV4 ? '2' : '10' );
|
||||
|
||||
emit( 'progress_message2 "Setting up log backend"',
|
||||
'',
|
||||
"if [ -f $file ]; then",
|
||||
" if sysctl $ctl=$setting; then",
|
||||
" if echo $setting > $file; then",
|
||||
" progress_message 'Log Backend set to $setting'",
|
||||
' else',
|
||||
" error_message 'WARNING: Unable to set log backend to $setting'",
|
||||
|
Loading…
Reference in New Issue
Block a user