debian experimental exim-daemon-heavy config
[exim.git] / test / scripts / 0000-Basic / 0286
... / ...
CommitLineData
1# max_rcpt and connection_max_messages (2x parallel)
2need_ipv4
3#
4# There are deliveries in parallel in this script, and the processes that
5# run in parallel may not finish in the same order on different hosts. (Indeed,
6# they always seem to finish in precisely the opposite orders on Linux and
7# FreeBSD.) For that reason, we do a hacked-up sort on the log file right at
8# the end, to ensure that the log lines are always in the same order.
9#
10exim -odq a b c d e f
11.
12****
13server PORT_S 2
14220 ESMTP
15EHLO
16250-OK
17250 HELP
18MAIL FROM:
19250 Sender OK
20RCPT TO:
21250 Recipient OK
22RCPT TO:
23250 Recipient OK
24DATA
25354 Send data
26.
27250 OK
28MAIL FROM:
29250 Sender OK
30RCPT TO:
31550 Recipient not OK
32QUIT
33250 OK
34*eof
35220 ESMTP
36EHLO
37250-OK
38250 HELP
39MAIL FROM:
40250 Sender OK
41RCPT TO:
42550 Recipient not OK
43RCPT TO:
44250 Recipient OK
45DATA
46354 Send data
47.
48250 OK
49MAIL FROM:
50250 Sender OK
51RCPT TO:
52250 Recipient OK
53DATA
54354 Send data
55.
56250 OK
57QUIT
58250 OK
59****
60exim -q
61****
62exim -q
63****
64exim -odq a b c d e f g h
65.
66****
67server PORT_S 2
68220 ESMTP
69EHLO
70250-OK
71250 HELP
72MAIL FROM:
73250 Sender OK
74RCPT TO:
75550 Recipient not OK
76RCPT TO:
77550 Recipient not OK
78RSET
79250 OK
80MAIL FROM:
81250 Sender OK
82RCPT TO:
83250 Recipient OK
84RCPT TO:
85250 Recipient OK
86DATA
87354 Send data
88.
89250 OK
90QUIT
91250 OK
92*eof
93220 ESMTP
94EHLO
95250-OK
96250 HELP
97MAIL FROM:
98250 Sender OK
99RCPT TO:
100550 Recipient not OK
101RCPT TO:
102550 Recipient not OK
103RSET
104250 OK
105MAIL FROM:
106250 Sender OK
107RCPT TO:
108250 Recipient OK
109RCPT TO:
110250 Recipient OK
111DATA
112354 Send data
113.
114250 OK
115QUIT
116250 OK
117****
118exim -q
119****
120exim -q
121****
122# This is the hack to sort the log lines. Search for groups of delivery log
123# lines (**, =>, and -> lines), and sort them according to the local part of
124# the address.
125#
126sudo perl
127open(IN, "DIR/spool/log/mainlog") ||
128 die "Can't open DIR/spool/log/mainlog: $!\n";
129@lines = <IN>;
130close(IN);
131
132for ($i = 0; $i < @lines; $i++)
133 {
134 next unless $lines[$i] =~ / \*\* | => | -> /;
135 for ($j = $i + 1; $j < @lines; $j++)
136 { last if $lines[$j] !~ / \*\* | => | -> /; }
137
138 @sublist = splice @lines, $i, $j - $i;
139 @sublist = sort {
140 my($x) = $a =~ /(?: \*\* | => | -> )([^@]+)/;
141 my($y) = $b =~ /(?: \*\* | => | -> )([^@]+)/;
142 return $x cmp $y;
143 } @sublist;
144
145 splice @lines, $i, 0, @sublist;
146 $i = $j;
147 }
148
149open (OUT, ">DIR/spool/log/mainlog") ||
150 die "Can't open DIR/spool/log/mainlog: $!\n";
151print OUT @lines;
152close(OUT);
153****