/[smeserver]/rpms/e-smith-qmail/sme8/e-smith-qmail-2.2.0-Concurrency.patch
ViewVC logotype

Contents of /rpms/e-smith-qmail/sme8/e-smith-qmail-2.2.0-Concurrency.patch

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph


Revision 1.1 - (show annotations) (download)
Sat Jun 29 18:13:34 2013 UTC (11 years, 4 months ago) by wellsi
Branch: MAIN
CVS Tags: e-smith-qmail-2_2_0-11_el5_sme, HEAD
* Sat Jun 29 2013 Ian Wells <esmith@wellsi.com> 2.2.0-11.sme
- Simplify qmail concurrency templates[SME: 7718]

1 diff -ruN e-smith-qmail-2.2.0.old/root/etc/e-smith/templates/var/qmail/control/concurrencylocal e-smith-qmail-2.2.0/root/etc/e-smith/templates/var/qmail/control/concurrencylocal
2 --- e-smith-qmail-2.2.0.old/root/etc/e-smith/templates/var/qmail/control/concurrencylocal 2006-01-10 23:04:56.000000000 -0800
3 +++ e-smith-qmail-2.2.0/root/etc/e-smith/templates/var/qmail/control/concurrencylocal 2013-06-29 10:57:34.000000000 -0700
4 @@ -1 +1 @@
5 -10
6 +{ $DB->get('qmail')->prop('ConcurrencyLocal') || "20"; }
7 diff -ruN e-smith-qmail-2.2.0.old/root/etc/e-smith/templates/var/qmail/control/concurrencyremote e-smith-qmail-2.2.0/root/etc/e-smith/templates/var/qmail/control/concurrencyremote
8 --- e-smith-qmail-2.2.0.old/root/etc/e-smith/templates/var/qmail/control/concurrencyremote 2006-01-10 23:04:56.000000000 -0800
9 +++ e-smith-qmail-2.2.0/root/etc/e-smith/templates/var/qmail/control/concurrencyremote 2013-06-29 10:57:38.000000000 -0700
10 @@ -1,34 +1 @@
11 -{
12 - return $qmail{ConcurrencyRemote} if defined $qmail{ConcurrencyRemote};
13 -
14 - my $concurrencyRemote = 20;
15 -
16 - open(MEMINFO, "/proc/meminfo") || die "Couldn't read meminfo: $!";
17 -
18 - my $line;
19 -
20 - while ( $line = <MEMINFO> )
21 - {
22 - if ( $line =~ /^MemTotal:\s+(\d+)\s+/ )
23 - {
24 - my $memTotal = $1;
25 -
26 - if ( $memTotal <= 16384 )
27 - {
28 - $concurrencyRemote = 2;
29 - }
30 - elsif ( $memTotal <= 32768 )
31 - {
32 - $concurrencyRemote = 4;
33 - }
34 - else
35 - {
36 - $concurrencyRemote = 20;
37 - }
38 -
39 - last;
40 - }
41 - }
42 -
43 - $concurrencyRemote;
44 -}
45 +{ $DB->get('qmail')->prop('ConcurrencyRemote') || "20"; }

admin@koozali.org
ViewVC Help
Powered by ViewVC 1.2.1 RSS 2.0 feed