Timestamp problem when running --debug-sa

Jeff A. Earickson jaearick at colby.edu
Mon Apr 7 21:53:57 IST 2008


Hi,

I played with this on Friday, by fiddling with check_mailscanner.sh
and changing the PATH and AWK definitions there.  My GNU gawk is
in /usr/local/bin so I put that in the path first.  I use Solaris
10 (sparc) too.

I got debug mode to work with timestamps from gawk, but version
4.68.8 would just hang in the middle of a debug run with gawk
in play.  :(  Haven't had time to chase it further.

Yes, I would like this working for Solaris as well.

Jeff Earickson
Colby College

On Mon, 7 Apr 2008, shuttlebox wrote:

> Date: Mon, 7 Apr 2008 16:30:05 +0200
> From: shuttlebox <shuttlebox at gmail.com>
> Reply-To: MailScanner discussion <mailscanner at lists.mailscanner.info>
> To: MailScanner discussion <mailscanner at lists.mailscanner.info>
> Subject: Timestamp problem when running --debug-sa
> 
> I tried the new timestamp feature in --debug-sa introduced in 4.67 and
> it complained about awk not supporting strftime, I kind of expected
> that since Solaris comes with a legacy awk in /bin. I installed gawk
> and it's in my path as can be seen below:
>
> # which awk
> /bin/awk
> # which gawk
> /opt/csw/bin/gawk
>
> I then changed the two awk calls in SA.pm to gawk but still got this:
>
> # MailScanner --debug --debug-sa
> In Debugging mode, not forking...
> Trying to setlogsock(udp)
> sh: gawk: not found
>
> *****
> If 'awk' (with support for the function strftime) was
> available on your $PATH then all the SpamAssassin debug
> output would have the current time added to the start of
> every line, making debugging far easier.
> *****
>
> I assume MailScanner uses some short custom path even though it claims
> that it would work if I had gawk in my path which I do. If I hardcode
> the complete path to my gawk (opt/csw/bin/gawk) I get the correct
> result:
>
> # MailScanner --debug --debug-sa
> In Debugging mode, not forking...
> Trying to setlogsock(udp)
> 16:17:44 SpamAssassin temp dir =
> /var/spool/MailScanner/incoming/SpamAssassin-Temp
>
> On a single system this could simply be solved by symlinking old awk
> to new gawk but I would like a "clean" solution for my Solaris
> packages, I will of course have to add gawk as a dependency to
> MailScanner but should I just change the paths in SA.pm for my package
> (that will have to be done for every release) or should MS look for
> awk/gawk in more places or should we have a new config option for the
> location of awk?
>
> I'm fine with me changing the paths for every release, I have a
> totally automated build script, but I'm a little surprised that no one
> else has had problems. I guess most have GNU tools as the default...
>
> -- 
> /peter
> -- 
> MailScanner mailing list
> mailscanner at lists.mailscanner.info
> http://lists.mailscanner.info/mailman/listinfo/mailscanner
>
> Before posting, read http://wiki.mailscanner.info/posting
>
> Support MailScanner development - buy the book off the website!
>


More information about the MailScanner mailing list