--- qmailmrtg7.c 2004-11-05 17:37:11.000000000 +0100 +++ qmailmrtg7.c 2008-06-24 15:59:16.000000000 +0200 @@ -35,6 +35,7 @@ int success; int failure; int deferral; +int authreq, authreqe; int unsub; double bytes; int local; @@ -76,6 +77,7 @@ case 't': case 'a': case 'm': + case 'n': case 'c': case 's': case 'S': @@ -104,6 +106,8 @@ success = 0; failure = 0; deferral = 0; + authreq = 0; + authreqe = 0; bytes = 0; local = 0; remote = 0; @@ -162,6 +166,11 @@ case 'C': printf("%i\n%i\n\n\n",cfound*12,cerror*12); break; + + /* auth required */ + case 'n': + printf("%d\n%d\n\n\n",authreq,authreqe); + break; /* tcpserver concurrency */ case 't': @@ -267,6 +276,10 @@ ++cerror; } break; + + case 'n': + if ((tmpstr1 = strstr(TmpBuf, " authrequired:"))!=NULL) authreq++; + break; case 't': if ((tmpstr1 = strstr(TmpBuf, "status:"))!=NULL) { @@ -317,7 +330,7 @@ case 'R': if(strstr(TmpBuf,"success:")) success++; if(strstr(TmpBuf,"failure:")) failure++; - if(strstr(TmpBuf,"deferral:")) deferral++; + if(strstr(TmpBuf,"deferral:")) deferral++; break; case 'v': @@ -378,7 +391,7 @@ void usage() { printf("usage: type dir\n"); - printf("where type is one of t, a, m, c, s, b, q, r, R, l, v, S, C, Q\n"); + printf("where type is one of t, a, m, n, c, s, b, q, r, R, l, v, S, C, Q\n"); printf("and dir is a directory containing multilog files\n"); printf("for q option dir is the qmail queue dir\n"); } --- qmail.mrtg.cfg 2008-06-24 16:09:55.000000000 +0200 +++ qmail.mrtg.cfg 2008-06-24 16:07:30.000000000 +0200 @@ -52,6 +52,23 @@ #------------------------------------------------------------------- +Title[authreq]: authrequired - FQDN +MaxBytes[authreq]: 10000 +AbsMax[authreq]: 100000 +Options[authreq]: gauge +Target[authreq]: `/usr/local/bin/qmailmrtg7 n /var/log/qmail/smtpd` +PageTop[authreq]: FQDN AUTH Required
+ShortLegend[authreq]: Msg +YLegend[authreq]: viri/hour +Legend1[authreq]: rejected NON AUTH  +LegendI[authreq]: reject  +LegendO[authreq]: errors:  +WithPeak[authreq]: ymwd +XSize[authreq]: 350 +YSize[authreq]: 150 + +#------------------------------------------------------------------- + Title[spamd]: spamd - FQDN MaxBytes[spamd]: 10000 AbsMax[spamd]: 100000