1# The client writes a message to Sys::Syslog native method.
2# The syslogd writes into duplicate files depending on program and hostname.
3# The syslogd writes it into a file and through a pipe.
4# The syslogd passes it via UDP to the loghost.
5# The server receives the message on its UDP socket.
6# Find the message in client, file, pipe, syslogd, server log.
7# Check that the message exaclty appears in the files allowed by both blocks.
8
9use strict;
10use warnings;
11
12our %args = (
13    syslogd => {
14	conf => <<'EOF',
15!nonexist
16+nonexist
17*.*	$objdir/file-0.log
18*.*	$objdir/file-1.log
19*.*	$objdir/file-2.log
20*.*	$objdir/file-3.log
21!syslogd-regress
22*.*	$objdir/file-1.log
23*.*	$objdir/file-2.log
24*.*	$objdir/file-4.log
25*.*	$objdir/file-5.log
26+$host
27*.*	$objdir/file-2.log
28*.*	$objdir/file-3.log
29*.*	$objdir/file-5.log
30*.*	$objdir/file-6.log
31EOF
32    },
33    # exactly the files in the last block get the log message
34    multifile => [
35	{ loggrep => { get_testgrep() => 0 } },
36	{ loggrep => { get_testgrep() => 0 } },
37	{ loggrep => { get_testgrep() => 1 } },
38	{ loggrep => { get_testgrep() => 1 } },
39	{ loggrep => { get_testgrep() => 0 } },
40	{ loggrep => { get_testgrep() => 1 } },
41	{ loggrep => { get_testgrep() => 1 } },
42    ],
43);
44
451;
46